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.HilbertScheme.Presentations.ResidueFieldDetection |
| 2 | import OAI.AlgebraicGeometry.HilbertScheme.Presentations.Flat.ExactKernels |
| 3 | import Mathlib.RingTheory.Finiteness.Finsupp |
| 4 | |
| 5 | /-! # Fiberwise Exactness -/ |
| 6 | |
| 7 | namespace OAI.AlgebraicGeometry.HilbertScheme.Presentations.FiberwiseExactness |
| 8 | |
| 9 | noncomputable section |
| 10 | |
| 11 | /-! Fiberwise exactness lifts to an actual module sequence when its homology is finite and the outgoing image is flat. -/ |
| 12 | |
| 13 | open TensorProduct |
| 14 | |
| 15 | universe u v w t |
| 16 | |
| 17 | variable (R : Type u) [CommRing R] |
| 18 | variable {M : Type v} [AddCommGroup M] [Module R M] |
| 19 | variable {N : Type w} [AddCommGroup N] [Module R N] |
| 20 | variable {P : Type t} [AddCommGroup P] [Module R P] |
| 21 | |
| 22 | def linearMapToKernel (f : M →ₗ[R] N) (g : N →ₗ[R] P) (hfg : ∀ m, g (f m) = 0) : |
| 23 | M →ₗ[R] g.ker := f.codRestrict g.ker hfg |
| 24 | |
| 25 | abbrev linearKernelCohomology (f : M →ₗ[R] N) (g : N →ₗ[R] P) (hfg : ∀ m, g (f m) = 0) := |
| 26 | g.ker ⧸ (linearMapToKernel R f g hfg).range |
| 27 | |
| 28 | theorem kernel_finite_of_finite_cohomology (f : M →ₗ[R] N) (g : N →ₗ[R] P) |
| 29 | (hfg : ∀ m, g (f m) = 0) [Module.Finite R M] |
| 30 | [Module.Finite R (linearKernelCohomology R f g hfg)] : Module.Finite R g.ker := |
| 31 | Module.Finite.of_submodule_quotient (linearMapToKernel R f g hfg).range |
| 32 | |
| 33 | theorem exact_kernel_rangeRestrict (g : N →ₗ[R] P) : Function.Exact g.ker.subtype g.rangeRestrict := by |
| 34 | intro y |
| 35 | constructor |
| 36 | · intro hy |
| 37 | exact ⟨⟨y, congrArg Subtype.val hy⟩, rfl⟩ |
| 38 | · rintro ⟨x, rfl⟩ |
| 39 | exact Subtype.ext x.property |
| 40 | |
| 41 | theorem kernel_flat_of_flat_range (f : M →ₗ[R] N) [Module.Flat R M] [Module.Flat R f.range] : |
| 42 | Module.Flat R f.ker := by |
| 43 | let : Module.Flat R f.rangeRestrict.ker := Presentations.Flat.ExactKernels.kernel_flat_of_surjective f.rangeRestrict f.surjective_rangeRestrict |
| 44 | exact Module.Flat.of_linearEquiv (LinearEquiv.ofEq _ _ (LinearMap.ker_rangeRestrict f).symm) |
| 45 | |
| 46 | theorem exact_of_residueFields_of_flat_range |
| 47 | (f : M →ₗ[R] N) (g : N →ₗ[R] P) (hfg : ∀ m, g (f m) = 0) |
| 48 | [Module.Flat R g.range] [Module.Finite R (g.ker ⧸ (linearMapToKernel R f g hfg).range)] |
| 49 | (h : ∀ p : PrimeSpectrum R, |
| 50 | Function.Exact (f.lTensor p.asIdeal.ResidueField) (g.lTensor p.asIdeal.ResidueField)) : |
| 51 | Function.Exact f g := by |
| 52 | let f' := linearMapToKernel R f g hfg |
| 53 | have hfcomp : g.ker.subtype.comp f' = f := by |
| 54 | apply LinearMap.ext |
| 55 | intro m |
| 56 | rfl |
| 57 | have hgcomp : g.comp g.ker.subtype = 0 := by |
| 58 | apply LinearMap.ext |
| 59 | intro x |
| 60 | exact x.property |
| 61 | have hsurj : Function.Surjective f' := by |
| 62 | apply ResidueFieldDetection.surjective_of_residueFields_of_finite_cokernel R f' |
| 63 | intro p x |
| 64 | have hinj := LinearMap.lTensor_injective_of_exact_of_flat g.rangeRestrict g.surjective_rangeRestrict |
| 65 | g.ker.subtype g.ker.subtype_injective (exact_kernel_rangeRestrict R g) p.asIdeal.ResidueField |
| 66 | have hx : g.lTensor p.asIdeal.ResidueField (g.ker.subtype.lTensor p.asIdeal.ResidueField x) = 0 := by |
| 67 | rw [← LinearMap.lTensor_comp_apply, hgcomp, LinearMap.lTensor_zero, LinearMap.zero_apply] |
| 68 | obtain ⟨y, hy⟩ := (h p _).mp hx |
| 69 | refine ⟨y, hinj ?_⟩ |
| 70 | rw [← LinearMap.lTensor_comp_apply, hfcomp] |
| 71 | exact hy |
| 72 | intro y |
| 73 | constructor |
| 74 | · intro hy |
| 75 | obtain ⟨x, hx⟩ := hsurj ⟨y, hy⟩ |
| 76 | exact ⟨x, congrArg Subtype.val hx⟩ |
| 77 | · rintro ⟨x, rfl⟩ |
| 78 | exact hfg x |
| 79 | |
| 80 | end |
| 81 | |
| 82 | end OAI.AlgebraicGeometry.HilbertScheme.Presentations.FiberwiseExactness |