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

◆ operator/=()

const MonomDRL & BIBasis::MonomDRL::operator/= ( const MonomDRL & anotherMonom)
inline

Definition at line 323 of file monomDRL.hpp.

324 {
325 VarsListNode **iterator = &ListHead,
326 *anotherIterator = anotherMonom.ListHead;
327
328 while (*iterator && anotherIterator)
329 {
330 if ((*iterator)->Value == anotherIterator->Value)
331 {
332 VarsListNode* nodeToDelete = *iterator;
333 *iterator = (*iterator)->Next;
334 delete nodeToDelete;
335 --TotalDegree;
336 anotherIterator = anotherIterator->Next;
337 }
338 else if ((*iterator)->Value > anotherIterator->Value)
339 {
340 iterator = &((*iterator)->Next);
341 }
342 }
343
344 return *this;
345 }
Integer TotalDegree
Definition monom.hpp:106
VarsListNode * ListHead
Definition monom.hpp:105
Singly linked-list node of a Monom's variable list, with a per-class slab allocator.
Definition monom.hpp:94

References BIBasis::Monom::ListHead, MonomDRL(), BIBasis::Monom::VarsListNode::Next, operator/=(), and BIBasis::Monom::TotalDegree.

Referenced by operator/=().