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.Generalized.ReducedGeometry.Paths.Action.PathRestriction |
| 2 | |
| 3 | /-! |
| 4 | # Restriction retaining the prescribed final endpoint |
| 5 | |
| 6 | The tail used to splice a competing prefix into an actual full path, |
| 7 | Morgan-Tian Definition 6.2 and Proposition 6.30, pp. 106, 118-119. |
| 8 | The curve and velocity are unchanged; the original endpoint witness |
| 9 | is retained in the path type. |
| 10 | -/ |
| 11 | |
| 12 | set_option autoImplicit false |
| 13 | |
| 14 | universe u |
| 15 | |
| 16 | namespace PoincareMT.M14 |
| 17 | |
| 18 | variable {n : ℕ} {X : Type u} [TopologicalSpace X] {time : X → ℝ} |
| 19 | {I : SpacetimeInterval} {G : GeneralizedLGeometryTransport n X time I} |
| 20 | {T τ₁ τ₂ : ℝ} {x y : G.Point} |
| 21 | |
| 22 | /-- Restrict an actual path to a tail while retaining its prescribed |
| 23 | final endpoint, Definition 6.2 and Proposition 6.30, pp. 106, 118-119. -/ |
| 24 | def tailPath (p : M14BackwardPath G T τ₁ τ₂ x y) (a : ℝ) |
| 25 | (ha : τ₁ ≤ a) (hab : a < τ₂) : M14BackwardPath G T a τ₂ (p.curve a) y := |
| 26 | { restrictPath p a τ₂ ha hab le_rfl with |
| 27 | endpoint_time := p.endpoint_time |
| 28 | curve_end := p.curve_end } |
| 29 | |
| 30 | end PoincareMT.M14 |