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 | /-! # Local Completions -/ |
| 4 | |
| 5 | namespace OAI.NumberTheory.Adeles.LocalCompletions.CompletionFactors |
| 6 | |
| 7 | noncomputable section |
| 8 | |
| 9 | section |
| 10 | |
| 11 | /-! The absolute idele modulus, constructed from normalized local absolute values. -/ |
| 12 | |
| 13 | open _root_.NumberField IsDedekindDomain |
| 14 | open scoped _root_.NumberField _root_.Topology NNReal |
| 15 | |
| 16 | abbrev Adele (K : Type*) [Field K] [NumberField K] := AdeleRing (𝓞 K) K |
| 17 | abbrev FiniteAdele (K : Type*) [Field K] [NumberField K] := FiniteAdeleRing (𝓞 K) K |
| 18 | abbrev Idele (K : Type*) [Field K] [NumberField K] := (Adele K)ˣ |
| 19 | |
| 20 | def principalIdele (K : Type*) [Field K] [NumberField K] : Kˣ →* Idele K := |
| 21 | Units.map (algebraMap K (Adele K)).toMonoidHom |
| 22 | |
| 23 | abbrev IdeleClass (K : Type*) [Field K] [NumberField K] := |
| 24 | Idele K ⧸ (principalIdele K).range |
| 25 | |
| 26 | variable {K : Type*} [Field K] [NumberField K] |
| 27 | |
| 28 | /-- Only finitely many normalized finite-place factors differ from one. -/ |
| 29 | theorem finite_norm_support (a : (FiniteAdele K)ˣ) : |
| 30 | Function.HasFiniteMulSupport (fun v : HeightOneSpectrum (𝓞 K) => ‖a.val v‖₊) := by |
| 31 | have h := FiniteAdeleRing.unitsEquiv_finite_valued_eq_one a |
| 32 | have hnorm : ∀ᶠ v : HeightOneSpectrum (𝓞 K) in Filter.cofinite, ‖a.val v‖₊ = 1 := by |
| 33 | filter_upwards [h] with v hv |
| 34 | apply NNReal.eq |
| 35 | change ‖a.val v‖ = 1 |
| 36 | rw [FinitePlace.norm_def] |
| 37 | change ((WithZeroMulInt.toNNReal (HeightOneSpectrum.absNorm_ne_zero v)) |
| 38 | (Valued.v (a.val v)) : ℝ) = 1 |
| 39 | change Valued.v (a.val v) = 1 at hv |
| 40 | simp [hv] |
| 41 | exact hnorm |
| 42 | |
| 43 | /-- The finite part of the absolute modulus. -/ |
| 44 | def finiteModulus : (FiniteAdele K)ˣ →* ℝ≥0 where |
| 45 | toFun a := ∏ᶠ v : HeightOneSpectrum (𝓞 K), ‖a.val v‖₊ |
| 46 | map_one' := by |
| 47 | change (∏ᶠ v : HeightOneSpectrum (𝓞 K), ‖(1 : v.adicCompletion K)‖₊) = 1 |
| 48 | simp |
| 49 | map_mul' a b := by |
| 50 | change (∏ᶠ v : HeightOneSpectrum (𝓞 K), ‖a.val v * b.val v‖₊) = _ |
| 51 | simp only [nnnorm_mul] |
| 52 | exact finprod_mul_distrib (finite_norm_support a) (finite_norm_support b) |
| 53 | |
| 54 | def infiniteModulus : (InfiniteAdeleRing K)ˣ →* ℝ≥0 where |
| 55 | toFun a := ∏ v : InfinitePlace K, ‖a.val v‖₊ ^ v.mult |
| 56 | map_one' := by |
| 57 | change (∏ v : InfinitePlace K, ‖(1 : v.Completion)‖₊ ^ v.mult) = 1 |
| 58 | simp |
| 59 | map_mul' a b := by |
| 60 | change (∏ v : InfinitePlace K, ‖a.val v * b.val v‖₊ ^ v.mult) = _ |
| 61 | simp only [nnnorm_mul, mul_pow, Finset.prod_mul_distrib] |
| 62 | |
| 63 | theorem finiteModulus_eq_one_of_integral |
| 64 | (a : (FiniteAdele K)ˣ) |
| 65 | (ha : ∀ v : HeightOneSpectrum (𝓞 K), a.val v ∈ v.adicCompletionIntegers K) |
| 66 | (hi : ∀ v : HeightOneSpectrum (𝓞 K), a.inv v ∈ v.adicCompletionIntegers K) : |
| 67 | finiteModulus a = 1 := by |
| 68 | apply finprod_eq_one_of_forall_eq_one |
| 69 | intro v |
| 70 | have hv : Valued.v (a.val v) = 1 := |
| 71 | (HeightOneSpectrum.adicCompletionIntegers.mem_units_iff_valued_eq_one |
| 72 | (a := RestrictedProduct.unitsEquiv _ a v)).mp ⟨ha v, hi v⟩ |
| 73 | apply NNReal.eq |
| 74 | change ‖a.val v‖ = 1 |
| 75 | rw [FinitePlace.norm_def] |
| 76 | simp [hv] |
| 77 | |
| 78 | theorem continuous_finiteModulus : Continuous (finiteModulus (K := K)) := by |
| 79 | apply continuous_of_continuousAt_one |
| 80 | have ho : IsOpen {a : FiniteAdele K | |
| 81 | ∀ v : HeightOneSpectrum (𝓞 K), a v ∈ v.adicCompletionIntegers K} := |
| 82 | RestrictedProduct.isOpen_forall_mem |
| 83 | (fun v : HeightOneSpectrum (𝓞 K) => Valued.isOpen_valuationSubring (v.adicCompletion K)) |
| 84 | have hv := ho.preimage (Units.continuous_val (M := FiniteAdele K)) |
| 85 | have hi := ho.preimage (Units.continuous_coe_inv (M := FiniteAdele K)) |
| 86 | apply continuousAt_const.congr_of_eventuallyEq |
| 87 | filter_upwards [(hv.inter hi).mem_nhds (show (1 : (FiniteAdele K)ˣ) ∈ _ from |
| 88 | ⟨fun v => (v.adicCompletionIntegers K).one_mem, |
| 89 | fun v => (v.adicCompletionIntegers K).one_mem⟩)] with a ha |
| 90 | exact finiteModulus_eq_one_of_integral a ha.1 ha.2 |
| 91 | |
| 92 | theorem continuous_infiniteModulus : Continuous (infiniteModulus (K := K)) := by |
| 93 | apply continuous_finsetProd |
| 94 | intro v _ |
| 95 | have he : Continuous (fun a : InfiniteAdeleRing K => a v) := continuous_apply v |
| 96 | exact (he.comp (Units.continuous_val (M := InfiniteAdeleRing K))).nnnorm.pow v.mult |
| 97 | |
| 98 | def finiteIdeleProjection : Idele K →* (FiniteAdele K)ˣ := |
| 99 | Units.map (MonoidHom.snd (InfiniteAdeleRing K) (FiniteAdele K)) |
| 100 | |
| 101 | def infiniteIdeleProjection : Idele K →* (InfiniteAdeleRing K)ˣ := |
| 102 | Units.map (MonoidHom.fst (InfiniteAdeleRing K) (FiniteAdele K)) |
| 103 | |
| 104 | /-- The full product of normalized local absolute values. -/ |
| 105 | def ideleModulusNonneg : Idele K →* ℝ≥0 := |
| 106 | (infiniteModulus.comp infiniteIdeleProjection) * |
| 107 | (finiteModulus.comp finiteIdeleProjection) |
| 108 | |
| 109 | theorem continuous_ideleModulusNonneg : Continuous (ideleModulusNonneg (K := K)) := by |
| 110 | apply Continuous.mul |
| 111 | · exact continuous_infiniteModulus.comp (Continuous.units_map _ continuous_fst) |
| 112 | · exact continuous_finiteModulus.comp (Continuous.units_map _ continuous_snd) |
| 113 | |
| 114 | theorem infiniteModulus_principal (x : Kˣ) : |
| 115 | (infiniteModulus (infiniteIdeleProjection (principalIdele K x)) : ℝ) = |
| 116 | |Algebra.norm ℚ (x : K)| := by |
| 117 | change ((∏ v : InfinitePlace K, |
| 118 | ‖(algebraMap K (InfiniteAdeleRing K) (x : K)) v‖₊ ^ v.mult : ℝ≥0) : ℝ) = _ |
| 119 | simp only [NNReal.coe_prod, NNReal.coe_pow, coe_nnnorm] |
| 120 | exact InfiniteAdeleRing.coe_norm_eq_abs_norm (x : K) |
| 121 | |
| 122 | theorem finiteModulus_principal (x : Kˣ) : |
| 123 | (finiteModulus (finiteIdeleProjection (principalIdele K x)) : ℝ) = |
| 124 | |Algebra.norm ℚ (x : K)|⁻¹ := by |
| 125 | change ((∏ᶠ v : HeightOneSpectrum (𝓞 K), |
| 126 | ‖FinitePlace.embedding v (x : K)‖₊ : ℝ≥0) : ℝ) = _ |
| 127 | have hcast := NNReal.toRealHom.toMonoidHom.map_finprod_of_injective |
| 128 | NNReal.coe_injective (fun v : HeightOneSpectrum (𝓞 K) => ‖FinitePlace.embedding v (x : K)‖₊) |
| 129 | change ((∏ᶠ v : HeightOneSpectrum (𝓞 K), |
| 130 | ‖FinitePlace.embedding v (x : K)‖₊ : ℝ≥0) : ℝ) = |
| 131 | ∏ᶠ v : HeightOneSpectrum (𝓞 K), ‖FinitePlace.embedding v (x : K)‖ at hcast |
| 132 | rw [hcast] |
| 133 | change (∏ᶠ v : HeightOneSpectrum (𝓞 K), ‖FinitePlace.embedding v (x : K)‖) = _ |
| 134 | rw [← finprod_comp_equiv FinitePlace.equivHeightOneSpectrum] |
| 135 | change (∏ᶠ v : FinitePlace K, ‖FinitePlace.embedding v.maximalIdeal (x : K)‖) = _ |
| 136 | simp_rw [FinitePlace.norm_embedding_eq] |
| 137 | exact FinitePlace.prod_eq_inv_abs_norm (Units.ne_zero x) |
| 138 | |
| 139 | /-- The actual product formula kills the diagonal multiplicative group. -/ |
| 140 | theorem ideleModulusNonneg_principal (x : Kˣ) : |
| 141 | ideleModulusNonneg (principalIdele K x) = 1 := by |
| 142 | apply NNReal.eq |
| 143 | change (infiniteModulus (infiniteIdeleProjection (principalIdele K x)) : ℝ) * |
| 144 | (finiteModulus (finiteIdeleProjection (principalIdele K x)) : ℝ) = 1 |
| 145 | rw [infiniteModulus_principal, finiteModulus_principal] |
| 146 | have hn : Algebra.norm ℚ (x : K) ≠ 0 := Algebra.norm_ne_zero_iff.mpr (Units.ne_zero x) |
| 147 | have hnR : (Algebra.norm ℚ (x : K) : ℝ) ≠ 0 := by exact_mod_cast hn |
| 148 | simpa only [Rat.cast_abs, Rat.cast_inv] using mul_inv_cancel₀ (abs_ne_zero.mpr hnR) |
| 149 | |
| 150 | /-- Nonnegative units are the multiplicative group of positive real numbers. -/ |
| 151 | def ideleModulus : Idele K →ₜ* ℝ≥0ˣ where |
| 152 | toMonoidHom := ideleModulusNonneg.toHomUnits |
| 153 | continuous_toFun := Units.continuous_iff.mpr |
| 154 | ⟨continuous_ideleModulusNonneg, continuous_ideleModulusNonneg.comp continuous_inv⟩ |
| 155 | |
| 156 | theorem ideleModulus_principal (x : Kˣ) : ideleModulus (principalIdele K x) = 1 := by |
| 157 | apply Units.ext |
| 158 | exact ideleModulusNonneg_principal x |
| 159 | |
| 160 | /-- The absolute modulus descends to the concrete quotient by principal ideles. -/ |
| 161 | def ideleClassModulus : IdeleClass K →ₜ* ℝ≥0ˣ where |
| 162 | toMonoidHom := QuotientGroup.lift (principalIdele K).range ideleModulus.toMonoidHom (by |
| 163 | rintro a ⟨x, rfl⟩ |
| 164 | exact ideleModulus_principal x) |
| 165 | continuous_toFun := (QuotientGroup.isQuotientMap_mk (principalIdele K).range).continuous_iff.mpr |
| 166 | ideleModulus.continuous |
| 167 | |
| 168 | @[simp] theorem ideleClassModulus_mk (a : Idele K) : |
| 169 | ideleClassModulus (QuotientGroup.mk a) = ideleModulus a := rfl |
| 170 | |
| 171 | /-- The descended map computes the prescribed normalized product on representatives. -/ |
| 172 | theorem ideleClassModulus_mk_formula (a : Idele K) : |
| 173 | (ideleClassModulus (QuotientGroup.mk a) : ℝ≥0) = |
| 174 | (∏ v : InfinitePlace K, ‖a.val.1 v‖₊ ^ v.mult) * |
| 175 | ∏ᶠ v : HeightOneSpectrum (𝓞 K), ‖a.val.2 v‖₊ := rfl |
| 176 | |
| 177 | theorem ideleModulus_principal_mul (x : Kˣ) (a : Idele K) : |
| 178 | ideleModulus (principalIdele K x * a) = ideleModulus a := by |
| 179 | rw [map_mul, ideleModulus_principal, one_mul] |
| 180 | |
| 181 | /-- Norm-one ideles, defined by the constructed absolute modulus. -/ |
| 182 | def normOneIdeles (K : Type*) [Field K] [NumberField K] : Subgroup (Idele K) := |
| 183 | (ideleModulus (K := K)).toMonoidHom.ker |
| 184 | |
| 185 | /-- Norm-one idele classes, with the inherited topology. -/ |
| 186 | def normOneIdeleClasses (K : Type*) [Field K] [NumberField K] : Subgroup (IdeleClass K) := |
| 187 | (ideleClassModulus (K := K)).toMonoidHom.ker |
| 188 | |
| 189 | /-- The product formula places the diagonal group inside the norm-one ideles. -/ |
| 190 | def principalNormOne : Kˣ →* normOneIdeles K := |
| 191 | (principalIdele K).codRestrict (normOneIdeles K) ideleModulus_principal |
| 192 | |
| 193 | end |
| 194 | |
| 195 | /-! Canonical extension maps between completions at finite places. -/ |
| 196 | |
| 197 | open _root_.NumberField IsDedekindDomain HeightOneSpectrum |
| 198 | open scoped _root_.NumberField _root_.Topology |
| 199 | |
| 200 | variable {F E : Type*} [Field F] [NumberField F] |
| 201 | [Field E] [NumberField E] [Algebra F E] |
| 202 | (v : HeightOneSpectrum (𝓞 F)) (w : HeightOneSpectrum (𝓞 E)) |
| 203 | [w.asIdeal.LiesOver v.asIdeal] |
| 204 | |
| 205 | /-- Extension of the field embedding to the completions at `w | v`. -/ |
| 206 | def finiteCompletionMap : v.adicCompletion F →+* w.adicCompletion E := |
| 207 | ((adicCompletion.equiv E w).symm.toRingHom.comp |
| 208 | (UniformSpace.Completion.mapRingHom |
| 209 | (algebraMap (WithVal (v.valuation F)) (WithVal (w.valuation E))) |
| 210 | (uniformContinuous_algebraMap_liesOver (K := F) (L := E) v w).continuous)).comp |
| 211 | (adicCompletion.equiv F v).toRingHom |
| 212 | |
| 213 | theorem continuous_finiteCompletionMap : Continuous (finiteCompletionMap v w) := |
| 214 | (adicCompletion.continuous_ofCompletion E w).comp |
| 215 | (UniformSpace.Completion.continuous_map.comp |
| 216 | (adicCompletion.continuous_toCompletion F v)) |
| 217 | |
| 218 | @[simp] theorem finiteCompletionMap_coe (x : F) : |
| 219 | finiteCompletionMap v w (x : v.adicCompletion F) = |
| 220 | (algebraMap F E x : w.adicCompletion E) := by |
| 221 | apply adicCompletion.ext |
| 222 | change UniformSpace.Completion.mapRingHom |
| 223 | (algebraMap (WithVal (v.valuation F)) (WithVal (w.valuation E))) _ |
| 224 | ((WithVal.equiv (v.valuation F)).symm x : UniformSpace.Completion _) = _ |
| 225 | rw [UniformSpace.Completion.mapRingHom_coe] |
| 226 | rfl |
| 227 | |
| 228 | namespace FiniteLiesOver |
| 229 | |
| 230 | /-- Scoped to avoid a second algebra structure when the two fields coincide. -/ |
| 231 | scoped instance : Algebra (v.adicCompletion F) (w.adicCompletion E) := |
| 232 | (finiteCompletionMap v w).toAlgebra |
| 233 | |
| 234 | scoped instance : IsScalarTower F (v.adicCompletion F) (w.adicCompletion E) := |
| 235 | .of_algebraMap_eq fun x => (finiteCompletionMap_coe v w x).symm |
| 236 | |
| 237 | scoped instance : ContinuousSMul (v.adicCompletion F) (w.adicCompletion E) where |
| 238 | continuous_smul := |
| 239 | ((continuous_finiteCompletionMap v w).comp continuous_fst).mul continuous_snd |
| 240 | |
| 241 | end FiniteLiesOver |
| 242 | |
| 243 | open scoped OAI.NumberTheory.Adeles.LocalCompletions.CompletionFactors.FiniteLiesOver |
| 244 | |
| 245 | /-- The completion extension is finite-dimensional, using density and finite-dimensional closure. -/ |
| 246 | theorem finiteCompletion_finiteDimensional : |
| 247 | FiniteDimensional (v.adicCompletion F) (w.adicCompletion E) := inferInstance |
| 248 | |
| 249 | end |
| 250 | |
| 251 | end OAI.NumberTheory.Adeles.LocalCompletions.CompletionFactors |