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 | /- |
| 2 | Derived from AINTLIB: |
| 3 | projects/ModularCurves/ModularCurves/ForMathlib/TotalComplexUpNatLowDegrees.lean |
| 4 | The upstream AINTLIB repository is licensed under Apache 2.0. |
| 5 | This file has been modified. |
| 6 | -/ |
| 7 | import OAI.AlgebraicGeometry.AbelianModuli.HilbertConstruction.FirstQuadrantTotalSigns |
| 8 | |
| 9 | /-! # First Quadrant Total Coordinates -/ |
| 10 | |
| 11 | namespace OAI.AlgebraicGeometry.AbelianModuli.HilbertConstruction.FirstQuadrantTotalCoordinates.TotalComplex |
| 12 | |
| 13 | /-! |
| 14 | # Low degrees of a first-quadrant total complex |
| 15 | |
| 16 | Expose component projections, the decompositions in total degrees zero and one, and the |
| 17 | signed differential formula for mathlib's total complex of an `ℕ × ℕ` cochain bicomplex. |
| 18 | -/ |
| 19 | |
| 20 | open _root_.CategoryTheory _root_.CategoryTheory.Limits _root_.CategoryTheory.Preadditive |
| 21 | |
| 22 | universe v u |
| 23 | |
| 24 | open _root_.HomologicalComplex₂ |
| 25 | |
| 26 | variable {C : Type u} [Category.{v} C] [Preadditive C] |
| 27 | variable (K : HomologicalComplex₂ C (.up ℕ) (.up ℕ)) |
| 28 | variable [K.HasTotal (.up ℕ)] |
| 29 | |
| 30 | /-- Projection from a total degree onto one bidegree. It is zero unless the bidegree |
| 31 | belongs to the specified total degree. -/ |
| 32 | noncomputable def πTotalUpNat (q p n : ℕ) : |
| 33 | (K.total (.up ℕ)).X n ⟶ (K.X q).X p := |
| 34 | K.totalDesc (c₁₂ := .up ℕ) fun q' p' _ ↦ |
| 35 | if hq : q' = q then |
| 36 | if hp : p' = p then (K.XXIsoOfEq _ _ _ hq hp).hom else 0 |
| 37 | else 0 |
| 38 | |
| 39 | @[reassoc (attr := simp)] |
| 40 | theorem ιTotal_πTotalUpNat (q' p' n : ℕ) (h : q' + p' = n) (q p : ℕ) : |
| 41 | K.ιTotal (.up ℕ) q' p' n h ≫ πTotalUpNat K q p n = |
| 42 | if hq : q' = q then |
| 43 | if hp : p' = p then (K.XXIsoOfEq _ _ _ hq hp).hom else 0 |
| 44 | else 0 := by |
| 45 | simp [πTotalUpNat] |
| 46 | |
| 47 | @[simp] |
| 48 | theorem ιTotal_πTotalUpNat_self (q p : ℕ) : |
| 49 | K.ιTotal (.up ℕ) q p (q + p) rfl ≫ πTotalUpNat K q p (q + p) = 𝟙 _ := by |
| 50 | simp [πTotalUpNat] |
| 51 | |
| 52 | /-- Total degree zero consists only of bidegree `(0,0)`. -/ |
| 53 | theorem totalUpNat_zero_decomposition : |
| 54 | πTotalUpNat K 0 0 0 ≫ K.ιTotal (.up ℕ) 0 0 0 rfl = 𝟙 _ := by |
| 55 | apply HomologicalComplex₂.total.hom_ext |
| 56 | intro q p h |
| 57 | change q + p = 0 at h |
| 58 | have hq : q = 0 := by omega |
| 59 | have hp : p = 0 := by omega |
| 60 | subst q p |
| 61 | simp |
| 62 | |
| 63 | /-- Total degree one is the sum of bidegrees `(0,1)` and `(1,0)`. -/ |
| 64 | theorem totalUpNat_one_decomposition : |
| 65 | πTotalUpNat K 0 1 1 ≫ K.ιTotal (.up ℕ) 0 1 1 rfl + |
| 66 | πTotalUpNat K 1 0 1 ≫ K.ιTotal (.up ℕ) 1 0 1 rfl = 𝟙 _ := by |
| 67 | apply HomologicalComplex₂.total.hom_ext |
| 68 | intro q p h |
| 69 | change q + p = 1 at h |
| 70 | rcases show (q = 0 ∧ p = 1) ∨ (q = 1 ∧ p = 0) by omega with h | h |
| 71 | · obtain ⟨rfl, rfl⟩ := h |
| 72 | simp |
| 73 | · obtain ⟨rfl, rfl⟩ := h |
| 74 | simp |
| 75 | |
| 76 | /-- The total differential on a bidegree is the resolution differential plus the |
| 77 | signed Cech differential. -/ |
| 78 | @[reassoc] |
| 79 | theorem ιTotal_d_upNat (q p : ℕ) : |
| 80 | K.ιTotal (.up ℕ) q p (q + p) rfl ≫ |
| 81 | (K.total (.up ℕ)).d (q + p) (q + p + 1) = |
| 82 | (K.d q (q + 1)).f p ≫ |
| 83 | K.ιTotal (.up ℕ) (q + 1) p (q + p + 1) |
| 84 | (by change q + 1 + p = q + p + 1; omega) + |
| 85 | ((-1 : ℤˣ) ^ q) • ((K.X q).d p (p + 1) ≫ |
| 86 | K.ιTotal (.up ℕ) q (p + 1) (q + p + 1) |
| 87 | (by change q + (p + 1) = q + p + 1; omega)) := by |
| 88 | change _ ≫ (K.D₁ (.up ℕ) (q + p) (q + p + 1) + |
| 89 | K.D₂ (.up ℕ) (q + p) (q + p + 1)) = _ |
| 90 | calc |
| 91 | _ = (K.ιTotal (.up ℕ) q p (q + p) rfl ≫ |
| 92 | K.D₁ (.up ℕ) (q + p) (q + p + 1)) + |
| 93 | (K.ιTotal (.up ℕ) q p (q + p) rfl ≫ |
| 94 | K.D₂ (.up ℕ) (q + p) (q + p + 1)) := |
| 95 | Preadditive.comp_add _ _ _ _ _ _ |
| 96 | _ = _ := by |
| 97 | congr 1 |
| 98 | · calc |
| 99 | _ = K.d₁ (.up ℕ) q p (q + p + 1) := |
| 100 | K.ι_D₁ (.up ℕ) (q + p) (q + p + 1) q p rfl |
| 101 | _ = _ := by |
| 102 | rw [K.d₁_eq (.up ℕ) |
| 103 | (show (ComplexShape.up ℕ).Rel q (q + 1) by rfl) p (q + p + 1) |
| 104 | (by change q + 1 + p = q + p + 1; omega)] |
| 105 | simp |
| 106 | · calc |
| 107 | _ = K.d₂ (.up ℕ) q p (q + p + 1) := |
| 108 | K.ι_D₂ (.up ℕ) (q + p) (q + p + 1) q p rfl |
| 109 | _ = _ := by |
| 110 | rw [K.d₂_eq (.up ℕ) q |
| 111 | (show (ComplexShape.up ℕ).Rel p (p + 1) by rfl) (q + p + 1) |
| 112 | (by change q + (p + 1) = q + p + 1; omega)] |
| 113 | simp |
| 114 | |
| 115 | end OAI.AlgebraicGeometry.AbelianModuli.HilbertConstruction.FirstQuadrantTotalCoordinates.TotalComplex |