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.Topology.Manifold.Poincare.Final.Compatibility.SourceNames |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.CanonicalInduction.Terminal.Source.TerminalSourcePhysicalComponent |
| 3 | import PoincareLib.Geometry.RicciFlow.Surgery.CanonicalInduction.Terminal.Curvature.TerminalCurvaturePartialInverse |
| 4 | import PoincareLib.Geometry.RicciFlow.Compactness.GeometricLimit.Overlap.SourceMetric |
| 5 | import PoincareLib.Geometry.Riemannian.Curvature.LocalIsometryInvariants |
| 6 | import PoincareLib.Geometry.RicciFlow.Rescaling.Construction |
| 7 | import PoincareLib.Geometry.Riemannian.Homothety.Curvature.ContractionTransport |
| 8 | import PoincareLib.Geometry.Riemannian.Connection.Construction |
| 9 | |
| 10 | /-! |
| 11 | # Actual component scalars and whole original chart maps |
| 12 | |
| 13 | The normalized physical component retains scalar divided by the original |
| 14 | positive scale. Each genuine subtype chart has a partial inverse with |
| 15 | the same entire coordinate map, including its totalized values. |
| 16 | MT Claim 17.11; terminal-regular-physical-ceiling.md, K1. |
| 17 | -/ |
| 18 | |
| 19 | set_option autoImplicit false |
| 20 | set_option backward.isDefEq.respectTransparency false |
| 21 | |
| 22 | open Set Filter TopologicalSpace |
| 23 | open scoped Manifold ContDiff Topology |
| 24 | |
| 25 | universe u |
| 26 | |
| 27 | namespace PoincareMT.M47 |
| 28 | |
| 29 | local notation "E" => EuclideanSpace ℝ (Fin 3) |
| 30 | |
| 31 | /-- The actual normalized physical component has scalar exactly divided |
| 32 | by the original positive scale, for every compatible connection. -/ |
| 33 | theorem terminalSource_regular_component_scalar |
| 34 | {M : Type u} [TopologicalSpace M] [ChartedSpace E M] |
| 35 | [IsManifold (𝓡 3) ∞ M] [T2Space M] |
| 36 | (g : RiemannianMetric 3 M) (D : LeviCivitaData g) |
| 37 | (Q : ℝ) (hQ : 0 < Q) (center : M) |
| 38 | (DC : LeviCivitaData (RiemannianMetric.connectedComponentMetric |
| 39 | (M13.scaleSmoothMetric g Q hQ) center)) |
| 40 | (z : Poincare.connectedComponentOpens E center) : |
| 41 | DC.scalarCurvature z = D.scalarCurvature z.val / Q := by |
| 42 | let h : RiemannianMetric 3 M := M13.scaleSmoothMetric g Q hQ |
| 43 | let DH : LeviCivitaData h := h.leviCivitaData |
| 44 | let C := Poincare.connectedComponentOpens E center |
| 45 | have hscalar := DC.scalarCurvature_eq_of_local_isometry DH |
| 46 | (f := (Subtype.val : C → M)) isOpen_univ |
| 47 | (Poincare.isLocalDiffeomorph_opensSubtypeVal (𝓡 3) C).contMDiff.contMDiffOn |
| 48 | (fun _ _ _ _ => rfl) (mem_univ z) |
| 49 | exact hscalar.trans (M13.homothety_scalarCurvature_eq g h |
| 50 | (Diffeomorph.refl (𝓡 3) M ∞) Q hQ |
| 51 | (M13.identity_metricHomothety g Q hQ) D DH z.val) |
| 52 | |
| 53 | /-- A genuine original subtype chart produces a partial chart whose |
| 54 | whole coordinate map is exactly the retained chart parametrization. -/ |
| 55 | theorem terminalSource_regular_physical_chart |
| 56 | {M : Type u} [TopologicalSpace M] [ChartedSpace E M] |
| 57 | [IsManifold (𝓡 3) ∞ M] |
| 58 | (U : ℕ → Opens E) [∀ i, Nonempty (U i)] (i : ℕ) |
| 59 | (e : U i → M) (he : Topology.IsOpenEmbedding e) |
| 60 | (hs : IsLocalDiffeomorph (𝓡 3) (𝓡 3) ∞ e) : |
| 61 | let a := ChartDistance.chartParametrization |
| 62 | (fun j => (U j : Set E)) (fun j => (U j).isOpen) e |
| 63 | ∃ f : PartialDiffeomorph (𝓡 3) (𝓡 3) E M ∞, |
| 64 | (f : E → M) = a ∧ f.source = U i ∧ f.target = a '' (U i : Set E) := by |
| 65 | let a := ChartDistance.chartParametrization |
| 66 | (fun j => (U j : Set E)) (fun j => (U j).isOpen) e |
| 67 | have ha : (fun x : U i => a x.val) = e := by |
| 68 | funext x |
| 69 | exact ChartDistance.chartParametrization_apply |
| 70 | (fun j => (U j : Set E)) (fun j => (U j).isOpen) e x |
| 71 | have hopen : Topology.IsOpenEmbedding (fun x : U i => a x.val) := ha ▸ he |
| 72 | have hlocal : IsLocalDiffeomorphOn (𝓡 3) (𝓡 3) ∞ a (U i) := by |
| 73 | intro x |
| 74 | have hcomp : IsLocalDiffeomorphAt (𝓡 3) (𝓡 3) ∞ |
| 75 | (a ∘ (Subtype.val : U i → E)) x := by |
| 76 | change IsLocalDiffeomorphAt (𝓡 3) (𝓡 3) ∞ (fun y : U i => a y.val) x |
| 77 | rw [ha] |
| 78 | exact hs x |
| 79 | exact (Poincare.isLocalDiffeomorph_opensSubtypeVal (𝓡 3) (U i) x).of_comp hcomp |
| 80 | exact terminalCurvature_exists_actual_partial_inverse (U i).isOpen hopen hlocal |
| 81 | |
| 82 | end PoincareMT.M47 |