Riemann hypothesis: the Lean proof, cleaned up together
The 2026 Lean proof of the Riemann hypothesis and GRH, machine-checked by others, not refereed, no word from Clay; cleaned up together: more readable, faster to build, the theorems unchanged

| 1 | module |
| 2 | |
| 3 | public import New.Derivatives.FormalGroup.Resolution |
| 4 | public import New.Derivatives.Vacuum.IntegralVacuum |
| 5 | |
| 6 | /-! |
| 7 | # The scale of the Taylor series of a vector |
| 8 | |
| 9 | * `New.Space.jet_jetSeries_of_isHomogeneous`: the derivative of the Taylor series along a |
| 10 | homogeneous polynomial is a theta value times a power of the scale. |
| 11 | * `New.Parameters.norm_periodFactor_mul_daggerForms_le_one`: the scaled linear form of a vector `y` |
| 12 | is integral at `p` if `α⁻¹ y` is integral above `p`. |
| 13 | |
| 14 | The period scale is `jetScale` times an integer `π_M` of `K` of norm `M`. The statement with this |
| 15 | factor is `New.Data.norm_taylorScale_eq_one_of_not_dvd`. |
| 16 | |
| 17 | The statements use these notions: |
| 18 | * `jetSeries a f`: the Taylor series of the theta function of `f`, with variables scaled by `a`; |
| 19 | `jetPairing Q F` is the derivative at zero of the series `F` along the polynomial `Q`. |
| 20 | * `daggerForms u j`: the coefficients in `ℂ_p` of the linear form `z ↦ y† z` of the vector |
| 21 | `y = u j`; at a pair `(v, i)` of an infinite place and a coordinate the coefficient is the image |
| 22 | in `ℂ_p` of the complex conjugate of `Φ_v (y i)`, with `Φ_v` the embedding chosen at `v`. |
| 23 | * `periodFactor`: the complex number `vacuumRoot / chowlaSelbergUnit`, where `vacuumRoot` is a root |
| 24 | of the inverse of the value `chiFin α` of a character at the idele `α` and the denominator is a |
| 25 | unit at every `p`-adic place; `jetScale` is `periodFactor * √(2π / √d) / cmPeriod`, where |
| 26 | `cmPeriod * 𝓞_K` is the lattice of the CM curve of the field `K = ℚ(i√d)`. |
| 27 | |
| 28 | ## Relation to the literature |
| 29 | |
| 30 | The modulus of `jetScale` is computed from the formula of Chowla and Selberg, |
| 31 | `New.CMLattice.chowla_selberg`. |
| 32 | -/ |
| 33 | |
| 34 | @[expose] public section |
| 35 | |
| 36 | open NumberField ComplexConjugate MvPolynomial |
| 37 | |
| 38 | namespace New |
| 39 | |
| 40 | /-- Scaling all variables of a power series `F` by `a` multiplies the derivative `jetPairing Q F` at |
| 41 | zero along a homogeneous polynomial `Q` of degree `l` by `a ^ l`. -/ |
| 42 | lemma jet_rescale {R X : Type*} [CommSemiring R] {Q : MvPolynomial X R} {l : ℕ} |
| 43 | (hQ : Q.IsHomogeneous l) (a : R) (F : MvPowerSeries X R) : |
| 44 | jetPairing Q (MvPowerSeries.rescale (fun (_ : X) ↦ a) F) = a ^ l * jetPairing Q F := by |
| 45 | rw [jetPairing_eq_sum, jetPairing_eq_sum, Finset.mul_sum] |
| 46 | refine Finset.sum_congr rfl fun α hα ↦ ?_ |
| 47 | simp only [MvPowerSeries.coeff_rescale, Finsupp.prod, Finset.prod_pow_eq_pow_sum, |
| 48 | ← hQ.degree_eq_sum_deg_support hα] |
| 49 | ac_rfl |
| 50 | |
| 51 | /-- Let `E` be a CM number field with a chosen CM type (`CMType`) and the data of its Weil |
| 52 | representation (`WeilData`). For a homogeneous polynomial `Q` of degree `l` and a vector `f` of |
| 53 | the Weil representation `𝒮 V` of the hermitian space `V` with signs `ε`, the derivative at zero |
| 54 | along `Q` of the series `V.jetSeries a f` is `a ^ l θ(v_Q ⊗ f)`. Here `θ` is the theta functional, |
| 55 | `realSigns E ε` gives each pair (infinite place, coordinate) the sign of the coordinate, |
| 56 | `v_Q = polyVector Q` is the Fock vector of `Q` for these signs, and `⊗` is `V.integrated`, the |
| 57 | bilinear map that integrates the action of the real Heisenberg group on `f` against `v_Q`. The |
| 58 | series `V.jetSeries a f` has one variable for each such pair; its coefficient at the monomial |
| 59 | `z ^ α` is `a ^ |α| / α! * θ(v_{z ^ α} ⊗ f)`. -/ |
| 60 | lemma Space.jet_jetSeries_of_isHomogeneous {E n : Type} [Field E] [CMType E] [WeilData E] |
| 61 | [Fintype n] [DecidableEq n] {ε : n → ℤˣ} (V : Space E n ε) |
| 62 | {Q : MvPolynomial (InfinitePlace E × n) ℂ} {l : ℕ} (hQ : Q.IsHomogeneous l) (a : ℂ) (f : 𝒮 V) : |
| 63 | jetPairing Q (V.jetSeries a f) = |
| 64 | a ^ l * V.θ (V.integrated (Fock.polyVector (realSigns E ε) Q) f) := by |
| 65 | -- Write the scale as `a * 1`, take out `a ^ l` and use the formula at the scale `1`. |
| 66 | rw [← mul_one a, jetSeries_mul_eq_rescale, jet_rescale hQ, jet_jetSeries_eq_theta, mul_one] |
| 67 | simp only [one_smul, aeval_X_left_apply] |
| 68 | |
| 69 | /-- Let `σ` be an embedding of the number field `E` into a `p`-adic field `F`, that is, a normed |
| 70 | algebra over `ℚ_p` that is a field, here ultrametric and not necessarily complete. The image of a |
| 71 | finite adele `x` under the extension of `σ` to finite adeles has norm at most one if and only if |
| 72 | the component of `x` at the place induced by `σ` is integral. -/ |
| 73 | lemma norm_adeleExtension_le_one_iff {E F : Type} [Field E] [NumberField E] {p : ℕ} [Fact p.Prime] |
| 74 | [NormedField F] [IsUltrametricDist F] [CharZero F] [PadicField F p] (σ : E →+* F) |
| 75 | {x : 𝔸f E} : ‖adeleExtension σ x‖ ≤ 1 ↔ Valued.v (evalAt (placeOfEmb σ) x) ≤ 1 := by |
| 76 | -- `adeleExtension σ` is by definition the component at the place, mapped by the extension of `σ`. |
| 77 | change ‖placeOfEmbExtension σ (evalAt (placeOfEmb σ) x)‖ ≤ 1 ↔ _ |
| 78 | exact (valuation_comap_placeOfEmbExtension_isEquiv σ).le_one_iff_le_one |
| 79 | |
| 80 | namespace Parameters |
| 81 | |
| 82 | /-- Let `y = u j` be a vector over the field `E = P.E s` of the parameters at the index `s`, a |
| 83 | cyclotomic extension of `K = P.K = ℚ(i√d)`, and `α = P.α s` their idele. Let `ιₚ : ℂ → ℂ_p` be the |
| 84 | ring homomorphism chosen by `PadicPlace p`. For a pair `x = (v, i)` of an infinite place of `E` and |
| 85 | a coordinate, `daggerForms u j x` is the image under `ιₚ` of the complex conjugate of `Φ_v (y i)`, |
| 86 | with `Φ_v : E → ℂ` the embedding that the CM type chooses at `v`. If the finite adelic vector |
| 87 | `α⁻¹ y` (`finiteImage (u j)`) is integral at all places above `p` (`integralAfter 1`), then the |
| 88 | product of `ιₚ periodFactor` and this coefficient has norm at most one. -/ |
| 89 | lemma norm_periodFactor_mul_daggerForms_le_one {P : Parameters} {s : ℕ} {n : Type} {p : ℕ} |
| 90 | [Fact p.Prime] [PadicPlace p] {J : Type} {u : J → n → P.E s} {j : J} |
| 91 | (h_integral : |
| 92 | finiteImage (u j) ∈ integralAfter (1 : 𝓞 P.K) fun w : FinPlace (P.E s) ↦ ↑p ∈ w.asIdeal) |
| 93 | (x : InfinitePlace (P.E s) × n) : |
| 94 | ‖ιₚ (P.periodFactor s) * daggerForms u j x‖ ≤ 1 := by |
| 95 | -- The norm in question is that of the coordinate `x.2` of `α⁻¹ y` at the place given by `x.1`. |
| 96 | let σ : P.E s →+* ℂ_[p] := weightEmbedding ιₚ x.1 |
| 97 | have h_int : ‖adeleExtension σ (finiteImage (u j) x.2)‖ ≤ 1 := by |
| 98 | have h_val : Valued.v (evalAt (placeOfEmb σ) |
| 99 | (algebraMap (P.E s) (𝔸f (P.E s)) (algebraMap P.K (P.E s) ((1 : 𝓞 P.K) : P.K)) * |
| 100 | finiteImage (u j) x.2)) ≤ 1 := h_integral x.2 _ (natCast_mem_placeOfEmb σ) |
| 101 | rw [RingOfIntegers.coe_eq_algebraMap, map_one, map_one, map_one, one_mul] at h_val |
| 102 | exact (norm_adeleExtension_le_one_iff σ).2 h_val |
| 103 | have h_image : finiteImage (u j) x.2 = |
| 104 | ((P.α s)⁻¹).val * algebraMap (P.E s) (𝔸f (P.E s)) (u j x.2) := rfl |
| 105 | have h_form : daggerForms u j x = σ (u j x.2) := by |
| 106 | rw [daggerForms, dagger, RingHom.comp_apply, RingHom.comp_apply, starRingEnd_apply, |
| 107 | starRingEnd_apply, map_star_complex] |
| 108 | rw [h_image, map_mul, norm_mul, map_units_inv, norm_inv, adeleExtension_algebraMap] at h_int |
| 109 | rwa [norm_mul, norm_iota_periodFactor x.1, h_form] |
| 110 | |
| 111 | end Parameters |
| 112 | |
| 113 | end New |