Hodge conjecture: the CM case in Lean, read and discussed
OpenAI's Lean proof of the Hodge conjecture for CM abelian varieties: rerun it, read its statement, and keep the open questions with their sources. The conjecture is open

| 1 | import Mathlib.NumberTheory.NumberField.Basic |
| 2 | import Mathlib.LinearAlgebra.Matrix.ToLin |
| 3 | import Mathlib.Tactic.Ring |
| 4 | import Mathlib.Tactic.Abel |
| 5 | |
| 6 | /-! # Matrix To Lattice Congruence -/ |
| 7 | |
| 8 | namespace OAI.AlgebraicGeometry.AbelianModuli.ReferenceFamily.MatrixToLatticeCongruence |
| 9 | |
| 10 | noncomputable section |
| 11 | |
| 12 | /-! Transfer literal integral matrix congruences to the specified |
| 13 | integral lattice using its fixed coordinate and basis denominators. |
| 14 | The lattice is only required to have its actual integral scalar action. |
| 15 | -/ |
| 16 | |
| 17 | variable {E I : Type*} [Field E] [NumberField E] [Fintype I] [DecidableEq I] |
| 18 | |
| 19 | omit [NumberField E] in |
| 20 | theorem integral_vector_multiple_mem_lattice |
| 21 | (Λ : Submodule ℤ (I → E)) |
| 22 | (hO : ∀ a : NumberField.RingOfIntegers E, ∀ x ∈ Λ, (a : E) • x ∈ Λ) |
| 23 | (d : ℤ) (hbasis : ∀ j : I, d • (Pi.single j (1 : E)) ∈ Λ) |
| 24 | (z : I → E) (hz : ∀ i, IsIntegral ℤ (z i)) : d • z ∈ Λ := by |
| 25 | have he : d • z = ∑ j, z j • (d • (Pi.single j (1 : E))) := by |
| 26 | ext i |
| 27 | simp [Pi.single_apply, zsmul_eq_mul, mul_comm] |
| 28 | rw [he] |
| 29 | apply Λ.sum_mem |
| 30 | intro j _ |
| 31 | exact hO ⟨z j, hz j⟩ (d • Pi.single j 1) (hbasis j) |
| 32 | |
| 33 | omit [NumberField E] in |
| 34 | theorem integral_matrix_congruence_on_lattice |
| 35 | (Λ : Submodule ℤ (I → E)) |
| 36 | (hO : ∀ a : NumberField.RingOfIntegers E, ∀ x ∈ Λ, (a : E) • x ∈ Λ) |
| 37 | (d c : ℤ) (hbasis : ∀ j : I, d • (Pi.single j (1 : E)) ∈ Λ) |
| 38 | (hcoords : ∀ x ∈ Λ, ∀ i, IsIntegral ℤ (c • x i)) |
| 39 | (D ℓ N : ℕ) (k : ℤ) (hlevel : (ℓ : ℤ) = (N : ℤ) * d * c * k) |
| 40 | (f : (I → E) →ₗ[E] (I → E)) |
| 41 | (A : Matrix I I (NumberField.RingOfIntegers E)) |
| 42 | (hA : ∀ i j, (D : E) * (LinearMap.toMatrix' f i j - (1 : Matrix I I E) i j) = |
| 43 | (ℓ : E) * (A i j : E)) : |
| 44 | ∀ x ∈ Λ, ∃ y ∈ Λ, (D : E) • (f x - x) = (N : E) • y := by |
| 45 | intro x hx |
| 46 | let A₀ := A.map (algebraMap (NumberField.RingOfIntegers E) E) |
| 47 | let C := A₀.mulVec (c • x) |
| 48 | have hC : ∀ i, IsIntegral ℤ (C i) := by |
| 49 | intro i |
| 50 | change (∑ j, (A i j : E) * (c • x j)) ∈ integralClosure ℤ E |
| 51 | apply (integralClosure ℤ E).sum_mem |
| 52 | intro j _ |
| 53 | exact (integralClosure ℤ E).mul_mem (A i j).property (hcoords x hx j) |
| 54 | have hy : d • (k • C) ∈ Λ := |
| 55 | integral_vector_multiple_mem_lattice Λ hO d hbasis (k • C) |
| 56 | (fun i => (hC i).smul k) |
| 57 | have hmat : (D : E) • (LinearMap.toMatrix' f - 1) = (ℓ : E) • A₀ := by |
| 58 | ext i j |
| 59 | exact hA i j |
| 60 | have he := congrArg (fun M : Matrix I I E => M.mulVec x) hmat |
| 61 | simp only [Matrix.smul_mulVec, Matrix.sub_mulVec, LinearMap.toMatrix'_mulVec, |
| 62 | Matrix.one_mulVec] at he |
| 63 | have hlevelE : (ℓ : E) = (N : E) * (d : E) * (c : E) * (k : E) := by |
| 64 | simpa only [Int.cast_natCast, Int.cast_mul] using congrArg (fun n : ℤ => (n : E)) hlevel |
| 65 | have hright : (N : E) • (d • (k • C)) = (ℓ : E) • A₀.mulVec x := by |
| 66 | dsimp only [C] |
| 67 | rw [← Int.cast_smul_eq_zsmul E d, ← Int.cast_smul_eq_zsmul E k, |
| 68 | ← Int.cast_smul_eq_zsmul E c, Matrix.mulVec_smul] |
| 69 | simp only [smul_smul] |
| 70 | rw [hlevelE] |
| 71 | congr 1 |
| 72 | ring |
| 73 | exact ⟨d • (k • C), hy, he.trans hright.symm⟩ |
| 74 | |
| 75 | theorem integer_multiple_congruent_one_on_lattice |
| 76 | {V : Type*} [AddCommGroup V] [Module ℤ V] |
| 77 | (Λ : Submodule ℤ V) (D N : ℕ) (hD : (N : ℤ) ∣ (D : ℤ) - 1) |
| 78 | (f : V → V) |
| 79 | (hf : ∀ x ∈ Λ, ∃ y ∈ Λ, D • (f x - x) = N • y) : |
| 80 | ∀ x ∈ Λ, ∃ y ∈ Λ, D • f x - x = N • y := by |
| 81 | obtain ⟨k, hk⟩ := hD |
| 82 | intro x hx |
| 83 | obtain ⟨y, hy, he⟩ := hf x hx |
| 84 | have hscalar : D • x - x = N • (k • x) := by |
| 85 | calc |
| 86 | D • x - x = ((D : ℤ) - 1) • x := by |
| 87 | rw [sub_zsmul, one_zsmul, natCast_zsmul, sub_eq_add_neg] |
| 88 | _ = ((N : ℤ) * k) • x := congrArg (fun a : ℤ => a • x) hk |
| 89 | _ = N • (k • x) := by rw [mul_zsmul, natCast_zsmul] |
| 90 | refine ⟨y + k • x, Λ.add_mem hy (Λ.toAddSubgroup.zsmul_mem hx k), ?_⟩ |
| 91 | calc |
| 92 | D • f x - x = D • (f x - x) + (D • x - x) := by rw [nsmul_sub]; abel |
| 93 | _ = N • y + N • (k • x) := by rw [he, hscalar] |
| 94 | _ = N • (y + k • x) := by rw [nsmul_add] |
| 95 | |
| 96 | theorem integer_multiple_mem_lattice_of_congruence |
| 97 | {V : Type*} [AddCommGroup V] [Module ℤ V] |
| 98 | (Λ : Submodule ℤ V) (D N : ℕ) (f : V → V) |
| 99 | (hf : ∀ x ∈ Λ, ∃ y ∈ Λ, D • f x - x = N • y) : |
| 100 | ∀ x ∈ Λ, D • f x ∈ Λ := by |
| 101 | intro x hx |
| 102 | obtain ⟨y, hy, he⟩ := hf x hx |
| 103 | have hNy : N • y ∈ Λ := Λ.toAddSubgroup.nsmul_mem hy N |
| 104 | have hm := Λ.add_mem hNy hx |
| 105 | rwa [← he, sub_add_cancel] at hm |
| 106 | |
| 107 | end |
| 108 | |
| 109 | end OAI.AlgebraicGeometry.AbelianModuli.ReferenceFamily.MatrixToLatticeCongruence |