Compfiles/Usa2025P2.lean
Explanation legend Lean4 Domain Explanation Language (L4DEL)
L4DEL explanations are a separate layer. They do not change the Lean source. Intuition is explanatory prose; numbered items are a reading path; sources link the wording back to evidence.
- L4DEL
- Lean4 Domain Explanation Language
Credit: The upstream authors and contributors retain credit for the project and mathematics. lean4-explainer only renders their pinned source and adds the separately disclosed explanation layer.
Project sources: Pinned compfiles documentation, Pinned compfiles corpus index
9 declarations, 0 contain sorry, 0 declared as axioms
USA Mathematical Olympiad 2025, Problem 2
Let n > k ≥ 1 be integers. Let P(x) ∈ ℝ[x] be a polynomial of degree n with no
repeated roots and P(0) ≠ 0. Suppose that for any real numbers a₀, a₁, ..., aₖ such
that the polynomial aₖxᵏ + ··· + a₁x + a₀ divides P(x), the product a₀a₁···aₖ is
zero. Prove that P(x) has a nonreal root.
Imports (6)
Imported by 1 file
- lemma
Usa2025P2.coeff_iterate_derivative_factorThe coefficients of an iterated formal derivative are the shifted coefficients of the original polynomial, up to a natural-number factor line 37 sourceSource documentation
The coefficients of an iterated formal derivative are the shifted coefficients of the original polynomial, up to a natural-number factor.
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Polynomial,Real,Nat,Exists,Eq,Finsupp,Polynomial.coeff,Nat.iterate,LinearMap,RingHom.id,Polynomial.derivative,HMul.hMul,HAdd.hAddProof uses:
Nat.recAux,Exists.intro,OfNat.ofNat,of_eq_true,Eq.trans,True,congrArg,congr,add_zero,Nat.cast_one,mul_one,eq_self,Eq.mpr,id,Nat.succ,Function.iterate_succ_apply',Polynomial.coeff_derivative,Nat.cast_mul,Nat.cast_add,Mathlib.Tactic.Ring.of_eqand 23 more66 instances, coercions and auxiliary constants left out.
Tactic trace: 10 steps
Open to load the checked before-and-after goal states.
lemma coeff_iterate_derivative_factor (F : ℝ[X]) (j m : ℕ) : ∃ N : ℕ, (derivative^[j] F).coeff m = F.coeff (m + j) * N := by … - lemma
Usa2025P2.natDegree_iterate_derivative_eqThe degree of an iterated formal derivative, as long as it is nonzero line 50 sourceSource documentation
The degree of an iterated formal derivative, as long as it is nonzero.
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Polynomial,Real,Nat,LE.le,Polynomial.natDegree,Eq,Nat.iterate,LinearMap,RingHom.id,Polynomial.derivative,HSub.hSubProof uses:
Nat.recAux,OfNat.ofNat,of_eq_true,Eq.trans,True,congrArg,tsub_zero,eq_self,HAdd.hAdd,Eq.mpr,id,Nat.succ,Function.iterate_succ_apply',Polynomial.natDegree_derivative60 instances, coercions and auxiliary constants left out.
Tactic trace: 6 steps
Open to load the checked before-and-after goal states.
lemma natDegree_iterate_derivative_eq (F : ℝ[X]) (j : ℕ) (hj : j ≤ F.natDegree) : (derivative^[j] F).natDegree = F.natDegree - j := by … - lemma
Usa2025P2.good_derivativeRolle's theorem: if a real polynomial has all of its roots real and distinct, then so does its derivative line 61 sourceSource documentation
Rolle's theorem: if a real polynomial has all of its roots real and distinct, then so does its derivative.
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Polynomial,Real,And,Multiset.Nodup,Polynomial.roots,Eq,Nat,Multiset.card,Polynomial.natDegree,LinearMap,RingHom.id,Polynomial.derivativeProof uses:
dite,LE.le,OfNat.ofNat,Iff.mp,Nat.le_zero,LE.le.trans,HSub.hSub,Polynomial.natDegree_derivative_le,Nat.sub_le_sub_right,LE.le.trans_eq,Polynomial.card_roots',Eq.mpr,Multiset,id,congrArg,Multiset.card_eq_zero,And.intro,Multiset.nodup_zero,Multiset.card_zero,Eq.symmand 121 more166 instances, coercions and auxiliary constants left out.
Tactic trace: 96 steps
Open to load the checked before-and-after goal states.
lemma good_derivative {F : ℝ[X]} (h : F.roots.Nodup ∧ Multiset.card F.roots = F.natDegree) : F.derivative.roots.Nodup ∧ Multiset.card F.derivative.roots = F.derivative.natDegree := by …Mentions: h
- lemma
Usa2025P2.good_iterateIterated derivatives of a polynomial with distinct real roots still have distinct real roots line 145 sourceSource documentation
Iterated derivatives of a polynomial with distinct real roots still have distinct real roots.
standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Polynomial,Real,Nat,And,Multiset.Nodup,Polynomial.roots,Eq,Multiset.card,Polynomial.natDegree,Nat.iterate,LinearMap,RingHom.id,Polynomial.derivativeProof uses:
Nat.recAux,Eq.mpr,HAdd.hAdd,OfNat.ofNat,id,congrArg,Nat.succ,Function.iterate_succ_apply', Usa2025P2.good_derivative23 instances, coercions and auxiliary constants left out.
Tactic trace: 4 steps
Open to load the checked before-and-after goal states.
lemma good_iterate (F : ℝ[X]) (j : ℕ) (h : F.roots.Nodup ∧ Multiset.card F.roots = F.natDegree) : (derivative^[j] F).roots.Nodup ∧ Multiset.card (derivative^[j] F).roots = (derivative^[j] F).natDegree := by …Mentions: h
- lemma
Usa2025P2.dvd_X_pow_two_iterate_derivativeIf the coefficients ofx^(t-1)andx^tofRboth vanish, thenX^2divides the(t-1)-st derivative ofRline 155 sourceSource documentation
If the coefficients of
x^(t-1)andx^tofRboth vanish, thenX^2divides the(t-1)-st derivative ofR.standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Polynomial,Real,Nat,LE.le,OfNat.ofNat,Eq,Finsupp,Polynomial.coeff,HSub.hSub,Dvd.dvd,HPow.hPow,Polynomial.X,Nat.iterate,LinearMap,RingHom.id,Polynomial.derivativeProof uses:
Eq.mpr,LT.lt,id,congrArg,propext,Polynomial.X_pow_dvd_iff,HMul.hMul,HAdd.hAdd,Exists, Usa2025P2.coeff_iterate_derivative_factor,dite,MulZeroClass.zero_mul,Eq.refl,Eq.symm,le_antisymm,Nat.ge_of_not_lt,Mathlib.Tactic.IntervalCases.of_lt_right,Nat.rawCast,Mathlib.Meta.NormNum.IsNat.to_raw_eq,Mathlib.Meta.NormNum.isNat_ofNatand 2 more75 instances, coercions and auxiliary constants left out.
Tactic trace: 10 steps
Open to load the checked before-and-after goal states.
lemma dvd_X_pow_two_iterate_derivative (R : ℝ[X]) {t : ℕ} (ht : 1 ≤ t) (h0 : R.coeff (t - 1) = 0) (h1 : R.coeff t = 0) : (X : ℝ[X]) ^ 2 ∣ derivative^[t - 1] R := by … - lemma
Usa2025P2.not_nodup_roots_of_X_pow_two_dvdA nonzero polynomial divisible byX^2has0as a multiple root, so its root multiset is duplicate-free nowhere line 167 sourceSource documentation
A nonzero polynomial divisible by
X^2has0as a multiple root, so its root multiset is duplicate-free nowhere.standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Polynomial,Real,Ne,OfNat.ofNat,Dvd.dvd,HPow.hPow,Nat,Polynomial.X,Not,Multiset.Nodup,Polynomial.rootsProof uses:
LE.le,Polynomial.rootMultiplicity,Eq.mpr,HSub.hSub,RingHom,Polynomial.C,id,Eq,congrArg,propext,Polynomial.le_rootMultiplicity_iff,congrFun',Eq.trans,map_zero,sub_zero,Multiset.count,Eq.mp,Multiset.nodup_iff_count_le_one,Polynomial.count_roots58 instances, coercions and auxiliary constants left out.
Tactic trace: 8 steps
Open to load the checked before-and-after goal states.
lemma not_nodup_roots_of_X_pow_two_dvd {F : ℝ[X]} (hF : F ≠ 0) (h : (X : ℝ[X]) ^ 2 ∣ F) : ¬ F.roots.Nodup := by …Mentions: h
- lemma
Usa2025P2.core_pigeonholeThe combinatorial heart of the problem line 184 sourceSource documentation
The combinatorial heart of the problem. Let
sbe a set ofk + 1real numbers (withk ≥ 1). Then it is impossible that for everyi ∈ s, the polynomial∏_{r ∈ s \ {i}} (X - r)has a zero coefficient among the positions1, ..., k - 1. Indeed, two such polynomials would share the positiontof a zero coefficient (pigeonhole), forcing the common sub-product∏_{r ∈ s \ {i₁, i₂}} (X - r)to have two consecutive zero coefficients, contradicting Rolle's theorem.standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,LE.le,OfNat.ofNat,Finset,Real,Eq,Finset.card,HAdd.hAdd,Membership.mem,Exists,And,Finset.Icc,HSub.hSub,Finsupp,Polynomial.coeff,Finset.prod,Polynomial,Finset.erase,Polynomial.X,RingHomand 2 moreProof uses:
Subtype,Subtype.property,dite,Subtype.mk,Not,rfl,LT.lt,Eq.mpr,id,congrArg,Nat.card_Icc,Ne,Finset.exists_ne_map_eq_of_card_lt_of_maps_to,Set,dite_eq_left,And.left,Eq.symm,And.right,Eq.mp,Finset.card_erase_of_memand 112 more151 instances, coercions and auxiliary constants left out.
Tactic trace: 89 steps
Open to load the checked before-and-after goal states.
lemma core_pigeonhole {k : ℕ} (hk : 1 ≤ k) {s : Finset ℝ} (hscard : s.card = k + 1) (H : ∀ i ∈ s, ∃ t ∈ Finset.Icc 1 (k - 1), (∏ r ∈ s.erase i, (X - C r)).coeff t = 0) : False := by … - lemma
Usa2025P2.roots_real_auxIf every complex root of a squarefree real polynomialPis real, then the real roots ofPare distinct and there aredeg Pmany of them (i.e.Psplits overℝ) line 275 sourceSource documentation
If every complex root of a squarefree real polynomial
Pis real, then the real roots ofPare distinct and there aredeg Pmany of them (i.e.Psplits overℝ).standard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Polynomial,Real,Ne,OfNat.ofNat,Squarefree,Complex,Eq,AlgHom,Polynomial.aeval,Complex.im,And,Multiset.Nodup,Polynomial.roots,Nat,Multiset.card,Polynomial.natDegreeProof uses:
Polynomial.Separable,Iff.mpr,PerfectField.separable_iff_squarefree,Polynomial.nodup_roots,And.intro,Polynomial.map,Algebra.algebraMap,rfl,Function.Injective,RingHom,RingHom.injective,Polynomial.map_ne_zero,Polynomial.Separable.map,Membership.mem,Multiset,Eq.mpr,Polynomial.eval₂,id,congrArg,Polynomial.aeval_defand 36 more98 instances, coercions and auxiliary constants left out.
Tactic trace: 44 steps
Open to load the checked before-and-after goal states.
lemma roots_real_aux {P : ℝ[X]} (hP : P ≠ 0) (hsq : Squarefree P) (h : ∀ z : ℂ, aeval z P = 0 → z.im = 0) : P.roots.Nodup ∧ Multiset.card P.roots = P.natDegree := by … - problem
Usa2025P2.usa2025_p2line 321 sourcestandard axioms: Classical.choice, Quot.sound, propext what this means
Statement uses:
Nat,LT.lt,LE.le,OfNat.ofNat,Polynomial,Real,Eq,Polynomial.natDegree,Squarefree,Ne,Polynomial.eval,Fin,HAdd.hAdd,Dvd.dvd,Finset.sum,Finset.univ,HMul.hMul,RingHom,Polynomial.C,HPow.hPowand 8 moreProof uses:
False,Eq.symm,Classical.byContradiction,Not,Multiset.Nodup,Polynomial.roots,Multiset.card, Usa2025P2.roots_real_aux,Eq.mp,Eq.trans,binderNameHint,forall_congr,Mathlib.Tactic.Push.not_and_eq,implies_congr,Eq.refl,Finset,Multiset.toFinset,rfl,Finset.card,Eq.mprand 71 more173 instances, coercions and auxiliary constants left out.
Tactic trace: 64 steps
Open to load the checked before-and-after goal states.