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 | Copyright 2026 The Formal Conjectures Authors. |
| 3 | Released under Apache 2.0 license as described in the file LICENSE. |
| 4 | This file has been modified. |
| 5 | -/ |
| 6 | import OAI.AlgebraicTopology.Support.DerivedSections |
| 7 | import Mathlib.Algebra.Homology.DerivedCategory.RightDerivedFunctorPlus |
| 8 | import Mathlib.CategoryTheory.Abelian.GrothendieckCategory.EnoughInjectives |
| 9 | import Mathlib.Topology.Sheaves.Abelian |
| 10 | import Mathlib.Topology.Sheaves.Functors |
| 11 | import Mathlib.Topology.Sets.Closeds |
| 12 | |
| 13 | /-! # Derived Sections On -/ |
| 14 | |
| 15 | namespace OAI.AlgebraicTopology.Support.DerivedSectionsOn.TopCat.Sheaf |
| 16 | |
| 17 | noncomputable section |
| 18 | |
| 19 | open _root_.TopCat |
| 20 | open _root_.TopCat.Sheaf |
| 21 | |
| 22 | /-! |
| 23 | # Concrete sheaf sections with support and their right derived functor |
| 24 | |
| 25 | -/ |
| 26 | |
| 27 | /-! ### Constructions used only in proofs -/ |
| 28 | |
| 29 | section |
| 30 | open _root_.CategoryTheory _root_.CategoryTheory.Limits _root_.TopologicalSpace Opposite |
| 31 | universe u |
| 32 | variable (X : TopCat.{u}) |
| 33 | |
| 34 | @[reassoc (attr := simp)] |
| 35 | lemma sheafSectionsSupportedOutsideInclusion_restriction (U : Opens X) |
| 36 | (F : Sheaf AddCommGrpCat.{u} X) : |
| 37 | (DerivedSections.TopCat.Sheaf.sheafSectionsSupportedOutsideInclusion X U).app F ≫ |
| 38 | (DerivedSections.TopCat.Sheaf.toOpenRestrictionPushforward X U).app F = 0 := |
| 39 | kernel.condition _ |
| 40 | |
| 41 | end |
| 42 | |
| 43 | open _root_.CategoryTheory _root_.CategoryTheory.Limits _root_.TopologicalSpace Opposite |
| 44 | |
| 45 | universe u |
| 46 | |
| 47 | variable (X : TopCat.{u}) |
| 48 | |
| 49 | /-- Let `U` be open in a topological space `X` and `f: F → G` a morphism of sheaves of abelian |
| 50 | groups whose restriction to `U` is zero. This is the unique factorization of `f` through the |
| 51 | subsheaf of `G` consisting of sections supported in `X \ U`. -/ |
| 52 | def liftSheafSectionsSupportedOutside (U : Opens X) |
| 53 | {F G : Sheaf AddCommGrpCat.{u} X} (f : F ⟶ G) |
| 54 | (hf : f ≫ (DerivedSections.TopCat.Sheaf.toOpenRestrictionPushforward X U).app G = 0) : |
| 55 | F ⟶ (DerivedSections.TopCat.Sheaf.sheafSectionsSupportedOutside X U).obj G := |
| 56 | kernel.lift _ f hf |
| 57 | |
| 58 | @[reassoc (attr := simp)] |
| 59 | lemma liftSheafSectionsSupportedOutside_inclusion (U : Opens X) |
| 60 | {F G : Sheaf AddCommGrpCat.{u} X} (f : F ⟶ G) |
| 61 | (hf : f ≫ (DerivedSections.TopCat.Sheaf.toOpenRestrictionPushforward X U).app G = 0) : |
| 62 | liftSheafSectionsSupportedOutside X U f hf ≫ |
| 63 | (DerivedSections.TopCat.Sheaf.sheafSectionsSupportedOutsideInclusion X U).app G = f := |
| 64 | kernel.lift_ι _ _ _ |
| 65 | |
| 66 | /-- Let `X` be a topological space, `U,V ⊆ X` open, and `F` a sheaf of abelian groups. This |
| 67 | identifies sections on `V` of the subsheaf supported in `X \ U` with `ker(F(V) → F(V ∩ U))`, |
| 68 | where the map is restriction. -/ |
| 69 | def sheafSectionsSupportedOutsideOnOpenIso (U V : Opens X) |
| 70 | (F : Sheaf AddCommGrpCat.{u} X) : |
| 71 | ((DerivedSections.TopCat.Sheaf.sheafSectionsSupportedOutside X U).obj F).presheaf.obj (op V) ≅ |
| 72 | kernel (((DerivedSections.TopCat.Sheaf.toOpenRestrictionPushforward X U).app F).hom.app (op V)) := |
| 73 | let ev : Sheaf AddCommGrpCat.{u} X ⥤ AddCommGrpCat.{u} := |
| 74 | sheafToPresheaf (Opens.grothendieckTopology X) AddCommGrpCat ⋙ |
| 75 | (evaluation _ AddCommGrpCat).obj (op V) |
| 76 | letI : ev.PreservesZeroMorphisms := ⟨fun _ _ => rfl⟩ |
| 77 | letI : PreservesLimitsOfShape WalkingParallelPair ev := |
| 78 | comp_preservesLimitsOfShape |
| 79 | (sheafToPresheaf (Opens.grothendieckTopology X) AddCommGrpCat.{u}) |
| 80 | ((evaluation (Opens X)ᵒᵖ AddCommGrpCat.{u}).obj (op V)) |
| 81 | PreservesKernel.iso ev ((DerivedSections.TopCat.Sheaf.toOpenRestrictionPushforward X U).app F) |
| 82 | |
| 83 | /-- The kernel comparison preserves the inclusion of supported sections |
| 84 | into all sections. -/ |
| 85 | @[reassoc (attr := simp)] |
| 86 | lemma sheafSectionsSupportedOutsideOnOpenIso_hom_ι (U V : Opens X) |
| 87 | (F : Sheaf AddCommGrpCat.{u} X) : |
| 88 | (sheafSectionsSupportedOutsideOnOpenIso X U V F).hom ≫ |
| 89 | kernel.ι (((DerivedSections.TopCat.Sheaf.toOpenRestrictionPushforward X U).app F).hom.app (op V)) = |
| 90 | ((DerivedSections.TopCat.Sheaf.sheafSectionsSupportedOutsideInclusion X U).app F).hom.app (op V) := by |
| 91 | let ev : Sheaf AddCommGrpCat.{u} X ⥤ AddCommGrpCat.{u} := |
| 92 | sheafToPresheaf (Opens.grothendieckTopology X) AddCommGrpCat ⋙ |
| 93 | (evaluation _ AddCommGrpCat).obj (op V) |
| 94 | let _ : ev.PreservesZeroMorphisms := ⟨fun _ _ => rfl⟩ |
| 95 | let _ : PreservesLimitsOfShape WalkingParallelPair ev := |
| 96 | comp_preservesLimitsOfShape |
| 97 | (sheafToPresheaf (Opens.grothendieckTopology X) AddCommGrpCat.{u}) |
| 98 | ((evaluation (Opens X)ᵒᵖ AddCommGrpCat.{u}).obj (op V)) |
| 99 | change (PreservesKernel.iso ev ((DerivedSections.TopCat.Sheaf.toOpenRestrictionPushforward X U).app F)).hom ≫ |
| 100 | _ = _ |
| 101 | exact kernelComparison_comp_ι ((DerivedSections.TopCat.Sheaf.toOpenRestrictionPushforward X U).app F) ev |
| 102 | |
| 103 | /-- Let `X` be a topological space and `Z ⊆ X` closed. This functor sends a sheaf of abelian groups |
| 104 | `F` to the subsheaf `Γ_Z(F)` whose sections on `V` are those elements of `F(V)` that vanish on |
| 105 | `V \ Z`. It is the kernel of restriction to the direct image from `X \ Z`. -/ |
| 106 | def sheafSectionsWithClosedSupport (Z : Closeds X) : |
| 107 | Sheaf AddCommGrpCat.{u} X ⥤ Sheaf AddCommGrpCat.{u} X := |
| 108 | DerivedSections.TopCat.Sheaf.sheafSectionsSupportedOutside X Z.compl |
| 109 | |
| 110 | instance (Z : Closeds X) : (sheafSectionsWithClosedSupport X Z).Additive := |
| 111 | inferInstanceAs (DerivedSections.TopCat.Sheaf.sheafSectionsSupportedOutside X Z.compl).Additive |
| 112 | |
| 113 | /-- Let `X` be a topological space and `Z ⊆ X` closed. This functor sends a sheaf of abelian groups |
| 114 | `F` to `Γ_Z(X,F) = ker(F(X) → F(X \ Z))`, the group of global sections whose support is |
| 115 | contained in `Z`. -/ |
| 116 | def closedSupportSections (Z : Closeds X) : |
| 117 | Sheaf AddCommGrpCat.{u} X ⥤ AddCommGrpCat.{u} := |
| 118 | sheafSectionsWithClosedSupport X Z ⋙ |
| 119 | sheafToPresheaf (Opens.grothendieckTopology X) AddCommGrpCat ⋙ |
| 120 | (evaluation _ AddCommGrpCat).obj (op ⊤) |
| 121 | |
| 122 | instance (Z : Closeds X) : (closedSupportSections X Z).Additive where |
| 123 | map_add {F G} f g := |
| 124 | congrArg (fun h : (sheafSectionsWithClosedSupport X Z).obj F ⟶ |
| 125 | (sheafSectionsWithClosedSupport X Z).obj G => h.hom.app (op ⊤)) |
| 126 | ((sheafSectionsWithClosedSupport X Z).map_add (f := f) (g := g)) |
| 127 | |
| 128 | attribute [local instance] DerivedSections.TopCat.Sheaf.supportSheafHasDerivedCategory |
| 129 | |
| 130 | attribute [local instance] DerivedSections.TopCat.Sheaf.supportGroupsHasDerivedCategory |
| 131 | |
| 132 | /-- Let `X` be a topological space and `Z ⊆ X` closed. This right derived functor on bounded-below |
| 133 | complexes of sheaves of abelian groups replaces a complex by an injective resolution and then |
| 134 | takes, in every degree, the subsheaf of sections vanishing off `Z`. Its values are complexes of |
| 135 | sheaves on `X` in the bounded-below derived category. -/ |
| 136 | def derivedSheafSectionsWithClosedSupport (Z : Closeds X) : |
| 137 | DerivedCategory.Plus (Sheaf AddCommGrpCat.{u} X) ⥤ |
| 138 | DerivedCategory.Plus (Sheaf AddCommGrpCat.{u} X) := |
| 139 | (sheafSectionsWithClosedSupport X Z).rightDerivedFunctorPlus |
| 140 | |
| 141 | /-- Let `X` be a topological space and `Z ⊆ X` closed. For a bounded-below complex `K` of sheaves of |
| 142 | abelian groups, the resolution map `K → I` induces a map from the termwise subsheaves of |
| 143 | sections supported in `Z` to the corresponding subsheaves of `I`. This is the resulting natural |
| 144 | comparison with the right derived sheaf functor. -/ |
| 145 | def derivedSheafSectionsWithClosedSupportUnit (Z : Closeds X) : |
| 146 | (sheafSectionsWithClosedSupport X Z).mapHomotopyCategoryPlus ⋙ |
| 147 | DerivedCategory.Plus.Qh ⟶ |
| 148 | DerivedCategory.Plus.Qh ⋙ derivedSheafSectionsWithClosedSupport X Z := |
| 149 | (sheafSectionsWithClosedSupport X Z).rightDerivedFunctorPlusUnith |
| 150 | |
| 151 | /-- The construction satisfies Mathlib's universal property of a right derived functor. -/ |
| 152 | instance derivedSheafSectionsWithClosedSupport_isRightDerivedFunctor (Z : Closeds X) : |
| 153 | (derivedSheafSectionsWithClosedSupport X Z).IsRightDerivedFunctor |
| 154 | (derivedSheafSectionsWithClosedSupportUnit X Z) |
| 155 | (HomotopyCategory.Plus.quasiIso (Sheaf AddCommGrpCat.{u} X)) := by |
| 156 | dsimp only [derivedSheafSectionsWithClosedSupport, |
| 157 | derivedSheafSectionsWithClosedSupportUnit] |
| 158 | infer_instance |
| 159 | |
| 160 | /-- Let `X` be a topological space and `Z ⊆ X` closed. The functor `RΓ_Z(X,-)` from bounded-below |
| 161 | sheaf complexes to the bounded-below derived category of abelian groups is computed by an |
| 162 | injective resolution `I`: in degree `q`, take global sections of `I^q` vanishing on `X \ Z`. Its |
| 163 | degree-`n` cohomology is cohomology with support in `Z`. -/ |
| 164 | def derivedClosedSupportSections (Z : Closeds X) : |
| 165 | DerivedCategory.Plus (Sheaf AddCommGrpCat.{u} X) ⥤ |
| 166 | DerivedCategory.Plus AddCommGrpCat.{u} := |
| 167 | (closedSupportSections X Z).rightDerivedFunctorPlus |
| 168 | |
| 169 | /-- Let `X` be a topological space and `Z ⊆ X` closed. For a bounded-below complex `K` of sheaves of |
| 170 | abelian groups, this natural map compares the complex of global sections of `K` supported in `Z` |
| 171 | with its right derived value `RΓ_Z(X,K)`. It is induced by mapping `K` to an injective |
| 172 | resolution. -/ |
| 173 | def derivedClosedSupportSectionsUnit (Z : Closeds X) : |
| 174 | (closedSupportSections X Z).mapHomotopyCategoryPlus ⋙ |
| 175 | DerivedCategory.Plus.Qh ⟶ |
| 176 | DerivedCategory.Plus.Qh ⋙ derivedClosedSupportSections X Z := |
| 177 | (closedSupportSections X Z).rightDerivedFunctorPlusUnith |
| 178 | |
| 179 | /-- Group-valued supported sections satisfy the universal property of their |
| 180 | right derived functor. -/ |
| 181 | instance derivedClosedSupportSections_isRightDerivedFunctor (Z : Closeds X) : |
| 182 | (derivedClosedSupportSections X Z).IsRightDerivedFunctor |
| 183 | (derivedClosedSupportSectionsUnit X Z) |
| 184 | (HomotopyCategory.Plus.quasiIso (Sheaf AddCommGrpCat.{u} X)) := by |
| 185 | dsimp only [derivedClosedSupportSections, derivedClosedSupportSectionsUnit] |
| 186 | infer_instance |
| 187 | |
| 188 | end |
| 189 | |
| 190 | end OAI.AlgebraicTopology.Support.DerivedSectionsOn.TopCat.Sheaf |