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.Existence.Construction.Curvature.PositiveScalarComparison |
| 2 | |
| 3 | /-! |
| 4 | # A universal finite lifetime for partial cap flows |
| 5 | |
| 6 | At one explicit time before the positive scalar barrier's pole, that |
| 7 | barrier exceeds the scalar bound of a hypothetical longer partial flow. |
| 8 | The resulting finite bound is chosen before the partial flow and supplies |
| 9 | the chain/Zorn construction. It is not the sharp unit-lifetime conclusion |
| 10 | (Morgan-Tian Theorem 12.5, pp. 296-297). |
| 11 | -/ |
| 12 | |
| 13 | set_option autoImplicit false |
| 14 | |
| 15 | open Set |
| 16 | |
| 17 | namespace PoincareMT.M34 |
| 18 | |
| 19 | /-- Every partial cap flow has lifetime bounded by the pole of the |
| 20 | positive scalar barrier of its supplied initial metric |
| 21 | (Theorem 12.5, pp. 296-297). -/ |
| 22 | theorem partialFlow_lifetime_le_scalar_bound (P : RicciFlowCurvatureTheory.{0}) |
| 23 | {g0 : StandardInitialMetric} (E0 : StandardCapEstimate g0) |
| 24 | (F : PartialStandardCapFlow g0) : |
| 25 | F.lifetime ≤ 3 / (2 * E0.scalar_constant⁻¹) := by |
| 26 | let a := E0.scalar_constant⁻¹ |
| 27 | have ha : 0 < a := inv_pos.mpr E0.scalar_constant_pos |
| 28 | let B := 3 / (2 * a) |
| 29 | have hB : 0 < B := div_pos (by norm_num) (mul_pos (by norm_num) ha) |
| 30 | by_contra hno |
| 31 | have hBF : B < F.lifetime := lt_of_not_ge hno |
| 32 | obtain ⟨K, hK, hfull⟩ := F.curvature_locally_bounded B hB.le hBF |
| 33 | let M := 9 * K |
| 34 | have hM : 0 ≤ M := mul_nonneg (by norm_num) hK |
| 35 | have hden : 0 < a + M + 1 := by positivity |
| 36 | let t := B * (M + 1) / (a + M + 1) |
| 37 | have ht : 0 < t := div_pos (mul_pos hB (by positivity)) hden |
| 38 | have htB : t < B := by |
| 39 | apply (div_lt_iff₀ hden).mpr |
| 40 | exact mul_lt_mul_of_pos_left (by linarith) hB |
| 41 | have hcancel : (2 * a / 3) * B = 1 := by |
| 42 | dsimp [B] |
| 43 | field_simp |
| 44 | have hsmall : (2 * a / 3) * t < 1 := by |
| 45 | exact (mul_lt_mul_of_pos_left htB (by positivity)).trans_eq hcancel |
| 46 | have hdeneq : 1 - (2 * a / 3) * t = a / (a + M + 1) := by |
| 47 | dsimp only [t, B] |
| 48 | field_simp [ne_of_gt ha, ne_of_gt hden] |
| 49 | ring |
| 50 | have hvalue : a / (1 - (2 * a / 3) * t) = a + M + 1 := by |
| 51 | rw [hdeneq] |
| 52 | field_simp [ne_of_gt ha] |
| 53 | have hcomp := partialFlow_positive_scalar_comparison P E0 F ha ht (htB.trans hBF) |
| 54 | hsmall (fun x => (E0.scalar_bounds x).1) t ⟨ht.le, le_rfl⟩ 0 |
| 55 | rw [hvalue] at hcomp |
| 56 | have hscalar := M10.abs_scalarCurvature_le (F.flow.metric t) (F.flow.connection t) 0 |
| 57 | norm_num only [Nat.cast_ofNat, show (3 : ℝ) ^ 2 = 9 by norm_num] at hscalar |
| 58 | have hupper : (F.flow.connection t).scalarCurvature 0 ≤ M := |
| 59 | (le_abs_self _).trans (hscalar.trans (mul_le_mul_of_nonneg_left |
| 60 | ((le_abs_self _).trans (hfull t ⟨ht.le, htB.le⟩ 0)) (by norm_num))) |
| 61 | linarith |
| 62 | |
| 63 | end PoincareMT.M34 |