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.Algebra.Azumaya.Basic |
| 4 | import Mathlib.Algebra.Central.End |
| 5 | import Mathlib.Algebra.Module.StablyFree.Basic |
| 6 | import Mathlib.Algebra.Module.ZLattice.Summable |
| 7 | import Mathlib.Algebra.Order.Star.Real |
| 8 | import Mathlib.AlgebraicTopology.FundamentalGroupoid.SimplyConnected |
| 9 | import Mathlib.Analysis.Convex.Contractible |
| 10 | import Mathlib.RingTheory.Etale.Weakly |
| 11 | import Mathlib.RingTheory.Finiteness.ModuleFinitePresentation |
| 12 | import Mathlib.RingTheory.PiTensorProduct |
| 13 | import Mathlib.RingTheory.RegularLocalRing.Defs |
| 14 | import Mathlib.RingTheory.SimpleRing.Principal |
| 15 | import Mathlib.RingTheory.TotallySplit |
| 16 | import Mathlib.Tactic.Linter.Style |
| 17 | public import Lib.Shimura.ComplexTheta.AppellHumbertData |
| 18 | import Lib.General.Analysis.HolomorphicIntegrals |
| 19 | |
| 20 | /-! |
| 21 | # Theta functions on complex tori: dimension formula, base points, multipliers |
| 22 | |
| 23 | This file treats Appell–Humbert data `(B, χ)` with positive Riemann form `E` for a full lattice |
| 24 | `L` in a finite-dimensional complex space `V`. It proves the convergence of theta series and the |
| 25 | existence of a nonzero theta function. It proves that the square of the dimension of the space of |
| 26 | theta functions equals the index of `L` in its dual lattice, and that the twisted translations by |
| 27 | the dual lattice act irreducibly. It shows that multiples of a positive type have no base point. |
| 28 | It also defines the canonical multiplier and the normalised translations. |
| 29 | |
| 30 | ## Main definitions and results |
| 31 | |
| 32 | * `New.IsAppellHumbert.finrank_sq_eq_relIndex`: for Appell–Humbert data with positive `E`, |
| 33 | `(dim thetaSpace)² = [dual : L]`, the dimension is positive, and the twisted translations by the |
| 34 | dual lattice span all endomorphisms of the space of theta functions; so the space is irreducible |
| 35 | (`New.IsAppellHumbert.thetaSpace_le_of_thetaShift_mem`, `New.IsAppellHumbert.schur_lemma`). |
| 36 | * `New.IsAppellHumbert.exists_mem_thetaSpace_nsmul_apply_ne_zero`: for Appell–Humbert data with |
| 37 | positive `E` and `n ≥ 2` the theta functions of type `(n B, χ ^ n)` have no common zero. |
| 38 | * `New.ThetaTori.canonicalMultiplier`, `New.ThetaTori.normalizedShift`: a canonical multiplier |
| 39 | `exp (πi E(b x, x))` for a linear map `b`, and the twisted translations divided by it, which, for |
| 40 | Appell–Humbert data and `b` with `E (b u) w = E u w - E u (b w)`, obey a Heisenberg law |
| 41 | (`New.IsAppellHumbert.normalizedShift_normalizedShift`). |
| 42 | |
| 43 | Notions from other files: |
| 44 | * `New.RealComplexForm.thetaSpace`: the entire `f` with |
| 45 | `f (z + l) = χ l * exp (B l z + B l l / 2) * f z` for `l ∈ L`. |
| 46 | * `New.RealComplexForm.thetaShift`: translation by `a` twisted by `exp (-(B a z + B a a / 2))`. |
| 47 | * `New.RealComplexForm.dualLattice`: the `v` in `V` with `E(v, l)` an integer for all `l` in `L`. |
| 48 | |
| 49 | ## Relation to the literature |
| 50 | |
| 51 | Frobenius' dimension formula and irreducibility of the theta group. Here the statement is |
| 52 | basis-free, with the square of the dimension equal to the index of the lattice in its dual. It is |
| 53 | proved together with irreducibility from a theta kernel on the torus without a symplectic basis, and |
| 54 | the orthogonality relation and the absence of base points follow. Source: G. Frobenius, Über die |
| 55 | Grundlagen der Theorie der Jacobischen Functionen, Crelle 97 (1884); Birkenhake–Lange, Complex |
| 56 | Abelian Varieties, 3.2.7, 4.1.5, 6.4; survey of proofs in D. Bump, A. Pekker, Proc. AMS 130 (2002) |
| 57 | 3473–3481. |
| 58 | |
| 59 | See also `Lib.Shimura.Uniformisation.AppellHumbert`. |
| 60 | -/ |
| 61 | |
| 62 | @[expose] public section |
| 63 | |
| 64 | noncomputable section |
| 65 | |
| 66 | namespace New |
| 67 | |
| 68 | open FourierTransform Complex Module MeasureTheory QuotientAddGroup Fintype Quotient |
| 69 | LinearMap.BilinForm Submodule Finset ComplexConjugate IsZLattice |
| 70 | |
| 71 | variable {V : Type} [FinComplexSpace V] |
| 72 | {L : Submodule ℤ V} [IsFullRankLattice L] {B : ThetaTori.LatticeForm L} |
| 73 | {χ f : V → ℂ} [hB : IsAppellHumbert B χ] [hp : IsPosRiemann B] (hf : f ∈ B.thetaSpace χ) |
| 74 | |
| 75 | include hB hf |
| 76 | |
| 77 | omit hp |
| 78 | |
| 79 | omit hf |
| 80 | |
| 81 | /-! ### Convergence of theta series -/ |
| 82 | |
| 83 | /-- Normal convergence of theta series, for Appell–Humbert data (B, χ) (instance `hB`). Let `T c`, |
| 84 | for `c` in a finite-dimensional complex space `P`, be real-linear maps of `V`, analytic in `c` |
| 85 | near `b`, with `Re (B x (T b x)) > 0` for `x ≠ 0`. The series over `l ∈ L` with terms |
| 86 | `term q l = exp (exponent q l) / χ l`, where |
| 87 | `exponent q l = ξ (u + T c l) - B l z - B l (T c l) / 2` at `q = (c, ξ, u, z)`, converges at |
| 88 | `c = b` for every `p = (ξ, u, z)`, and its sum is analytic in `q` at `(b, p)`. -/ |
| 89 | lemma IsAppellHumbert.summable_and_analyticAt_tsum {P : Type*} {b : P} [FinComplexSpace P] |
| 90 | {T : P → V →L[ℝ] V} (hT : ∀ᶠ c : P in nhds b, ∀ x : V, AnalyticAt ℂ (fun c' : P ↦ T c' x) c) |
| 91 | (hpos : ∀ x ≠ (0 : V), 0 < (B x (T b x)).re) (p : StrongDual ℂ V × V × V) : |
| 92 | let exponent : P × StrongDual ℂ V × V × V → V → ℂ := |
| 93 | fun (c, ξ, u, z) (l : V) ↦ ξ (u + T c l) - B l z - B l (T c l) / 2 |
| 94 | let term (q : P × StrongDual ℂ V × V × V) (l : L) : ℂ := (exponent q l).exp / χ l |
| 95 | Summable (term (b, p)) ∧ AnalyticAt ℂ (fun q : P × StrongDual ℂ V × V × V ↦ tsum (term q)) |
| 96 | (b, p) := by |
| 97 | -- Near `(b, p)` the terms are bounded by a constant times `exp (-‖l‖)`, which is summable |
| 98 | -- over the lattice; then differentiate under the sum. |
| 99 | intro exponent term |
| 100 | have T_cont : ContinuousAt T b := |
| 101 | continuousAt_clm_apply.2 fun x ↦ (hT.self_of_nhds x).continuousAt |
| 102 | -- A homogenised bound on the unit sphere of `ℝ × V`, with a small extra parameter `ε`: here |
| 103 | -- `r = (ε, c, ξ, u, z)`, so `r.2.1 = c` and `r.2.2 = (ξ, u, z)`, and `y = (s, x)`. At `ε = 0` it |
| 104 | -- says `-Re (B x (T b x)) / 2 < s ^ 2`, true as `(s, x) ≠ 0`; it persists nearby. |
| 105 | have on_sphere : |
| 106 | ∀ᶠ r : ℝ × P × StrongDual ℂ V × V × V in nhds (0, b, p), ∀ y ∈ Metric.sphere (0 : ℝ × V) 1, |
| 107 | (exponent (r.2.1, (y.1 * r.1) • r.2.2) y.2).re + y.1 * r.1 * ‖y.2‖ < y.1 ^ 2 := by |
| 108 | refine (isCompact_sphere 0 1).eventually_forall_of_forall_eventually fun (s, x) hx ↦ |
| 109 | ContinuousAt.eventually_lt (by fun_prop) (by fun_prop) ?_ |
| 110 | -- At `r = (0, b, p)` the left side is `-Re (B x (T b x)) / 2`: negative if `x ≠ 0`, and zero |
| 111 | -- if `x = 0`, when `s ≠ 0` as `(s, x)` lies on the sphere. |
| 112 | have h_base : -((B x (T b x)).re / 2) < s ^ 2 := by |
| 113 | rcases eq_or_ne x 0 with rfl | hx_ne |
| 114 | · have hs_ne : s ≠ 0 := fun hs ↦ by simp [hs] at hx |
| 115 | simpa using sq_pos_of_ne_zero hs_ne |
| 116 | · linarith [hpos x hx_ne, sq_nonneg s] |
| 117 | simpa [exponent] using h_base |
| 118 | obtain ⟨scale, h_scale_pos, near⟩ : |
| 119 | ∃ scale > (0 : ℝ), ∀ᶠ q : P × StrongDual ℂ V × V × V in nhds (b, p), |
| 120 | ∀ y ∈ Metric.sphere (0 : ℝ × V) 1, |
| 121 | (exponent (q.1, (y.1 * scale) • q.2) y.2).re + y.1 * scale * ‖y.2‖ < y.1 ^ 2 := |
| 122 | on_sphere.curry_nhds.exists_gt |
| 123 | -- `exp (-‖l‖)` decays faster than the power `‖l‖ ^ (-rank L - 1)`, which is summable over `L`. |
| 124 | have norm_tendsto : Filter.Tendsto (fun l : L ↦ ‖(l : V)‖) Filter.cofinite Filter.atTop := |
| 125 | tendsto_norm_cocompact_atTop.comp |
| 126 | (L.toAddSubgroup.tendsto_coe_cofinite_of_isDiscrete |
| 127 | ⟨inferInstanceAs (DiscreteTopology L)⟩) |
| 128 | have h_isBigO : (fun l : L ↦ Real.exp (-1 * ‖(l : V)‖)) =O[Filter.cofinite] |
| 129 | fun l : L ↦ ‖(l : V)‖ ^ (-(Module.finrank ℤ L : ℝ) - 1) := |
| 130 | (isLittleO_exp_neg_mul_rpow_atTop one_pos _).isBigO.comp_tendsto norm_tendsto |
| 131 | let g (l : L) : ℝ := Real.exp (scale⁻¹ ^ 2) * Real.exp (-1 * ‖(l : V)‖) |
| 132 | have g_summable : Summable g := |
| 133 | (summable_of_isBigO (ZLattice.summable_norm_rpow L _ (sub_one_lt _)) h_isBigO).mul_left _ |
| 134 | -- At the point of the sphere in the direction `(scale⁻¹, l)` all terms are homogeneous of degree |
| 135 | -- two, and the bound reads `Re (exponent q l) + ‖l‖ < scale⁻¹ ^ 2`. |
| 136 | have bound : ∀ᶠ q in nhds (b, p), ∀ l, ‖term q l‖ ≤ g l := by |
| 137 | filter_upwards [near] with q hq l |
| 138 | have h_unit : NormedSpace.normalize (scale⁻¹, (l : V)) ∈ Metric.sphere (0 : ℝ × V) 1 := by |
| 139 | simp [h_scale_pos.ne'] |
| 140 | -- Multiply the bound at this unit vector by the square of the norm of `(scale⁻¹, l)`. |
| 141 | have h_re : (exponent q l).re + ‖(l : V)‖ ≤ scale⁻¹ ^ 2 := by |
| 142 | simpa [exponent, -Prod.norm_mk, h_scale_pos.ne', NormedSpace.normalize, norm_smul, fieldLe] |
| 143 | using (hq _ h_unit).le |
| 144 | calc ‖term q l‖ |
| 145 | _ = Real.exp (exponent q l).re := by simp [term, norm_exp, hB.norm_eq_one _ l.prop] |
| 146 | _ ≤ Real.exp (scale⁻¹ ^ 2 - ‖(l : V)‖) := Real.exp_le_exp.mpr (by linarith) |
| 147 | _ = g l := by simp [g, sub_eq_add_neg, Real.exp_add] |
| 148 | refine ⟨g_summable.of_norm_bounded bound.self_of_nhds, ?_⟩ |
| 149 | -- The sum is an integral against counting measure. |
| 150 | borelize V |
| 151 | have dominated : ∀ᶠ q in nhds (b, p), ∀ l, |
| 152 | DifferentiableAt ℂ (fun q ↦ term q l) q ∧ ‖term q l‖ ≤ g l := by |
| 153 | filter_upwards [bound, hT.prod_inl_nhds p] with q hq T_an l |
| 154 | exact ⟨by fun_prop, hq l⟩ |
| 155 | have h_analytic_integral : |
| 156 | AnalyticAt ℂ (fun q ↦ ∫ l, term q l ∂Measure.count) (b, p) := |
| 157 | analyticAt_integral (integrable_count_iff.2 g_summable.abs) (by fun_prop) dominated |
| 158 | simpa [integral_count_eq_tsum] using h_analytic_integral |
| 159 | |
| 160 | /-- Let `L` be a full-rank lattice in a finite-dimensional complex space `V`, and let (B, χ) be |
| 161 | Appell–Humbert data (instance `hB`) with `Re B(x, x) > 0` for `x ≠ 0`. The Poincaré series |
| 162 | `K(x, y) = ∑_{l ∈ L} exp(B(x, y − x + l) − B(l, y) − B(l, l)/2)/χ(l)` has these properties: (a) it |
| 163 | converges for all `x, y`; (b) it is jointly continuous in `(x, y)`; (c) for each `x` it is a theta |
| 164 | function of type (B, χ) in `y`; (d) the diagonal `x ↦ K(x, x)` has mean `(χ 0)⁻¹` over `V ⧸ L`; and |
| 165 | (e) it does not vanish at some point `(w, w)`. -/ |
| 166 | lemma IsAppellHumbert.poincareSeries_mem_thetaSpace_and_quotMean |
| 167 | (h_pos : ∀ x ≠ (0 : V), 0 < (B x x).re) : |
| 168 | -- (a) |
| 169 | (∀ x y : V, Summable (B.poincareTerm χ x y)) ∧ |
| 170 | -- (b) |
| 171 | Continuous ↿(B.poincareSeries χ) ∧ |
| 172 | -- (c) |
| 173 | (∀ x : V, B.poincareSeries χ x ∈ B.thetaSpace χ) ∧ |
| 174 | -- (d) |
| 175 | quotMean L.toAddSubgroup (fun x : V ↦ B.poincareSeries χ x x) = (χ 0)⁻¹ ∧ |
| 176 | -- (e) |
| 177 | ∃ w : V, B.poincareSeries χ w w ≠ 0 := by |
| 178 | -- The series is the case `T = 1` of `summable_and_analyticAt_tsum`, at the parameters |
| 179 | -- `(B x, y - x, y)`; as `T` is constant, any base point `b` serves. |
| 180 | let t : StrongDual ℂ V × V × V → L → ℂ := |
| 181 | fun (ξ, u, z) (l : L) ↦ (ξ (u + l) - B l z - B l l / 2).exp / χ l |
| 182 | have h_T_an : ∀ᶠ c : ℂ in nhds I, ∀ x : V, |
| 183 | AnalyticAt ℂ (fun c' : ℂ ↦ (1 : ℂ → V →L[ℝ] V) c' x) c := by simp [analyticAt_const] |
| 184 | have series (p : StrongDual ℂ V × V × V) : |
| 185 | Summable (t p) ∧ AnalyticAt ℂ (fun q ↦ tsum (t q)) p := |
| 186 | (hB.summable_and_analyticAt_tsum (b := I) (T := 1) h_T_an h_pos p).imp_right |
| 187 | fun h ↦ h.comp (f := fun q ↦ (I, q)) (by fun_prop) |
| 188 | have mean : (quotMean L.toAddSubgroup fun x ↦ B.poincareSeries χ x x) = (χ 0)⁻¹ := by |
| 189 | -- On the diagonal the series is `∑ l, 𝐞 (B.riemannForm x l) * t 0 l`, a Fourier series on |
| 190 | -- `V ⧸ L`; its mean is the coefficient at `l = 0`. |
| 191 | have h_term (x : V) (l : L) : B.poincareTerm χ x x l = 𝐞 (B.riemannForm x l) * t 0 l := by |
| 192 | simp [t, ThetaTori.LatticeForm.poincareTerm, exp_sub, ← hB.sub_eq_riemannForm, field] |
| 193 | have coef : ∑' l : ({0} : Set L), t 0 l = |
| 194 | quotMean L.toAddSubgroup fun x ↦ ∑' l : L, 𝐞 (B.riemannForm x l) * t 0 l := |
| 195 | (isPosRiemann_of_re_pos h_pos).isDualFamily.tsum_coeff_eq_quotMean |
| 196 | (fun l : L ↦ ⟨l, hB.le_dualLattice l.prop⟩) (S := {0}) (by simp) (series 0).1 |
| 197 | have h_series (x : V) : B.poincareSeries χ x x = ∑' l : L, 𝐞 (B.riemannForm x l) * t 0 l := by |
| 198 | simp only [ThetaTori.LatticeForm.poincareSeries] |
| 199 | exact tsum_congr (h_term x) |
| 200 | simp only [h_series, ← coef] |
| 201 | simp [t] |
| 202 | refine ⟨fun x y ↦ (series (B x, y - x, y)).1, ?_, fun x ↦ ⟨fun y ↦ ?_, fun m hm z ↦ ?_⟩, mean, ?_⟩ |
| 203 | · exact (AnalyticOnNhd.continuous fun p _ ↦ (series p).2).comp |
| 204 | (f := fun p : V × V ↦ (B p.1, p.2 - p.1, p.2)) (by fun_prop) |
| 205 | · exact (series _).2.differentiableAt.comp (f := fun y ↦ (B x, y - x, y)) y (by fun_prop) |
| 206 | · -- Translating `z` by `m` shifts the summation index by `m`, up to the factor of automorphy: |
| 207 | -- use the cocycle rule for `χ (m + l)` and `B m l - B l m = 2 π I * B.riemannForm m l`. |
| 208 | have shift (l : L) : B.poincareTerm χ x (z + m) l = |
| 209 | χ m * (B m z + B m m / 2).exp * B.poincareTerm χ x z (Equiv.addLeft ⟨m, hm⟩ l) := by |
| 210 | have hχ_m : χ m ≠ 0 := hB.ne_zero hm |
| 211 | have hχ_l : χ l ≠ 0 := hB.ne_zero l.prop |
| 212 | simp [ThetaTori.LatticeForm.poincareTerm, hB.semicharacter, hm, field, ← exp_add] |
| 213 | -- The exponents differ by `(B m l - B l m) / 2 + π I E(l, m)`, which is zero. |
| 214 | congr 1 |
| 215 | linear_combination (-1 / 2 : ℂ) * hB.sub_eq_riemannForm (l : V) m |
| 216 | rw [ThetaTori.LatticeForm.poincareSeries, tsum_congr shift, tsum_mul_left, Equiv.tsum_eq, |
| 217 | ThetaTori.LatticeForm.poincareSeries] |
| 218 | · -- A function with nonzero mean is not identically zero. |
| 219 | contrapose! mean |
| 220 | simp [mean, hB.ne_zero, eq_comm] |
| 221 | |
| 222 | omit [IsFullRankLattice L] in |
| 223 | /-- The form `B (I • u) v + I * B u v`, which is `2 I` times the part of `B` that is complex-linear |
| 224 | in the first variable, is symmetric. -/ |
| 225 | lemma IsAppellHumbert.linearPart_symm (u v : V) : |
| 226 | B (I • u) v + I * B u v = B (I • v) u + I * B v u := by |
| 227 | simpa [Complex.ext_iff, hB.re_symm, add_comm] using hB.re_symm (I • u) (I • v) |
| 228 | |
| 229 | include hp |
| 230 | |
| 231 | /-- For Appell–Humbert data (B, χ) (instance `hB`) whose Riemann form is positive (instance `hp`) |
| 232 | there is a nonzero theta function of type (B, χ). -/ |
| 233 | lemma IsAppellHumbert.exists_mem_thetaSpace_ne_zero : ∃ f ∈ B.thetaSpace χ, f ≠ 0 := by |
| 234 | -- `T` is minus the part of `B` that is complex-linear in the first variable, so that `B + T` is |
| 235 | -- hermitian, with the same Riemann form. Its Poincaré series is not zero at some point `(w, w)`. |
| 236 | let T : RealComplexForm V := (I / 2) • (B ∘L .lsmul ℝ ℂ I + I • B) |
| 237 | have T_symm {u v : V} : T u v = T v u := |
| 238 | congrArg (fun w : ℂ ↦ I / 2 * w) (hB.linearPart_symm u v) |
| 239 | -- As `T` is symmetric, its Riemann form vanishes, and `(B + T, χ)` are Appell–Humbert data. |
| 240 | have h_riem : (B + T).riemannForm = B.riemannForm := by |
| 241 | ext u v |
| 242 | simp [riemannForm_def, T_symm] |
| 243 | have hB' : IsAppellHumbert (B + T) χ := |
| 244 | { re_symm := fun u v ↦ by simp [hB.re_symm u v, T_symm] |
| 245 | norm_eq_one := hB.norm_eq_one |
| 246 | semicharacter := by simpa [h_riem] using hB.semicharacter } |
| 247 | -- The real part of `(B + T) x x` is `π E(x, i x)`, positive for `x ≠ 0`. |
| 248 | have h_re (x : V) : ((B + T) x x).re = Real.pi * B.riemannForm x (I • x) := by |
| 249 | simp [T, riemannForm_def, field] |
| 250 | ring |
| 251 | have pos : ∀ x ≠ 0, 0 < ((B + T) x x).re := fun x hx ↦ by |
| 252 | rw [h_re x] |
| 253 | exact mul_pos Real.pi_pos (hp.riemannForm_pos x hx) |
| 254 | obtain ⟨-, -, series_mem, -, w, hw⟩ := hB'.poincareSeries_mem_thetaSpace_and_quotMean pos |
| 255 | -- A factor without zeros carries theta functions for `B + T` to theta functions for `B`. |
| 256 | have mem : (fun z ↦ ((B z z - (B + T) z z) / 2).exp * (B + T).poincareSeries χ w z) ∈ |
| 257 | B.thetaSpace χ := |
| 258 | hB'.exp_mul_mem_thetaSpace hB h_riem (fun _ _ ↦ rfl) (series_mem w) |
| 259 | exact ⟨_, mem, fun h_zero ↦ mul_ne_zero (exp_ne_zero _) hw (congrFun h_zero w)⟩ |
| 260 | |
| 261 | /-- For Appell–Humbert data (B, χ) with positive Riemann form (instances `hB`, `hp`), `L` has finite |
| 262 | index in its dual lattice, as both are full lattices. -/ |
| 263 | lemma IsAppellHumbert.finite_dualLattice_quotient : |
| 264 | Finite (B.dualLattice ⧸ (L.submoduleOf B.dualLattice).toAddSubgroup) := by |
| 265 | refine (finiteQuotient_iff _).mpr ?_ |
| 266 | simp [ZLattice.rank ℝ, (submoduleOfEquivOfLe hB.le_dualLattice).finrank_eq] |
| 267 | |
| 268 | /-- The form `T u v = (i / 2) (C (i u) v + i C u v)`, which is minus the part of `C` that is |
| 269 | complex-linear in the first variable. -/ |
| 270 | private def linearPartForm (C : RealComplexForm V) : RealComplexForm V := |
| 271 | (I / 2) • (C ∘L .lsmul ℝ ℂ I + I • C) |
| 272 | |
| 273 | omit [IsFullRankLattice L] hB hp in |
| 274 | /-- The twisted translates of a theta function `f`, `(u, z) ↦ thetaShift B u f z`, form a continuous |
| 275 | function of two variables. -/ |
| 276 | private lemma continuous_uncurry_thetaShift (f : B.thetaSpace χ) : |
| 277 | Continuous ↿(fun u : V ↦ B.thetaShift u f) := |
| 278 | .mul (by fun_prop) ((differentiable_of_mem_thetaSpace f.prop).continuous.comp (by fun_prop)) |
| 279 | |
| 280 | /-- For tuples `s`, `t` of theta functions, the function |
| 281 | `x ↦ exp (T b b / 2) * ∑ i, conj ((thetaShift x (s i)) 0) * (thetaShift x (t i)) b` on `V`, with `T` |
| 282 | the form `linearPartForm B`. Its mean over `V ⧸ L` pairs `s` with `t`. -/ |
| 283 | private def pairingIntegrand {n : ℕ} (s t : Fin n → B.thetaSpace χ) (b : V) : V → ℂ := |
| 284 | fun x : V ↦ |
| 285 | (linearPartForm B b b / 2).exp * |
| 286 | ∑ i : Fin n, conj (B.thetaShift x (s i) 0) * B.thetaShift x (t i) b |
| 287 | |
| 288 | omit [IsFullRankLattice L] hp in |
| 289 | /-- The integrand `pairingIntegrand s t b` is continuous and periodic under `L`. -/ |
| 290 | private lemma isContPeriodic_pairingIntegrand {n : ℕ} |
| 291 | (s t : Fin n → B.thetaSpace χ) (b : V) : |
| 292 | IsContPeriodic L.toAddSubgroup (pairingIntegrand s t b) := by |
| 293 | refine ⟨?_, fun l hl x ↦ ?_⟩ |
| 294 | · have shift_cont := continuous_uncurry_thetaShift (B := B) (χ := χ) |
| 295 | unfold pairingIntegrand |
| 296 | fun_prop |
| 297 | -- Translating by `l ∈ L` multiplies every translate of a theta function by one scalar `c`, and |
| 298 | -- `conj c * c = ‖c‖ ^ 2 = 1`. |
| 299 | let c : ℂ := exp (-(Real.pi * I * B.riemannForm x l)) * χ l |
| 300 | have h_shift (f : B.thetaSpace χ) : B.thetaShift (l + x) f = c • B.thetaShift x f := by |
| 301 | rw [add_comm l x] |
| 302 | exact hB.thetaShift_add_eq_smul_of_mem f.prop x hl |
| 303 | have h_norm_c : ‖c‖ = 1 := by simp [c, norm_exp, hB.norm_eq_one l hl] |
| 304 | have h_conj_mul : conj c * c = 1 := by simp [conj_mul', h_norm_c] |
| 305 | simp [pairingIntegrand, h_shift, mul_mul_mul_comm _ (conj _), h_conj_mul] |
| 306 | |
| 307 | /-- The mean over `V ⧸ L` of `pairingIntegrand s t b`; at `b = 0` it is the inner product of the |
| 308 | tuples `s` and `t` of theta functions. -/ |
| 309 | private def pairingMean {n : ℕ} (s t : Fin n → B.thetaSpace χ) (b : V) : ℂ := |
| 310 | quotMean L.toAddSubgroup (pairingIntegrand s t b) |
| 311 | |
| 312 | omit hp in |
| 313 | /-- The mean `pairingMean s t` is holomorphic in `b`. -/ |
| 314 | private lemma differentiable_pairingMean {n : ℕ} (s t : Fin n → B.thetaSpace χ) : |
| 315 | Differentiable ℂ (pairingMean s t) := by |
| 316 | -- `T = linearPartForm B` is symmetric, so `b ↦ T b b` is holomorphic; `fun_prop` below uses |
| 317 | -- `T_symm` and `shift_cont`. |
| 318 | have T_symm {u v : V} : linearPartForm B u v = linearPartForm B v u := |
| 319 | congrArg (fun z : ℂ ↦ I / 2 * z) (hB.linearPart_symm u v) |
| 320 | have shift_cont (f : B.thetaSpace χ) : Continuous ↿(fun u : V ↦ B.thetaShift u f) := |
| 321 | continuous_uncurry_thetaShift f |
| 322 | -- By periodicity the integrand does not depend on the representative of a class of `V ⧸ L`. |
| 323 | have h_out (c x : V) : pairingIntegrand s t c (QuotientAddGroup.mk x : V ⧸ L.toAddSubgroup).out = |
| 324 | pairingIntegrand s t c x := |
| 325 | (isContPeriodic_pairingIntegrand s t c).apply_out_mk x |
| 326 | -- The integrand at representatives is continuous in `(b, q)` and holomorphic in `b`. |
| 327 | have h_cont (a : V) (q : V ⧸ L.toAddSubgroup) : |
| 328 | ContinuousAt |
| 329 | (Function.uncurry fun (c : V) (q : V ⧸ L.toAddSubgroup) ↦ pairingIntegrand s t c (out q)) |
| 330 | (a, q) := by |
| 331 | refine ((isQuotientMap_mk _).continuous_lift_prod_right ?_).continuousAt |
| 332 | simp only [Function.uncurry_apply_pair, h_out] |
| 333 | simp only [pairingIntegrand] |
| 334 | fun_prop |
| 335 | have h_diff (a : V) (q : V ⧸ L.toAddSubgroup) : |
| 336 | DifferentiableAt ℂ (fun c : V ↦ pairingIntegrand s t c (out q)) a := by |
| 337 | have t_diff (i : Fin n) := differentiable_of_mem_thetaSpace (t i).prop |
| 338 | simp only [pairingIntegrand] |
| 339 | fun_prop |
| 340 | -- Hence the integrand is an analytic family, and its mean over `V ⧸ L` is analytic. |
| 341 | exact fun b ↦ ((isAnalyticFamily_of_differentiable |
| 342 | (.of_forall fun a q ↦ ⟨h_cont a q, h_diff a q⟩)).analyticAt_integral _).differentiableAt |
| 343 | |
| 344 | omit hp in |
| 345 | /-- Swapping the tuples and the sign of `b` conjugates `pairingMean`, the mean over `V ⧸ L` of |
| 346 | `pairingIntegrand s t b`. -/ |
| 347 | private lemma pairingMean_neg {n : ℕ} (s t : Fin n → B.thetaSpace χ) (b : V) : |
| 348 | pairingMean t s (-b) = conj (pairingMean s t b) := by |
| 349 | -- After translating the mean by `b`, the integrands agree up to conjugation: the theta values |
| 350 | -- match, and so do the exponents, written here as they appear after unfolding. |
| 351 | have h_exponent (x : V) : |
| 352 | (I / 2 * B (I • b) b + I / 2 * I * B b b) / 2 + |
| 353 | (-((conj (B x x) + conj (B x b) + (conj (B b x) + conj (B b b))) / 2) + |
| 354 | (-((B x x + B x b + (B b x + B b b)) / 2) + (B b b + B x b))) = |
| 355 | (-(I / 2 * conj (B (I • b) b)) + I / 2 * I * conj (B b b)) / 2 + |
| 356 | (-(B x x / 2) + (-(conj (B x x) / 2) + -conj (B x b))) := by |
| 357 | -- Use symmetry of the real part, including at `I • b`, in both components. |
| 358 | apply Complex.ext <;> simp [hB.re_symm, neg_div] <;> ring |
| 359 | have h_integrand (x : V) : |
| 360 | pairingIntegrand t s (-b) (x + b) = conj (pairingIntegrand s t b x) := by |
| 361 | simp [pairingIntegrand, linearPartForm, mul_sum, thetaShift_apply_apply, ← exp_conj, |
| 362 | ← mul_assoc, mul_right_comm _ (conj _), conj_ofNat, ← exp_add, neg_div, map_sum, |
| 363 | add_comm b x, h_exponent] |
| 364 | calc pairingMean t s (-b) |
| 365 | = quotMean L.toAddSubgroup fun x ↦ pairingIntegrand t s (-b) (x + b) := |
| 366 | (quotMean_translate (isContPeriodic_pairingIntegrand t s (-b)) b).symm |
| 367 | _ = quotMean L.toAddSubgroup fun x ↦ conj (pairingIntegrand s t b x) := by |
| 368 | simp only [h_integrand] |
| 369 | _ = conj (pairingMean s t b) := by simp [pairingMean, quotMean, ← integral_conj] |
| 370 | |
| 371 | omit hp in |
| 372 | /-- Liouville's theorem applied to the mean `m = pairingMean`: if `m s t 0 = 0`, then `m t s` |
| 373 | vanishes everywhere. -/ |
| 374 | private lemma pairingMean_eq_zero_of_eq_zero {n : ℕ} |
| 375 | {s t : Fin n → B.thetaSpace χ} (h_zero : pairingMean s t 0 = 0) (b : V) : |
| 376 | pairingMean t s b = 0 := by |
| 377 | -- `exp (-m s t (-b) * m t s b) = exp (-‖m t s b‖ ^ 2)` is entire and bounded by `1`, so it keeps |
| 378 | -- its value `1` at `b = 0`. |
| 379 | have h_entire : Differentiable ℂ fun b ↦ exp (-pairingMean s t (-b) * pairingMean t s b) := |
| 380 | (((differentiable_pairingMean s t).comp differentiable_id.neg).neg.mul |
| 381 | (differentiable_pairingMean t s)).cexp |
| 382 | have h_bound (c : V) : ‖exp (-pairingMean s t (-c) * pairingMean t s c)‖ ≤ 1 := by |
| 383 | simp [pairingMean_neg, mul_nonneg, conj_mul', sq, norm_exp] |
| 384 | have h_const : exp (-pairingMean s t (-b) * pairingMean t s b) = |
| 385 | exp (-pairingMean s t (-0) * pairingMean t s 0) := |
| 386 | h_entire.apply_eq_apply_of_bounded |
| 387 | (isBounded_iff_forall_norm_le.mpr ⟨1, Set.forall_mem_range.mpr h_bound⟩) b 0 |
| 388 | simpa [pairingMean_neg, h_zero, conj_mul', sq, norm_exp] using congrArg norm h_const |
| 389 | |
| 390 | omit hp in |
| 391 | /-- Let `(B, χ)` be Appell–Humbert data for a full-rank lattice `L` in `V`, and let `s` and `t` be |
| 392 | `n`-tuples of theta functions of type `(B, χ)`. If the pairing mean of the shift of `s` by each |
| 393 | chosen coset representative of `B.dualLattice / L` with `t` vanishes at `0`, then for every `b : V` |
| 394 | and `a ∈ B.dualLattice`, the Fourier coefficient of `pairingIntegrand t s b` at the character |
| 395 | `x ↦ 𝐞 (B.riemannForm x a)` vanishes. -/ |
| 396 | private lemma IsAppellHumbert.quotMean_pairingIntegrand_eq_zero {n : ℕ} |
| 397 | {s t : Fin n → B.thetaSpace χ} |
| 398 | (ht : ∀ q : B.dualLattice ⧸ (L.submoduleOf B.dualLattice).toAddSubgroup, |
| 399 | pairingMean (thetaShiftEnd q.out ∘ s) t 0 = 0) |
| 400 | (b : V) (a : B.dualLattice) : |
| 401 | quotMean L.toAddSubgroup (fun x ↦ 𝐞 (B.riemannForm x a) * pairingIntegrand t s b x) = 0 := by |
| 402 | -- The chosen representative of the class of `a` is `a + l` with `l ∈ L`. |
| 403 | obtain ⟨⟨l, hl : (l : V) ∈ L⟩, out_eq⟩ := mk_out_eq_add (L.submoduleOf _).toAddSubgroup a |
| 404 | have inner_zero : pairingMean (thetaShiftEnd (a + l) ∘ s) t 0 = 0 := by |
| 405 | rw [← out_eq] |
| 406 | exact ht _ |
| 407 | have shifted : pairingMean t (thetaShiftEnd (a + l) ∘ s) (b - a) = 0 := |
| 408 | pairingMean_eq_zero_of_eq_zero inner_zero (b - a) |
| 409 | -- Translating `s i` by `a + l` gives `χ l`, a phase and the translate by `a`; moving that past |
| 410 | -- the translation by `x` gives the character `𝐞 (E(x, a))` (`thetaShift_comm`), and evaluating |
| 411 | -- at `b - a` moves the argument back to `b`. |
| 412 | have h_term (x : V) (i : Fin n) : |
| 413 | B.thetaShift x ((thetaShiftEnd (a + l) ∘ s) i : V → ℂ) (b - a) = |
| 414 | exp (-(Real.pi * I * B.riemannForm a l)) * χ l * 𝐞 (B.riemannForm x a) * |
| 415 | exp (-(B a (b - a) + B a a / 2)) * B.thetaShift x (s i) b := by |
| 416 | rw [Function.comp_apply, LinearMap.coe_restrict_apply, Submodule.coe_add, |
| 417 | hB.thetaShift_add_eq_smul_of_mem (s i).prop (a : V) hl, map_smul, Pi.smul_apply, |
| 418 | hB.thetaShift_comm x (a : V), Pi.smul_apply, thetaShift_apply_apply (a := (a : V)), |
| 419 | sub_add_cancel, smul_eq_mul, smul_eq_mul] |
| 420 | ring |
| 421 | -- So the integrand is `c` times `𝐞 (E(x, a))` times the integrand for `s` at `b`. |
| 422 | let c : ℂ := exp (linearPartForm B (b - a) (b - a) / 2) * exp (-(B a (b - a) + B a a / 2)) * |
| 423 | (exp (-(Real.pi * I * B.riemannForm a l)) * χ l) / exp (linearPartForm B b b / 2) |
| 424 | have hc_ne : c ≠ 0 := by simp [c, hB.ne_zero hl] |
| 425 | have h_integrand : pairingIntegrand t (thetaShiftEnd (a + l) ∘ s) (b - a) = |
| 426 | fun x ↦ c * (𝐞 (B.riemannForm x a) * pairingIntegrand t s b x) := by |
| 427 | funext x |
| 428 | simp only [pairingIntegrand, h_term, c, mul_sum] |
| 429 | refine Finset.sum_congr rfl fun i _ ↦ ?_ |
| 430 | field_simp |
| 431 | have h_mean : c * quotMean L.toAddSubgroup |
| 432 | (fun x ↦ 𝐞 (B.riemannForm x a) * pairingIntegrand t s b x) = 0 := by |
| 433 | rwa [← quotMean_const_mul, ← h_integrand] |
| 434 | exact (mul_eq_zero.mp h_mean).resolve_left hc_ne |
| 435 | |
| 436 | /-- Upper bound for the dimension. Let `(B, χ)` be Appell–Humbert data with positive Riemann form |
| 437 | for a full-rank lattice `L` in `V`. If there are `n` linearly independent theta functions `s i` of |
| 438 | type `(B, χ)`, then there is an injective `ℂ`-linear map from `n`-tuples of such theta functions to |
| 439 | the functions on the dual lattice `B.dualLattice` modulo `L`. -/ |
| 440 | lemma IsAppellHumbert.exists_injective_to_dual_quotient {n : ℕ} {s : Fin n → B.thetaSpace χ} |
| 441 | (hs : LinearIndependent ℂ s) : |
| 442 | ∃ ψ : (Fin n → B.thetaSpace χ) →ₗ[ℂ] |
| 443 | (B.dualLattice ⧸ (L.submoduleOf B.dualLattice).toAddSubgroup → ℂ), |
| 444 | Function.Injective ψ := by |
| 445 | let pairingAt (q : B.dualLattice ⧸ (L.submoduleOf B.dualLattice).toAddSubgroup) : |
| 446 | (Fin n → B.thetaSpace χ) →ₗ[ℂ] ℂ := |
| 447 | { toFun t := pairingMean (thetaShiftEnd q.out ∘ s) t 0 |
| 448 | map_add' t t' := by |
| 449 | -- The integrand is additive in `t`, and the integrands are integrable. |
| 450 | have h_add (x : V) : |
| 451 | pairingIntegrand (thetaShiftEnd q.out ∘ s) (t + t') 0 x = |
| 452 | pairingIntegrand (thetaShiftEnd q.out ∘ s) t 0 x + |
| 453 | pairingIntegrand (thetaShiftEnd q.out ∘ s) t' 0 x := by |
| 454 | simp [pairingIntegrand, mul_add, sum_add_distrib] |
| 455 | have h_per (u : Fin n → B.thetaSpace χ) : |
| 456 | IsContPeriodic L.toAddSubgroup (pairingIntegrand (thetaShiftEnd q.out ∘ s) u 0) := |
| 457 | isContPeriodic_pairingIntegrand _ u 0 |
| 458 | simp only [pairingMean, quotMean, h_add] |
| 459 | exact integral_add (h_per t).integrable_out (h_per t').integrable_out |
| 460 | map_smul' c t := by |
| 461 | unfold pairingMean pairingIntegrand |
| 462 | simp [mul_left_comm, ← mul_sum] } |
| 463 | refine ⟨.pi pairingAt, (injective_iff_map_eq_zero _).mpr fun t ht ↦ ?_⟩ |
| 464 | -- Up to a non-zero factor, `pairingMean t (thetaShiftEnd a ∘ s) (b - a)` is the Fourier |
| 465 | -- coefficient of `pairingIntegrand t s b` at the character of `a`; changing `a` by an element of |
| 466 | -- `L` only changes the factor. |
| 467 | have coef_zero (b : V) (a : B.dualLattice) : |
| 468 | quotMean L.toAddSubgroup (fun x ↦ 𝐞 (B.riemannForm x a) * pairingIntegrand t s b x) = 0 := |
| 469 | hB.quotMean_pairingIntegrand_eq_zero (congrFun ht) b a |
| 470 | -- So `pairingIntegrand t s` vanishes, which says that `∑ i, conj (t i y) • s i = 0`. |
| 471 | ext i y |
| 472 | have relation : ∑ i, conj ((t i : V → ℂ) y) • s i = 0 := by |
| 473 | ext x |
| 474 | simpa [pairingIntegrand, thetaShift_apply_apply, mul_mul_mul_comm, ← mul_sum] using |
| 475 | hp.isDualFamily.eq_zero_of_quotMean_mul_eq_zero (isContPeriodic_pairingIntegrand t s (x - y)) |
| 476 | (fun a _ ↦ coef_zero _ a) y |
| 477 | simpa using Fintype.linearIndependent_iff.mp hs _ relation i |
| 478 | |
| 479 | /-- For Appell–Humbert data with positive Riemann form, the space of theta functions has finite |
| 480 | dimension. -/ |
| 481 | lemma IsAppellHumbert.finite_thetaSpace : Module.Finite ℂ (B.thetaSpace χ) := by |
| 482 | -- The space embeds in the functions on the dual lattice modulo `L`, a finite group. |
| 483 | obtain ⟨f, hf, hf_ne⟩ : ∃ f ∈ B.thetaSpace χ, f ≠ 0 := hB.exists_mem_thetaSpace_ne_zero |
| 484 | have := hB.finite_dualLattice_quotient |
| 485 | have h_indep : LinearIndependent ℂ ![(⟨f, hf⟩ : B.thetaSpace χ)] := by simpa using hf_ne |
| 486 | obtain ⟨ψ, hψ_inj⟩ := hB.exists_injective_to_dual_quotient h_indep |
| 487 | have h_finite_tuples : Module.Finite ℂ (Fin 1 → B.thetaSpace χ) := .of_injective ψ hψ_inj |
| 488 | exact Finite.pi_iff.mp h_finite_tuples 0 |
| 489 | |
| 490 | /-- For Appell–Humbert data with positive Riemann form, the space of theta functions has positive |
| 491 | dimension. -/ |
| 492 | lemma IsAppellHumbert.finrank_thetaSpace_pos : 0 < finrank ℂ (B.thetaSpace χ) := by |
| 493 | obtain ⟨f, hf, hf_ne⟩ : ∃ f ∈ B.thetaSpace χ, f ≠ 0 := hB.exists_mem_thetaSpace_ne_zero |
| 494 | have h_finite : Module.Finite ℂ (B.thetaSpace χ) := hB.finite_thetaSpace |
| 495 | exact finrank_pos_iff_exists_ne_zero.mpr ⟨⟨f, hf⟩, by simpa using hf_ne⟩ |
| 496 | |
| 497 | /-- For Appell–Humbert data with positive Riemann form, the twisted translations |
| 498 | `New.IsAppellHumbert.thetaShiftEnd` by representatives of the dual lattice modulo `L` are linearly |
| 499 | independent endomorphisms of the space of theta functions. -/ |
| 500 | lemma IsAppellHumbert.linearIndependent_thetaShiftEnd_out : |
| 501 | LinearIndependent ℂ fun q : B.dualLattice ⧸ (L.submoduleOf B.dualLattice).toAddSubgroup ↦ |
| 502 | hB.thetaShiftEnd q.out := by |
| 503 | -- They are simultaneous eigenvectors of the conjugations by all `thetaShiftEnd y`, for distinct |
| 504 | -- characters `e q`. |
| 505 | let N : AddSubgroup B.dualLattice := (L.submoduleOf B.dualLattice).toAddSubgroup |
| 506 | let e (q : B.dualLattice ⧸ N) (y : B.dualLattice) : ℂ := B.riemannPhase q.out (y : V) |
| 507 | have e_inj : e.Injective := by |
| 508 | intro q q' h_eq |
| 509 | -- Equal characters give `𝐞 (E (-q + q', y)) = 1` for all `y`, so `-q + q'` lies in `L`. |
| 510 | refine out_equiv_out.mp (leftRel_apply.mpr (hp.isDualFamily.mem_of_forall_eq_one _ ?_)) |
| 511 | show ∀ y : B.dualLattice, (𝐞 (B.riemannForm ((-out q + out q' : B.dualLattice) : V) y) : ℂ) = 1 |
| 512 | intro y |
| 513 | have h_phase : (𝐞 (B.riemannForm ((q.out : B.dualLattice) : V) y) : ℂ) = |
| 514 | 𝐞 (B.riemannForm ((q'.out : B.dualLattice) : V) y) := |
| 515 | congrFun h_eq y |
| 516 | simp [neg_add_eq_sub, AddChar.map_sub_eq_div, h_phase] |
| 517 | let conjugation (y : B.dualLattice) : End ℂ (End ℂ (B.thetaSpace χ)) := |
| 518 | .mulLeftRight ℂ (hB.thetaShiftEnd (-y), hB.thetaShiftEnd y) |
| 519 | have eigen (q : B.dualLattice ⧸ N) : |
| 520 | hB.thetaShiftEnd q.out ∈ ⨅ y, (conjugation y).eigenspace (e q y) := by |
| 521 | -- `T(-y) T(y) = 1`, and `T(q) T(y) = e q y • T(y) T(q)` (`thetaShift_comm`): conjugating |
| 522 | -- `T(q)` by `T(y)` multiplies it by `e q y`. |
| 523 | have h_conj (y : B.dualLattice) (g : V → ℂ) : |
| 524 | B.thetaShift (-(y : V)) (B.thetaShift q.out (B.thetaShift y g)) = |
| 525 | e q y • B.thetaShift q.out g := by |
| 526 | have h_inv (g : V → ℂ) : B.thetaShift (-y : V) (B.thetaShift y g) = g := by |
| 527 | simp [hB.thetaShift_thetaShift] |
| 528 | rw [hB.thetaShift_comm ((q.out : B.dualLattice) : V) (y : V), map_smul, h_inv] |
| 529 | simp only [Submodule.mem_iInf, Module.End.mem_eigenspace_iff] |
| 530 | refine fun y ↦ LinearMap.ext fun g ↦ Subtype.ext ?_ |
| 531 | simpa [conjugation] using h_conj y g |
| 532 | have shift_ne (q : B.dualLattice ⧸ N) : hB.thetaShiftEnd q.out ≠ 0 := by |
| 533 | obtain ⟨f, hf, hf_ne⟩ : ∃ f ∈ B.thetaSpace χ, f ≠ 0 := hB.exists_mem_thetaSpace_ne_zero |
| 534 | obtain ⟨w, hw⟩ : ∃ w : V, f w ≠ 0 := Function.ne_iff.mp hf_ne |
| 535 | intro h_zero |
| 536 | -- The translate of `f` would vanish at `w - q.out`, where it is a nonzero multiple of `f w`. |
| 537 | have h_value := congrArg (fun T ↦ (T ⟨f, hf⟩ : V → ℂ) (w - q.out)) h_zero |
| 538 | simp [thetaShift_apply_apply, hw] at h_value |
| 539 | have indep : iSupIndep fun c : B.dualLattice → ℂ ↦ ⨅ y, (conjugation y).eigenspace (c y) := |
| 540 | iSupIndep.iInf _ fun y ↦ (conjugation y).eigenspaces_iSupIndep |
| 541 | exact (indep.comp e_inj).linearIndependent _ eigen shift_ne |
| 542 | |
| 543 | /-- For Appell–Humbert data with positive Riemann form, the index of `L` in its dual lattice is the |
| 544 | dimension of the endomorphism algebra of the space of theta functions. -/ |
| 545 | lemma IsAppellHumbert.relIndex_dualLattice_eq_finrank_end : |
| 546 | L.toAddSubgroup.relIndex B.dualLattice.toAddSubgroup = |
| 547 | finrank ℂ (End ℂ (B.thetaSpace χ)) := by |
| 548 | -- With `n` the dimension of the space of theta functions, independence of the translations gives |
| 549 | -- index `≤ n ^ 2`, and the embedding of `n`-tuples gives `n ^ 2 ≤` index. |
| 550 | let N : AddSubgroup B.dualLattice := (L.submoduleOf B.dualLattice).toAddSubgroup |
| 551 | have := hB.finite_dualLattice_quotient |
| 552 | let h_fintype_quot : Fintype (B.dualLattice ⧸ N) := Fintype.ofFinite (B.dualLattice ⧸ N) |
| 553 | have h_finite : Module.Finite ℂ (B.thetaSpace χ) := hB.finite_thetaSpace |
| 554 | have card_le : card (B.dualLattice ⧸ N) ≤ finrank ℂ (End ℂ (B.thetaSpace χ)) := |
| 555 | hB.linearIndependent_thetaShiftEnd_out.fintype_card_le_finrank |
| 556 | -- A basis of the theta functions gives `n` independent ones, so the `n`-tuples embed. |
| 557 | have h_embed : |
| 558 | finrank ℂ (Fin (finrank ℂ (B.thetaSpace χ)) → B.thetaSpace χ) ≤ |
| 559 | finrank ℂ (B.dualLattice ⧸ N → ℂ) := |
| 560 | finrank_le_iff_exists_linearMap.mpr |
| 561 | (hB.exists_injective_to_dual_quotient (finBasis ℂ (B.thetaSpace χ)).linearIndependent) |
| 562 | have le_card : finrank ℂ (End ℂ (B.thetaSpace χ)) ≤ card (B.dualLattice ⧸ N) := by |
| 563 | simpa [finrank_linearMap, finrank_pi_fintype] using h_embed |
| 564 | calc L.toAddSubgroup.relIndex B.dualLattice.toAddSubgroup |
| 565 | _ = card (B.dualLattice ⧸ N) := card_eq_nat_card.symm |
| 566 | _ = finrank ℂ (End ℂ (B.thetaSpace χ)) := card_le.antisymm le_card |
| 567 | |
| 568 | /-- For Appell–Humbert data with positive Riemann form, the twisted translations by the dual lattice |
| 569 | span the endomorphisms of the space of theta functions. |
| 570 | |
| 571 | Known result: irreducibility of the action of the theta group. -/ |
| 572 | lemma IsAppellHumbert.span_range_thetaShiftEnd_eq_top : |
| 573 | span ℂ (Set.range hB.thetaShiftEnd) = ⊤ := by |
| 574 | -- The translations by representatives modulo `L` are independent and as many as the dimension. |
| 575 | let N : AddSubgroup B.dualLattice := (L.submoduleOf B.dualLattice).toAddSubgroup |
| 576 | have := hB.finite_dualLattice_quotient |
| 577 | let h_fintype_quot : Fintype (B.dualLattice ⧸ N) := Fintype.ofFinite (B.dualLattice ⧸ N) |
| 578 | have card_eq : card (B.dualLattice ⧸ N) = finrank ℂ (End ℂ (B.thetaSpace χ)) := |
| 579 | card_eq_nat_card.trans hB.relIndex_dualLattice_eq_finrank_end |
| 580 | exact eq_top_mono (span_mono (Set.range_comp_subset_range out hB.thetaShiftEnd)) |
| 581 | (hB.linearIndependent_thetaShiftEnd_out.span_eq_top_of_card_eq_finrank card_eq) |
| 582 | |
| 583 | /-- For Appell–Humbert data with positive Riemann form, the square of the dimension of the space of |
| 584 | theta functions is the index of `L` in its dual lattice. |
| 585 | |
| 586 | Known result: Frobenius' dimension formula. -/ |
| 587 | lemma IsAppellHumbert.finrank_thetaSpace_sq : |
| 588 | finrank ℂ (B.thetaSpace χ) ^ 2 = L.toAddSubgroup.relIndex B.dualLattice.toAddSubgroup := by |
| 589 | have := hB.finite_thetaSpace |
| 590 | simp [hB.relIndex_dualLattice_eq_finrank_end, sq, finrank_linearMap] |
| 591 | |
| 592 | /-- Let `(B, χ)` be Appell–Humbert data for `L` with positive Riemann form. (a) The translations by |
| 593 | the dual lattice span the endomorphisms of the space of theta functions. (b) The square of its |
| 594 | dimension is the index of `L` in the dual lattice. (c) The dimension is positive. |
| 595 | |
| 596 | Known result: Frobenius' dimension formula and irreducibility of the action of the theta group. -/ |
| 597 | lemma IsAppellHumbert.finrank_sq_eq_relIndex : |
| 598 | span ℂ (Set.range hB.thetaShiftEnd) = ⊤ ∧ |
| 599 | finrank ℂ (B.thetaSpace χ) ^ 2 = L.toAddSubgroup.relIndex B.dualLattice.toAddSubgroup ∧ |
| 600 | 0 < finrank ℂ (B.thetaSpace χ) := |
| 601 | ⟨hB.span_range_thetaShiftEnd_eq_top, hB.finrank_thetaSpace_sq, hB.finrank_thetaSpace_pos⟩ |
| 602 | |
| 603 | /-- Irreducibility: for Appell–Humbert data with positive Riemann form, a complex space of |
| 604 | functions that contains all twisted translates, by the dual lattice, of one non-zero theta |
| 605 | function contains every theta function. -/ |
| 606 | lemma IsAppellHumbert.thetaSpace_le_of_thetaShift_mem (hf : f ∈ B.thetaSpace χ) (h_ne : f ≠ 0) |
| 607 | (S : Submodule ℂ (V → ℂ)) (hS : ∀ a ∈ B.dualLattice, B.thetaShift a f ∈ S) : |
| 608 | B.thetaSpace χ ≤ S := by |
| 609 | -- The translations span all endomorphisms, among them `ℓ ⊗ g` with `ℓ f = 1`, which maps `f` to |
| 610 | -- `g`. The endomorphisms that map `f` into `S` form a subspace that contains the translations. |
| 611 | intro g hg |
| 612 | obtain ⟨ℓ, hℓ⟩ : ∃ ℓ : Module.Dual ℂ (V → ℂ), ℓ f = 1 := Projective.exists_dual_eq_one ℂ h_ne |
| 613 | -- `A` sends `f` to `ℓ f • g = g`. |
| 614 | let A : End ℂ (B.thetaSpace χ) := (ℓ.domRestrict (B.thetaSpace χ)).smulRight ⟨g, hg⟩ |
| 615 | have hA_apply : A ⟨f, hf⟩ = ⟨g, hg⟩ := by simp [A, hℓ] |
| 616 | let W : Submodule ℂ (End ℂ (B.thetaSpace χ)) := |
| 617 | (S.submoduleOf (B.thetaSpace χ)).comap (.applyₗ ⟨f, hf⟩) |
| 618 | have hA_mem_span : A ∈ span ℂ (Set.range hB.thetaShiftEnd) := |
| 619 | hB.span_range_thetaShiftEnd_eq_top.ge mem_top |
| 620 | have shift_mem (a : B.dualLattice) : hB.thetaShiftEnd a ∈ W := hS a a.prop |
| 621 | have hA_mem : A ∈ W := mem_span.mp hA_mem_span W (Set.range_subset_iff.mpr shift_mem) |
| 622 | -- Membership in `W` says that the value at `f` lies in `S`. |
| 623 | have h_value_mem : ((A ⟨f, hf⟩ : B.thetaSpace χ) : V → ℂ) ∈ S := hA_mem |
| 624 | rwa [hA_apply] at h_value_mem |
| 625 | |
| 626 | /-- Schur's lemma: for Appell–Humbert data (L, B, χ) with positive Riemann form, a linear |
| 627 | endomorphism of the theta functions of type (B, χ) that commutes with the twisted |
| 628 | translations `New.RealComplexForm.thetaShift` by the dual lattice is a scalar. -/ |
| 629 | lemma IsAppellHumbert.schur_lemma {Q : End ℂ (B.thetaSpace χ)} |
| 630 | (h_comm : ∀ a : B.dualLattice, Commute (hB.thetaShiftEnd a) Q) : |
| 631 | ∃ c : ℂ, Q = c • 1 := by |
| 632 | -- `Q` commutes with the span of the translations, which is everything, so it is central. |
| 633 | have central (A : End ℂ (B.thetaSpace χ)) : Commute A Q := |
| 634 | Commute.span_left (Set.forall_mem_range.mpr h_comm) A |
| 635 | (hB.span_range_thetaShiftEnd_eq_top.ge mem_top) |
| 636 | exact (Algebra.IsCentral.mem_center_iff ℂ).mp (Subring.mem_center_iff.mpr central) |
| 637 | |
| 638 | /-- For Appell–Humbert data with positive Riemann form, some positive integer `N` multiplies every |
| 639 | vector of the dual lattice into `L`. -/ |
| 640 | lemma IsAppellHumbert.exists_nsmul_mem_of_mem_dualLattice : |
| 641 | ∃ N ≠ (0 : ℕ), ∀ a ∈ B.dualLattice, N • a ∈ L := by |
| 642 | -- The index is the cardinality of the finite quotient of the dual lattice. |
| 643 | exact ⟨L.toAddSubgroup.relIndex B.dualLattice.toAddSubgroup, |
| 644 | Nat.card_ne_zero.mpr ⟨inferInstance, hB.finite_dualLattice_quotient⟩, |
| 645 | fun a ha ↦ L.toAddSubgroup.nsmul_relIndex_mem ha⟩ |
| 646 | |
| 647 | end New |
| 648 | |
| 649 | /-! |
| 650 | ## Multiples of a positive type have no base point |
| 651 | |
| 652 | Throughout, `L` is a full lattice in a finite-dimensional complex space `V`, and `(B, χ)` are |
| 653 | Appell–Humbert data for `L` (`New.IsAppellHumbert`) whose Riemann form is positive |
| 654 | (`New.IsPosRiemann`). |
| 655 | -/ |
| 656 | |
| 657 | section BasePointFree |
| 658 | |
| 659 | open New ThetaTori thetaSpace Complex |
| 660 | |
| 661 | variable {V : Type} [FinComplexSpace V] |
| 662 | {L : Submodule ℤ V} [IsFullRankLattice L] |
| 663 | {B : LatticeForm L} {χ : V → ℂ} |
| 664 | |
| 665 | /-- Let f and g be entire functions on a finite-dimensional complex space with f·g = 0. If f is not |
| 666 | identically zero, then g is identically zero. -/ |
| 667 | lemma New.ThetaTori.eq_zero_of_differentiable_of_mul_eq_zero {f g : V → ℂ} (hf : Differentiable ℂ f) |
| 668 | (hg : Differentiable ℂ g) (h : f * g = 0) (hf_ne : f ≠ 0) : |
| 669 | g = 0 := by |
| 670 | -- `g` vanishes near a point where `f` does not, hence everywhere by the identity theorem. |
| 671 | obtain ⟨z, hz⟩ : ∃ z : V, f z ≠ 0 := Function.ne_iff.mp hf_ne |
| 672 | have h_near : g =ᶠ[nhds z] 0 := by |
| 673 | filter_upwards [(hf z).continuousAt.eventually_ne hz] with w hw |
| 674 | exact (mul_eq_zero.mp (congrFun h w)).resolve_left hw |
| 675 | exact AnalyticOnNhd.eq_of_eventuallyEq |
| 676 | (fun w _ ↦ analyticAt_of_eventually_differentiableAt (.of_forall hg)) analyticOnNhd_const h_near |
| 677 | |
| 678 | /-- For Appell–Humbert data (B, χ) with positive Riemann form and n ≥ 2, the theta functions of |
| 679 | type (nB, χⁿ) have no common zero. -/ |
| 680 | lemma New.IsAppellHumbert.exists_mem_thetaSpace_nsmul_apply_ne_zero (hB : IsAppellHumbert B χ) |
| 681 | [IsPosRiemann B] (z : V) (n : ℕ) (hn : n > 1) : ∃ f ∈ (n • B).thetaSpace (χ ^ n), f z ≠ 0 := by |
| 682 | -- Take a nonzero theta function `f` of type `(B, χ)` and write the degree as `m + 1`, `m ≥ 1`. |
| 683 | -- For any `a`, the product of the translates of `f ^ m` by `a` and of `f` by `-m a` has type |
| 684 | -- `((m + 1) • B, χ ^ (m + 1))`. If all of these vanish at `z`, the product of two nonzero |
| 685 | -- entire functions of `a` is zero. |
| 686 | rcases n with _ | m |
| 687 | · omega |
| 688 | have hm_ne : m ≠ 0 := by omega |
| 689 | obtain ⟨f, hf, hf_ne⟩ : ∃ f ∈ B.thetaSpace χ, f ≠ 0 := hB.exists_mem_thetaSpace_ne_zero |
| 690 | have hf_diff : Differentiable ℂ f := differentiable_of_mem_thetaSpace hf |
| 691 | by_contra! h_zero |
| 692 | -- The two factors `exp (± 2 π i m E(l, a))` in the multiplier of the product cancel. |
| 693 | have h_multiplier (a l : V) : |
| 694 | (χ ^ m) l * (m • B).riemannPhase l a * (χ l * B.riemannPhase l (-(m : ℝ) • a)) = |
| 695 | (χ ^ (m + 1)) l := by |
| 696 | simp [exp_neg, field, pow_succ] |
| 697 | have h_mem (a : V) : thetaShift (m • B) a (f ^ m) * thetaShift B (-(m : ℝ) • a) f ∈ |
| 698 | ((m + 1) • B).thetaSpace (χ ^ (m + 1)) := by |
| 699 | refine (mul (thetaShift_mem (pow hf m) a) (thetaShift_mem hf _)).imp_right |
| 700 | fun h_law l hl w ↦ ?_ |
| 701 | simp only [h_law l hl w, Pi.mul_apply, h_multiplier a l, ← succ_nsmul] |
| 702 | -- At `z` the product is `f (z + a) ^ m * f (z - m a)` times a nonzero exponential. |
| 703 | have h_mul : ((fun a ↦ f (z + a)) * fun a ↦ f (z + -(m : ℝ) • a)) = 0 := by |
| 704 | funext a |
| 705 | simpa [thetaShift_apply, hm_ne] using h_zero _ (h_mem a) |
| 706 | have h_left : (fun a ↦ f (z + a)) ≠ 0 := (add_left_surjective z).injective_comp_right.ne hf_ne |
| 707 | have h_surj : Function.Surjective fun a : V ↦ z + -(m : ℝ) • a := |
| 708 | (add_left_surjective z).comp (MulAction.surjective₀ (by simpa using hm_ne)) |
| 709 | have h_right : (fun a ↦ f (z + -(m : ℝ) • a)) = 0 := |
| 710 | eq_zero_of_differentiable_of_mul_eq_zero (by fun_prop) (by fun_prop) h_mul h_left |
| 711 | exact h_surj.injective_comp_right.ne hf_ne h_right |
| 712 | |
| 713 | end BasePointFree |
| 714 | |
| 715 | /-! |
| 716 | ## The canonical multiplier and normalised translations |
| 717 | |
| 718 | * `New.ThetaTori.canonicalMultiplier`: for a linear map `b`, the multiplier `exp (π i E(b x, x))`, |
| 719 | defined on all of `V`. By `New.ThetaTori.isAppellHumbert_canonicalMultiplier` it satisfies the |
| 720 | Appell–Humbert conditions `New.IsAppellHumbert` if b + b* = 1 (adjoint for `E`), the real part of |
| 721 | `B` is symmetric and `E(b L, L)` is integral. |
| 722 | * `New.ThetaTori.normalizedShift`: the twisted translation `New.RealComplexForm.thetaShift B x` |
| 723 | divided by this multiplier. The theta functions are the entire functions fixed by it along `L` |
| 724 | (`New.ThetaTori.mem_thetaSpace_iff_normalizedShift`). If b + b* = 1 and `B` admits some |
| 725 | Appell–Humbert multiplier, it obeys the Heisenberg law |
| 726 | `New.IsAppellHumbert.normalizedShift_normalizedShift`. |
| 727 | -/ |
| 728 | |
| 729 | namespace New |
| 730 | |
| 731 | open Complex Finset ThetaTori |
| 732 | |
| 733 | variable {V V' ι : Type} [FinComplexSpace V] [FinComplexSpace V'] |
| 734 | (B : RealComplexForm V) (b : V →L[ℂ] V) {L : Submodule ℤ V} |
| 735 | |
| 736 | /-- The canonical multiplier x ↦ exp(πi E(bx, x)) attached to a complex-linear endomorphism b of |
| 737 | V, where E is the Riemann form of B. -/ |
| 738 | def ThetaTori.canonicalMultiplier (x : V) : ℂ := Complex.exp (Real.pi * I * B.riemannForm (b x) x) |
| 739 | |
| 740 | /-- Normalised translation: the twisted translation by x, divided by the canonical multiplier |
| 741 | exp(πi E(bx, x)). -/ |
| 742 | def ThetaTori.normalizedShift (x : V) : (V → ℂ) →ₗ[ℂ] V → ℂ := |
| 743 | (canonicalMultiplier B b x)⁻¹ • B.thetaShift x |
| 744 | |
| 745 | /-- For the sum of the pull-backs of forms B_i along linear maps A_i, the twisted translate by u of |
| 746 | the product of the f_i∘A_i is the product of the pulled-back translates of f_i by A_i u. -/ |
| 747 | lemma thetaShift_prod [Fintype ι] {B : ι → RealComplexForm V} {A : ι → V' →L[ℂ] V} {f : ι → V → ℂ} |
| 748 | (u : V') : |
| 749 | thetaShift (∑ i : ι, pullForm (A i) (B i)) u (∏ i : ι, f i ∘ A i) = |
| 750 | ∏ i : ι, thetaShift (B i) (A i u) (f i) ∘ A i := by |
| 751 | simp [funext_iff, thetaShift_apply, sum_div, exp_add, exp_neg, exp_sum, prod_mul_distrib] |
| 752 | |
| 753 | variable {B : LatticeForm L} {b} {x y : V} {f : V → ℂ} |
| 754 | |
| 755 | /-- The theta functions for L, B and the canonical multiplier of b are the entire functions |
| 756 | fixed by the normalised translations by the elements of L. -/ |
| 757 | lemma ThetaTori.mem_thetaSpace_iff_normalizedShift : |
| 758 | f ∈ B.thetaSpace (canonicalMultiplier B b) ↔ |
| 759 | Differentiable ℂ f ∧ ∀ l ∈ L, normalizedShift B b l f = f := by |
| 760 | refine Iff.and Iff.rfl ?_ |
| 761 | -- Both sides say `f (z + l) = exp (π i E(b l, l)) * exp (B l z + B l l / 2) * f z`. |
| 762 | simp [canonicalMultiplier, exp_add, normalizedShift, funext_iff, thetaShift_apply, exp_neg, |
| 763 | fieldEq] |
| 764 | exact forall₂_congr fun l _ ↦ forall_congr' fun z ↦ by rw [mul_right_comm (cexp _) (cexp (B l z))] |
| 765 | |
| 766 | /-- Let E be the Riemann form of `B`. If b + b* = 1 for E, that is E(bu, w) + E(u, bw) = E(u, w) |
| 767 | (hypothesis `adj`), the real part of `B` is symmetric and E(b L, L) is integral, then `B` and the |
| 768 | canonical multiplier are Appell–Humbert data for L. -/ |
| 769 | lemma ThetaTori.isAppellHumbert_canonicalMultiplier |
| 770 | (adj : ∀ u w : V, B.riemannForm (b u) w = B.riemannForm u w - B.riemannForm u (b w)) |
| 771 | (re_symm : ∀ u w : V, (B u w).re = (B w u).re) |
| 772 | (h_int : ∀ l ∈ L, ∀ m ∈ L, ∃ n : ℤ, B.riemannForm (b l) m = n) : |
| 773 | IsAppellHumbert B (canonicalMultiplier B b) := by |
| 774 | refine ⟨re_symm, fun l _ ↦ ?_, fun l hl m hm ↦ ?_⟩ |
| 775 | · -- The multiplier is the exponential of an imaginary number. |
| 776 | simp [norm_exp, canonicalMultiplier] |
| 777 | -- By `adj`, `E(b l, m) + E(b m, l) = E(m, l) + 2 E(b l, m)`, and `E(b l, m)` is an integer. |
| 778 | obtain ⟨n, hn⟩ : ∃ n : ℤ, B.riemannForm (b l) m = n := h_int l hl m hm |
| 779 | have h_riemannForm_add : |
| 780 | B.riemannForm (b (l + m)) (l + m) = |
| 781 | B.riemannForm (b l) l + B.riemannForm (b m) m + B.riemannForm m l + 2 * n := by |
| 782 | simp only [map_add, LinearMap.add_apply] |
| 783 | linear_combination adj m l - riemannForm_swap (B := B) (b l) m + 2 * hn |
| 784 | simp only [canonicalMultiplier, ← exp_add, h_riemannForm_add] |
| 785 | refine exp_eq_exp_iff_exists_int.mpr ⟨n, ?_⟩ |
| 786 | simp [fieldEq] |
| 787 | |
| 788 | /-- Heisenberg law: if (L, B, χ) are Appell–Humbert data and E(bu, w) + E(u, bw) = E(u, w), the |
| 789 | normalised translation by y followed by that by x is exp(2πi E(bx, y)) times that by x + y. -/ |
| 790 | lemma IsAppellHumbert.normalizedShift_normalizedShift |
| 791 | (adj : ∀ u w : V, B.riemannForm (b u) w = B.riemannForm u w - B.riemannForm u (b w)) |
| 792 | {χ : V → ℂ} (h : IsAppellHumbert B χ) : |
| 793 | normalizedShift B b x (normalizedShift B b y f) = |
| 794 | B.riemannPhase (b x) y • normalizedShift B b (x + y) f := by |
| 795 | -- The translations compose with the factor `exp (π i E(x, y))` (`thetaShift_thetaShift`); the |
| 796 | -- multipliers at `x`, `y` and `x + y` contribute `exp (π i (E(b x, y) + E(b y, x)))`, and by |
| 797 | -- `adj` `E(b y, x) = E(b x, y) - E(x, y)`. |
| 798 | have h_exponent : B.riemannForm (b y) x = B.riemannForm (b x) y - B.riemannForm x y := by |
| 799 | linear_combination adj y x - riemannForm_swap (B := B) (b x) y + riemannForm_swap (B := B) x y |
| 800 | -- The scalar in front of `thetaShift B (x + y) f` on each side. |
| 801 | have h_mult : |
| 802 | (canonicalMultiplier B b y)⁻¹ * |
| 803 | ((canonicalMultiplier B b x)⁻¹ * exp (Real.pi * I * B.riemannForm x y)) = |
| 804 | B.riemannPhase (b x) y * (canonicalMultiplier B b (x + y))⁻¹ := by |
| 805 | simp only [canonicalMultiplier, RealComplexForm.riemannPhase, coe_fourierChar_eq_exp, |
| 806 | ← exp_neg, ← exp_add, map_add, LinearMap.add_apply] |
| 807 | congr 1 |
| 808 | simp only [h_exponent] |
| 809 | push_cast |
| 810 | ring |
| 811 | simp only [normalizedShift, LinearMap.smul_apply, map_smul, h.thetaShift_thetaShift x y, |
| 812 | smul_smul, h_mult] |
| 813 | |
| 814 | end New |
| 815 | |
| 816 | end |