libsemigroups  v3.0.0
C++ library for semigroups and monoids
Loading...
Searching...
No Matches
KnuthBendix class

Defined in knuth-bendix-class.hpp.

On this page we describe the functionality relating to the Knuth-Bendix algorithm for semigroups and monoids in libsemigroups. This page contains details of the member functions of the class KnuthBendix.

This class is used to represent a string rewriting system defining a 1- or 2-sided congruence on a finitely presented monoid or semigroup.

Template Parameters
Wordthe type of the words in rules in the presentation.
Rewriterthe type of the rewriter.
ReductionOrderthe reduction ordering.
Example
Presentation<std::string> p;
p.contains_empty_word(true);
p.alphabet("abcd");
!kb.confluent(); // true
kb.run();
kb.number_of_active_rules(); // 8
kb.confluent(); // true
kb.number_of_classes(); // POSITIVE_INFINITY
KnuthBendix(congruence_kind, Presentation< Word > const &) -> KnuthBendix< Word >
Deduction guide.
@ twosided
Value representing a two-sided congruence.
Definition types.hpp:73
void add_rule_no_checks(Presentation< Word > &p, Word const &lhop, Word const &rhop)
Add a rule to the presentation by reference.
Definition presentation.hpp:786

Topics

 Member types
 Public member types.
 
 Constructors + initializers
 Construct or re-initialize a KnuthBendix instance (public member function).
 
 Settings
 Settings that control the behaviour of a KnuthBendix instance.
 
 Common member functions
 Documentation of common member functions of Congruence, Kambites, KnuthBendix, and ToddCoxeter.
 
 Accessors
 Member functions that can be used to access the state of a KnuthBendix instance.
 

Functions

template<typename Word>
 KnuthBendix (congruence_kind, Presentation< Word > &&) -> KnuthBendix< Word >
 Deduction guide.
 
template<typename Word>
 KnuthBendix (congruence_kind, Presentation< Word > const &) -> KnuthBendix< Word >
 Deduction guide.
 
template<typename Word>
 KnuthBendix (KnuthBendix< Word > &&) -> KnuthBendix< Word >
 Deduction guide.
 
template<typename Word>
 KnuthBendix (KnuthBendix< Word > const &) -> KnuthBendix< Word >
 Deduction guide.
 

Function Documentation

◆ KnuthBendix() [1/4]

template<typename Word>
KnuthBendix ( congruence_kind ,
Presentation< Word > &&  ) -> KnuthBendix< Word >

Defined in knuth-bendix-class.hpp.

Deduction guide to construct a KnuthBendix<Word> from a

Presentation<Word> rvalue reference.

◆ KnuthBendix() [2/4]

template<typename Word>
KnuthBendix ( congruence_kind ,
Presentation< Word > const &  ) -> KnuthBendix< Word >

Defined in knuth-bendix-class.hpp.

Deduction guide to construct a KnuthBendix<Word> from a Presentation<Word> const reference.

◆ KnuthBendix() [3/4]

template<typename Word>
KnuthBendix ( KnuthBendix< Word > && ) -> KnuthBendix< Word >

Defined in knuth-bendix-class.hpp.

Deduction guide to construct a KnuthBendix<Word> from a KnuthBendix<Word> rvalue reference.

◆ KnuthBendix() [4/4]

template<typename Word>
KnuthBendix ( KnuthBendix< Word > const & ) -> KnuthBendix< Word >

Defined in knuth-bendix-class.hpp.

Deduction guide to construct a KnuthBendix<Word> from a KnuthBendix<Word> const reference.