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/TopCatSheafRestrict.lean |
| 4 | The upstream AINTLIB repository is licensed under Apache 2.0. |
| 5 | This file has been modified. |
| 6 | -/ |
| 7 | import Mathlib.CategoryTheory.Sites.Pullback |
| 8 | import Mathlib.Topology.Sheaves.Flasque |
| 9 | |
| 10 | /-! # Top Cat Restrict -/ |
| 11 | |
| 12 | namespace OAI.AlgebraicGeometry.SheafCohomology.Cech.TopCatRestrict |
| 13 | |
| 14 | open _root_.TopCat |
| 15 | open _root_.TopCat.Sheaf |
| 16 | |
| 17 | /-! |
| 18 | # Restriction of sheaves to an open subspace |
| 19 | |
| 20 | This file supplies the restriction functor along an open embedding, its adjunction with |
| 21 | pushforward, and the exactness properties needed to restrict short exact sequences of sheaves of |
| 22 | abelian groups. |
| 23 | -/ |
| 24 | |
| 25 | open _root_.CategoryTheory Limits Opposite _root_.TopologicalSpace _root_.Topology |
| 26 | |
| 27 | universe u v w |
| 28 | |
| 29 | variable (C : Type v) [Category.{w} C] {X Y : TopCat.{u}} {f : Y ⟶ X} |
| 30 | (hf : IsOpenEmbedding f) |
| 31 | |
| 32 | namespace TopCat.Sheaf |
| 33 | |
| 34 | /-- Restriction of sheaves along an open embedding. -/ |
| 35 | abbrev restrict : Sheaf C X ⥤ Sheaf C Y := |
| 36 | haveI := hf.functor_isContinuous |
| 37 | hf.functor.sheafPushforwardContinuous C .. |
| 38 | |
| 39 | /-- Restriction along an open embedding is left adjoint to pushforward. -/ |
| 40 | abbrev restrictPushforwardAdjunction : restrict C hf ⊣ pushforward C f := |
| 41 | haveI := hf.functor_isContinuous |
| 42 | Adjunction.sheafPushforwardContinuous hf.isOpenMap.adjunction .. |
| 43 | |
| 44 | instance restrict_isLeftAdjoint : (restrict C hf).IsLeftAdjoint := |
| 45 | (restrictPushforwardAdjunction C hf).isLeftAdjoint |
| 46 | |
| 47 | variable (F : Sheaf C X) (U V : Opens X) |
| 48 | |
| 49 | /-- The adjunction unit from a sheaf to the pushforward of its restriction to an open. -/ |
| 50 | abbrev toRestrict := (restrictPushforwardAdjunction C U.isOpenEmbedding).unit |
| 51 | |
| 52 | lemma toRestrict_obj_obj_obj : |
| 53 | ((restrict C U.isOpenEmbedding ⋙ pushforward C U.inclusion').obj F).obj.obj (op V) = |
| 54 | F.obj.obj (op (U.isOpenEmbedding.functor.obj ((Opens.map U.inclusion').obj V))) := rfl |
| 55 | |
| 56 | lemma toRestrict_app_hom_app : |
| 57 | ((toRestrict C U).app F).hom.app (op V) = |
| 58 | F.obj.map (U.isOpenEmbedding.isOpenMap.adjunction.counit.app V).op := by |
| 59 | let := U.isOpenEmbedding.functor_isContinuous |
| 60 | exact Adjunction.sheafPushforwardContinuous_unit_app_hom_app |
| 61 | U.isOpenEmbedding.isOpenMap.adjunction _ _ F (op V) |
| 62 | |
| 63 | private lemma restrict_comp_sheafToPresheaf_preservesFiniteLimits |
| 64 | {X Y : TopCat.{u}} {f : Y ⟶ X} (hf : IsOpenEmbedding f) : |
| 65 | PreservesFiniteLimits |
| 66 | (restrict AddCommGrpCat.{u} hf ⋙ |
| 67 | sheafToPresheaf (Opens.grothendieckTopology Y) AddCommGrpCat.{u}) := by |
| 68 | let := hf.functor_isContinuous |
| 69 | let : PreservesFiniteLimits |
| 70 | (sheafToPresheaf (Opens.grothendieckTopology X) AddCommGrpCat.{u}) := inferInstance |
| 71 | let : PreservesFiniteLimits |
| 72 | ((Functor.whiskeringLeft (Opens Y)ᵒᵖ (Opens X)ᵒᵖ AddCommGrpCat.{u}).obj |
| 73 | hf.functor.op) := inferInstance |
| 74 | change PreservesFiniteLimits |
| 75 | (sheafToPresheaf (Opens.grothendieckTopology X) AddCommGrpCat.{u} ⋙ |
| 76 | (Functor.whiskeringLeft _ _ _).obj hf.functor.op) |
| 77 | exact comp_preservesFiniteLimits _ _ |
| 78 | |
| 79 | private lemma sheafToPresheaf_reflectsFiniteShape |
| 80 | {Y : TopCat.{u}} (J : Type) [SmallCategory J] [FinCategory J] : |
| 81 | ReflectsLimitsOfShape J |
| 82 | (sheafToPresheaf (Opens.grothendieckTopology Y) AddCommGrpCat.{u}) := by |
| 83 | infer_instance |
| 84 | |
| 85 | /-- Restriction of sheaves of abelian groups along an open embedding preserves finite limits. -/ |
| 86 | instance restrict_preservesFiniteLimits |
| 87 | {X Y : TopCat.{u}} {f : Y ⟶ X} (hf : IsOpenEmbedding f) : |
| 88 | PreservesFiniteLimits (restrict AddCommGrpCat.{u} hf) := by |
| 89 | let := restrict_comp_sheafToPresheaf_preservesFiniteLimits hf |
| 90 | constructor |
| 91 | intro J _ _ |
| 92 | have hPreserve : PreservesLimitsOfShape J |
| 93 | (restrict AddCommGrpCat.{u} hf ⋙ |
| 94 | sheafToPresheaf (Opens.grothendieckTopology Y) AddCommGrpCat.{u}) := inferInstance |
| 95 | have hReflect := sheafToPresheaf_reflectsFiniteShape (Y := Y) J |
| 96 | exact @preservesLimitsOfShape_of_reflects_of_preserves _ _ _ _ _ _ _ _ |
| 97 | (restrict AddCommGrpCat.{u} hf) |
| 98 | (sheafToPresheaf (Opens.grothendieckTopology Y) AddCommGrpCat.{u}) |
| 99 | hPreserve hReflect |
| 100 | |
| 101 | /-- Restriction of sheaves of abelian groups is additive. -/ |
| 102 | instance restrict_additive {X Y : TopCat.{u}} {f : Y ⟶ X} (hf : IsOpenEmbedding f) : |
| 103 | (restrict AddCommGrpCat.{u} hf).Additive where |
| 104 | map_add := by |
| 105 | intros |
| 106 | apply CategoryTheory.Sheaf.hom_ext |
| 107 | rfl |
| 108 | |
| 109 | /-- Pushforward of sheaves of abelian groups is additive. -/ |
| 110 | instance pushforward_additive {X Y : TopCat.{u}} (f : Y ⟶ X) : |
| 111 | (pushforward AddCommGrpCat.{u} f).Additive where |
| 112 | map_add := by |
| 113 | intros |
| 114 | apply CategoryTheory.Sheaf.hom_ext |
| 115 | rfl |
| 116 | |
| 117 | /-- Restriction of a flasque sheaf to an open subspace is flasque. -/ |
| 118 | theorem IsFlasque.of_restrict {X Y : TopCat.{u}} {f : Y ⟶ X} |
| 119 | (F : Sheaf C X) [F.IsFlasque] (hf : IsOpenEmbedding f) : |
| 120 | ((restrict C hf).obj F).IsFlasque where |
| 121 | epi i := by |
| 122 | change Epi (F.obj.map (hf.functor.op.map i)) |
| 123 | infer_instance |
| 124 | |
| 125 | end TopCat.Sheaf |
| 126 | |
| 127 | end OAI.AlgebraicGeometry.SheafCohomology.Cech.TopCatRestrict |