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.Noncollapse.Assembly.Configuration |
| 2 | |
| 3 | /-! |
| 4 | # The auxiliary test radius in Proposition 16.1 |
| 5 | |
| 6 | Morgan--Tian Lemma 11.2, pp. 268-269, and Proposition 16.1, |
| 7 | pp. 367-368. The guarded scalar estimates give a spatial radius r/(8B) |
| 8 | and a backward time r^2/(64B). A smaller radius fits both domains and |
| 9 | absorbs the factor 52 in the full-curvature estimate. |
| 10 | -/ |
| 11 | |
| 12 | set_option autoImplicit false |
| 13 | |
| 14 | namespace PoincareMT.Proofs.M46 |
| 15 | |
| 16 | /-- B is fixed from the canonical derivative constant before r is chosen. -/ |
| 17 | noncomputable def smallTestRadius (B r : ℝ) : ℝ := r / (32 * B) |
| 18 | |
| 19 | /-- The auxiliary radius is positive for every allowed next scale. -/ |
| 20 | theorem smallTestRadius_pos {B r : ℝ} (hB : 1 ≤ B) (hr : 0 < r) : |
| 21 | 0 < smallTestRadius B r := |
| 22 | div_pos hr (mul_pos (by norm_num) (zero_lt_one.trans_le hB)) |
| 23 | |
| 24 | /-- The auxiliary test remains below the actual surgery scale. -/ |
| 25 | theorem smallTestRadius_le {B r : ℝ} (hB : 1 ≤ B) (hr : 0 < r) : |
| 26 | smallTestRadius B r ≤ r := by |
| 27 | unfold smallTestRadius |
| 28 | apply (div_le_iff₀ (by positivity : 0 < 32 * B)).mpr |
| 29 | nlinarith |
| 30 | |
| 31 | /-- The terminal radius-2rho ball fits strictly inside the spatial |
| 32 | scalar-doubling ball. -/ |
| 33 | theorem twice_smallTestRadius_le {B r : ℝ} (hB : 1 ≤ B) (hr : 0 < r) : |
| 34 | 2 * smallTestRadius B r ≤ r / (8 * B) := by |
| 35 | have hBpos : 0 < B := zero_lt_one.trans_le hB |
| 36 | unfold smallTestRadius |
| 37 | field_simp |
| 38 | nlinarith |
| 39 | |
| 40 | /-- The closed backward interval fits inside the scalar-control interval. -/ |
| 41 | theorem smallTestRadius_sq_le {B r : ℝ} (hB : 1 ≤ B) (hr : 0 < r) : |
| 42 | smallTestRadius B r ^ 2 ≤ r ^ 2 / (64 * B) := by |
| 43 | have hBpos : 0 < B := zero_lt_one.trans_le hB |
| 44 | unfold smallTestRadius |
| 45 | apply (le_div_iff₀ (by positivity : 0 < 64 * B)).mpr |
| 46 | field_simp |
| 47 | nlinarith [sq_nonneg r, mul_nonneg (sq_nonneg r) (sub_nonneg.mpr hB)] |
| 48 | |
| 49 | /-- The pinched full-curvature ceiling becomes rho^-2. -/ |
| 50 | theorem fifty_two_inv_sq_le_smallTestRadius_inv_sq {B r : ℝ} |
| 51 | (hB : 1 ≤ B) (hr : 0 < r) : |
| 52 | 52 * r⁻¹ ^ 2 ≤ (smallTestRadius B r)⁻¹ ^ 2 := by |
| 53 | have hBsq : 1 ≤ B ^ 2 := one_le_pow₀ hB |
| 54 | have hi : 0 ≤ r⁻¹ ^ 2 := (sq_pos_of_pos (inv_pos.mpr hr)).le |
| 55 | have hmul := mul_le_mul_of_nonneg_right hBsq hi |
| 56 | have hinv : (smallTestRadius B r)⁻¹ = 32 * B * r⁻¹ := by |
| 57 | simp [smallTestRadius, div_eq_mul_inv] |
| 58 | rw [hinv, mul_pow, mul_pow] |
| 59 | nlinarith only [hi, hmul] |
| 60 | |
| 61 | end PoincareMT.Proofs.M46 |