Skip to content

Lean formalization of the Riemann Hypothesis (Alpöge, 2026-11-20) being cleaned up by members of the Lean community.

Python

doc(Lib/Weil/Construction): add docstrings in ThetaDictionary

sangxsh2f0c2ad0b59d
diff --git a/src/Lib/Weil/Construction/ThetaDictionary.lean b/src/Lib/Weil/Construction/ThetaDictionary.lean
index a4971216aa6..ab569626296 100644
--- a/src/Lib/Weil/Construction/ThetaDictionary.lean
+++ b/src/Lib/Weil/Construction/ThetaDictionary.lean
@@ -66,6 +66,7 @@ variable {X}
lemma fockForm_apply (u z : X → ℂ) : fockForm X u z = star u ⬝ᵥ z := rfl
+/-- The real part of the standard Hermitian form is symmetric in its two arguments. -/
lemma re_fockForm_comm (u z : X → ℂ) : (fockForm X u z).re = (fockForm X z u).re := by
simp [fockForm_apply, dotProduct, mul_comm]
@@ -97,11 +98,14 @@ lemma realImage_apply (γ : n → E) (x : InfinitePlace E × n) :
noncomputable def realImageHom : (n → E) →+ InfinitePlace E × n → ℂ :=
.mk' realImage fun γ γ' ↦ funext fun x ↦ by simp [realImage_apply, add_div]
+/-- The real image of a sum of rational vectors is the sum of their real images. -/
lemma realImage_add (γ γ' : n → E) : realImage (γ + γ') = realImage γ + realImage γ' :=
realImageHom.map_add γ γ'
+/-- The real image of the negative of a rational vector is the negative of its real image. -/
lemma realImage_neg (γ : n → E) : realImage (-γ) = -realImage γ := realImageHom.map_neg γ
+/-- The real image of the zero vector is `0`. -/
lemma realImage_zero : realImage (0 : n → E) = 0 := realImageHom.map_zero
/-- A rational vector is determined by its real image. -/
@@ -115,6 +119,7 @@ variable (E n) in
noncomputable def idealLattice : AddSubgroup (n → E) :=
(stdLattice E n).comap finiteImage.toAddMonoidHom
+/-- A vector `γ` lies in `𝔞₀ⁿ` exactly when its finite image lies in `stdLattice E n`. -/
lemma mem_idealLattice {γ : n → E} : γ ∈ idealLattice E n ↔ finiteImage γ ∈ stdLattice E n :=
Iff.rfl
@@ -125,6 +130,7 @@ lemma smul_mem_idealLattice {δ : E} (hδ : ↑δ ∈ Ô E) {γ : n → E} (hγ
rw [mem_idealLattice, map_smul, ← algebraMap_smul (𝔸f E)]
exact smul_mem_stdLattice hδ hγ
+/-- For `δ ≠ 0`, a vector `y` lies in `δ⁻¹ 𝔞₀ⁿ` exactly when `δ • y` lies in `𝔞₀ⁿ`. -/
lemma mem_inv_smul_idealLattice {δ : E} (hδ : δ ≠ 0) {y : n → E} :
y ∈ δ⁻¹ • idealLattice E n ↔ δ • y ∈ idealLattice E n := by
rw [AddSubgroup.mem_pointwise_smul_iff_inv_smul_mem₀ (inv_ne_zero hδ), inv_inv]
@@ -145,6 +151,7 @@ noncomputable def ratPhase (γ γ' : n → E) : ℂ := exp (2 * Real.pi * I * ra
variable {F : (InfinitePlace E × n → ℂ) → ℂ}
+/-- The translation `T_0` by the zero vector is the identity. -/
lemma ratShift_zero : ratShift (0 : n → E) F = F := by
rw [ratShift, realImage_zero, thetaShift_zero]
@@ -159,6 +166,7 @@ lemma ratShift_ratShift (γ γ' : n → E) :
rw [ratShift, ratShift, ratShift, realImage_add]
exact isAppellHumbert_fockForm.thetaShift_thetaShift _ _
+/-- The Riemann form `{γ, γ'}` of rational vectors is antisymmetric. -/
lemma ratRiemannForm_swap (γ γ' : n → E) : ratRiemannForm γ' γ = -ratRiemannForm γ γ' :=
riemannForm_swap _ _
@@ -334,6 +342,7 @@ noncomputable def realLattice : Submodule ℤ (InfinitePlace E × n → ℂ) :=
((idealLattice E n).map realImageHom).toIntSubmodule
omit [Fintype n] [DecidableEq n] in
+/-- A point lies in `realLattice E n` exactly when it is the real image of a vector of `𝔞₀ⁿ`. -/
lemma mem_realLattice {x : InfinitePlace E × n → ℂ} :
x ∈ realLattice E n ↔ ∃ γ ∈ idealLattice E n, realImage γ = x := Iff.rfl