Hodge conjecture: the CM case in Lean, read and discussed
OpenAI's Lean proof of the Hodge conjecture for CM abelian varieties: rerun it, read its statement, and keep the open questions with their sources. The conjecture is open

| 1 | import Mathlib |
| 2 | |
| 3 | /-! # Restricted Coefficients -/ |
| 4 | |
| 5 | namespace OAI |
| 6 | |
| 7 | noncomputable section |
| 8 | |
| 9 | namespace NumberTheory.PadicHodge.WeakAdmissibility.RestrictedCoefficients |
| 10 | |
| 11 | /-! Restricted coefficient sequences extracted from completed direct sums. -/ |
| 12 | |
| 13 | open AdicCompletion |
| 14 | variable {R : Type*} [CommRing R] (q : R) |
| 15 | |
| 16 | /-- The coefficients tend to zero in the q-adic topology. -/ |
| 17 | def IsRestricted (a : ℕ → R) : Prop := ∀ r : ℕ, ∃ N : ℕ, ∀ n ≥ N, q ^ r ∣ a n |
| 18 | |
| 19 | theorem coordinate_dvd_of_mem (r : ℕ) (f : ℕ →₀ R) |
| 20 | (hf : f ∈ (Ideal.span {q}) ^ r • (⊤ : Submodule R (ℕ →₀ R))) (i : ℕ) : q ^ r ∣ f i := by |
| 21 | rw [Ideal.span_singleton_pow, Submodule.ideal_span_singleton_smul, |
| 22 | Submodule.mem_smul_pointwise_iff_exists] at hf |
| 23 | obtain ⟨g, _, hg⟩ := hf |
| 24 | exact ⟨g i, (DFunLike.congr_fun hg i).symm⟩ |
| 25 | |
| 26 | def coordinateCauchy (c : AdicCauchySequence (Ideal.span {q}) (ℕ →₀ R)) (i : ℕ) : |
| 27 | AdicCauchySequence (Ideal.span {q}) R := |
| 28 | ⟨fun n => c n i, by |
| 29 | intro m n hmn |
| 30 | have hm := c.property hmn |
| 31 | rw [SModEq.sub_mem] at hm |
| 32 | rw [SModEq.sub_mem, smul_eq_mul, Ideal.mul_top, Ideal.span_singleton_pow, Ideal.mem_span_singleton] |
| 33 | exact coordinate_dvd_of_mem q m (c m - c n) hm i⟩ |
| 34 | |
| 35 | variable [IsPrecomplete (Ideal.span {q}) R] |
| 36 | |
| 37 | theorem cauchy_coefficients (c : AdicCauchySequence (Ideal.span {q}) (ℕ →₀ R)) : |
| 38 | ∃ a : ℕ → R, (∀ r i : ℕ, q ^ r ∣ a i - c r i) ∧ IsRestricted q a := by |
| 39 | have hlim (i : ℕ) : ∃ a : R, ∀ r : ℕ, |
| 40 | c r i ≡ a [SMOD (Ideal.span {q}) ^ r • (⊤ : Submodule R R)] := |
| 41 | IsPrecomplete.prec (show IsPrecomplete (Ideal.span {q}) R from inferInstance) |
| 42 | (coordinateCauchy q c i).property |
| 43 | choose a ha using hlim |
| 44 | have happrox (r i : ℕ) : q ^ r ∣ a i - c r i := by |
| 45 | have he := (ha i r).symm |
| 46 | rwa [SModEq.sub_mem, smul_eq_mul, Ideal.mul_top, Ideal.span_singleton_pow, Ideal.mem_span_singleton] at he |
| 47 | refine ⟨a, happrox, ?_⟩ |
| 48 | intro r |
| 49 | refine ⟨(c r).support.sup id + 1, fun n hn => ?_⟩ |
| 50 | have hnmem : n ∉ (c r).support := by |
| 51 | intro hmem |
| 52 | have hnle : n ≤ (c r).support.sup id := Finset.le_sup (f := id) hmem |
| 53 | omega |
| 54 | have hz : c r n = 0 := Finsupp.notMem_support_iff.mp hnmem |
| 55 | simpa only [hz, sub_zero] using happrox r n |
| 56 | |
| 57 | theorem completed_coefficients (x : AdicCompletion (Ideal.span {q}) (ℕ →₀ R)) : |
| 58 | ∃ (c : AdicCauchySequence (Ideal.span {q}) (ℕ →₀ R)) (a : ℕ → R), |
| 59 | AdicCompletion.mk (Ideal.span {q}) (ℕ →₀ R) c = x ∧ |
| 60 | (∀ r i : ℕ, q ^ r ∣ a i - c r i) ∧ IsRestricted q a := by |
| 61 | obtain ⟨c, hc⟩ := AdicCompletion.mk_surjective (Ideal.span {q}) (ℕ →₀ R) x |
| 62 | obtain ⟨a, ha, hnull⟩ := cauchy_coefficients q c |
| 63 | exact ⟨c, a, hc, ha, hnull⟩ |
| 64 | |
| 65 | end NumberTheory.PadicHodge.WeakAdmissibility.RestrictedCoefficients |
| 66 | |
| 67 | namespace NumberTheory.PadicHodge.WeakAdmissibility.RestrictedCoefficients.Series |
| 68 | |
| 69 | /-! Construction of completed direct sums from restricted coefficient sequences. -/ |
| 70 | |
| 71 | open OAI.NumberTheory.PadicHodge.WeakAdmissibility.RestrictedCoefficients AdicCompletion |
| 72 | variable {R : Type*} [CommRing R] (q : R) |
| 73 | |
| 74 | theorem mem_power_smul_finsupp (r : ℕ) (f : ℕ →₀ R) : |
| 75 | f ∈ (Ideal.span {q}) ^ r • (⊤ : Submodule R (ℕ →₀ R)) ↔ ∀ i, q ^ r ∣ f i := by |
| 76 | classical |
| 77 | refine ⟨fun hf i => coordinate_dvd_of_mem q r f hf i, fun hf => ?_⟩ |
| 78 | let g : ℕ →₀ R := Finsupp.onFinset f.support |
| 79 | (fun i => if i ∈ f.support then (hf i).choose else 0) (by |
| 80 | intro i hi |
| 81 | by_contra h |
| 82 | simp only [h, ↓reduceIte] at hi |
| 83 | exact hi rfl) |
| 84 | rw [Ideal.span_singleton_pow, Submodule.ideal_span_singleton_smul, |
| 85 | Submodule.mem_smul_pointwise_iff_exists] |
| 86 | refine ⟨g, Submodule.mem_top, ?_⟩ |
| 87 | ext i |
| 88 | change q ^ r * g i = f i |
| 89 | simp only [g, Finsupp.onFinset_apply] |
| 90 | split_ifs with hi |
| 91 | · exact (hf i).choose_spec.symm |
| 92 | · simp only [mul_zero, (Finsupp.notMem_support_iff.mp hi)] |
| 93 | |
| 94 | def truncate (N : ℕ) (a : ℕ → R) : ℕ →₀ R := |
| 95 | Finsupp.onFinset (Finset.range N) (fun i => if i < N then a i else 0) (by |
| 96 | intro i hi |
| 97 | rw [Finset.mem_range] |
| 98 | by_contra h |
| 99 | simp only [h, ↓reduceIte] at hi |
| 100 | exact hi rfl) |
| 101 | |
| 102 | theorem truncate_apply (N : ℕ) (a : ℕ → R) (i : ℕ) : |
| 103 | truncate N a i = if i < N then a i else 0 := rfl |
| 104 | |
| 105 | def cutoff (a : ℕ → R) (ha : IsRestricted q a) (r : ℕ) : ℕ := |
| 106 | (Finset.range (r + 1)).sup (fun n => (ha n).choose) |
| 107 | |
| 108 | theorem cutoff_mono (a : ℕ → R) (ha : IsRestricted q a) : Monotone (cutoff q a ha) := by |
| 109 | intro m n hmn |
| 110 | apply Finset.sup_mono |
| 111 | exact Finset.range_mono (Nat.add_le_add_right hmn 1) |
| 112 | |
| 113 | theorem cutoff_bound (a : ℕ → R) (ha : IsRestricted q a) (r i : ℕ) |
| 114 | (hi : cutoff q a ha r ≤ i) : q ^ r ∣ a i := by |
| 115 | apply (ha r).choose_spec |
| 116 | apply le_trans ?_ hi |
| 117 | exact Finset.le_sup (f := fun n => (ha n).choose) (Finset.mem_range.mpr (Nat.lt_succ_self r)) |
| 118 | |
| 119 | def truncatedCauchy (a : ℕ → R) (ha : IsRestricted q a) : |
| 120 | AdicCauchySequence (Ideal.span {q}) (ℕ →₀ R) := |
| 121 | ⟨fun r => truncate (cutoff q a ha r) a, by |
| 122 | intro m n hmn |
| 123 | rw [SModEq.sub_mem, mem_power_smul_finsupp] |
| 124 | intro i |
| 125 | change q ^ m ∣ truncate (cutoff q a ha m) a i - truncate (cutoff q a ha n) a i |
| 126 | rw [truncate_apply, truncate_apply] |
| 127 | by_cases him : i < cutoff q a ha m |
| 128 | · have hin := lt_of_lt_of_le him (cutoff_mono q a ha hmn) |
| 129 | simp only [him, hin, ↓reduceIte, sub_self, dvd_zero] |
| 130 | · by_cases hin : i < cutoff q a ha n |
| 131 | · simp only [him, hin, ↓reduceIte, zero_sub] |
| 132 | exact dvd_neg.mpr (cutoff_bound q a ha m i (Nat.le_of_not_gt him)) |
| 133 | · simp only [him, hin, ↓reduceIte, sub_self, dvd_zero]⟩ |
| 134 | |
| 135 | def restrictedSeries (a : ℕ → R) (ha : IsRestricted q a) : |
| 136 | AdicCompletion (Ideal.span {q}) (ℕ →₀ R) := |
| 137 | AdicCompletion.mk (Ideal.span {q}) (ℕ →₀ R) (truncatedCauchy q a ha) |
| 138 | |
| 139 | theorem truncatedCauchy_approx (a : ℕ → R) (ha : IsRestricted q a) (r i : ℕ) : |
| 140 | q ^ r ∣ a i - truncatedCauchy q a ha r i := by |
| 141 | change q ^ r ∣ a i - truncate (cutoff q a ha r) a i |
| 142 | rw [truncate_apply] |
| 143 | split_ifs with hi |
| 144 | · simp only [sub_self, dvd_zero] |
| 145 | · rw [sub_zero] |
| 146 | exact cutoff_bound q a ha r i (Nat.le_of_not_gt hi) |
| 147 | |
| 148 | theorem completion_eq_of_coefficients |
| 149 | (c d : AdicCauchySequence (Ideal.span {q}) (ℕ →₀ R)) (a : ℕ → R) |
| 150 | (hc : ∀ r i, q ^ r ∣ a i - c r i) (hd : ∀ r i, q ^ r ∣ a i - d r i) : |
| 151 | AdicCompletion.mk (Ideal.span {q}) (ℕ →₀ R) c = |
| 152 | AdicCompletion.mk (Ideal.span {q}) (ℕ →₀ R) d := by |
| 153 | apply Subtype.ext |
| 154 | funext r |
| 155 | change Submodule.Quotient.mk (c r) = Submodule.Quotient.mk (d r) |
| 156 | apply (Submodule.Quotient.eq _).mpr |
| 157 | rw [mem_power_smul_finsupp] |
| 158 | intro i |
| 159 | change q ^ r ∣ c r i - d r i |
| 160 | have h := dvd_sub (hd r i) (hc r i) |
| 161 | simpa only [sub_sub_sub_cancel_left] using h |
| 162 | |
| 163 | end NumberTheory.PadicHodge.WeakAdmissibility.RestrictedCoefficients.Series |
| 164 | |
| 165 | end |
| 166 | |
| 167 | end OAI |