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

◆ elem_text_out() [1/2]

void res_poly::elem_text_out ( buffer & o,
const resterm * f ) const

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

237{
238 if (f == nullptr)
239 {
240 o << "0";
241 return;
242 }
243
244 bool p_one = false;
245 bool p_parens = true;
246 bool p_plus = false;
247 for (const resterm *t = f; t != nullptr; t = t->next)
248 {
249 int isone = M->is_one(t->monom);
250 K->elem_text_out(o, t->coeff, p_one, p_parens, p_plus);
251 if (!isone) M->elem_text_out(o, t->monom, p_one);
252 o << "<" << t->comp->me << ">";
253 p_plus = true;
254 }
255}
const Ring * K
const Monoid * M

References K, M, and resterm::next.

Referenced by drespoly(), and elem_text_out().