Kambites helpers

This page contains the documentation for various helper functions for manipulating Kambites objects.

Contents

non_trivial_classes(…)

Find the non-trivial classes in the partition of a list of words.

normal_forms(…)

Returns an iterator yielding normal forms.

partition(…)

Partition a list of words.

Full API

This page contains the documentation for the kambites subpackage, that contains helper functions for the Kambites class.

kambites.non_trivial_classes(k: Kambites, words: list[list[int] | str]) list[list[list[int]] | list[str]]

Find the non-trivial classes in the partition of a list of words.

This function returns the classes with size at least \(2\) in the partition of the words in the list words induced by the Kambites instance k.

Parameters:
Returns:

The partition of the input list.

Return type:

list[list[list[int]] | list[str]]

Raises:

LibsemigroupsError – if k.small_overlap_class() is not at least \(4\).

kambites.normal_forms(k: Kambites) collections.abc.Iterator[str | list[int]]

Returns an iterator yielding normal forms.

This function returns an iterator yielding normal forms of the classes of the congruence represented by an instance of Kambites.

Parameters:

k (Kambites) – the Kambites instance.

Returns:

An iterator yielding normal forms.

Return type:

collections.abc.Iterator[str | list[int]]

Raises:

LibsemigroupsError – if k.small_overlap_class() is not at least \(4\).

kambites.partition(k: Kambites, words: list[list[int] | str]) list[list[list[int]] | list[str]]

Partition a list of words.

This function returns the classes in the partition of the words in the input list words induced by the Kambites instance k. This function triggers a full enumeration of k.

Parameters:
Returns:

The partitioned list of words.

Return type:

list[list[list[int]] | list[str]]

Raises:

LibsemigroupsError – if k.small_overlap_class() is not at least \(4\).