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

◆ multpower()

template<class E, bool OC>
void ExponentVector< E, OC >::multpower ( int nvars,
ConstExponents a,
ConstExponents b,
const Exponent n,
Exponents result )
inlinestatic

Definition at line 124 of file ExponentVector.hpp.

129 {
130 if constexpr (OC)
131 for (int i = nvars; i > 0; i--)
132 *result++ = safe::add(*a++, safe::mult(*b++, n));
133 else
134 for (int i = nvars; i > 0; i--) *result++ = *a++ + *b++ * n;
135 }