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.Blowup.Construction.ShortTime.Terminal.TerminalRicciKernel |
| 2 | import PoincareLib.Geometry.RicciFlow.Blowup.Construction.ShortTime.ParallelSections.FiniteParallelSection |
| 3 | import PoincareLib.Geometry.RicciFlow.Blowup.Construction.ShortTime.Nullity.NullityTransport |
| 4 | |
| 5 | /-! |
| 6 | # Terminal nullity and local parallel sections from finite domains |
| 7 | |
| 8 | Morgan--Tian Corollary 4.19, pp. 71--73, and Claim 11.7, pp. 270--271. |
| 9 | |
| 10 | Each target point is covered by a connected finite flow domain that also |
| 11 | contains fixed null-plane and nonflat anchors. The actual local isometry |
| 12 | transports the finite terminal argument and the prescribed parallel section |
| 13 | back to the supplied target metric. |
| 14 | -/ |
| 15 | |
| 16 | set_option autoImplicit false |
| 17 | set_option backward.isDefEq.respectTransparency false |
| 18 | |
| 19 | open Set Manifold PoincareMT.RicciFlow.Splitting |
| 20 | open scoped Manifold ContDiff Bundle |
| 21 | |
| 22 | universe u v w |
| 23 | |
| 24 | namespace PoincareMT.M30 |
| 25 | |
| 26 | /-- Finite connected flow domains covering the two fixed anchors and each |
| 27 | target point force terminal Ricci nullity one and provide prescribed local |
| 28 | parallel null sections for the supplied target Levi-Civita data (Morgan--Tian |
| 29 | Corollary 4.19, pp. 71--73, and Claim 11.7, pp. 270--271). -/ |
| 30 | theorem terminal_nullity_and_local_parallel_sections |
| 31 | {ι : Type w} {N : ι → Type u} {M : Type v} |
| 32 | [∀ i, TopologicalSpace (N i)] [TopologicalSpace M] |
| 33 | [∀ i, T2Space (N i)] [∀ i, ConnectedSpace (N i)] |
| 34 | [∀ i, ChartedSpace (EuclideanSpace ℝ (Fin 3)) (N i)] |
| 35 | [ChartedSpace (EuclideanSpace ℝ (Fin 3)) M] |
| 36 | [∀ i, IsManifold (𝓡 3) ∞ (N i)] [IsManifold (𝓡 3) ∞ M] |
| 37 | (hC : RicciFlowCurvatureTheory.{u}) |
| 38 | (a : ι → ℝ) (ha : ∀ i, a i < 0) |
| 39 | (F : ∀ i, RicciFlow 3 (N i) (Icc (a i) 0)) |
| 40 | (hoperator : ∀ i, ∀ t ∈ Icc (a i) 0, ∀ z : N i, |
| 41 | ((F i).connection t).NonnegativeCurvatureOperator z) |
| 42 | {g : RiemannianMetric 3 M} (D : LeviCivitaData g) |
| 43 | (e : ∀ i, N i → M) |
| 44 | (he : ∀ i, IsLocalDiffeomorph (𝓡 3) (𝓡 3) ∞ (e i)) |
| 45 | (hmetric : ∀ i, ∀ z : N i, ∀ v1 v2 : TangentSpace (𝓡 3) z, |
| 46 | ((F i).metric 0).inner z v1 v2 = g.inner (e i z) |
| 47 | (mfderiv (𝓡 3) (𝓡 3) (e i) z v1) |
| 48 | (mfderiv (𝓡 3) (𝓡 3) (e i) z v2)) |
| 49 | (p0 : M) (hnonflat : D.curvatureTensorNorm p0 ≠ 0) |
| 50 | (x : M) (v1 v2 : TangentSpace (𝓡 3) x) |
| 51 | (hv1 : g.inner x v1 v1 = 1) (hv2 : g.inner x v2 v2 = 1) |
| 52 | (horth : g.inner x v1 v2 = 0) |
| 53 | (hzero : D.curvatureTensor x v1 v2 v1 v2 = 0) |
| 54 | (hcapture : ∀ y : M, ∃ i : ι, |
| 55 | x ∈ range (e i) ∧ p0 ∈ range (e i) ∧ y ∈ range (e i)) : |
| 56 | (∀ y : M, ricciNullity D y = 1) ∧ |
| 57 | ∀ p : UnitRicciKernel D, |
| 58 | ∃ (U : Set M) (V : (y : M) → TangentSpace (𝓡 3) y), |
| 59 | IsOpen U ∧ p.1.proj ∈ U ∧ |
| 60 | ContMDiffOn (𝓡 3) ((𝓡 3).prod (𝓡 3)) ∞ (T% V) U ∧ |
| 61 | V p.1.proj = p.1.snd ∧ |
| 62 | ∀ y ∈ U, g.inner y (V y) (V y) = 1 ∧ |
| 63 | (∀ z : TangentSpace (𝓡 3) y, D.ricci y (V y) z = 0) ∧ |
| 64 | ∀ z : TangentSpace (𝓡 3) y, D.connection V y z = 0 := by |
| 65 | classical |
| 66 | have hterminal : ∀ i : ι, x ∈ range (e i) → p0 ∈ range (e i) → |
| 67 | ∀ y : N i, ricciNullity ((F i).connection 0) y = 1 := by |
| 68 | intro i hxi hp0 |
| 69 | obtain ⟨xi, hxi⟩ := hxi |
| 70 | obtain ⟨pi, hpi⟩ := hp0 |
| 71 | subst x |
| 72 | subst p0 |
| 73 | let L := mfderiv (𝓡 3) (𝓡 3) (e i) xi |
| 74 | have hL : L.IsInvertible := |
| 75 | ⟨(he i xi).mfderivToContinuousLinearEquiv (by simp), rfl⟩ |
| 76 | let u1 : TangentSpace (𝓡 3) xi := L.inverse v1 |
| 77 | let u2 : TangentSpace (𝓡 3) xi := L.inverse v2 |
| 78 | have hu1 : L u1 = v1 := hL.self_apply_inverse v1 |
| 79 | have hu2 : L u2 = v2 := hL.self_apply_inverse v2 |
| 80 | have hu1norm : ((F i).metric 0).inner xi u1 u1 = 1 := by |
| 81 | calc |
| 82 | ((F i).metric 0).inner xi u1 u1 = |
| 83 | g.inner (e i xi) (L u1) (L u1) := hmetric i xi u1 u1 |
| 84 | _ = 1 := by rw [hu1]; exact hv1 |
| 85 | have hu2norm : ((F i).metric 0).inner xi u2 u2 = 1 := by |
| 86 | calc |
| 87 | ((F i).metric 0).inner xi u2 u2 = |
| 88 | g.inner (e i xi) (L u2) (L u2) := hmetric i xi u2 u2 |
| 89 | _ = 1 := by rw [hu2]; exact hv2 |
| 90 | have hu12 : ((F i).metric 0).inner xi u1 u2 = 0 := by |
| 91 | calc |
| 92 | ((F i).metric 0).inner xi u1 u2 = |
| 93 | g.inner (e i xi) (L u1) (L u2) := hmetric i xi u1 u2 |
| 94 | _ = 0 := by rw [hu1, hu2]; exact horth |
| 95 | have hcurv : ((F i).connection 0).curvatureTensor xi u1 u2 u1 u2 = 0 := by |
| 96 | calc |
| 97 | ((F i).connection 0).curvatureTensor xi u1 u2 u1 u2 = |
| 98 | D.curvatureTensor (e i xi) (L u1) (L u2) (L u1) (L u2) := |
| 99 | LeviCivitaData.curvatureTensor_eq_of_local_isometry |
| 100 | ((F i).connection 0) D isOpen_univ (he i).contMDiff.contMDiffOn |
| 101 | (fun z _ a b => hmetric i z a b) (mem_univ xi) u1 u2 u1 u2 |
| 102 | _ = 0 := by rw [hu1, hu2]; exact hzero |
| 103 | have hnorm : ((F i).connection 0).curvatureTensorNorm pi ≠ 0 := by |
| 104 | rw [LeviCivitaData.curvatureTensorNorm_eq_of_local_isometry |
| 105 | ((F i).connection 0) D isOpen_univ (he i).contMDiff.contMDiffOn |
| 106 | (fun z _ a b => hmetric i z a b) (mem_univ pi)] |
| 107 | exact hnonflat |
| 108 | exact ricciNullity_eq_one_of_finite_terminal_null_plane |
| 109 | (ha i) hC (F i) (fun t ht z => hoperator i t ht z) |
| 110 | ⟨pi, hnorm⟩ xi u1 u2 hu1norm hu2norm hu12 hcurv |
| 111 | have hnullity : ∀ y : M, ricciNullity D y = 1 := by |
| 112 | intro y |
| 113 | obtain ⟨i, hxi, hp0, hy⟩ := hcapture y |
| 114 | obtain ⟨yi, hyi⟩ := hy |
| 115 | have hs := hterminal i hxi hp0 yi |
| 116 | have ht := ricciNullity_eq_of_local_isometry |
| 117 | ((F i).connection 0) D (he i) (hmetric i) yi |
| 118 | rw [ht] at hs |
| 119 | simpa [hyi] using hs |
| 120 | have hsection : ∀ (y : M) (v : TangentSpace (𝓡 3) y), |
| 121 | g.inner y v v = 1 → |
| 122 | (∀ z : TangentSpace (𝓡 3) y, D.ricci y v z = 0) → |
| 123 | ∃ (U : Set M) (V : (z : M) → TangentSpace (𝓡 3) z), |
| 124 | IsOpen U ∧ y ∈ U ∧ |
| 125 | ContMDiffOn (𝓡 3) ((𝓡 3).prod (𝓡 3)) ∞ (T% V) U ∧ |
| 126 | V y = v ∧ |
| 127 | ∀ z ∈ U, g.inner z (V z) (V z) = 1 ∧ |
| 128 | (∀ w : TangentSpace (𝓡 3) z, D.ricci z (V z) w = 0) ∧ |
| 129 | ∀ w : TangentSpace (𝓡 3) z, D.connection V z w = 0 := by |
| 130 | intro y v hv hnull |
| 131 | obtain ⟨i, hxi, hp0, hy⟩ := hcapture y |
| 132 | obtain ⟨yi, hyi⟩ := hy |
| 133 | subst y |
| 134 | have hdim : ∀ z : N i, ricciNullity ((F i).connection 0) z = 1 := |
| 135 | hterminal i hxi hp0 |
| 136 | have hsec : ∀ t ∈ Icc (a i) 0, |
| 137 | ((F i).connection t).NonnegativeSectionalCurvature := by |
| 138 | intro t ht z u w |
| 139 | exact ((F i).connection t).curvatureTensor_self_nonneg_of_nonnegative_curvatureOperator |
| 140 | z (hoperator i t ht z) u w |
| 141 | exact exists_prescribed_parallel_null_section_of_finite_terminal_local_isometry |
| 142 | hC (ha i) (F i) hsec hdim D (he i) (hmetric i) yi v hv hnull |
| 143 | refine ⟨hnullity, ?_⟩ |
| 144 | intro p |
| 145 | exact hsection p.1.proj p.1.snd p.2.1 p.2.2 |
| 146 | |
| 147 | end PoincareMT.M30 |