763{
764 int i;
765 if (g == nullptr) return;
766 if (f == nullptr)
767 {
770 return;
771 }
772 int fdeg = f->deg;
773 int gdeg = g->deg;
774
776 for (i = 0; i <= gdeg; i++)
778 if (gdeg > fdeg)
779 f->deg = gdeg;
780 else if (gdeg == fdeg)
781 {
782
783 for (int j = fdeg; j >= 0; --j)
784 if (f->arr.polys[j] != nullptr)
785 {
786 f->deg = j;
787 return;
788 }
789
791 }
792}
void subtract_in_place(int level, TowerPolynomial &f, const TowerPolynomial g)
static void increase_size_n(int newdeg, TowerPolynomial &f)
static TowerPolynomial copy(int level, const TowerPolynomial f)
static void dealloc_poly(TowerPolynomial &f)
void negate_in_place(int level, TowerPolynomial &f)