Local variation jumps for alternating polynomial chains #
IsAlternating records the sign conditions of a chain whose last entry has no roots.
Interior zeros preserve sign variations. Crossing a simple root of the first
entry changes the variation by the sign of its derivative times the second entry.
These local identities supply the signed root sum in Sturm.Sum.
A alternating chain has opposite neighbors at every interior zero and no real zero in its last entry. These are the properties of a signed remainder chain after its common polynomial factor has been removed.
- nonzero (q : Polynomial R) : q ∈ cs → q ≠ 0
Every entry is a nonzero polynomial.
- last (q : Polynomial R) : cs.getLast? = some q → ∀ (r : R), Polynomial.eval r q ≠ 0
The terminal polynomial has no root in the coefficient ring.
- alternate (i : ℕ) (q0 q1 q2 : Polynomial R) : cs[i]? = some q0 → cs[i + 1]? = some q1 → cs[i + 2]? = some q2 → ∀ (r : R), Polynomial.eval r q1 = 0 → Polynomial.eval r q0 * Polynomial.eval r q2 < 0
At an interior zero the adjacent values are nonzero and have opposite signs.
Instances For
A alternating chain has the same variations at two points if no entry vanishes at the first, the head does not vanish at the second, and all surviving signs agree.
Consecutive entries of a alternating chain cannot both vanish.
Crossing isolated interior zeros does not change variations.
At a simple root of the head, the variation jump is the sign of the product of the head derivative and the second entry.