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.Extinction.Width.Transport.EventWidthTransport |
| 2 | |
| 3 | set_option autoImplicit false |
| 4 | |
| 5 | namespace PoincareMT |
| 6 | |
| 7 | /-! A surgery estimate with arbitrarily small multiplicative loss has no jump. -/ |
| 8 | theorem le_of_factor_sq_mul_forall_eta {v w : ℝ} (hw : 0 ≤ w) |
| 9 | (h : ∀ eta : ℝ, 0 < eta → v ≤ (1 + eta) ^ 2 * w) : |
| 10 | v ≤ w := by |
| 11 | apply le_of_forall_pos_le_add |
| 12 | intro epsilon hepsilon |
| 13 | by_cases hbig : 4 * (w + 1) ≤ epsilon |
| 14 | · have h1 := h 1 zero_lt_one |
| 15 | nlinarith |
| 16 | · have hsmall : epsilon < 4 * (w + 1) := lt_of_not_ge hbig |
| 17 | have hden : 0 < 4 * (w + 1) := by nlinarith |
| 18 | let eta : ℝ := epsilon / (4 * (w + 1)) |
| 19 | have heta : 0 < eta := by |
| 20 | dsimp [eta] |
| 21 | exact div_pos hepsilon hden |
| 22 | have heta_le : eta ≤ 1 := by |
| 23 | dsimp [eta] |
| 24 | apply (div_le_iff₀ hden).2 |
| 25 | simpa using hsmall.le |
| 26 | have hηsq : eta ^ 2 ≤ eta := by nlinarith [sq_nonneg (eta - 1)] |
| 27 | have heq : 4 * eta * (w + 1) = epsilon := by |
| 28 | dsimp [eta] |
| 29 | field_simp |
| 30 | have hηw : 0 ≤ eta * w := mul_nonneg heta.le hw |
| 31 | have hbound := h eta heta |
| 32 | nlinarith |
| 33 | |
| 34 | end PoincareMT |