sort_generating_pairs(sort_free_function_type)¶
-
inline ToddCoxeter &libsemigroups::congruence::ToddCoxeter::sort_generating_pairs(sort_free_function_type func = shortlex_compare)¶
Sorts all existing generating pairs according to the binary function
func.Additionally, if
thiswas 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
thisare 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.