sort_generating_pairs(sort_function_type)¶
-
ToddCoxeter &libsemigroups::congruence::ToddCoxeter::sort_generating_pairs(sort_function_type func)¶
Sorts all existing generating pairs according to the binary function
func
.Additionally, if
this
was defined over a finitely presented semigroup, then the copy of the defining relations of that semigroup contained inthis
(if any) are also sorted according tofunc
.Warning
If add_pair is called after this function, then it may no longer be the case that the defining relations and generating pairs of
this
are sorted byfunc
.- Parameters
func – a value of type sort_function_type that defines a linear order on the relations in a ToddCoxeter instance.
- Throws
LibsemigroupsException – if started() returns
true
.- Returns
a reference to the object pointed to by
this
.