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

◆ monomInsertFromWord()

void FreeMonoid::monomInsertFromWord ( MonomialInserter & result,
const Word & w ) const

Definition at line 304 of file FreeMonoid.cpp.

305{
306 result.push_back(word.size() + mNumWeights + 1);
307 for (int j = 0; j < mNumWeights; ++j)
308 result.push_back(0);
309 for (auto a : word) result.push_back(a);
310 Monom tmpMonom(&*(result.end()-1-mNumWeights-word.size()));
311 setWeights(tmpMonom);
312}
std::vector< int > word
const int mNumWeights
void setWeights(Monom &m) const
VALGRIND_MAKE_MEM_DEFINED & result(result)

References mNumWeights, result(), setWeights(), and word.

Referenced by NCF4::displayF4Matrix(), NCF4::displayFullF4Matrix(), FreeAlgebra::from_word(), FreeAlgebra::mult_by_term_left(), FreeAlgebra::mult_by_term_left_and_right(), FreeAlgebra::mult_by_term_left_and_right(), FreeAlgebra::mult_by_term_right(), and NCF4::reducedRowToPoly().