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

◆ isSuffix()

bool WordWithDataTable::isSuffix ( WordWithData word,
int & output ) const

Definition at line 407 of file WordTable.cpp.

409{
410 for (auto i = 0; i < mMonomials.size(); ++i)
411 {
412 if (mIndices[i] == -1) continue;
413 if (isSuffixOf(mMonomials[i], word))
414 {
415 output = i;
416 return true;
417 }
418 }
419 return false;
420}
std::vector< int > word
std::vector< int > mIndices
static bool isSuffixOf(WordWithData word1, WordWithData word2)
std::vector< WordWithData > mMonomials

References isSuffixOf(), mIndices, mMonomials, and word.