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/SheafDerivedGlobalSections.lean |
| 4 | The upstream AINTLIB repository is licensed under Apache 2.0. |
| 5 | This file has been modified. |
| 6 | -/ |
| 7 | import OAI.AlgebraicGeometry.DivisorClass.Chern.Intrinsic.HomComplexSections |
| 8 | import Mathlib.Algebra.Homology.Embedding.ExtendHomology |
| 9 | |
| 10 | /-! # Resolution Extension Sections -/ |
| 11 | |
| 12 | namespace OAI.AlgebraicGeometry.DivisorClass.Chern.ResolutionExtensionSections |
| 13 | |
| 14 | noncomputable section |
| 15 | |
| 16 | /-! Actual additive global sections commute with extension of a nonnegative resolution by zero. -/ |
| 17 | |
| 18 | open _root_.CategoryTheory _root_.CategoryTheory.Limits |
| 19 | set_option backward.isDefEq.respectTransparency false |
| 20 | set_option backward.isDefEq.respectTransparency.types false |
| 21 | set_option backward.defeqAttrib.useBackward true |
| 22 | |
| 23 | universe u v |
| 24 | variable {C : Type u} [Category.{v} C] [Abelian C] |
| 25 | {G : C ⥤ AddCommGrpCat.{v}} [G.Additive] |
| 26 | |
| 27 | def resolutionMapXIso (K : CochainComplex C ℕ) (n : ℕ) : |
| 28 | G.obj (K.X n) ≅ ((G.mapHomologicalComplex (.up ℕ)).obj K).X n := |
| 29 | Iso.refl _ |
| 30 | |
| 31 | theorem resolutionMapXIso_naturality (K : CochainComplex C ℕ) (i j : ℕ) : |
| 32 | (resolutionMapXIso K i).hom ≫ ((G.mapHomologicalComplex (.up ℕ)).obj K).d i j = |
| 33 | G.map (K.d i j) ≫ (resolutionMapXIso K j).hom := |
| 34 | rfl |
| 35 | |
| 36 | def resolutionMapExtendXIso |
| 37 | (K : CochainComplex C ℕ) (n : ℤ) : |
| 38 | G.obj ((K.extend ComplexShape.embeddingUpNat).X n) ≅ |
| 39 | (((G.mapHomologicalComplex (.up ℕ)).obj K).extend |
| 40 | ComplexShape.embeddingUpNat).X n := by |
| 41 | classical |
| 42 | exact if h : 0 ≤ n then |
| 43 | G.mapIso (HomologicalComplex.extendXIso K ComplexShape.embeddingUpNat |
| 44 | (Int.toNat_of_nonneg h)) ≪≫ |
| 45 | resolutionMapXIso K n.toNat ≪≫ |
| 46 | (HomologicalComplex.extendXIso ((G.mapHomologicalComplex (.up ℕ)).obj K) |
| 47 | ComplexShape.embeddingUpNat (Int.toNat_of_nonneg h)).symm |
| 48 | else |
| 49 | IsZero.iso |
| 50 | (G.map_isZero (K.isZero_extend_X ComplexShape.embeddingUpNat n |
| 51 | (fun k hk ↦ h (hk ▸ Int.natCast_nonneg k)))) |
| 52 | (((G.mapHomologicalComplex (.up ℕ)).obj K).isZero_extend_X |
| 53 | ComplexShape.embeddingUpNat n (fun k hk ↦ h (hk ▸ Int.natCast_nonneg k))) |
| 54 | |
| 55 | theorem resolutionMapExtendXIso_natCast (K : CochainComplex C ℕ) (k : ℕ) : |
| 56 | resolutionMapExtendXIso (G := G) K (k : ℤ) = |
| 57 | G.mapIso (HomologicalComplex.extendXIso K ComplexShape.embeddingUpNat |
| 58 | (ComplexShape.embeddingUpNat_f k)) ≪≫ |
| 59 | resolutionMapXIso (G := G) K k ≪≫ |
| 60 | (HomologicalComplex.extendXIso ((G.mapHomologicalComplex (.up ℕ)).obj K) |
| 61 | ComplexShape.embeddingUpNat (ComplexShape.embeddingUpNat_f k)).symm := by |
| 62 | classical |
| 63 | simp [resolutionMapExtendXIso] |
| 64 | |
| 65 | def resolutionMapExtendIso (K : CochainComplex C ℕ) : |
| 66 | (G.mapHomologicalComplex (.up ℤ)).obj (K.extend ComplexShape.embeddingUpNat) ≅ |
| 67 | ((G.mapHomologicalComplex (.up ℕ)).obj K).extend ComplexShape.embeddingUpNat := |
| 68 | HomologicalComplex.Hom.isoOfComponents (resolutionMapExtendXIso K) fun i j hij ↦ by |
| 69 | clear hij |
| 70 | by_cases hi : ∃ k, ComplexShape.embeddingUpNat.f k = i |
| 71 | · obtain ⟨a, ha⟩ := hi |
| 72 | have ha' : (a : ℤ) = i := (ComplexShape.embeddingUpNat_f a).symm.trans ha |
| 73 | clear ha |
| 74 | subst i |
| 75 | by_cases hj : ∃ k, ComplexShape.embeddingUpNat.f k = j |
| 76 | · obtain ⟨b, hb⟩ := hj |
| 77 | have hb' : (b : ℤ) = j := (ComplexShape.embeddingUpNat_f b).symm.trans hb |
| 78 | clear hb |
| 79 | subst j |
| 80 | rw [resolutionMapExtendXIso_natCast (G := G) K a, resolutionMapExtendXIso_natCast (G := G) K b] |
| 81 | rw [Functor.mapHomologicalComplex_obj_d, |
| 82 | HomologicalComplex.extend_d_eq ((G.mapHomologicalComplex (.up ℕ)).obj K) |
| 83 | ComplexShape.embeddingUpNat (ComplexShape.embeddingUpNat_f a) |
| 84 | (ComplexShape.embeddingUpNat_f b), |
| 85 | HomologicalComplex.extend_d_eq K ComplexShape.embeddingUpNat |
| 86 | (ComplexShape.embeddingUpNat_f a) (ComplexShape.embeddingUpNat_f b)] |
| 87 | let eᵢ := HomologicalComplex.extendXIso K ComplexShape.embeddingUpNat |
| 88 | (ComplexShape.embeddingUpNat_f a) |
| 89 | let eⱼ := HomologicalComplex.extendXIso K ComplexShape.embeddingUpNat |
| 90 | (ComplexShape.embeddingUpNat_f b) |
| 91 | let fᵢ := HomologicalComplex.extendXIso ((G.mapHomologicalComplex (.up ℕ)).obj K) |
| 92 | ComplexShape.embeddingUpNat (ComplexShape.embeddingUpNat_f a) |
| 93 | let fⱼ := HomologicalComplex.extendXIso ((G.mapHomologicalComplex (.up ℕ)).obj K) |
| 94 | ComplexShape.embeddingUpNat (ComplexShape.embeddingUpNat_f b) |
| 95 | let mᵢ := resolutionMapXIso (G := G) K a |
| 96 | let mⱼ := resolutionMapXIso (G := G) K b |
| 97 | change (G.map eᵢ.hom ≫ mᵢ.hom ≫ fᵢ.inv) ≫ |
| 98 | (fᵢ.hom ≫ ((G.mapHomologicalComplex (.up ℕ)).obj K).d |
| 99 | a b ≫ fⱼ.inv) = |
| 100 | G.map (eᵢ.hom ≫ K.d a b ≫ eⱼ.inv) ≫ |
| 101 | (G.map eⱼ.hom ≫ mⱼ.hom ≫ fⱼ.inv) |
| 102 | calc |
| 103 | _ = G.map eᵢ.hom ≫ |
| 104 | (mᵢ.hom ≫ ((G.mapHomologicalComplex (.up ℕ)).obj K).d |
| 105 | a b) ≫ fⱼ.inv := by |
| 106 | simp only [Category.assoc, Iso.inv_hom_id_assoc] |
| 107 | _ = G.map eᵢ.hom ≫ |
| 108 | (G.map (K.d a b) ≫ mⱼ.hom) ≫ fⱼ.inv := by |
| 109 | rw [show mᵢ.hom ≫ ((G.mapHomologicalComplex (.up ℕ)).obj K).d |
| 110 | a b = G.map (K.d a b) ≫ mⱼ.hom by |
| 111 | exact resolutionMapXIso_naturality K a b] |
| 112 | _ = _ := by simp [Functor.map_comp, Category.assoc] |
| 113 | · exact (((G.mapHomologicalComplex (.up ℕ)).obj K).isZero_extend_X |
| 114 | ComplexShape.embeddingUpNat j (fun k hk ↦ hj ⟨k, hk⟩) |>.eq_of_tgt _ _) |
| 115 | · exact (G.map_isZero (K.isZero_extend_X ComplexShape.embeddingUpNat i |
| 116 | (fun k hk ↦ hi ⟨k, hk⟩)) |>.eq_of_src _ _) |
| 117 | |
| 118 | end |
| 119 | |
| 120 | end OAI.AlgebraicGeometry.DivisorClass.Chern.ResolutionExtensionSections |