Zeta and L-valuesBlueprintDependency graphThesis
Contents

v436-CharacterTables.lean

Statement index · Original Lean file

1import Mathlib.NumberTheory.DirichletCharacter.Orthogonality2import Mathlib.Analysis.Complex.Polynomial.Basic3import Mathlib.RingTheory.RootsOfUnity.AlgebraicallyClosed4import Mathlib.Tactic.FinCases5import Mathlib.Tactic.NormNum67/-!8# The finite examples in §2.1910The entries are encoded in the multiplicative monoid of ℤ/5ℤ. Its generator 211is sent to the complex fourth root i; zero is sent to zero. This lets the kernel12check each multiplication in the two printed tables by finite enumeration.13The cardinality of the complex character group then proves that each table is exhaustive.14-/1516namespace Thesis.CharacterTables1718open Complex19noncomputable section2021/-- Decode the five entries zero, one, i, −i, and −1. This map is multiplicative. -/22def value (a : ZMod 5) : ℂ :=23 match a with24 | 0 => 025 | 1 => 126 | 2 => I27 | 3 => -I28 | 4 => -12930private theorem value_mul (a b : ZMod 5) : value (a * b) = value a * value b := by31 fin_cases a <;> fin_cases b <;> norm_num [value, I_mul_I] <;> rfl3233private theorem value_injective : Function.Injective value := by34 intro a b h35 fin_cases a <;> fin_cases b <;> first | rfl | norm_num [value, Complex.ext_iff] at h3637/-- Example 2.2. The four rows are indexed in the order printed; columns are38the residues 0 through 4, including the zero column for the extension to nonunits. -/39def five : Fin 4 → ZMod 5 → ZMod 5 :=40 ![![0,1,1,1,1], ![0,1,2,3,4], ![0,1,3,2,4], ![0,1,4,4,1]]4142/-- Example 2.3. The row labels in the thesis are 1,2,4,7,8,11,13,14 in this order.43The columns include every residue modulo 15; characters vanish on the nonunits. -/44def fifteen : Fin 8 → ZMod 15 → ZMod 5 :=45 ![![0,1,1,0,1,0,0,1,1,0,0,1,0,1,1],46 ![0,1,3,0,4,0,0,2,2,0,0,4,0,3,1],47 ![0,1,4,0,1,0,0,4,4,0,0,1,0,4,1],48 ![0,1,2,0,4,0,0,2,3,0,0,1,0,3,4],49 ![0,1,2,0,4,0,0,3,3,0,0,4,0,2,1],50 ![0,1,4,0,1,0,0,1,4,0,0,4,0,1,4],51 ![0,1,3,0,4,0,0,3,2,0,0,1,0,2,4],52 ![0,1,1,0,1,0,0,4,1,0,0,4,0,4,4]]5354private def ofRow {n : ℕ} (t : ZMod n → ZMod 5)55 (h1 : t 1 = 1) (hm : ∀ a b, t (a * b) = t a * t b)56 (hz : ∀ a, ¬IsUnit a → t a = 0) : DirichletCharacter ℂ n where57 toFun a := value (t a)58 map_one' := by rw [h1]; rfl59 map_mul' a b := by rw [hm, value_mul]60 map_nonunit' a h := by rw [hz a h]; rfl6162set_option maxRecDepth 8192 in63/-- Each printed row modulo five, as a complex Dirichlet character. -/64def charFive (r : Fin 4) : DirichletCharacter ℂ 5 :=65 ofRow (five r) ((by decide : ∀ j, five j 1 = 1) r)66 ((by decide : ∀ j a b, five j (a*b) = five j a * five j b) r)67 ((by decide : ∀ j a, ¬IsUnit a → five j a = 0) r)6869set_option maxRecDepth 8192 in70set_option maxHeartbeats 1000000 in71/-- Each printed row modulo fifteen, as a complex Dirichlet character. -/72def charFifteen (r : Fin 8) : DirichletCharacter ℂ 15 :=73 ofRow (fifteen r) ((by decide : ∀ j, fifteen j 1 = 1) r)74 ((by decide : ∀ j a b, fifteen j (a*b) = fifteen j a * fifteen j b) r)75 ((by decide : ∀ j a, ¬IsUnit a → fifteen j a = 0) r)7677@[simp] theorem charFive_apply (r : Fin 4) (a : ZMod 5) :78 charFive r a = value (five r a) := rfl7980@[simp] theorem charFifteen_apply (r : Fin 8) (a : ZMod 15) :81 charFifteen r a = value (fifteen r a) := rfl8283private theorem exhaustive {m n : ℕ} [NeZero n] (χ : Fin m → DirichletCharacter ℂ n)84 (hχ : Function.Injective χ) (hcount : n.totient = m) : Function.Bijective χ := by85 apply hχ.bijective_of_nat_card_le86 rw [DirichletCharacter.card_eq_totient_of_hasEnoughRootsOfUnity, Nat.card_fin, hcount]8788/-- Example 2.2, including exhaustiveness and distinctness. -/89theorem charFive_bijective : Function.Bijective charFive := by90 apply exhaustive _ _ (by decide : Nat.totient 5 = 4)91 intro r s h92 apply (by decide : ∀ i j, (∀ a, five i a = five j a) → i = j) r s93 intro a94 exact value_injective (congrArg (fun χ : DirichletCharacter ℂ 5 => χ a) h)9596/-- Example 2.3, including exhaustiveness and distinctness. -/97theorem charFifteen_bijective : Function.Bijective charFifteen := by98 apply exhaustive _ _ (by decide : Nat.totient 15 = 8)99 intro r s h100 apply (by decide : ∀ i j, (∀ a, fifteen i a = fifteen j a) → i = j) r s101 intro a102 exact value_injective (congrArg (fun χ : DirichletCharacter ℂ 15 => χ a) h)103104end105106end Thesis.CharacterTables