Modifiers
This page contains documentation of the member functions of ToddCoxeter
that can be used to modify the state of a ToddCoxeter
instance. In other
words, for modifying the WordGraph
that is the output of the algorithm in
a way that preserves it up to isomorphism.
- ToddCoxeter.perform_lookahead(self: ToddCoxeter, stop_early: bool) None
Perform a lookahead.
This function can be used to explicitly perform a lookahead. The style and extent of this lookahead are controlled by the settings
ToddCoxeter.lookahead_style
andToddCoxeter.lookahead_extent
. If the argument stop_early isTrue
, then the settingslookahead_stop_early_interval
andlookahead_stop_early_ratio
are used to determine whether or not the lookahead should be aborted early. If stop_early isFalse
, then these settings are ignored.- Parameters:
stop_early (bool) – whether or not to consider stopping the lookahead early if too few nodes are killed.
- ToddCoxeter.shrink_to_fit(self: ToddCoxeter) None
Shrink the underlying word graph to remove all dead nodes. This function triggers a full enumeration, and standardization, and removes from
word_graph
any dead nodes. IfRunner.finished
returnsFalse
, then this function does nothing.
- ToddCoxeter.standardize(self: ToddCoxeter, val: Order) bool
Standardize
ToddCoxeter.current_word_graph
.This function standardizes the return value of
current_word_graph
, and does not trigger any enumeration. Seestandardization_order
for a full description. The return value of this function indicates whether or not thecurrent_word_graph
was modified. In other words, if this function returnsTrue
, then the word graph was not previously standardized with respect to val, and was modified by calling this function ifFalse
is returned, then the word graph was previously standardized with respect to val (although this might not have been known), and was not modified by calling this function.- Parameters:
val (Order) – the order of the standardization.
- Returns:
Whether or not the word graph was modified by the standardization.
- Return type:
See also