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.CategoryTheory.Comma.Over.Pullback |
| 2 | import Mathlib.CategoryTheory.Linear.FunctorCategory |
| 3 | |
| 4 | /-! # Product Presheaf Sections -/ |
| 5 | |
| 6 | namespace OAI.NumberTheory.PadicHodge.IntegralComparison.ProductPresheafSections |
| 7 | |
| 8 | noncomputable section |
| 9 | |
| 10 | /-! |
| 11 | # IntegralComparison: constant-source sections of a product presheaf |
| 12 | |
| 13 | Evaluation along the diagonal recovers the original section on the frame. |
| 14 | The inverse pulls it back along the first projection. |
| 15 | -/ |
| 16 | |
| 17 | open _root_.CategoryTheory _root_.CategoryTheory.Limits Opposite |
| 18 | |
| 19 | universe u v w z t |
| 20 | |
| 21 | variable {C : Type u} [Category.{v} C] [HasBinaryProducts C] |
| 22 | {D : Type w} [Category.{z} D] (F : C) (P : Cᵒᵖ ⥤ D) (M : D) |
| 23 | |
| 24 | abbrev productPresheaf : Cᵒᵖ ⥤ D := (prod.functor.obj F).op ⋙ P |
| 25 | |
| 26 | omit [HasBinaryProducts C] in |
| 27 | theorem map_comp_op {U V W : C} (g : U ⟶ V) (h : V ⟶ W) : |
| 28 | P.map h.op ≫ P.map g.op = P.map (g ≫ h).op := |
| 29 | (P.map_comp h.op g.op).symm |
| 30 | |
| 31 | omit [HasBinaryProducts C] in |
| 32 | theorem pull_comp {U V W : C} (a : M ⟶ P.obj (op W)) (g : U ⟶ V) (h : V ⟶ W) : |
| 33 | (a ≫ P.map h.op) ≫ P.map g.op = a ≫ P.map (g ≫ h).op := |
| 34 | (Category.assoc _ _ _).trans (congrArg (fun t => a ≫ t) (map_comp_op P g h)) |
| 35 | |
| 36 | def fromFrame (g : M ⟶ P.obj (op F)) : (Functor.const Cᵒᵖ).obj M ⟶ productPresheaf F P where |
| 37 | app U := g ≫ P.map (prod.fst : F ⨯ U.unop ⟶ F).op |
| 38 | naturality U V α := by |
| 39 | have h := (prod.map_fst (𝟙 F) α.unop).trans (Category.comp_id _) |
| 40 | exact (Category.id_comp _).trans |
| 41 | ((congrArg (fun t => g ≫ P.map t.op) h).symm.trans |
| 42 | (pull_comp P M g (prod.map (𝟙 F) α.unop) prod.fst).symm) |
| 43 | |
| 44 | def toFrame (a : (Functor.const Cᵒᵖ).obj M ⟶ productPresheaf F P) : M ⟶ P.obj (op F) := |
| 45 | a.app (op F) ≫ P.map (prod.lift (𝟙 F) (𝟙 F)).op |
| 46 | |
| 47 | theorem toFrame_fromFrame (g : M ⟶ P.obj (op F)) : |
| 48 | toFrame F P M (fromFrame F P M g) = g := by |
| 49 | exact (pull_comp P M g (prod.lift (𝟙 F) (𝟙 F)) prod.fst).trans |
| 50 | ((congrArg (fun t => g ≫ P.map t.op) (prod.lift_fst (𝟙 F) (𝟙 F))).trans |
| 51 | ((congrArg (fun t => g ≫ t) (P.map_id (op F))).trans (Category.comp_id g))) |
| 52 | |
| 53 | theorem fromFrame_toFrame (a : (Functor.const Cᵒᵖ).obj M ⟶ productPresheaf F P) : |
| 54 | fromFrame F P M (toFrame F P M a) = a := by |
| 55 | apply NatTrans.ext |
| 56 | funext U |
| 57 | let aF : M ⟶ P.obj (op (F ⨯ F)) := a.app (op F) |
| 58 | let aU : M ⟶ P.obj (op (F ⨯ U.unop)) := a.app U |
| 59 | let aP : M ⟶ P.obj (op (F ⨯ (F ⨯ U.unop))) := a.app (op (F ⨯ U.unop)) |
| 60 | let d : F ⨯ U.unop ⟶ F ⨯ (F ⨯ U.unop) := prod.lift prod.fst (𝟙 _) |
| 61 | have hf : aP = aF ≫ P.map (prod.map (𝟙 F) prod.fst).op := |
| 62 | (Category.id_comp aP).symm.trans (a.naturality (prod.fst : F ⨯ U.unop ⟶ F).op) |
| 63 | have hs : aP = aU ≫ P.map (prod.map (𝟙 F) prod.snd).op := |
| 64 | (Category.id_comp aP).symm.trans (a.naturality (prod.snd : F ⨯ U.unop ⟶ U.unop).op) |
| 65 | have hfirst : d ≫ prod.map (𝟙 F) (prod.fst : F ⨯ U.unop ⟶ F) = |
| 66 | prod.fst ≫ prod.lift (𝟙 F) (𝟙 F) := by |
| 67 | apply prod.hom_ext <;> simp [d] |
| 68 | have hsecond : d ≫ prod.map (𝟙 F) (prod.snd : F ⨯ U.unop ⟶ U.unop) = 𝟙 _ := by |
| 69 | apply prod.hom_ext <;> simp [d] |
| 70 | exact (pull_comp P M aF prod.fst (prod.lift (𝟙 F) (𝟙 F))).trans |
| 71 | ((congrArg (fun t => aF ≫ P.map t.op) hfirst).symm.trans |
| 72 | ((pull_comp P M aF d (prod.map (𝟙 F) prod.fst)).symm.trans |
| 73 | ((congrArg (fun t => t ≫ P.map d.op) (hf.symm.trans hs)).trans |
| 74 | ((pull_comp P M aU d (prod.map (𝟙 F) prod.snd)).trans |
| 75 | ((congrArg (fun t => aU ≫ P.map t.op) hsecond).trans |
| 76 | ((congrArg (fun t => aU ≫ t) (P.map_id (op (F ⨯ U.unop)))).trans |
| 77 | (Category.comp_id aU))))))) |
| 78 | |
| 79 | def homEquiv : ((Functor.const Cᵒᵖ).obj M ⟶ productPresheaf F P) ≃ (M ⟶ P.obj (op F)) where |
| 80 | toFun := toFrame F P M |
| 81 | invFun := fromFrame F P M |
| 82 | left_inv := fromFrame_toFrame F P M |
| 83 | right_inv := toFrame_fromFrame F P M |
| 84 | |
| 85 | variable (R : Type t) [CommRing R] [Preadditive D] [Linear R D] |
| 86 | |
| 87 | def homLinearEquiv : ((Functor.const Cᵒᵖ).obj M ⟶ productPresheaf F P) ≃ₗ[R] (M ⟶ P.obj (op F)) := |
| 88 | { homEquiv F P M with |
| 89 | map_add' := by |
| 90 | intro a b |
| 91 | change (a.app (op F) + b.app (op F)) ≫ P.map (prod.lift (𝟙 F) (𝟙 F)).op = _ |
| 92 | rw [Preadditive.add_comp] |
| 93 | rfl |
| 94 | map_smul' := by |
| 95 | intro r a |
| 96 | exact Linear.smul_comp _ _ _ r (a.app (op F)) (P.map (prod.lift (𝟙 F) (𝟙 F)).op) } |
| 97 | |
| 98 | end |
| 99 | |
| 100 | end OAI.NumberTheory.PadicHodge.IntegralComparison.ProductPresheafSections |