Poincaré conjecture: the Lean proof, cleaned up together
The 2026 Lean proof of the Poincaré conjecture after Morgan and Tian, 3 million lines, cleaned up together: smaller, faster to build, more readable, the theorems unchanged

| 1 | import PoincareLib.Geometry.RicciFlow.Limit.Equation |
| 2 | import PoincareLib.Geometry.Riemannian.Connection.OpenDomain |
| 3 | import PoincareLib.Geometry.RicciFlow.Limit.CoordinateTime |
| 4 | import PoincareLib.Geometry.Riemannian.Connection.ChangeMetric |
| 5 | |
| 6 | /-! |
| 7 | # Ricci flows from smooth positive limits on fixed open domains |
| 8 | |
| 9 | The limiting connection is constructed from the smooth metric. Its Ricci |
| 10 | tensor converges by the spatial jet theorem, so the source equations give an |
| 11 | ordinary Ricci flow with precisely the prescribed limiting metric family. |
| 12 | |
| 13 | Reference: Morgan--Tian, Proposition 5.14, pp. 90--91. |
| 14 | -/ |
| 15 | |
| 16 | set_option autoImplicit false |
| 17 | |
| 18 | open scoped Manifold ContDiff Bundle Topology |
| 19 | open Filter |
| 20 | |
| 21 | namespace PoincareMT.RicciFlow |
| 22 | |
| 23 | /-- Scalar coordinate spatial and time jets construct a limiting Ricci flow |
| 24 | on an arbitrary smooth manifold. A source connection supplies the reference |
| 25 | for the constructed limiting connection. -/ |
| 26 | theorem exists_of_scalar_coordinate_jets |
| 27 | {n : ℕ} {M : Type*} [TopologicalSpace M] |
| 28 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 29 | {J : Set ℝ} (Fseq : ℕ → RicciFlow n M J) |
| 30 | (g : ℝ → RiemannianMetric n M) |
| 31 | (hJ : IsOpen J) (hg : RiemannianMetric.IsSmoothFamilyOn g J) |
| 32 | (hspace : ∀ t ∈ J, ∀ x : M, ∀ r : ℕ, r ≤ 2 → ∀ a c : Fin n, |
| 33 | Tendsto (fun k => iteratedFDeriv ℝ r |
| 34 | (fun y => ((Fseq k).metric t).pullbackCoefficients |
| 35 | (extChartAt (𝓡 n) x).symm y |
| 36 | (EuclideanSpace.basisFun (Fin n) ℝ a) |
| 37 | (EuclideanSpace.basisFun (Fin n) ℝ c)) (extChartAt (𝓡 n) x x)) atTop |
| 38 | (𝓝 (iteratedFDeriv ℝ r |
| 39 | (fun y => (g t).pullbackCoefficients (extChartAt (𝓡 n) x).symm y |
| 40 | (EuclideanSpace.basisFun (Fin n) ℝ a) |
| 41 | (EuclideanSpace.basisFun (Fin n) ℝ c)) (extChartAt (𝓡 n) x x)))) |
| 42 | (htime : ∀ t ∈ J, ∀ (x : M) (a b : Fin n), |
| 43 | Tendsto (fun k => deriv (fun s => ((Fseq k).metric s).pullbackCoefficients |
| 44 | (extChartAt (𝓡 n) x).symm (extChartAt (𝓡 n) x x) |
| 45 | (EuclideanSpace.basisFun (Fin n) ℝ a) |
| 46 | (EuclideanSpace.basisFun (Fin n) ℝ b)) t) atTop |
| 47 | (𝓝 (deriv (fun s => (g s).pullbackCoefficients |
| 48 | (extChartAt (𝓡 n) x).symm (extChartAt (𝓡 n) x x) |
| 49 | (EuclideanSpace.basisFun (Fin n) ℝ a) |
| 50 | (EuclideanSpace.basisFun (Fin n) ℝ b)) t))) : |
| 51 | ∃ F : RicciFlow n M J, F.metric = g := by |
| 52 | let D : ∀ t, LeviCivitaData (g t) := fun t => ((Fseq 0).connection 0).withMetric (g t) |
| 53 | have htime' := fun t ht x => |
| 54 | RiemannianMetric.tendsto_inner_time_deriv_of_coordinate_deriv |
| 55 | (fun k => (Fseq k).metric) g (fun k => (Fseq k).smooth) hg hJ ht x (htime t ht x) |
| 56 | exact ⟨{ |
| 57 | metric := g |
| 58 | connection := D |
| 59 | interval := (Fseq 0).interval |
| 60 | nontrivial := (Fseq 0).nontrivial |
| 61 | smooth := hg |
| 62 | equation := equation_of_coordinate_jets Fseq g D hJ hg hspace htime' }, rfl⟩ |
| 63 | |
| 64 | /-- A smooth positive limit on a fixed open domain is an ordinary Ricci flow, |
| 65 | with its Levi-Civita connection constructed from the limit metric. -/ |
| 66 | theorem exists_of_coordinate_jets_on_open |
| 67 | {n : ℕ} (U : TopologicalSpace.Opens (EuclideanSpace ℝ (Fin n))) |
| 68 | {J : Set ℝ} (Fseq : ℕ → RicciFlow n U J) |
| 69 | (g : ℝ → RiemannianMetric n U) |
| 70 | (hJ : IsOpen J) (hg : RiemannianMetric.IsSmoothFamilyOn g J) |
| 71 | (hspace : ∀ t ∈ J, ∀ x : U, ∀ r : ℕ, r ≤ 2 → ∀ a c : Fin n, |
| 72 | Tendsto (fun k => iteratedFDeriv ℝ r |
| 73 | (fun y => ((Fseq k).metric t).pullbackCoefficients |
| 74 | (extChartAt (𝓡 n) x).symm y |
| 75 | (EuclideanSpace.basisFun (Fin n) ℝ a) |
| 76 | (EuclideanSpace.basisFun (Fin n) ℝ c)) (extChartAt (𝓡 n) x x)) atTop |
| 77 | (𝓝 (iteratedFDeriv ℝ r |
| 78 | (fun y => (g t).pullbackCoefficients (extChartAt (𝓡 n) x).symm y |
| 79 | (EuclideanSpace.basisFun (Fin n) ℝ a) |
| 80 | (EuclideanSpace.basisFun (Fin n) ℝ c)) (extChartAt (𝓡 n) x x)))) |
| 81 | (htime : ∀ t ∈ J, ∀ (x : U) (u v : TangentSpace (𝓡 n) x), |
| 82 | Tendsto (fun k => deriv (fun s => ((Fseq k).metric s).inner x u v) t) atTop |
| 83 | (𝓝 (deriv (fun s => (g s).inner x u v) t))) : |
| 84 | ∃ F : RicciFlow n U J, F.metric = g := by |
| 85 | let D : ∀ t, LeviCivitaData (g t) := fun t => (g t).openEuclideanLeviCivitaData U |
| 86 | exact ⟨{ |
| 87 | metric := g |
| 88 | connection := D |
| 89 | interval := (Fseq 0).interval |
| 90 | nontrivial := (Fseq 0).nontrivial |
| 91 | smooth := hg |
| 92 | equation := equation_of_coordinate_jets Fseq g D hJ hg hspace htime }, rfl⟩ |
| 93 | |
| 94 | end PoincareMT.RicciFlow |