letter_to_posΒΆ

element_index_type libsemigroups::FroidurePinBase::letter_to_pos(letter_type i) const

Returns the position in this of the generator with index i.

If i is not a valid generator index, a LibsemigroupsException will be thrown. In many cases letter_to_pos(i) will equal i, examples of when this will not be the case are: