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

◆ quotient_as_vp()

void ResMonoidDense::quotient_as_vp ( res_const_packed_monomial a,
res_const_packed_monomial b,
res_varpower_monomial result ) const
inline

Definition at line 479 of file res-moninfo-dense.hpp.

482 {
483 // sets result
485 a += firstvar;
486 b += firstvar;
487 int len = 0;
488 res_varpower_word* r = result + 1;
489 for (int i = nvars - 1; i >= 0; --i)
490 {
491 res_varpower_word c = a[i] - b[i];
492 if (c > 0)
493 {
494 *r++ = i;
495 *r++ = c;
496 len++;
497 }
498 }
499 result[0] = len;
500 }
unsigned long ncalls_quotient_as_vp
VALGRIND_MAKE_MEM_DEFINED & result(result)
res_varpower_monomials::Exponent res_varpower_word

References firstvar, ncalls_quotient_as_vp, nvars, and result().

Referenced by SchreyerFrame::createQuotientElement().