Univariate Division Correctness #
Correctness theorems for division-style univariate polynomial algorithms.
CompPoly's divByMonic is correct w.r.t. Mathlib's divByMonic
CompPoly's modByMonic is correct w.r.t. Mathlib's modByMonic
Euclidean division identity for a monic divisor, stated directly on
CPolynomial: p.modByMonic q + q * p.divByMonic q = p whenever q is monic.
This holds over an arbitrary commutative ring, so it
instantiates at nested coefficient rings, e.g. CBivariate R = CPolynomial (CPolynomial R), giving Euclidean division by any monic divisor in
the outer variable.
Any nonzero polynomial scaled by the inverse of its leading coefficient is monic.
Equality between CompPoly's div and Mathlib's divByMonic
Equality between CompPoly's mod and Mathlib's modByMonic
Exact-division bridge: G.toPoly factors as f.toPoly * V.toPoly iff the computable
mod vanishes and the computable division recovers f.
The reversal monic remainder agrees with the canonical monic remainder.