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.Uniqueness.Imports |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.StandardCap.Uniqueness.RawFlow.IntrinsicSlopeEquation |
| 3 | import PoincareLib.Geometry.RicciFlow.Surgery.StandardCap.Uniqueness.RawFlow.RawRadialVelocityBound |
| 4 | import PoincareLib.Geometry.RicciFlow.ReducedGeometry.ReducedVolume.Minimum.Compactness.ScalarBound |
| 5 | |
| 6 | /-! |
| 7 | # Actual bounded coefficients of the radial-slope equation |
| 8 | |
| 9 | Morgan-Tian Section 12.6, pp. 309-314. Complete nonnegative raw geometry |
| 10 | bounds the slope between zero and one. Its reaction is tangential |
| 11 | sectional curvature away from the tip, bounded using the actual scalar |
| 12 | trace and the supplied raw slab curvature bound. |
| 13 | -/ |
| 14 | |
| 15 | set_option autoImplicit false |
| 16 | |
| 17 | open Set |
| 18 | open scoped Manifold ContDiff Bundle |
| 19 | |
| 20 | namespace PoincareMT.M35.Uniqueness |
| 21 | |
| 22 | variable (P : RicciFlowCurvatureTheory.{0}) {g₀ : StandardInitialMetric} |
| 23 | (G : PartialStandardCapFlow g₀) |
| 24 | (hrotation : ∀ t ∈ Ico 0 G.lifetime, |
| 25 | ∀ A : Matrix.specialOrthogonalGroup (Fin 3) ℝ, ∀ x u v : StandardCapSpace, |
| 26 | (G.flow.metric t).inner (standardRotation A x) |
| 27 | (mfderiv (𝓡 3) (𝓡 3) (standardRotation A) x u) |
| 28 | (mfderiv (𝓡 3) (𝓡 3) (standardRotation A) x v) = (G.flow.metric t).inner x u v) |
| 29 | |
| 30 | theorem rawWarpingSlope_zero {t : ℝ} (ht : t ∈ Ico 0 G.lifetime) : |
| 31 | rawWarpingSlope P G hrotation t 0 = 1 := by |
| 32 | unfold rawWarpingSlope |
| 33 | rw [rawWarpingRadius_eq P G hrotation ht] |
| 34 | exact (intrinsicWarpingRadius_hasDerivAt_zero (G.flow.metric t) (hrotation t ht) |
| 35 | (G.complete P ht)).deriv |
| 36 | |
| 37 | theorem rawWarpingSlope_bounds {t s : ℝ} (ht : t ∈ Ico 0 G.lifetime) (hs : 0 ≤ s) : |
| 38 | rawWarpingSlope P G hrotation t s ∈ Icc 0 1 := by |
| 39 | rcases hs.eq_or_lt with rfl | hs |
| 40 | · rw [rawWarpingSlope_zero P G hrotation ht] |
| 41 | exact ⟨zero_le_one, le_rfl⟩ |
| 42 | have hr := rawInverseRadius_pos P G hrotation ht hs |
| 43 | have hsec := raw_nonnegative_sectional P G ht |
| 44 | change deriv (rawWarpingRadius P G hrotation t) s ∈ Icc 0 1 |
| 45 | rw [(rawWarpingRadius_hasDerivAt P G hrotation ht hs).deriv] |
| 46 | exact ⟨axisWarpingSlope_nonneg (G.flow.connection t) (hrotation t ht) hsec (G.complete P ht) hr, |
| 47 | axisWarpingSlope_le_one (G.flow.connection t) (hrotation t ht) hsec hr⟩ |
| 48 | |
| 49 | theorem rawWarpingSlope_deriv_nonpos {t s : ℝ} (ht : t ∈ Ico 0 G.lifetime) (hs : 0 < s) : |
| 50 | deriv (rawWarpingSlope P G hrotation t) s ≤ 0 := by |
| 51 | change deriv (deriv (rawWarpingRadius P G hrotation t)) s ≤ 0 |
| 52 | rw [(rawWarpingRadius_deriv_hasDerivAt P G hrotation ht hs).deriv] |
| 53 | exact axisWarpingSecond_nonpos (G.flow.connection t) (hrotation t ht) |
| 54 | (raw_nonnegative_sectional P G ht) (rawInverseRadius_pos P G hrotation ht hs) |
| 55 | |
| 56 | /-- One uniform upper bound for the actual reaction on a closed raw slab. |
| 57 | The harmless totalized value at zero is unused by the interior PDE. -/ |
| 58 | theorem rawTangentialCurvature_bounds {T K : ℝ} (hK : 0 ≤ K) |
| 59 | (hTlt : T < G.lifetime) |
| 60 | (hbound : ∀ t ∈ Icc 0 T, ∀ x, (G.flow.connection t).curvatureTensorNorm x ≤ K) |
| 61 | {t s : ℝ} (ht : t ∈ Icc 0 T) (hs : 0 ≤ s) : |
| 62 | rawTangentialCurvature P G hrotation t s ∈ Icc 0 (9 * K) := by |
| 63 | have htG : t ∈ Ico 0 G.lifetime := ⟨ht.1, ht.2.trans_lt hTlt⟩ |
| 64 | rcases hs.eq_or_lt with rfl | hs |
| 65 | · have hf0 : rawWarpingRadius P G hrotation t 0 = 0 := by |
| 66 | rw [rawWarpingRadius_eq P G hrotation htG] |
| 67 | exact intrinsicWarpingRadius_zero (G.flow.metric t) (hrotation t htG) (G.complete P htG) |
| 68 | simp only [rawTangentialCurvature, hf0, zero_pow (by norm_num : (2 : ℕ) ≠ 0), div_zero, |
| 69 | mem_Icc, le_refl, true_and] |
| 70 | positivity |
| 71 | have hp := rawWarpingSlope_bounds P G hrotation htG hs.le |
| 72 | have hf : 0 < rawWarpingRadius P G hrotation t s := by |
| 73 | rw [rawWarpingRadius_eq P G hrotation htG] |
| 74 | exact intrinsicWarpingRadius_pos (G.flow.metric t) (hrotation t htG) (G.complete P htG) hs |
| 75 | have hreaction : 0 ≤ rawTangentialCurvature P G hrotation t s := by |
| 76 | apply div_nonneg _ (sq_nonneg _) |
| 77 | nlinarith only [hp.1, hp.2] |
| 78 | have hsecond := rawWarpingSlope_deriv_nonpos P G hrotation htG hs |
| 79 | let x : StandardCapSpace := (radialArclengthOrderIso (G.flow.metric t) (hrotation t htG) |
| 80 | (G.complete P htG)).symm s • EuclideanSpace.single (2 : Fin 3) 1 |
| 81 | have hscalar := M10.abs_scalarCurvature_le (G.flow.metric t) (G.flow.connection t) x |
| 82 | norm_num at hscalar |
| 83 | have hscalarBound : (G.flow.connection t).scalarCurvature x ≤ 9 * K := by |
| 84 | have hcurv := hbound t ht x |
| 85 | linarith [le_abs_self ((G.flow.connection t).scalarCurvature x)] |
| 86 | have hformula := rotational_scalar_eq_intrinsicWarping (G.flow.metric t) |
| 87 | (hrotation t htG) (G.complete P htG) (G.flow.connection t) hs |
| 88 | rw [← rawWarpingRadius_eq P G hrotation htG] at hformula |
| 89 | have hformula' : (G.flow.connection t).scalarCurvature x = |
| 90 | 2 * rawTangentialCurvature P G hrotation t s - |
| 91 | 4 * deriv (rawWarpingSlope P G hrotation t) s / rawWarpingRadius P G hrotation t s := by |
| 92 | change (G.flow.connection t).scalarCurvature x = |
| 93 | 2 * ((1 - deriv (rawWarpingRadius P G hrotation t) s ^ 2) / |
| 94 | rawWarpingRadius P G hrotation t s ^ 2) - |
| 95 | 4 * deriv (deriv (rawWarpingRadius P G hrotation t)) s / rawWarpingRadius P G hrotation t s |
| 96 | rw [hformula] |
| 97 | ring |
| 98 | have hterm : 4 * deriv (rawWarpingSlope P G hrotation t) s / |
| 99 | rawWarpingRadius P G hrotation t s ≤ 0 := |
| 100 | div_nonpos_of_nonpos_of_nonneg (mul_nonpos_of_nonneg_of_nonpos (by norm_num) hsecond) hf.le |
| 101 | exact ⟨hreaction, by linarith⟩ |
| 102 | |
| 103 | end PoincareMT.M35.Uniqueness |