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

◆ make_monic()

void res_poly::make_monic ( resterm *& f) const

Definition at line 122 of file res-a1-poly.cpp.

123{
124 if (f == nullptr) return;
125 ring_elem c_inv = K->invert(f->coeff);
126
127 for (resterm *tm = f; tm != nullptr; tm = tm->next) K->mult_to(tm->coeff, c_inv);
128
129 K->remove(c_inv);
130}
const Ring * K
ring_elem coeff

References resterm::coeff, K, and resterm::next.