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 | import Mathlib.Order.CompletePartialOrder |
| 4 | import Mathlib.Topology.Connected.Separation |
| 5 | import Mathlib.Topology.MetricSpace.Ultra.TotallySeparated |
| 6 | import TauCeti.RingTheory.MvPowerSeries.Derivative |
| 7 | import TauCeti.RingTheory.MvPowerSeries.Dvd |
| 8 | import TauCeti.RingTheory.MvPowerSeries.Rescale |
| 9 | public import Lib.General.Algebra.IntegralPowerSeries |
| 10 | import Lib.General.Algebra.SeriesBounds |
| 11 | import Lib.General.Algebra.SeriesCongruences |
| 12 | |
| 13 | /-! |
| 14 | # Couplings and the normal form |
| 15 | |
| 16 | * `New.coupling`, `New.couplingSum`, `New.HasNormalForm`: the couplings `Γ_e` and the normal form |
| 17 | `F(ϖ z) = W exp (c_ϖ Ξ)` with `W` integral, `c_ϖ = ϖ ^ (p + 1) / p` and |
| 18 | `Ξ = ∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`, for any rule that assigns partners to places. |
| 19 | * `New.HasNormalForm.rescale`: the normal form is kept, with other numbers `λ_{e j}`, under |
| 20 | `z ↦ α z` with `α` integral. |
| 21 | * `New.HasNormalForm.norm_coeff_subst_le_one`: if `F` has the normal form and `Z` is integral |
| 22 | without constant term, then `F(ϖ Z)` is integral in degrees at most `B` if the couplings `Γ_e(Z)` |
| 23 | with `e ∈ S`, `e ≤ log_p B` are divisible by some `π` with `‖c_ϖ π‖ ≤ p ^ (-1 / (p - 1))`. |
| 24 | * `New.HasNormalForm.of_dvd_sub`: it is enough to know the exponent modulo such a `π`. |
| 25 | * `New.dvd_pderiv_couplingSum_sub`: the derivatives of `Ξ` modulo `p`, if `0 ∉ S`. They are not |
| 26 | needed for the divisibility bound, only for its sharpness. |
| 27 | |
| 28 | ## Notation |
| 29 | |
| 30 | * `valRingCp p` is the valuation ring `𝒪` of `ℂ_[p]`; a series over it is called integral. |
| 31 | * `seriesToCp W` is the series `W` over `𝒪`, seen as a series over `ℂ_[p]`. |
| 32 | * `expSubst g` is the series `exp g`, for `g` without constant term. |
| 33 | * The variables `z_x` are indexed by pairs `x = (τ, i)` in `Φ × c`, for finite types `Φ` and `c`; |
| 34 | the elements `τ` of `Φ` are called places. |
| 35 | -/ |
| 36 | |
| 37 | @[expose] public section |
| 38 | |
| 39 | open MvPowerSeries WithPiTopology IsLocalRing |
| 40 | |
| 41 | namespace New |
| 42 | |
| 43 | variable {p : ℕ} [Fact p.Prime] {Φ c : Type} [Fintype Φ] [Fintype c] |
| 44 | |
| 45 | /-- The coupling `Γ_e = ∑ z_(τ,i) ^ p ^ e * z_(τ',i)`, summed over all `(τ, i) : Φ × c`, where |
| 46 | `τ' = pr e τ` is the partner of `τ`. -/ |
| 47 | noncomputable def coupling (pr : ℕ → Φ → Φ) (e : ℕ) : MvPowerSeries (Φ × c) (valRingCp p) := |
| 48 | ∑ x : Φ × c, X x ^ p ^ e * X (pr e x.1, x.2) |
| 49 | |
| 50 | /-- The series `Ξ = ∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`, where `λ_{e j} = l e j` and `Γ_e` is the |
| 51 | coupling for the partner rule `pr`. -/ |
| 52 | noncomputable def couplingSum (S : Set ℕ) (pr : ℕ → Φ → Φ) (l : ℕ → ℕ → valRingCp p) : |
| 53 | MvPowerSeries (Φ × c) (valRingCp p) := |
| 54 | ∑' x : S × ℕ, l x.1 x.2 • coupling pr x.1 ^ p ^ x.2 |
| 55 | |
| 56 | /-- `F` has the normal form with the given numbers `ϖ` and `λ_{e j} = l e j`: |
| 57 | `F(ϖ z) = W exp (c_ϖ ∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j)` with `W` integral and |
| 58 | `c_ϖ = ϖ ^ (p + 1) / p`. -/ |
| 59 | def HasNormalForm (S : Set ℕ) (pr : ℕ → Φ → Φ) (ϖ : ℂ_[p]) (l : ℕ → ℕ → valRingCp p) |
| 60 | (F : MvPowerSeries (Φ × c) ℂ_[p]) : Prop := |
| 61 | ∃ W : MvPowerSeries (Φ × c) (valRingCp p), |
| 62 | F.rescale (fun _ : Φ × c ↦ ϖ) = |
| 63 | seriesToCp W * expSubst ((ϖ ^ (p + 1) / p) • seriesToCp (couplingSum S pr l)) |
| 64 | |
| 65 | variable {S : Set ℕ} {pr : ℕ → Φ → Φ} {ϖ : ℂ_[p]} {l : ℕ → ℕ → valRingCp p} |
| 66 | {F : MvPowerSeries (Φ × c) ℂ_[p]} |
| 67 | |
| 68 | /-- A substitution `Z` that is allowed (`HasSubst Z`) commutes with the exponential: |
| 69 | `(exp g)(Z) = exp (g(Z))` if `g(0) = 0`. -/ |
| 70 | lemma subst_expSubst {σ τ : Type} {g : MvPowerSeries σ ℂ_[p]} (hg : constantCoeff g = 0) |
| 71 | {Z : σ → MvPowerSeries τ ℂ_[p]} (hZ : HasSubst Z) : |
| 72 | (expSubst g).subst Z = expSubst (g.subst Z) := |
| 73 | subst_comp_subst_apply (PowerSeries.HasSubst.of_constantCoeff_zero hg).const hZ _ |
| 74 | |
| 75 | /-- The coupling after a substitution: `Γ_e(Z) = ∑ Z_(τ,i) ^ p ^ e * Z_(pr e τ, i)`. -/ |
| 76 | lemma subst_coupling {τ : Type} {Z : Φ × c → MvPowerSeries τ (valRingCp p)} (hZ : HasSubst Z) |
| 77 | (e : ℕ) : (coupling pr e : MvPowerSeries (Φ × c) (valRingCp p)).subst Z = |
| 78 | ∑ x : Φ × c, Z x ^ p ^ e * Z (pr e x.1, x.2) := by |
| 79 | simp only [coupling, ← coe_substAlgHom hZ, map_sum, map_mul, map_pow, substAlgHom_X] |
| 80 | |
| 81 | /-- The coupling `Γ_e` is homogeneous of degree `p ^ e + 1`. -/ |
| 82 | lemma rescale_coupling (α : valRingCp p) (e : ℕ) : |
| 83 | rescale (fun _ : Φ × c ↦ α) (coupling pr e : MvPowerSeries (Φ × c) (valRingCp p)) = |
| 84 | α ^ (p ^ e + 1) • coupling pr e := by |
| 85 | rw [rescale_eq_subst, subst_coupling (HasSubst.smul_X _), coupling, Finset.smul_sum] |
| 86 | simp only [Pi.smul_apply', smul_pow, smul_mul_smul_comm, pow_succ] |
| 87 | |
| 88 | /-- The coupling `Γ_e` has order at least `p ^ e + 1`. -/ |
| 89 | lemma le_order_coupling (e : ℕ) : |
| 90 | ((p ^ e + 1 : ℕ) : ℕ∞) ≤ (coupling pr e : MvPowerSeries (Φ × c) (valRingCp p)).order := by |
| 91 | refine le_order fun d hd ↦ ?_ |
| 92 | rw [coupling, map_sum] |
| 93 | refine Finset.sum_eq_zero fun x _ ↦ coeff_of_lt_order (hd.trans_le ?_) |
| 94 | grw [← le_order_mul, ← le_order_pow_of_constantCoeff_eq_zero _ (constantCoeff_X x), |
| 95 | ← one_le_order_iff_constCoeff_eq_zero.2 (constantCoeff_X _), Nat.cast_succ] |
| 96 | |
| 97 | /-- The sum `∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j` that defines `couplingSum S pr l` converges, as the |
| 98 | orders of its terms tend to infinity. -/ |
| 99 | lemma hasSum_couplingSum : |
| 100 | HasSum (fun x : S × ℕ ↦ l x.1 x.2 • coupling pr x.1 ^ p ^ x.2) |
| 101 | (couplingSum S pr l : MvPowerSeries (Φ × c) (valRingCp p)) := |
| 102 | (summable_smul_pow_pow (Fact.out : p.Prime).one_lt le_order_coupling S l).hasSum |
| 103 | |
| 104 | /-- The series `couplingSum S pr l = ∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j` has no constant term. -/ |
| 105 | lemma constantCoeff_couplingSum : |
| 106 | constantCoeff (couplingSum S pr l : MvPowerSeries (Φ × c) (valRingCp p)) = 0 := by |
| 107 | refine ((hasSum_couplingSum (S := S) (pr := pr) (l := l)).map constantCoeff |
| 108 | (continuous_constantCoeff _)).unique ?_ |
| 109 | simp [Function.comp_def, coupling, (Fact.out : p.Prime).ne_zero] |
| 110 | |
| 111 | /-- A substitution of series `Z_x` without constant term into |
| 112 | `couplingSum S pr l = ∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`, where `λ_{e j} = l e j` and |
| 113 | `Γ_e = coupling pr e`, may be carried out term by term. -/ |
| 114 | lemma hasSum_subst_couplingSum {τ : Type} {Z : Φ × c → MvPowerSeries τ (valRingCp p)} |
| 115 | (hZ : ∀ x : Φ × c, constantCoeff (Z x) = 0) : |
| 116 | HasSum (fun x : S × ℕ ↦ l x.1 x.2 • (coupling (p := p) pr x.1).subst Z ^ p ^ x.2) |
| 117 | ((couplingSum S pr l).subst Z) := by |
| 118 | have h_subst : HasSubst Z := hasSubst_of_constantCoeff_zero hZ |
| 119 | simpa only [Function.comp_def, coe_substAlgHom, subst_smul h_subst, subst_pow h_subst] using |
| 120 | (hasSum_couplingSum (S := S) (pr := pr) (l := l)).map (substAlgHom h_subst) |
| 121 | (by simpa only [coe_substAlgHom] using continuous_subst_of_constantCoeff_eq_zero hZ) |
| 122 | |
| 123 | /-- Let `Ξ = couplingSum S pr l` be the series `∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`. As `Γ_e` is |
| 124 | homogeneous of degree `p ^ e + 1`, the series `Ξ(α z)` is the same sum with `λ_{e j}` multiplied by |
| 125 | `α ^ ((p ^ e + 1) p ^ j)`. -/ |
| 126 | lemma rescale_couplingSum (α : valRingCp p) : |
| 127 | rescale (fun _ : Φ × c ↦ α) (couplingSum S pr l : MvPowerSeries (Φ × c) (valRingCp p)) = |
| 128 | couplingSum S pr fun e j : ℕ ↦ α ^ ((p ^ e + 1) * p ^ j) * l e j := by |
| 129 | let Z : Φ × c → MvPowerSeries (Φ × c) (valRingCp p) := (fun _ : Φ × c ↦ α) • X |
| 130 | have h_term (x : S × ℕ) : l x.1 x.2 • (coupling (p := p) pr x.1).subst Z ^ p ^ x.2 = |
| 131 | (α ^ ((p ^ (x.1 : ℕ) + 1) * p ^ x.2) * l x.1 x.2) • coupling pr x.1 ^ p ^ x.2 := by |
| 132 | rw [← rescale_eq_subst, rescale_coupling, smul_pow, smul_smul, ← pow_mul, mul_comm (l _ _)] |
| 133 | rw [rescale_eq_subst] |
| 134 | refine (hasSum_subst_couplingSum (Z := Z) fun x ↦ by simp [Z]).unique ?_ |
| 135 | simpa only [h_term] using hasSum_couplingSum (l := fun e j ↦ α ^ ((p ^ e + 1) * p ^ j) * l e j) |
| 136 | |
| 137 | /-- If `‖a π‖ ≤ p ^ (-1 / (p - 1))` and the integral series `G` has no constant term and |
| 138 | coefficients divisible by `π` in degrees at most `B`, then `exp (a G)` is integral in these |
| 139 | degrees. -/ |
| 140 | lemma norm_coeff_expSubst_smul_le_one {τ : Type} {a : ℂ_[p]} {π : valRingCp p} |
| 141 | (hπ : ‖a * π‖ ≤ p ^ (-(1 / (p - 1)) : ℝ)) {G : MvPowerSeries τ (valRingCp p)} |
| 142 | (hG : constantCoeff G = 0) {B : ℕ} (h_dvd : ∀ d : τ →₀ ℕ, d.degree ≤ B → π ∣ coeff d G) |
| 143 | {m : τ →₀ ℕ} (hm : m.degree ≤ B) : ‖coeff m (expSubst (a • seriesToCp G))‖ ≤ 1 := by |
| 144 | refine norm_coeff_expSubst_le_one (by simp [hG]) (fun d hd ↦ ?_) hm |
| 145 | calc ‖coeff d (a • seriesToCp G)‖ = ‖a * (coeff d G : valRingCp p)‖ := rfl |
| 146 | _ ≤ p ^ (-(1 / (p - 1)) : ℝ) := by |
| 147 | grw [← hπ, norm_mul, norm_mul, valRingCp.dvd_iff_norm_le.1 (h_dvd d hd)] |
| 148 | |
| 149 | /-- To prove that `F` has the normal form `F(ϖ z) = W exp (c_ϖ Ξ₀)`, where `W` is integral, |
| 150 | `c_ϖ = ϖ ^ (p + 1) / p` and `Ξ₀ = couplingSum S pr l`, it is enough to know the exponent modulo a |
| 151 | `π` with `‖c_ϖ π‖ ≤ p ^ (-1 / (p - 1))`: it suffices that `F(ϖ z) = W exp (c_ϖ Ξ)` with `W`, `Ξ` |
| 152 | integral, `Ξ(0) = 0` and `Ξ ≡ Ξ₀` modulo `π`. -/ |
| 153 | lemma HasNormalForm.of_dvd_sub {π : valRingCp p} |
| 154 | (hπ : ‖ϖ ^ (p + 1) / p * π‖ ≤ p ^ (-(1 / (p - 1)) : ℝ)) |
| 155 | {W Ξ : MvPowerSeries (Φ × c) (valRingCp p)} (hΞ : constantCoeff Ξ = 0) |
| 156 | (h_dvd : C π ∣ Ξ - couplingSum S pr l) |
| 157 | (hF : F.rescale (fun _ : Φ × c ↦ ϖ) = |
| 158 | seriesToCp W * expSubst ((ϖ ^ (p + 1) / p) • seriesToCp Ξ)) : |
| 159 | HasNormalForm S pr ϖ l F := by |
| 160 | -- The exponential `V` of `c_ϖ` times the difference `G` is integral and is moved into `W`. |
| 161 | let a : ℂ_[p] := ϖ ^ (p + 1) / p |
| 162 | set G : MvPowerSeries (Φ × c) (valRingCp p) := Ξ - couplingSum S pr l with hG |
| 163 | have hG_zero : constantCoeff G = 0 := by simp [hG, hΞ, constantCoeff_couplingSum] |
| 164 | have h_int (d : Φ × c →₀ ℕ) : ‖coeff d (expSubst (a • seriesToCp G))‖ ≤ 1 := |
| 165 | norm_coeff_expSubst_smul_le_one hπ hG_zero |
| 166 | (fun d' _ ↦ (C_dvd_iff_dvd_coeff _ _).1 h_dvd d') le_rfl |
| 167 | obtain ⟨V, hV⟩ : ∃ V : MvPowerSeries (Φ × c) (valRingCp p), |
| 168 | seriesToCp V = expSubst (a • seriesToCp G) := ⟨fun d ↦ ⟨_, h_int d⟩, rfl⟩ |
| 169 | have h_exp : expSubst (a • seriesToCp Ξ) = |
| 170 | seriesToCp V * expSubst (a • seriesToCp (couplingSum S pr l)) := by |
| 171 | rw [hV, ← expSubst_add _ (by simp [hG_zero]) (by simp [constantCoeff_couplingSum]), ← smul_add, |
| 172 | ← map_add, hG, sub_add_cancel] |
| 173 | exact ⟨W * V, by rw [hF, h_exp, map_mul seriesToCp W V, mul_assoc]⟩ |
| 174 | |
| 175 | /-- Let `F` have the normal form `F(ϖ z) = W exp (c_ϖ ∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j)` with `W` |
| 176 | integral. If the series `Z_x` are integral without constant term, then `F(ϖ Z)` is an integral |
| 177 | series times `exp (c_ϖ ∑_{e ∈ S} ∑_j λ_{e j} Γ_e(Z) ^ p ^ j)`. -/ |
| 178 | lemma HasNormalForm.exists_subst_eq_mul_expSubst (hF : HasNormalForm S pr ϖ l F) {τ : Type} |
| 179 | {Z : Φ × c → MvPowerSeries τ (valRingCp p)} (hZ : ∀ x : Φ × c, constantCoeff (Z x) = 0) : |
| 180 | ∃ W : MvPowerSeries τ (valRingCp p), |
| 181 | F.subst (fun x : Φ × c ↦ ϖ • seriesToCp (Z x)) = |
| 182 | seriesToCp W * |
| 183 | expSubst ((ϖ ^ (p + 1) / p) • seriesToCp ((couplingSum S pr l).subst Z)) := by |
| 184 | obtain ⟨W, hW⟩ := hF |
| 185 | have hZ_subst : HasSubst Z := hasSubst_of_constantCoeff_zero hZ |
| 186 | have h_subst : HasSubst fun x : Φ × c ↦ seriesToCp (Z x) := hZ_subst.map _ |
| 187 | refine ⟨W.subst Z, (subst_rescale (fun _ ↦ ϖ) F h_subst).symm.trans ?_⟩ |
| 188 | rw [hW, subst_mul h_subst, subst_expSubst (by simp [constantCoeff_couplingSum]) h_subst, |
| 189 | subst_smul h_subst, map_subst hZ_subst, map_subst hZ_subst] |
| 190 | |
| 191 | /-- Let `F` have the normal form `F(ϖ z) = W exp (c_ϖ ∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j)` with `W` |
| 192 | integral. Then, for integral `α`, the series `F(α z)` has the normal form with the same `ϖ` and with |
| 193 | `λ_{e j}` multiplied by `α ^ ((p ^ e + 1) p ^ j)`. -/ |
| 194 | lemma HasNormalForm.rescale (hF : HasNormalForm S pr ϖ l F) (α : valRingCp p) : |
| 195 | HasNormalForm S pr ϖ (fun e j : ℕ ↦ α ^ ((p ^ e + 1) * p ^ j) * l e j) |
| 196 | (F.rescale fun _ : Φ × c ↦ (α : ℂ_[p])) := by |
| 197 | let Z : Φ × c → MvPowerSeries (Φ × c) (valRingCp p) := fun x ↦ α • X x |
| 198 | have h_subst : (F.rescale fun _ ↦ (α : ℂ_[p])).rescale (fun _ ↦ ϖ) = |
| 199 | F.subst fun x : Φ × c ↦ ϖ • seriesToCp (Z x) := by |
| 200 | rw [rescale_rescale, rescale_eq_subst] |
| 201 | congr! with x |
| 202 | simp [Z, smul_smul, mul_comm] |
| 203 | unfold HasNormalForm |
| 204 | rw [h_subst, ← rescale_couplingSum, rescale_eq_subst _ (couplingSum S pr l)] |
| 205 | exact hF.exists_subst_eq_mul_expSubst fun x ↦ by simp [Z] |
| 206 | |
| 207 | /-- Let `Γ_e = coupling pr e` be the coupling `∑ z_(τ,i) ^ p ^ e * z_(pr e τ, i)`, homogeneous of |
| 208 | degree `p ^ e + 1`. A substitution of series `Z_x` without constant term does not lower orders, so |
| 209 | `Γ_e(Z) ^ p ^ j` has order at least `p ^ e + 1`. -/ |
| 210 | lemma le_order_subst_coupling_pow {τ : Type} {Z : Φ × c → MvPowerSeries τ (valRingCp p)} |
| 211 | (hZ : ∀ x : Φ × c, constantCoeff (Z x) = 0) (e j : ℕ) : |
| 212 | ((p ^ e + 1 : ℕ) : ℕ∞) ≤ ((coupling (p := p) pr e).subst Z ^ p ^ j).order := by |
| 213 | calc ((p ^ e + 1 : ℕ) : ℕ∞) ≤ (coupling (p := p) (c := c) pr e).order := le_order_coupling e |
| 214 | _ ≤ ((coupling (p := p) pr e).subst Z).order := by |
| 215 | grw [← le_order_subst (hasSubst_of_constantCoeff_zero hZ), |
| 216 | ← le_iInf fun x ↦ one_le_order_iff_constCoeff_eq_zero.2 (hZ x), one_mul] |
| 217 | _ ≤ ((coupling (p := p) pr e).subst Z ^ p ^ j).order := by |
| 218 | grw [← le_order_pow, ← Nat.one_le_pow j p (Fact.out : p.Prime).pos, one_nsmul] |
| 219 | |
| 220 | /-- Let `Ξ = couplingSum S pr l` be the series `∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`. If the series |
| 221 | `Z_x` have no constant term and `π` divides `Γ_e(Z)` for all `e ∈ S` with `e ≤ log_p B`, then `π` |
| 222 | divides the coefficients of `Ξ(Z)` in degrees at most `B`. -/ |
| 223 | lemma dvd_coeff_subst_couplingSum {π : valRingCp p} {τ : Type} |
| 224 | {Z : Φ × c → MvPowerSeries τ (valRingCp p)} (hZ : ∀ x : Φ × c, constantCoeff (Z x) = 0) {B : ℕ} |
| 225 | (hΓ : ∀ e ∈ S, e ≤ p.log B → |
| 226 | C π ∣ (coupling pr e : MvPowerSeries (Φ × c) (valRingCp p)).subst Z) |
| 227 | {d : τ →₀ ℕ} (hd : d.degree ≤ B) : π ∣ coeff d ((couplingSum S pr l).subst Z) := by |
| 228 | have hp : p.Prime := Fact.out |
| 229 | refine dvd_of_hasSum (hasSum_iff_hasSum_coeff.1 (hasSum_subst_couplingSum hZ) d) ?_ |
| 230 | rintro ⟨⟨e, he⟩, j⟩ |
| 231 | set G : MvPowerSeries τ (valRingCp p) := (coupling (p := p) pr e).subst Z ^ p ^ j |
| 232 | suffices h_dvd : π ∣ coeff d G by simpa only [coeff_smul] using h_dvd.mul_left (l e j) |
| 233 | obtain h_le | h_lt := le_or_gt e (p.log B) |
| 234 | · exact (C_dvd_iff_dvd_coeff _ _).1 ((hΓ e he h_le).pow (pow_ne_zero j hp.ne_zero)) d |
| 235 | · have h_deg : d.degree < p ^ e + 1 := |
| 236 | (hd.trans_lt (Nat.lt_pow_of_log_lt hp.one_lt h_lt)).trans (Nat.lt_succ_self _) |
| 237 | rw [coeff_of_lt_order ((Nat.cast_lt.2 h_deg).trans_le (le_order_subst_coupling_pow hZ e j))] |
| 238 | exact dvd_zero π |
| 239 | |
| 240 | /-- Let `F` have the normal form `F(ϖ z) = W exp (c_ϖ ∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j)`. Let |
| 241 | `‖c_ϖ π‖ ≤ p ^ (-1 / (p - 1))`, and let the series `Z_x` be integral without constant term, with `π` |
| 242 | dividing `Γ_e(Z)` for all `e ∈ S` with `e ≤ log_p B`. Then the coefficients of `F(ϖ Z)` in degrees |
| 243 | at most `B` have norm at most `1`. -/ |
| 244 | lemma HasNormalForm.norm_coeff_subst_le_one (hF : HasNormalForm S pr ϖ l F) {π : valRingCp p} |
| 245 | (hπ : ‖ϖ ^ (p + 1) / p * π‖ ≤ p ^ (-(1 / (p - 1)) : ℝ)) {τ : Type} |
| 246 | {Z : Φ × c → MvPowerSeries τ (valRingCp p)} (hZ : ∀ x : Φ × c, constantCoeff (Z x) = 0) {B : ℕ} |
| 247 | (hΓ : ∀ e ∈ S, e ≤ p.log B → |
| 248 | C π ∣ (coupling pr e : MvPowerSeries (Φ × c) (valRingCp p)).subst Z) |
| 249 | {m : τ →₀ ℕ} (hm : m.degree ≤ B) : |
| 250 | ‖coeff m (F.subst fun x : Φ × c ↦ ϖ • seriesToCp (Z x))‖ ≤ 1 := by |
| 251 | classical |
| 252 | set Ξ : MvPowerSeries τ (valRingCp p) := (couplingSum S pr l).subst Z |
| 253 | have h_exponent_zero : constantCoeff Ξ = 0 := |
| 254 | constantCoeff_subst_eq_zero (hasSubst_of_constantCoeff_zero hZ) hZ constantCoeff_couplingSum |
| 255 | -- Only couplings of sufficiently small degree can affect the truncated exponential. |
| 256 | have h_exp_integral (d : τ →₀ ℕ) (hd : d.degree ≤ B) : |
| 257 | ‖coeff d (expSubst ((ϖ ^ (p + 1) / p) • seriesToCp Ξ))‖ ≤ 1 := |
| 258 | norm_coeff_expSubst_smul_le_one hπ h_exponent_zero |
| 259 | (fun _ hd' ↦ dvd_coeff_subst_couplingSum hZ hΓ hd') hd |
| 260 | obtain ⟨W, h_factorization⟩ : ∃ W : MvPowerSeries τ (valRingCp p), |
| 261 | F.subst (fun x : Φ × c ↦ ϖ • seriesToCp (Z x)) = |
| 262 | seriesToCp W * expSubst ((ϖ ^ (p + 1) / p) • seriesToCp Ξ) := |
| 263 | hF.exists_subst_eq_mul_expSubst hZ |
| 264 | -- The other factor is already integral. Each convolution term uses a coefficient |
| 265 | -- of the exponential of degree at most B. |
| 266 | rw [h_factorization, coeff_mul] |
| 267 | refine sum_mem (S := valRingCp p) fun ⟨d₁, d₂⟩ hd ↦ ?_ |
| 268 | have h_degree_bound : d₂ ≤ m := |
| 269 | le_of_add_le_right (Finset.HasAntidiagonal.mem_antidiagonal.1 hd).le |
| 270 | exact mul_mem (coeff d₁ W).property |
| 271 | (h_exp_integral d₂ ((Finsupp.degree_mono h_degree_bound).trans hm)) |
| 272 | |
| 273 | variable [DecidableEq Φ] [DecidableEq c] |
| 274 | |
| 275 | open Classical in |
| 276 | /-- The sum of the powers `z_x ^ p ^ e` over the `x = (τ, i)` whose partner `(pr e τ, i)` in the |
| 277 | coupling `Γ_e` is `y`. -/ |
| 278 | noncomputable def partnerPowerSum (pr : ℕ → Φ → Φ) (e : ℕ) (y : Φ × c) : |
| 279 | MvPowerSeries (Φ × c) (valRingCp p) := |
| 280 | ∑ x : Φ × c with (pr e x.1, x.2) = y, X x ^ p ^ e |
| 281 | |
| 282 | /-- The derivatives of a `p ^ e`-th power vanish modulo `p`, for `e > 0`. -/ |
| 283 | lemma dvd_pderiv_pow_pow {σ : Type} (G : MvPowerSeries σ (valRingCp p)) {e : ℕ} (he : e ≠ 0) |
| 284 | (y : σ) : C (p : valRingCp p) ∣ pderiv y (G ^ p ^ e) := by |
| 285 | rw [Derivation.leibniz_pow, nsmul_eq_mul, Nat.cast_pow, map_natCast] |
| 286 | exact (dvd_pow_self _ he).mul_right _ |
| 287 | |
| 288 | /-- For `e > 0`, only the linear factors of the coupling |
| 289 | `Γ_e = coupling pr e = ∑_{(τ, i)} z_(τ,i) ^ p ^ e * z_(pr e τ, i)` have a derivative modulo `p`: |
| 290 | `∂Γ_e / ∂z_y` is congruent to `partnerPowerSum pr e y`, the sum of the `z_x ^ p ^ e` over the |
| 291 | `x = (τ, i)` whose partner `(pr e τ, i)` is `y`. -/ |
| 292 | lemma dvd_pderiv_coupling_sub {e : ℕ} (he : e ≠ 0) (y : Φ × c) : |
| 293 | C (p : valRingCp p) ∣ pderiv y (coupling pr e) - partnerPowerSum pr e y := by |
| 294 | rw [coupling, map_sum, partnerPowerSum, Finset.sum_filter, ← Finset.sum_sub_distrib] |
| 295 | refine Finset.dvd_sum fun x _ ↦ ?_ |
| 296 | have h_linear : X x ^ p ^ e * pderiv y (X (pr e x.1, x.2)) = |
| 297 | if (pr e x.1, x.2) = y then X (R := valRingCp p) x ^ p ^ e else 0 := by |
| 298 | simp [pderiv_X, Pi.single_apply] |
| 299 | rw [Derivation.leibniz, smul_eq_mul, smul_eq_mul, h_linear, add_sub_cancel_left] |
| 300 | exact (dvd_pderiv_pow_pow (X x) he y).mul_left _ |
| 301 | |
| 302 | /-- If `y` is the partner of `x` for `e`, then `z_x ^ p ^ e` has coefficient `1` in |
| 303 | `partnerPowerSum pr e y`. -/ |
| 304 | lemma coeff_partnerPowerSum_self (e : ℕ) (x : Φ × c) : |
| 305 | coeff (.single x (p ^ e)) (partnerPowerSum (p := p) pr e (pr e x.1, x.2)) = 1 := by |
| 306 | simp [partnerPowerSum, coeff_X_pow, |
| 307 | Finsupp.single_left_inj (pow_ne_zero e (Fact.out : p.Prime).ne_zero)] |
| 308 | |
| 309 | /-- The only monomials of `partnerPowerSum pr e y` are the `z_x ^ p ^ e` with `y` the partner of |
| 310 | `x` for `e`. -/ |
| 311 | lemma exists_single_of_coeff_partnerPowerSum_ne_zero {e : ℕ} {y : Φ × c} {d : Φ × c →₀ ℕ} |
| 312 | (h_ne : coeff d (partnerPowerSum (p := p) pr e y) ≠ 0) : |
| 313 | ∃ x : Φ × c, (pr e x.1, x.2) = y ∧ d = .single x (p ^ e) := by |
| 314 | rw [partnerPowerSum, map_sum] at h_ne |
| 315 | obtain ⟨x, hx, h_coeff⟩ := Finset.exists_ne_zero_of_sum_ne_zero h_ne |
| 316 | exact ⟨x, (Finset.mem_filter.1 hx).2, by simpa [coeff_X_pow] using h_coeff⟩ |
| 317 | |
| 318 | /-- The series `partnerPowerSum pr e y` has order at least `p ^ e`. -/ |
| 319 | lemma le_order_partnerPowerSum (e : ℕ) (y : Φ × c) : |
| 320 | ((p ^ e : ℕ) : ℕ∞) ≤ (partnerPowerSum (p := p) pr e y).order := by |
| 321 | refine le_order fun d hd ↦ by_contra fun h_ne ↦ ?_ |
| 322 | obtain ⟨x, -, rfl⟩ := exists_single_of_coeff_partnerPowerSum_ne_zero h_ne |
| 323 | simp at hd |
| 324 | |
| 325 | /-- The sum `∑_{e ∈ S} λ_{e 0} * partnerPowerSum pr e y`, where `λ_{e 0} = l e 0` and |
| 326 | `partnerPowerSum pr e y` is the sum of the `z_x ^ p ^ e` over the `x = (τ, i)` with partner |
| 327 | `(pr e τ, i) = y`, converges, as the term `e` has order at least `p ^ e`. -/ |
| 328 | lemma summable_smul_partnerPowerSum (y : Φ × c) : |
| 329 | Summable fun e : S ↦ l e 0 • partnerPowerSum (p := p) pr e y := by |
| 330 | refine summable_of_finite_order_le fun n ↦ ?_ |
| 331 | refine ((Set.finite_Iic n).preimage Subtype.val_injective.injOn).subset fun e he ↦ ?_ |
| 332 | have h_le : ((p ^ (e : ℕ) : ℕ) : ℕ∞) ≤ n := |
| 333 | ((le_order_partnerPowerSum e y).trans le_order_smul).trans he |
| 334 | exact (Nat.lt_pow_self (Fact.out : p.Prime).one_lt).le.trans (Nat.cast_le.1 h_le) |
| 335 | |
| 336 | /-- Let `Ξ = couplingSum S pr l` be the series `∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`. If `0 ∉ S`, then |
| 337 | modulo `p` only the linear factors in the terms `j = 0` count in the derivatives: |
| 338 | `∂Ξ / ∂z_y ≡ ∑_{e ∈ S} λ_{e 0} * partnerPowerSum pr e y`. -/ |
| 339 | lemma dvd_pderiv_couplingSum_sub (hS : 0 ∉ S) (y : Φ × c) : |
| 340 | C (p : valRingCp p) ∣ |
| 341 | pderiv y (couplingSum S pr l) - ∑' e : S, l e 0 • partnerPowerSum pr e y := by |
| 342 | have h_deriv : |
| 343 | HasSum (fun x : S × ℕ ↦ pderiv y (l x.1 x.2 • coupling pr x.1 ^ p ^ x.2)) |
| 344 | (pderiv y (couplingSum S pr l)) := |
| 345 | hasSum_couplingSum.map (pderiv y).toLinearMap.toAddMonoidHom (continuous_pderiv y) |
| 346 | -- The second sum, written over the pairs `(e, j)` with zero terms for `j > 0`. |
| 347 | have h_main : HasSum (fun x : S × ℕ ↦ if x.2 = 0 then l x.1 0 • partnerPowerSum pr x.1 y else 0) |
| 348 | (∑' e : S, l e 0 • partnerPowerSum (p := p) pr e y) := by |
| 349 | refine ((Prod.mk_left_injective 0).hasSum_iff fun x hx ↦ ite_eq_right fun hj : x.2 = 0 ↦ |
| 350 | hx ⟨x.1, Prod.ext rfl hj.symm⟩).1 ?_ |
| 351 | simpa [Function.comp_def] using (summable_smul_partnerPowerSum y).hasSum |
| 352 | refine C_dvd_of_hasSum (h_deriv.sub h_main) ?_ |
| 353 | rintro ⟨⟨e, he⟩, _ | j⟩ |
| 354 | · simpa [← smul_sub, smul_eq_C_mul, ← mul_sub] using |
| 355 | (dvd_pderiv_coupling_sub (ne_of_mem_of_not_mem he hS) y).mul_left (C (l e 0)) |
| 356 | · rw [ite_eq_right j.succ_ne_zero, sub_zero, Derivation.map_smul, smul_eq_C_mul] |
| 357 | exact (dvd_pderiv_pow_pow _ j.succ_ne_zero y).mul_left _ |
| 358 | |
| 359 | /-- Let `Ξ = couplingSum S pr l` be the series `∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`. If `0 ∉ S`, then |
| 360 | modulo the maximal ideal of `valRingCp p` the coefficients of `∂Ξ / ∂z_y` are those of |
| 361 | `∑_{e ∈ S} λ_{e 0} * partnerPowerSum pr e y`. -/ |
| 362 | lemma residue_coeff_pderiv_couplingSum_eq (hS : 0 ∉ S) (y : Φ × c) (d : Φ × c →₀ ℕ) : |
| 363 | residue (valRingCp p) (coeff d (pderiv y (couplingSum S pr l))) = |
| 364 | residue (valRingCp p) (∑' e : S, l e 0 * coeff d (partnerPowerSum pr e y)) := by |
| 365 | have h_sum : ∑' e : S, l e 0 * coeff d (partnerPowerSum pr e y) = |
| 366 | coeff d (∑' e : S, l e 0 • partnerPowerSum pr e y) := |
| 367 | (hasSum_iff_hasSum_coeff.1 (summable_smul_partnerPowerSum y).hasSum d).tsum_eq |
| 368 | obtain ⟨a, ha⟩ : (p : valRingCp p) ∣ coeff d (pderiv y (couplingSum S pr l)) - |
| 369 | ∑' e : S, l e 0 * coeff d (partnerPowerSum pr e y) := by |
| 370 | simpa only [h_sum, ← map_sub] using |
| 371 | (C_dvd_iff_dvd_coeff _ _).1 (dvd_pderiv_couplingSum_sub hS y) d |
| 372 | rw [sub_eq_iff_eq_add'] at ha |
| 373 | simp only [ha, map_add, map_mul, map_natCast, CharP.cast_eq_zero, zero_mul, add_zero] |
| 374 | |
| 375 | /-- Let `Ξ = couplingSum S pr l` be the series `∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`. Let `0 ∉ S` and |
| 376 | `e ∈ S`, and let `y = (pr e τ, i)` be the partner of `x = (τ, i)` for `e`. Modulo the maximal ideal |
| 377 | of `valRingCp p`, the coefficient of the one monomial `z_x ^ p ^ e` in `∂Ξ / ∂z_y` is `λ_{e 0}`. -/ |
| 378 | lemma residue_coeff_pderiv_couplingSum (hS : 0 ∉ S) {e : ℕ} (he : e ∈ S) (x : Φ × c) : |
| 379 | residue (valRingCp p) |
| 380 | (coeff (.single x (p ^ e)) (pderiv (pr e x.1, x.2) (couplingSum S pr l))) = |
| 381 | residue (valRingCp p) (l e 0) := by |
| 382 | have h_zero (e' : S) (h_ne : e' ≠ ⟨e, he⟩) : |
| 383 | coeff (.single x (p ^ e)) (partnerPowerSum (p := p) pr e' (pr e x.1, x.2)) = 0 := by |
| 384 | by_contra h_ne_zero |
| 385 | obtain ⟨x', -, h_eq⟩ := exists_single_of_coeff_partnerPowerSum_ne_zero h_ne_zero |
| 386 | have h_pow : p ^ (e' : ℕ) = p ^ e := by |
| 387 | rw [← Finsupp.degree_single x (p ^ e), h_eq, Finsupp.degree_single] |
| 388 | exact h_ne (Subtype.ext (Nat.pow_right_injective (Fact.out : p.Prime).two_le h_pow)) |
| 389 | rw [residue_coeff_pderiv_couplingSum_eq hS, tsum_eq_single ⟨e, he⟩ fun e' h_ne ↦ by |
| 390 | simp [h_zero e' h_ne], coeff_partnerPowerSum_self, mul_one] |
| 391 | |
| 392 | /-- Let `Ξ = couplingSum S pr l` be the series `∑_{e ∈ S} ∑_j λ_{e j} Γ_e ^ p ^ j`. If `0 ∉ S`, then |
| 393 | modulo the maximal ideal of `𝒪 = valRingCp p` the series `∂Ξ / ∂z_y` has only monomials |
| 394 | `z_x ^ p ^ e` with `e ∈ S` and `y = (pr e τ, i)` the partner of `x = (τ, i)` for `e`. -/ |
| 395 | lemma exists_eq_single_of_residue_coeff_pderiv_ne_zero (hS : 0 ∉ S) {y : Φ × c} {d : Φ × c →₀ ℕ} |
| 396 | (h_ne : residue (valRingCp p) (coeff d (pderiv y (couplingSum S pr l))) ≠ 0) : |
| 397 | ∃ e ∈ S, ∃ x : Φ × c, (pr e x.1, x.2) = y ∧ d = .single x (p ^ e) := by |
| 398 | by_contra h_none |
| 399 | have h_zero (e : S) : coeff d (partnerPowerSum (p := p) pr e y) = 0 := |
| 400 | by_contra fun he ↦ h_none ⟨e, e.property, exists_single_of_coeff_partnerPowerSum_ne_zero he⟩ |
| 401 | simp [residue_coeff_pderiv_couplingSum_eq hS, h_zero] at h_ne |
| 402 | |
| 403 | end New |