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 OAI.AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe |
| 2 | import OAI.NumberTheory.PadicHodge.IntegralComparison.TopExteriorCoordinates |
| 3 | import Mathlib.Algebra.Homology.HomologicalComplex |
| 4 | import Mathlib.Algebra.Category.ModuleCat.Basic |
| 5 | |
| 6 | /-! # Koszul Complex -/ |
| 7 | |
| 8 | namespace OAI.NumberTheory.PadicHodge.IntegralComparison.Exterior.KoszulComplex |
| 9 | |
| 10 | noncomputable section |
| 11 | |
| 12 | /-! The actual exterior Koszul chain complex and its functoriality in the |
| 13 | module of generators. Its differential is contraction by the equation map. -/ |
| 14 | |
| 15 | open _root_.CategoryTheory |
| 16 | |
| 17 | set_option backward.defeqAttrib.useBackward true |
| 18 | set_option backward.isDefEq.respectTransparency false |
| 19 | |
| 20 | open OAI.AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction |
| 21 | |
| 22 | universe u |
| 23 | variable (R : Type u) [CommRing R] |
| 24 | (V W : Type u) [AddCommGroup V] [Module R V] [AddCommGroup W] [Module R W] |
| 25 | |
| 26 | theorem contraction_square (s : Module.Dual R V) (n : ℕ) : |
| 27 | (AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.contraction R V s n).comp (AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.contraction R V s (n + 1)) = 0 := by |
| 28 | apply LinearMap.ext |
| 29 | intro x |
| 30 | apply Subtype.ext |
| 31 | exact CliffordAlgebra.contractLeft_contractLeft s x.val |
| 32 | |
| 33 | def complex (s : Module.Dual R V) : ChainComplex (ModuleCat.{u} R) ℕ := |
| 34 | ChainComplex.of (fun n => ModuleCat.of R (⋀[R]^n V)) |
| 35 | (fun n => ModuleCat.ofHom (AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.contraction R V s n)) |
| 36 | (fun n => ModuleCat.hom_ext (contraction_square R V s n)) |
| 37 | |
| 38 | variable (s : Module.Dual R V) (t : Module.Dual R W) (f : V →ₗ[R] W) |
| 39 | (h : t.comp f = s) |
| 40 | |
| 41 | theorem map_coe (n : ℕ) (x : ⋀[R]^n V) : |
| 42 | (exteriorPower.map n f x : ExteriorAlgebra R W) = ExteriorAlgebra.map f x.val := by |
| 43 | have he : (⋀[R]^n W).subtype.comp (exteriorPower.map n f) = |
| 44 | (ExteriorAlgebra.map f).toLinearMap.comp (⋀[R]^n V).subtype := by |
| 45 | apply LinearMap.ext_on (exteriorPower.ιMulti_span R n V) |
| 46 | rintro x ⟨v, rfl⟩ |
| 47 | simp only [LinearMap.comp_apply, exteriorPower.map_apply_ιMulti] |
| 48 | exact (ExteriorAlgebra.map_apply_ιMulti f v).symm |
| 49 | exact LinearMap.congr_fun he x |
| 50 | |
| 51 | include h in |
| 52 | theorem ambient_naturality (x : ExteriorAlgebra R V) : |
| 53 | AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.ambientContraction R W t (ExteriorAlgebra.map f x) = |
| 54 | ExteriorAlgebra.map f (AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.ambientContraction R V s x) := by |
| 55 | induction x using CliffordAlgebra.left_induction with |
| 56 | | algebraMap a => simp [AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.ambientContraction, CliffordAlgebra.contractLeft_algebraMap] |
| 57 | | add x y hx hy => simp only [map_add, hx, hy] |
| 58 | | ι_mul x v hx => |
| 59 | simp only [map_mul, ExteriorAlgebra.map_apply_ι, AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.ambientContraction_ι_mul, |
| 60 | map_sub, map_smul, hx] |
| 61 | rw [show t (f v) = s v from LinearMap.congr_fun h v] |
| 62 | |
| 63 | include h in |
| 64 | theorem contraction_naturality (n : ℕ) : |
| 65 | (AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.contraction R W t n).comp (exteriorPower.map (n + 1) f) = |
| 66 | (exteriorPower.map n f).comp (AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.contraction R V s n) := by |
| 67 | apply LinearMap.ext |
| 68 | intro x |
| 69 | apply Subtype.ext |
| 70 | change AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.ambientContraction R W t (exteriorPower.map (n + 1) f x).val = |
| 71 | (exteriorPower.map n f (AlgebraicGeometry.Crystalline.Cohomology.ExteriorContractionCoe.ExteriorContraction.contraction R V s n x)).val |
| 72 | rw [map_coe, map_coe] |
| 73 | exact ambient_naturality R V W s t f h x.val |
| 74 | |
| 75 | def map (h : t.comp f = s) : complex R V s ⟶ complex R W t where |
| 76 | f n := ModuleCat.ofHom (exteriorPower.map n f) |
| 77 | comm' i j hij := by |
| 78 | have hi : j + 1 = i := hij |
| 79 | subst i |
| 80 | dsimp only [complex] |
| 81 | rw [ChainComplex.of_d, ChainComplex.of_d] |
| 82 | exact ModuleCat.hom_ext (contraction_naturality R V W s t f h j) |
| 83 | |
| 84 | theorem map_top {n : ℕ} (b : Module.Basis (Fin n) R V) |
| 85 | (s t : Module.Dual R V) (f : Module.End R V) (h : t.comp f = s) : |
| 86 | (KoszulComplex.map R V V s t f h).f n = |
| 87 | ModuleCat.ofHom (f.det • (LinearMap.id : (⋀[R]^n V) →ₗ[R] (⋀[R]^n V))) := by |
| 88 | exact congrArg ModuleCat.ofHom (TopExteriorDeterminant.map_eq_det_smul_of_basis b f) |
| 89 | |
| 90 | theorem dual_top {n : ℕ} (b : Module.Basis (Fin n) R V) |
| 91 | (s t : Module.Dual R V) (f : Module.End R V) (h : t.comp f = s) |
| 92 | (a : Module.Dual R (⋀[R]^n V)) : |
| 93 | a.comp ((KoszulComplex.map R V V s t f h).f n).hom = f.det • a := by |
| 94 | rw [map_top R V b] |
| 95 | apply LinearMap.ext |
| 96 | intro x |
| 97 | exact a.map_smul f.det x |
| 98 | |
| 99 | end |
| 100 | |
| 101 | end OAI.NumberTheory.PadicHodge.IntegralComparison.Exterior.KoszulComplex |