Constructors

This page contains information about the constructors for the KnuthBendix class.

libsemigroups::congruence::KnuthBendix::KnuthBendix()

Default constructor.

Parameters

(None)

Complexity

Constant.

inline libsemigroups::congruence::KnuthBendix::KnuthBendix(KnuthBendix const &copy)

Copy constructor.

Complexity

\(O(n)\) where \(n\) is the sum of the lengths of the words in rules of copy.

Parameters

copy – the congruence::KnuthBendix to be copied.

template<typename T>
inline explicit libsemigroups::congruence::KnuthBendix::KnuthBendix(T const &fp)

Constructs from FroidurePin instance.

Complexity

\(O(|S||A|)\) where \(A\) is the set of generators used to define S and S is the semigroup represented by the FroidurePin instance fp.

Warning

The FroidurePin instance used in construction is copied by this constructor. Use KnuthBendix(std::shared_ptr<FroidurePinBase>) to avoid making a copy.

Parameters

fp – the FroidurePin instance.

explicit libsemigroups::congruence::KnuthBendix::KnuthBendix(fpsemigroup::KnuthBendix const &copy)

Construct from fpsemigroup::KnuthBendix.

A congruence::KnuthBendix instance simply wraps an fpsemigroup::KnuthBendix, and provides an API compatible with the other algorithms for congruences in libsemigroups.

Complexity

\(O(n)\) where \(n\) is the sum of the lengths of the words in rules of copy.

Parameters

copy – the fpsemigroup::KnuthBendix.

explicit libsemigroups::congruence::KnuthBendix::KnuthBendix(std::shared_ptr<FroidurePinBase> fpb)

Construct from std::shared_ptr to FroidurePin instance.

Complexity

\(O(|S||A|)\) where \(A\) is the set of generators used to define S.

Note

The FroidurePin instance used in construction is not copied.

Parameters

fpb – the FroidurePin instance.