The ToddCoxeter.options class

This page contains documentation for the nested class ToddCoxeter.options which holds various values that can be used to control the behaviour of Todd-Coxeter.

class ToddCoxeter.options

This class containing various options that can be used to control the behaviour of Todd-Coxeter.

class def_policy

Enum class containing values for specifying how to handle edge definitions.

The values in this enum can be used as the argument for ToddCoxeter.def_policy.

For our purposes, a definition is a recently defined edge in the word graph that we are attempting to construct in an instance of ToddCoxeter. The values in this enum influence how these definitions are stored and processed.

For every definition held in the definition stack, a depth first search through the Felsch tree of the generating pairs is performed. The aim is to only follow paths from nodes in the word graph labelled by generating pairs that actually pass through the edge described by a definition.

The values in this enum represent what to do if the number of definitions in the stack exceeds the value ToddCoxeter.def_max.

The valid values are:

def_policy.no_stack_if_no_space = <def_policy.no_stack_if_no_space: 0>

Do not put newly generated definitions in the stack if the stack already has size def_max.

def_policy.purge_from_top = <def_policy.purge_from_top: 1>

If the definition stack has size def_max and a new definition is generated, then definitions with dead source node are are popped from the top of the stack (if any).

def_policy.purge_all = <def_policy.purge_all: 2>

If the definition stack has size def_max and a new definition is generated, then definitions with dead source node are are popped from the entire of the stack (if any).

def_policy.discard_all_if_no_space = <def_policy.discard_all_if_no_space: 3>

If the definition stack has size def_max and a new definition is generated, then all definitions in the stack are discarded.

def_policy.unlimited = <def_policy.unlimited: 4>

There is no limit to the number of definitions that can be put in the stack.

class def_version

Values for specifying how to handle definitions.

The valid values are:

def_version.one = <def_version.one: 0>

Version 1 definition processing.

def_version.two = <def_version.two: 1>

Version 2 definition processing.

class lookahead_extent

Enum for specifying the extent of any lookahead performed.

The values in this enum can be used as the argument for ToddCoxeter.lookahead_extent to specify the extent of any lookahead that should be performed.

The valid values are :

lookahead_extent.full = <lookahead_extent.full: 0>

Perform a full lookahead from every node in the word graph. Full lookaheads are therefore sometimes slower but may detect more coincidences than a partial lookahead.

lookahead_extent.partial = <lookahead_extent.partial: 1>

Perform a partial lookahead starting from the current node in the word graph. Partial lookaheads are sometimes faster but may not detect as many coincidences as a full lookahead.

class lookahead_style

Enum class for specifying the style of any lookahead performed.

The values in this enum can be used as the argument for ToddCoxeter.lookahead_style to specify the style of any lookahead that should be performed.

The valid values are :

lookahead_style.hlt = <lookahead_style.hlt: 0>

The lookahead will be done in HLT style by following the paths labelled by every relation from every node in the range specified by lookahead_extent.full or lookahead_extent.partial.

lookahead_style.felsch = <lookahead_style.hlt: 0>

The lookahead will be done in Felsch style where every edge is considered in every path labelled by a relation in which it occurs.

class strategy

Values for defining the strategy.

The values in this enum can be used as the argument for the method ToddCoxeter.strategy() to specify which strategy should be used when performing a coset enumeration.

The valid values are :

strategy.hlt = <strategy.hlt: 0>

This value indicates that the HLT (Hazelgrove-Leech-Trotter) strategy should be used. This is analogous to ACE’s R-style.

strategy.felsch = <strategy.felsch: 1>

This value indicates that the Felsch strategy should be used. This is analogous to ACE’s C-style.

strategy.CR = <strategy.CR: 2>

This strategy is meant to mimic the ACE strategy of the same name. The Felsch is run until at least f_defs nodes are defined, then the HLT strategy is run until at least hlt_defs divided by \(N\) nodes have been defined, where \(N\) is the sum of the lengths of the words in the presentation and generating pairs. These steps are repeated until the enumeration terminates.

strategy.R_over_C = <strategy.R_over_C: 3>

This strategy is meant to mimic the ACE strategy R/C. The HLT strategy is run until the first lookahead is triggered (when :the number of nodes active is at least lookahead_next). A full lookahead is then performed, and then the CR strategy is used.

strategy.Cr = <strategy.Cr: 4>

This strategy is meant to mimic the ACE strategy Cr. The Felsch strategy is run until at least f_defs new nodes have been defined, then the HLT strategy is run until at least hlt_defs divided by \(N\) nodes have been defined, where \(N\) is the sum of the lengths of the words in the presentation and generating pairs. Then the Felsch strategy is run.

strategy.Rc = <strategy.Rc: 5>

This strategy is meant to mimic the ACE strategy Rc. The HLT strategy is run until at least hlt_defs divided by \(N\) new nodes have been defined (where \(N\) is the sum of the lengths of the words in the presentation and generating pairs) the Felsch strategy is then run until at least f_defs new nodes are defined, and then the HLT strategy is run.