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 OAI.NumberTheory.Adeles.LocalCompletions |
| 2 | |
| 3 | /-! # Finite Character -/ |
| 4 | |
| 5 | namespace OAI.NumberTheory.Adeles.FiniteCharacter.CompletionFactors |
| 6 | |
| 7 | noncomputable section |
| 8 | |
| 9 | section |
| 10 | |
| 11 | /-! The fractional ideal of a finite idele and principal powers. -/ |
| 12 | |
| 13 | open _root_.NumberField IsDedekindDomain HeightOneSpectrum |
| 14 | open scoped _root_.NumberField _root_.Topology WithZero nonZeroDivisors |
| 15 | |
| 16 | variable {K : Type*} [Field K] [NumberField K] |
| 17 | |
| 18 | def finiteIdeleOrder (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) (v : HeightOneSpectrum (𝓞 K)) : ℤ := |
| 19 | -WithZero.log (Valued.v (a.val v)) |
| 20 | |
| 21 | theorem finiteIdeleOrder_support (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) : |
| 22 | ∀ᶠ v : HeightOneSpectrum (𝓞 K) in Filter.cofinite, finiteIdeleOrder a v = 0 := by |
| 23 | filter_upwards [FiniteAdeleRing.unitsEquiv_finite_valued_eq_one a] with v hv |
| 24 | change Valued.v (a.val v) = 1 at hv |
| 25 | simp [finiteIdeleOrder, hv] |
| 26 | |
| 27 | def finiteIdeleIdeal (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) : FractionalIdeal (𝓞 K)⁰ K := |
| 28 | ∏ᶠ v : HeightOneSpectrum (𝓞 K), |
| 29 | (v.asIdeal : FractionalIdeal (𝓞 K)⁰ K) ^ finiteIdeleOrder a v |
| 30 | |
| 31 | theorem finiteIdeleIdeal_ne_zero (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) : finiteIdeleIdeal a ≠ 0 := by |
| 32 | apply finprod_ne_zero |
| 33 | intro v |
| 34 | exact zpow_ne_zero _ (FractionalIdeal.coeIdeal_ne_zero.mpr v.ne_bot) |
| 35 | |
| 36 | theorem finiteIdeleIdeal_count (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) (v : HeightOneSpectrum (𝓞 K)) : |
| 37 | FractionalIdeal.count K v (finiteIdeleIdeal a) = finiteIdeleOrder a v := |
| 38 | FractionalIdeal.count_finprod K v _ (finiteIdeleOrder_support a) |
| 39 | |
| 40 | theorem count_spanSingleton_integer (v : HeightOneSpectrum (𝓞 K)) |
| 41 | (a : 𝓞 K) (ha : a ≠ 0) : |
| 42 | FractionalIdeal.count K v (FractionalIdeal.spanSingleton (𝓞 K)⁰ (a : K)) = |
| 43 | -WithZero.log (v.valuation K (a : K)) := by |
| 44 | rw [← FractionalIdeal.coeIdeal_span_singleton, |
| 45 | FractionalIdeal.count_coe K v (J := Ideal.span {a}) (by simpa using ha), valuation_of_algebraMap, |
| 46 | intValuation_if_neg _ ha, WithZero.log_exp, neg_neg] |
| 47 | |
| 48 | theorem count_spanSingleton (v : HeightOneSpectrum (𝓞 K)) (x : K) (hx : x ≠ 0) : |
| 49 | FractionalIdeal.count K v (FractionalIdeal.spanSingleton (𝓞 K)⁰ x) = |
| 50 | -WithZero.log (v.valuation K x) := by |
| 51 | obtain ⟨a, b, hb, hab⟩ := IsFractionRing.div_surjective (A := 𝓞 K) x |
| 52 | have hb0 : b ≠ 0 := nonZeroDivisors.ne_zero hb |
| 53 | have ha : a ≠ 0 := by |
| 54 | intro h |
| 55 | apply hx |
| 56 | rw [← hab, h, map_zero, zero_div] |
| 57 | rw [← hab, ← FractionalIdeal.spanSingleton_div_spanSingleton, div_eq_mul_inv, |
| 58 | FractionalIdeal.count_mul _ _ (FractionalIdeal.spanSingleton_ne_zero_iff.mpr |
| 59 | (RingOfIntegers.coe_ne_zero_iff.mpr ha)) (inv_ne_zero |
| 60 | (FractionalIdeal.spanSingleton_ne_zero_iff.mpr (RingOfIntegers.coe_ne_zero_iff.mpr hb0))), |
| 61 | FractionalIdeal.count_inv, count_spanSingleton_integer v a ha, |
| 62 | count_spanSingleton_integer v b hb0, map_div₀, |
| 63 | WithZero.log_div ((Valuation.ne_zero_iff _).mpr (RingOfIntegers.coe_ne_zero_iff.mpr ha)) |
| 64 | ((Valuation.ne_zero_iff _).mpr (RingOfIntegers.coe_ne_zero_iff.mpr hb0))] |
| 65 | ring |
| 66 | |
| 67 | theorem fractionalIdeal_exists_principal_power (I : FractionalIdeal (𝓞 K)⁰ K) (hI : I ≠ 0) : |
| 68 | ∃ (n : ℕ) (x : Kˣ), 0 < n ∧ I ^ n = FractionalIdeal.spanSingleton (𝓞 K)⁰ x.val := by |
| 69 | let u : (FractionalIdeal (𝓞 K)⁰ K)ˣ := Units.mk0 I hI |
| 70 | let n := Fintype.card (ClassGroup (𝓞 K)) |
| 71 | have hp : (↑(u ^ n) : Submodule (𝓞 K) K).IsPrincipal := by |
| 72 | apply ClassGroup.mk_eq_one_iff.mp |
| 73 | rw [map_pow] |
| 74 | exact pow_card_eq_one |
| 75 | obtain ⟨x, hx⟩ := hp.principal |
| 76 | have he : I ^ n = FractionalIdeal.spanSingleton (𝓞 K)⁰ x := by |
| 77 | apply FractionalIdeal.coeToSubmodule_injective |
| 78 | change (I ^ n : Submodule (𝓞 K) K) = |
| 79 | (FractionalIdeal.spanSingleton (𝓞 K)⁰ x : Submodule (𝓞 K) K) |
| 80 | rw [FractionalIdeal.coe_spanSingleton] |
| 81 | simp only [Units.val_pow_eq_pow_val, u, Units.val_mk0] at hx |
| 82 | exact hx |
| 83 | have hx0 : x ≠ 0 := by |
| 84 | intro h |
| 85 | apply pow_ne_zero n hI |
| 86 | simpa [h] using he |
| 87 | exact ⟨n, Units.mk0 x hx0, Fintype.card_pos, he⟩ |
| 88 | |
| 89 | theorem finiteIdele_exists_principal_power (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) : |
| 90 | ∃ (n : ℕ) (x : Kˣ), 0 < n ∧ |
| 91 | ∀ v : HeightOneSpectrum (𝓞 K), |
| 92 | Valued.v (a.val v) ^ n = v.valuation K x.val := by |
| 93 | obtain ⟨n, x, hn, hx⟩ := fractionalIdeal_exists_principal_power |
| 94 | (finiteIdeleIdeal a) (finiteIdeleIdeal_ne_zero a) |
| 95 | refine ⟨n, x, hn, fun v => ?_⟩ |
| 96 | have hv0 : Valued.v (a.val v) ≠ 0 := |
| 97 | (Valuation.ne_zero_iff _).mpr (Units.ne_zero (RestrictedProduct.unitsEquiv _ a v)) |
| 98 | have hx0 : v.valuation K x.val ≠ 0 := (Valuation.ne_zero_iff _).mpr x.ne_zero |
| 99 | have hc := congrArg (FractionalIdeal.count K v) hx |
| 100 | rw [FractionalIdeal.count_pow, finiteIdeleIdeal_count, count_spanSingleton v x.val x.ne_zero, |
| 101 | finiteIdeleOrder, mul_neg] at hc |
| 102 | have hlog : WithZero.log (Valued.v (a.val v) ^ n) = WithZero.log (v.valuation K x.val) := by |
| 103 | rw [WithZero.log_pow, nsmul_eq_mul] |
| 104 | exact neg_injective hc |
| 105 | have he := congrArg WithZero.exp hlog |
| 106 | simpa only [WithZero.exp_log (pow_ne_zero n hv0), WithZero.exp_log hx0] using he |
| 107 | |
| 108 | end |
| 109 | |
| 110 | /-! Finite idele characters are determined by principal ideles and integral units. -/ |
| 111 | |
| 112 | open _root_.NumberField IsDedekindDomain HeightOneSpectrum |
| 113 | open scoped _root_.NumberField _root_.Topology WithZero NNReal |
| 114 | |
| 115 | variable {K : Type*} [Field K] [NumberField K] |
| 116 | |
| 117 | def finitePrincipal : Kˣ →* (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ := |
| 118 | Units.map (algebraMap K (LocalCompletions.CompletionFactors.FiniteAdele K)).toMonoidHom |
| 119 | |
| 120 | theorem finiteIdele_exists_principal_unit_power (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) : |
| 121 | ∃ (n : ℕ) (x : Kˣ) (u : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ), 0 < n ∧ |
| 122 | a ^ n = u * finitePrincipal x ∧ |
| 123 | ∀ v : HeightOneSpectrum (𝓞 K), Valued.v (u.val v) = 1 := by |
| 124 | obtain ⟨n, x, hn, hv⟩ := finiteIdele_exists_principal_power a |
| 125 | let u := a ^ n / finitePrincipal x |
| 126 | refine ⟨n, x, u, hn, (div_mul_cancel _ _).symm, fun v => ?_⟩ |
| 127 | have he : u.val v = a.val v ^ n / algebraMap K (v.adicCompletion K) x.val := by |
| 128 | let ev : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ →* (v.adicCompletion K)ˣ := |
| 129 | Units.map (RestrictedProduct.evalMonoidHom (fun w : HeightOneSpectrum (𝓞 K) => |
| 130 | w.adicCompletion K) v) |
| 131 | have h := congrArg Units.val (map_div ev (a ^ n) (finitePrincipal x)) |
| 132 | rw [map_pow, Units.val_div_eq_div_val, Units.val_pow_eq_pow_val] at h |
| 133 | exact h |
| 134 | rw [he, map_div₀, map_pow, hv] |
| 135 | change v.valuation K x.val / Valued.v (x.val : v.adicCompletion K) = 1 |
| 136 | rw [adicCompletion.valued_coe] |
| 137 | exact div_self ((Valuation.ne_zero_iff _).mpr x.ne_zero) |
| 138 | |
| 139 | theorem finiteIdele_integral_of_valuation_one (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) |
| 140 | (ha : ∀ v : HeightOneSpectrum (𝓞 K), Valued.v (a.val v) = 1) : |
| 141 | (∀ v : HeightOneSpectrum (𝓞 K), a.val v ∈ v.adicCompletionIntegers K) ∧ |
| 142 | (∀ v : HeightOneSpectrum (𝓞 K), a.inv v ∈ v.adicCompletionIntegers K) := by |
| 143 | constructor |
| 144 | · intro v |
| 145 | exact (ha v).le |
| 146 | · intro v |
| 147 | have hi : a.inv v = (a.val v)⁻¹ := by |
| 148 | apply eq_inv_of_mul_eq_one_left |
| 149 | exact congrArg (fun b : LocalCompletions.CompletionFactors.FiniteAdele K => b v) a.inv_val |
| 150 | change Valued.v (a.inv v) ≤ 1 |
| 151 | rw [hi, map_inv₀, ha v, inv_one] |
| 152 | |
| 153 | theorem finiteCharacter_eq (p q : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ →* ℝ≥0) |
| 154 | (hp : ∀ u : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ, |
| 155 | (∀ v : HeightOneSpectrum (𝓞 K), Valued.v (u.val v) = 1) → p u = 1) |
| 156 | (hq : ∀ u : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ, |
| 157 | (∀ v : HeightOneSpectrum (𝓞 K), Valued.v (u.val v) = 1) → q u = 1) |
| 158 | (hprincipal : ∀ x : Kˣ, p (finitePrincipal x) = q (finitePrincipal x)) |
| 159 | (a : (LocalCompletions.CompletionFactors.FiniteAdele K)ˣ) : p a = q a := by |
| 160 | obtain ⟨n, x, u, hn, he, hu⟩ := finiteIdele_exists_principal_unit_power a |
| 161 | have hpow : p a ^ n = q a ^ n := by |
| 162 | rw [← map_pow, ← map_pow, he, map_mul, map_mul, hp u hu, hq u hu, |
| 163 | one_mul, one_mul, hprincipal] |
| 164 | exact (pow_left_injective hn.ne') hpow |
| 165 | |
| 166 | end |
| 167 | |
| 168 | end OAI.NumberTheory.Adeles.FiniteCharacter.CompletionFactors |