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.Induction.EpochExtension.Terminal.TerminalContinuation |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.Continuation.Construction.MaximalRestart |
| 3 | |
| 4 | /-! |
| 5 | # The next frontier of the actual M48 restart |
| 6 | |
| 7 | Apply M33 once to the selected terminal bridge, then observe that same |
| 8 | maximal restart at its next singular endpoint or the epoch boundary. |
| 9 | Section 17.2, pp. 409--410. Old-prefix and returned geometric controls are |
| 10 | separate M48 obligations. |
| 11 | -/ |
| 12 | |
| 13 | set_option autoImplicit false |
| 14 | set_option backward.isDefEq.respectTransparency false |
| 15 | |
| 16 | open Set |
| 17 | |
| 18 | universe u |
| 19 | |
| 20 | namespace PoincareMT.M48AnalyticCalibration |
| 21 | |
| 22 | /-- Retain the literal M33 branch, all selected M31 identities, and a |
| 23 | calibrated observation on that branch. An excluded endpoint supplies its |
| 24 | actual preterminal slab even at equality with the epoch boundary. -/ |
| 25 | theorem singular_frontier |
| 26 | {S : RepairedControlledSchedulesData.{u}} (A : M48AnalyticCalibration S) |
| 27 | (P : M48Predecessors.{u}) |
| 28 | {p : SurgeryParameterPrefix S.constants} {F : SurgeryFlowData.{u}} |
| 29 | {O : SurgeryObservation F} (hp : S.SeedCompatible p) |
| 30 | (old : SurgeryPrefixControls p F O) |
| 31 | {Q : SurgeryNoncollapseExtension.{u} p} {N : SurgeryCanonicalExtension p Q} |
| 32 | (controls : SurgeryEpochContinuationControls p F O Q N) |
| 33 | (hstart : surgeryEpochStart p.i ≤ O.H) |
| 34 | (hend : O.H < surgeryEpochStart (p.i + 1)) |
| 35 | (hdomain : F.time_domain = Ico 0 O.H) (L : RepairedPreterminalSlab F O.H) : |
| 36 | ∃ R : M48RegularSpacetimeData L, |
| 37 | ∃ reference : M48RegularReferenceData L R.history, |
| 38 | ∃ H : SingularTimeAssumptions R.history.generalized O.H (F.slice L.start).carrier, |
| 39 | ∃ limit : RepairedSingularRegularLimitData H, |
| 40 | ∃ horn : RepairedHornSelectionData H, |
| 41 | H.reference = reference.reference ∧ H.r₀ = A.historyRadius N.rNext ∧ |
| 42 | H.epsilon = S.setup.epsilon ∧ H.constant = S.setup.C ∧ |
| 43 | H.analytic_constant = S.calibration.analytic_constant ∧ |
| 44 | H.singularTimes = L.singularCatalog ∧ horn.limit = limit ∧ |
| 45 | ∃ _bridge : RepairedContinuationLimitBridge H limit horn |
| 46 | (A.continuationInput hp old controls hstart hend hdomain L |
| 47 | (m48TerminalCore H horn (F.parameters.delta O.H * F.parameters.r O.H))), |
| 48 | ∃ branch : RepairedBranchContinuationData |
| 49 | (A.continuationInput hp old controls hstart hend hdomain L |
| 50 | (m48TerminalCore H horn (F.parameters.delta O.H * F.parameters.r O.H))), |
| 51 | ∃ O' : SurgeryObservation branch.conclusion.extension.extended, |
| 52 | O.H < O'.H ∧ O'.H ≤ surgeryEpochStart (p.i + 1) ∧ |
| 53 | O.H ∈ branch.conclusion.extension.extended.surgery_times ∧ |
| 54 | Disjoint branch.conclusion.extension.extended.surgery_times |
| 55 | (Ioo O.H O'.H) ∧ |
| 56 | (O'.H < surgeryEpochStart (p.i + 1) → |
| 57 | branch.conclusion.extension.extended.time_domain = Ico 0 O'.H ∧ |
| 58 | ∃ next : RepairedPreterminalSlab |
| 59 | branch.conclusion.extension.extended O'.H, |
| 60 | next.start = O.H) ∧ |
| 61 | (branch.conclusion.extension.extended.time_domain = Ico 0 O'.H → |
| 62 | ∃ next : RepairedPreterminalSlab |
| 63 | branch.conclusion.extension.extended O'.H, |
| 64 | next.start = O.H) ∧ |
| 65 | HEq O'.standard_flow p.setup.standard_flow := by |
| 66 | obtain ⟨R, reference, H, limit, horn, href, hr, he, hC, hA, htimes, hlimit, |
| 67 | bridge, ⟨branch⟩⟩ := |
| 68 | A.singular_continuation P hp old controls hstart hend hdomain L |
| 69 | obtain ⟨U, hprogress, hbound, hinterval, hfree, hfrontier, hslab⟩ := |
| 70 | branch.conclusion.frontier_before hend |
| 71 | have hstandard : branch.conclusion.extension.extended.standard_initial = |
| 72 | p.setup.standard_initial := |
| 73 | branch.conclusion.extension.standard_initial_eq.trans old.standard_initial_eq |
| 74 | let O' : SurgeryObservation branch.conclusion.extension.extended := |
| 75 | { H := U |
| 76 | H_pos := O.H_pos.trans hprogress |
| 77 | interval_subset := hinterval |
| 78 | standard_flow := hstandard ▸ p.setup.standard_flow } |
| 79 | refine ⟨R, reference, H, limit, horn, href, hr, he, hC, hA, htimes, hlimit, |
| 80 | bridge, branch, O', hprogress, hbound, branch.conclusion.surgery_at_terminal, |
| 81 | hfree, ?_, hslab, ?_⟩ |
| 82 | · intro hlt |
| 83 | exact ⟨hfrontier hlt, hslab (hfrontier hlt)⟩ |
| 84 | · exact eqRec_heq _ _ |
| 85 | |
| 86 | end PoincareMT.M48AnalyticCalibration |