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.Surgery.Continuation.Branch |
| 2 | |
| 3 | /-! |
| 4 | Adapted from Mapher `PoincareMT/Definitions/M42VanishingContinuation.lean` at |
| 5 | `f927d9e1f0810042766d3b5f64d3f4da02ee93cc`. Declaration bodies are retained; |
| 6 | see `references/ricci-flow/mapher/surgery-adapters-port.json`. |
| 7 | -/ |
| 8 | |
| 9 | /-! |
| 10 | # M42 repaired vanishing-terminal continuation data |
| 11 | |
| 12 | This branch wrapper selects the whole-slice-vanishing terminal operation from |
| 13 | the continuation output and records extinction permanence on the extension. |
| 14 | -/ |
| 15 | |
| 16 | set_option autoImplicit false |
| 17 | |
| 18 | open scoped Manifold ContDiff Bundle ENNReal Topology |
| 19 | |
| 20 | universe u |
| 21 | |
| 22 | namespace PoincareMT |
| 23 | |
| 24 | structure RepairedVanishingContinuationData |
| 25 | {F : SurgeryFlowData.{u}} {T : ℝ} |
| 26 | (I : RepairedContinuationInput F T) |
| 27 | (branch : RepairedBranchContinuationData I) where |
| 28 | continued_empty : IsEmpty (branch.conclusion.extension.extended.slice T).carrier |
| 29 | operation : RepairedVanishingTerminalOperationCertificate I |
| 30 | branch.conclusion.extension branch.conclusion.surgery_at_terminal |
| 31 | continued_empty |
| 32 | operation_eq : branch.conclusion.terminal_operation = |
| 33 | RepairedTerminalOperation.vanishing continued_empty operation |
| 34 | end_time_top : branch.conclusion.end_time = ⊤ |
| 35 | post_terminal_interval : ∃ d : ℝ, 0 < d ∧ |
| 36 | Set.Ioo T (T + d) ⊆ branch.conclusion.extension.extended.time_domain ∧ |
| 37 | Disjoint branch.conclusion.extension.extended.surgery_times (Set.Ioo T (T + d)) |
| 38 | continued_admissible : SurgeryFlowAdmissible branch.conclusion.extension.extended |
| 39 | continued_pinched : SurgeryFlowPinched branch.conclusion.extension.extended |
| 40 | |
| 41 | end PoincareMT |