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.StandardCap.PersistenceGeometry |
| 2 | |
| 3 | /-! |
| 4 | # Restricting whole-ball removal to the requested tracked ball |
| 5 | |
| 6 | The positive collar sphere may require an auxiliary birth radius larger |
| 7 | than the requested radius. Both the actual cylinder and its disappearance |
| 8 | restrict to every smaller source region. Morgan--Tian, Claim 16.10 and |
| 9 | Proposition 16.5, pp. 374-375; M44 derivation 79. |
| 10 | -/ |
| 11 | |
| 12 | set_option autoImplicit false |
| 13 | |
| 14 | open Set |
| 15 | open scoped Manifold ContDiff |
| 16 | |
| 17 | universe u |
| 18 | |
| 19 | namespace PoincareMT.M44 |
| 20 | |
| 21 | /-- Restrict the original physical transport maps to a smaller |
| 22 | tracked birth region. Source: Proposition 16.5, pp. 374-375; |
| 23 | M44 derivation 79. -/ |
| 24 | def restrictCylinderSource |
| 25 | {F : SurgeryFlowData.{u}} {C : GeneralizedSliceCarrier.{u}} |
| 26 | {origin scale : ℝ} {I : Set ℝ} {U V : Set C.carrier} |
| 27 | (e : SurgeryFlowCylinder F C origin scale I U) (hVU : V ⊆ U) : |
| 28 | SurgeryFlowCylinder F C origin scale I V where |
| 29 | scale_pos := e.scale_pos |
| 30 | interval_connected := e.interval_connected |
| 31 | time_subset := e.time_subset |
| 32 | forward := e.forward |
| 33 | inverse := e.inverse |
| 34 | forward_smooth s hs := (e.forward_smooth s hs).mono hVU |
| 35 | inverse_smooth s hs := (e.inverse_smooth s hs).mono (image_mono hVU) |
| 36 | left_inverse s hs _ hx := e.left_inverse s hs (hVU hx) |
| 37 | right_inverse s hs _ hx := e.right_inverse s hs (image_mono hVU hx) |
| 38 | slab_compatibility a b hab hJ hNo s hs t ht hs' ht' x hx := |
| 39 | e.slab_compatibility a b hab hJ hNo s hs t ht hs' ht' x (hVU hx) |
| 40 | retained_at_surgery s hs hT _ hprev := |
| 41 | (image_mono hVU).trans (e.retained_at_surgery s hs hT hprev) |
| 42 | pre_retained_at_surgery s hs hT _ t ht ht' x hx := |
| 43 | e.pre_retained_at_surgery s hs hT t ht ht' x (hVU hx) |
| 44 | surgery_compatibility s hs hT _ t ht ht' x hx := |
| 45 | e.surgery_compatibility s hs hT t ht ht' x (hVU hx) |
| 46 | |
| 47 | /-- Whole-region disappearance passes to the restricted physical |
| 48 | cylinder without changing its times or transport maps. Source: |
| 49 | Claim 16.10, p. 375; M44 derivation 79. -/ |
| 50 | theorem disappears_restrict_source |
| 51 | {F : SurgeryFlowData.{u}} {origin scale tPlus : ℝ} {I : Set ℝ} |
| 52 | {U V : Set (F.slice origin).carrier} |
| 53 | {e : SurgeryFlowCylinder F (F.slice origin) origin scale I U} |
| 54 | (he : SurgeryBallDisappearsAt F e tPlus) (hVU : V ⊆ U) : |
| 55 | SurgeryBallDisappearsAt F (restrictCylinderSource e hVU) tPlus := by |
| 56 | rcases he with hempty | ⟨hT, hn, hinitial, s0, hs0, hlost⟩ |
| 57 | · exact Or.inl hempty |
| 58 | · refine Or.inr ⟨hT, hn, ?_, s0, hs0, ?_⟩ |
| 59 | · intro h x hx |
| 60 | exact hinitial h x (hVU hx) |
| 61 | · intro s hs hlate x hx ht |
| 62 | exact hlost s hs hlate x (hVU hx) ht |
| 63 | |
| 64 | end PoincareMT.M44 |