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.RingTheory.Localization.Free |
| 2 | import Mathlib.RingTheory.Localization.FractionRing |
| 3 | import Mathlib.RingTheory.TensorProduct.IsBaseChangeFree |
| 4 | import Mathlib.LinearAlgebra.Basis.VectorSpace |
| 5 | |
| 6 | /-! # Presentation Generic Freeness -/ |
| 7 | |
| 8 | namespace OAI.AlgebraicGeometry.AbelianModuli.HilbertConstruction.Finite.PresentationGenericFreeness |
| 9 | |
| 10 | noncomputable section |
| 11 | |
| 12 | /- Adapted from the Openness finite-presentation generic-freeness argument, with only its algebraic dependencies. -/ |
| 13 | |
| 14 | open scoped TensorProduct |
| 15 | |
| 16 | theorem exists_nonzero_free_localization |
| 17 | (R M : Type*) [CommRing R] [IsDomain R] |
| 18 | [AddCommGroup M] [Module R M] [Module.FinitePresentation R M] : |
| 19 | ∃ r : R, r ≠ 0 ∧ |
| 20 | Module.Free (Localization.Away r) (LocalizedModule.Away r M) := by |
| 21 | let K := FractionRing R |
| 22 | let f : M →ₗ[R] K ⊗[R] M := TensorProduct.mk R K M 1 |
| 23 | have : IsLocalizedModule (nonZeroDivisors R) f := by |
| 24 | dsimp [f, K] |
| 25 | infer_instance |
| 26 | have : Module.Free K (K ⊗[R] M) := by |
| 27 | change Module.Free (FractionRing R) (FractionRing R ⊗[R] M) |
| 28 | infer_instance |
| 29 | obtain ⟨r, hr, hfree, _⟩ := |
| 30 | Module.FinitePresentation.exists_free_localizedModule_powers |
| 31 | (nonZeroDivisors R) f K |
| 32 | exact ⟨r, mem_nonZeroDivisors_iff_ne_zero.mp hr, hfree⟩ |
| 33 | |
| 34 | end |
| 35 | |
| 36 | end OAI.AlgebraicGeometry.AbelianModuli.HilbertConstruction.Finite.PresentationGenericFreeness |