Member functions¶
This page lists the member functions of the Congruence class that are not present in its base classes Runner and CongruenceInterface.
-
template<typename T>
inline void libsemigroups::Congruence::add_runner(T const &r)¶ Adds a class derived from CongruenceInterface to the algorithms used to compute the congruence.
This function adds the algorithm represented by the parameter
rto the list of runners that are invoked when run is called.Warning
It’s the responsibility of the caller to ensure that
ris compatible with any existing CongruenceInterface instances inthis.- Template Parameters
T – a type derived from CongruenceInterface.
- Parameters
r – a const reference to an instance of a type derived from CongruenceInterface.
- Throws
LibsemigroupsException – if started() returns
true.- Returns
(None)
-
inline bool libsemigroups::Congruence::has_kambites() const¶
Checks if a Kambites instance is being used to compute the congruence.
- Parameters
(None)
- Exceptions
This function guarantees not to throw a LibsemigroupsException.
- Complexity
Constant.
- See
- Returns
A value to type
bool.
-
inline bool libsemigroups::Congruence::has_knuth_bendix() const¶
Checks if a KnuthBendix instance is being used to compute the congruence.
- Parameters
(None)
- Exceptions
This function guarantees not to throw a LibsemigroupsException.
- Complexity
Constant.
- See
- Returns
A value of type
bool.
-
inline bool libsemigroups::Congruence::has_todd_coxeter() const¶
Checks if a ToddCoxeter instance is being used to compute the congruence.
- Parameters
(None)
- Exceptions
This function guarantees not to throw a LibsemigroupsException.
- Complexity
Constant.
- See
- Returns
A value to type
bool.
-
inline std::shared_ptr<congruence::Kambites> libsemigroups::Congruence::kambites() const¶
Returns the Kambites instance used to compute the congruence (if any).
- Parameters
(None)
- Exceptions
This function guarantees not to throw a LibsemigroupsException.
- Complexity
Constant.
- See
- Returns
A shared_ptr to a congruence::Kambites or
nullptr.
-
inline std::shared_ptr<congruence::KnuthBendix> libsemigroups::Congruence::knuth_bendix() const¶
Returns the KnuthBendix instance used to compute the congruence (if any).
- Parameters
(None)
- Exceptions
This function guarantees not to throw a LibsemigroupsException.
- Complexity
Constant.
- See
- Returns
A std::shared_ptr to a congruence::KnuthBendix or
nullptr.
-
inline size_t libsemigroups::Congruence::max_threads() const noexcept¶
Get the current maximum number of threads.
- Exceptions
This function is
noexceptand is guaranteed never to throw.- Complexity
Constant.
- Parameters
(None)
- Returns
A value of type
size_t.
-
inline Congruence &libsemigroups::Congruence::max_threads(size_t val) noexcept¶
Set the maximum number of threads.
- Exceptions
This function is
noexceptand is guaranteed never to throw.- Complexity
Constant.
- Parameters
val – the number of threads.
- Returns
A reference to
this.
-
inline std::shared_ptr<congruence::ToddCoxeter> libsemigroups::Congruence::todd_coxeter() const¶
Returns the ToddCoxeter instance used to compute the congruence (if any).
- Parameters
(None)
- Exceptions
This function guarantees not to throw a LibsemigroupsException.
- Complexity
Constant.
- See
- Returns
A shared_ptr to a congruence::ToddCoxeter or
nullptr.