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.GlobalSchedule.Global.GlobalExtension |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.Induction.EpochExtension.Extension.ExtensionCylinderMetric |
| 3 | import PoincareLib.Geometry.RicciFlow.Surgery.Induction.EpochExtension.Canonical.RoundCylinderCongruence |
| 4 | |
| 5 | /-! |
| 6 | # Strong terminal necks on the chosen global events |
| 7 | |
| 8 | Push the actual selected stage's backward cylinder through its global |
| 9 | extension. The copied terminal metric and neck are literal source data; |
| 10 | the inverse-limit and pre-identification formulas give the reference path. |
| 11 | This verifies the strong-neck clause of Morgan--Tian Definition 15.8, |
| 12 | pp. 361-362, in the global construction of Section 17.2, pp. 409-411. |
| 13 | -/ |
| 14 | |
| 15 | set_option autoImplicit false |
| 16 | set_option backward.isDefEq.respectTransparency false |
| 17 | |
| 18 | open Set |
| 19 | open scoped Manifold ContDiff |
| 20 | |
| 21 | universe u |
| 22 | |
| 23 | namespace PoincareMT.M51.CompletedStageChain |
| 24 | |
| 25 | variable {S : RepairedControlledSchedulesData.{u}} |
| 26 | {N : RepairedNoncollapseInductionData S} |
| 27 | {C : RepairedCanonicalInductionData S N} |
| 28 | {F0 : SurgeryFlowData.{u}} {k : ℕ} |
| 29 | (Q : CompletedStageChain S N C F0 k) |
| 30 | (m13 : GeneralizedParabolicRescalingTheory.{u} 3) |
| 31 | |
| 32 | /-- Push a selected stage's terminal strong neck to the global event: |
| 33 | Definition 15.8, pp. 361-362; Section 17.2, pp. 409-411. -/ |
| 34 | noncomputable def globalTerminalStrongNeck |
| 35 | (T : ℝ) (hT : T ∈ Q.globalSurgeryTimes) |
| 36 | [Nonempty ((Q.globalFlow m13).slice T).carrier] |
| 37 | [Nonempty (Q.globalSlice T).carrier] |
| 38 | [Nonempty ((Q.flow (Q.representativeIndex T)).slice T).carrier] |
| 39 | (i : Fin (Q.globalEventSource T hT).cap_count) |
| 40 | (W : SurgeryTerminalStrongNeck (Q.flow (Q.representativeIndex T)) T |
| 41 | (Q.eventStageSurgery T hT) i) : |
| 42 | SurgeryTerminalStrongNeck (Q.globalFlow m13) T hT i := by |
| 43 | let A := Q.globalEventSource T hT |
| 44 | let D := Q.globalExtension m13 (Q.representativeIndex T) |
| 45 | let d := D.pushCylinder W.cylinder |
| 46 | refine ⟨d, ?_, ?_⟩ |
| 47 | · intro s hs ht x hx |
| 48 | change Q.globalIdentify (Q.representativeIndex T) |
| 49 | (T + s / (A.necks i).neck.scale⁻¹ ^ 2) |
| 50 | (W.cylinder.time_subset ⟨s, hs, rfl⟩) (W.cylinder.forward s hs x) = |
| 51 | (Q.globalEvent T hT).pre_identify |
| 52 | ⟨T + s / (A.necks i).neck.scale⁻¹ ^ 2, ht⟩ |
| 53 | ((Q.globalEvent T hT).limit_identify.inverse x) |
| 54 | rw [W.reference_compatibility s hs ht x hx, Q.globalEvent_pre_identify, |
| 55 | Q.globalEvent_limit_inverse, Diffeomorph.symm_apply_apply] |
| 56 | rfl |
| 57 | · have hcomparison : RoundCylinderFamilyClose (F0.parameters.delta T) |
| 58 | (Ioc (-1 : ℝ) 0) |
| 59 | (fun s => if s = 0 then |
| 60 | fun z v w => (A.necks i).neck.scale⁻¹ ^ 2 * |
| 61 | roundCylinderPullback A.limit_metric (A.necks i).neck.coordinate_map z v w |
| 62 | else surgeryCylinderPullback W.cylinder (A.necks i).neck.coordinate_map s) := by |
| 63 | have hdelta := congrArg (fun P : SurgeryParameters => P.delta T) |
| 64 | (Q.parameters_eq (Q.representativeIndex T)) |
| 65 | exact hdelta ▸ W.comparison |
| 66 | apply RoundCylinderFamilyClose.congr (B' := fun s => if s = 0 then |
| 67 | fun z v w => (A.necks i).neck.scale⁻¹ ^ 2 * |
| 68 | roundCylinderPullback A.limit_metric (A.necks i).neck.coordinate_map z v w |
| 69 | else surgeryCylinderPullback W.cylinder (A.necks i).neck.coordinate_map s) |
| 70 | ?_ hcomparison |
| 71 | intro s hs z hz v w |
| 72 | by_cases hs0 : s = 0 |
| 73 | · simp only [hs0] |
| 74 | rfl |
| 75 | · have hs' : s ∈ Ioo (-1 : ℝ) 0 := ⟨hs.1, lt_of_le_of_ne hs.2 hs0⟩ |
| 76 | have hz' : z.2 ∈ Ioo (-(A.necks i).neck.epsilon⁻¹) |
| 77 | (A.necks i).neck.epsilon⁻¹ := by |
| 78 | simpa only [A.neck_delta, Q.parameters_eq] using hz |
| 79 | have hcoord : (A.necks i).neck.coordinate_map z ∈ (A.necks i).neck.carrier := by |
| 80 | have h := (A.necks i).neck.coordinate_map_eq (z.1, ⟨z.2, hz'⟩) |
| 81 | exact h ▸ ((A.necks i).neck.coordinate (z.1, ⟨z.2, hz'⟩)).property |
| 82 | simp only [if_neg hs0, surgeryCylinderPullback, dif_pos hs'] |
| 83 | exact D.pushCylinder_pullbackInner W.cylinder |
| 84 | (A.necks i).neck.carrier_open s hs' _ hcoord _ _ |
| 85 | |
| 86 | end PoincareMT.M51.CompletedStageChain |