Macaulay2 Engine
Loading...
Searching...
No Matches

◆ constructWordTable()

std::unique_ptr< WordTable > constructWordTable ( const FreeAlgebra & A,
const ConstPolyList & gb )

Definition at line 15 of file matrix-ncbasis.cpp.

16{
17 std::unique_ptr<WordTable> W { new WordTable };
18
19 // Build the word table for the reduction
20 for (auto& f : gb)
21 {
22 auto i = f->cbegin();
23 Word tmp;
24 A.monoid().wordFromMonom(tmp,i.monom());
25 W->insert(tmp);
26 }
27 return W;
28}
const FreeMonoid & monoid() const
void wordFromMonom(Word &result, const Monom &m) const
Non-owning view of a non-commutative word: [begin, end) of int variable indices.
Definition Word.hpp:56
Index of Words (non-commutative monomials) with subword, prefix/suffix, and overlap lookup used by th...
Definition WordTable.hpp:89
void gb(IntermediateBasis &F, int n)

References gb(), FreeAlgebra::monoid(), and FreeMonoid::wordFromMonom().

Referenced by NCBasis::NCBasis().