Documentation

Formalizations.Analysis.Polynomial.RealRoots.AlternatingRoots

Alternating coefficients force nonnegative roots #

A monic real polynomial whose coefficients alternate in sign, (-1)^(n-k) c_k >= 0, has no negative root. As a corollary, a real symmetric matrix whose characteristic polynomial alternates is positive semidefinite.

Main results #

References #

theorem AlternatingRoots.root_nonneg_of_alternating {p : Polynomial ℝ} (hm : p.Monic) (halt : ∀ k ≤ p.natDegree, 0 ≤ (-1) ^ (p.natDegree - k) * p.coeff k) {x : ℝ} (hx : p.IsRoot x) :
0 ≤ x

Alternation rule. A monic real polynomial with (-1)^(n-k) * coeff k ≥ 0 for all k ≤ n = natDegree has no negative root. This is a corollary of Descartes' rule of signs in Mathlib (Polynomial.roots_countP_pos_le_signVariations).

theorem AlternatingRoots.posSemidef_of_charpoly_alternating {V : Type u_1} [Fintype V] [DecidableEq V] {A : Matrix V V ℝ} (hA : A.IsSymm) (halt : ∀ k ≤ A.charpoly.natDegree, 0 ≤ (-1) ^ (A.charpoly.natDegree - k) * A.charpoly.coeff k) :

PSD corollary. A real symmetric matrix whose characteristic polynomial alternates in sign is positive semidefinite.