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.ReducedGeometry.ReducedVolume.Exponential.InitialTime.InitialActionContinuity |
| 2 | import PoincareLib.Geometry.RicciFlow.ReducedGeometry.ReducedVolume.Regularity.Continuity.MinimizingLifts |
| 3 | import PoincareLib.Geometry.RicciFlow.ReducedGeometry.ReducedVolume.Minimum.Compactness.ScalarBound |
| 4 | import Mathlib.Analysis.Calculus.Deriv.MeanValue |
| 5 | import Mathlib.Analysis.Calculus.Deriv.Pow |
| 6 | |
| 7 | /-! |
| 8 | # A uniform lower bound for actual reduced length |
| 9 | |
| 10 | Morgan-Tian Theorem 7.10 and Claim 7.11, pp. 154-156. The square-time |
| 11 | action plus the scalar-curvature correction is nondecreasing from zero. |
| 12 | The argument retains the actual kinetic term and needs no scalar-curvature |
| 13 | integrability assertion beyond the supplied action primitive. |
| 14 | -/ |
| 15 | |
| 16 | set_option autoImplicit false |
| 17 | |
| 18 | open Set |
| 19 | open scoped Manifold ContDiff Bundle |
| 20 | |
| 21 | universe u |
| 22 | |
| 23 | namespace PoincareMT.ReducedVolume |
| 24 | |
| 25 | variable {n : ℕ} {M : Type u} [TopologicalSpace M] |
| 26 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 27 | {J : Set ℝ} {F : RicciFlow n M J} {T τmax : ℝ} {p : M} |
| 28 | |
| 29 | /-- The scalar-corrected square-time action has its actual nonsingular derivative. -/ |
| 30 | theorem corrected_square_action_hasDerivAt (G : LExponentialGeometry F T τmax p) |
| 31 | (Z : TangentSpace (𝓡 n) p) (C : ℝ) {s : ℝ} (hs : 0 < s) (hmax : s ^ 2 < τmax) : |
| 32 | HasDerivAt (fun r : ℝ ↦ G.toLExponentialFamily.action Z (r ^ 2) + (2 * C / 3) * r ^ 3) |
| 33 | (2 * s ^ 2 * ((F.connection (T - s ^ 2)).scalarCurvature (G.gamma Z (s ^ 2)) + |
| 34 | (F.metric (T - s ^ 2)).inner (G.gamma Z (s ^ 2)) |
| 35 | (curveVelocity (G.gamma Z) (s ^ 2)) (curveVelocity (G.gamma Z) (s ^ 2)) + C)) s := by |
| 36 | have ha := (G.action_time_derivative Z (s ^ 2) (sq_pos_of_pos hs) hmax).comp s |
| 37 | (h := fun r : ℝ ↦ r ^ 2) |
| 38 | (hasDerivAt_pow 2 s) |
| 39 | have hc := (hasDerivAt_pow 3 s).const_mul (2 * C / 3) |
| 40 | apply (ha.add hc).congr_deriv |
| 41 | simp only [backwardLIntegrand, Real.sqrt_sq hs.le] |
| 42 | ring |
| 43 | |
| 44 | /-- A scalar lower bound controls the normalized action of every canonical ray. -/ |
| 45 | theorem normalized_action_lower_bound (G : LExponentialGeometry F T τmax p) |
| 46 | (Z : TangentSpace (𝓡 n) p) {τ C : ℝ} (hτ : 0 < τ) (hmax : τ < τmax) |
| 47 | (hR : ∀ s ∈ Icc 0 τ, ∀ q : M, -C ≤ (F.connection (T - s)).scalarCurvature q) : |
| 48 | -C * τ / 3 ≤ G.toLExponentialFamily.action Z τ / (2 * Real.sqrt τ) := by |
| 49 | let H := fun s : ℝ ↦ G.toLExponentialFamily.action Z (s ^ 2) + (2 * C / 3) * s ^ 3 |
| 50 | let D := fun s : ℝ ↦ 2 * s ^ 2 * |
| 51 | ((F.connection (T - s ^ 2)).scalarCurvature (G.gamma Z (s ^ 2)) + |
| 52 | (F.metric (T - s ^ 2)).inner (G.gamma Z (s ^ 2)) |
| 53 | (curveVelocity (G.gamma Z) (s ^ 2)) (curveVelocity (G.gamma Z) (s ^ 2)) + C) |
| 54 | have hc : ContinuousOn H (Icc 0 (Real.sqrt τ)) := by |
| 55 | apply ContinuousOn.add _ (by fun_prop) |
| 56 | apply (action_continuousOn_initial G Z hτ hmax).comp (by fun_prop) |
| 57 | intro s hs |
| 58 | exact ⟨sq_nonneg s, by nlinarith [Real.sq_sqrt hτ.le, hs.1, hs.2]⟩ |
| 59 | have hd (s : ℝ) (hs : s ∈ Ioo 0 (Real.sqrt τ)) : HasDerivAt H (D s) s := by |
| 60 | apply corrected_square_action_hasDerivAt G Z C hs.1 |
| 61 | have hsτ : s ^ 2 ≤ τ := by nlinarith [Real.sq_sqrt hτ.le, hs.1, hs.2] |
| 62 | exact hsτ.trans_lt hmax |
| 63 | have hnonneg (s : ℝ) (hs : s ∈ Ioo 0 (Real.sqrt τ)) : 0 ≤ D s := by |
| 64 | have hsτ : s ^ 2 ∈ Icc 0 τ := |
| 65 | ⟨sq_nonneg s, by nlinarith [Real.sq_sqrt hτ.le, hs.1, hs.2]⟩ |
| 66 | have hscalar := hR (s ^ 2) hsτ (G.gamma Z (s ^ 2)) |
| 67 | have hkinetic : 0 ≤ (F.metric (T - s ^ 2)).inner (G.gamma Z (s ^ 2)) |
| 68 | (curveVelocity (G.gamma Z) (s ^ 2)) (curveVelocity (G.gamma Z) (s ^ 2)) := by |
| 69 | by_cases hv : curveVelocity (n := n) (G.gamma Z) (s ^ 2) = 0 |
| 70 | · rw [hv, map_zero] |
| 71 | · exact ((F.metric (T - s ^ 2)).pos _ _ hv).le |
| 72 | exact mul_nonneg (mul_nonneg (by norm_num) (sq_nonneg s)) (by linarith) |
| 73 | have hm : MonotoneOn H (Icc 0 (Real.sqrt τ)) := |
| 74 | monotoneOn_of_hasDerivWithinAt_nonneg (convex_Icc _ _) hc |
| 75 | (fun s hs ↦ (hd s (by simpa only [interior_Icc] using hs)).hasDerivWithinAt) |
| 76 | (fun s hs ↦ hnonneg s (by simpa only [interior_Icc] using hs)) |
| 77 | have hzero : H 0 = 0 := by |
| 78 | simp only [H, zero_pow (by omega : (2 : ℕ) ≠ 0), zero_pow (by omega : (3 : ℕ) ≠ 0), |
| 79 | LExponentialFamily.action, backwardLLength, intervalIntegral.integral_same, |
| 80 | mul_zero, add_zero] |
| 81 | have hend : H (Real.sqrt τ) = |
| 82 | G.toLExponentialFamily.action Z τ + (2 * C / 3) * τ * Real.sqrt τ := by |
| 83 | dsimp only [H] |
| 84 | rw [Real.sq_sqrt hτ.le] |
| 85 | rw [show (Real.sqrt τ) ^ 3 = τ * Real.sqrt τ by |
| 86 | rw [pow_succ, Real.sq_sqrt hτ.le]] |
| 87 | ring |
| 88 | have hbound := hm (left_mem_Icc.mpr (Real.sqrt_nonneg τ)) |
| 89 | (right_mem_Icc.mpr (Real.sqrt_nonneg τ)) (Real.sqrt_nonneg τ) |
| 90 | rw [hzero, hend] at hbound |
| 91 | apply (le_div_iff₀ (mul_pos (by norm_num) (Real.sqrt_pos.2 hτ))).mpr |
| 92 | nlinarith only [hbound] |
| 93 | |
| 94 | variable [ConnectedSpace M] [T3Space M] |
| 95 | |
| 96 | /-- One produced constant bounds reduced length from below at every endpoint and interior time. -/ |
| 97 | theorem exists_uniform_reducedLength_lower_bound |
| 98 | (hL : LGeodesicTheory F T τmax) (G : LExponentialGeometry F T τmax p) |
| 99 | (hcurvature : CompleteBoundedCurvatureOn F (Icc (T - τmax) T)) : |
| 100 | ∃ C : ℝ, 0 ≤ C ∧ ∀ τ : ℝ, 0 < τ → τ < τmax → ∀ q : M, |
| 101 | -C * τ / 3 ≤ reducedLength F T p q τ := by |
| 102 | obtain ⟨C, hC, hbound⟩ := exists_uniform_scalarCurvature_bound F hcurvature |
| 103 | refine ⟨C, hC, ?_⟩ |
| 104 | intro τ hτ hmax q |
| 105 | obtain ⟨Z, _, _, haction⟩ := exists_minimizing_lift hL G q τ hτ hmax |
| 106 | rw [haction] |
| 107 | apply normalized_action_lower_bound G Z hτ hmax |
| 108 | intro s hs y |
| 109 | have ht : T - s ∈ Icc (T - τmax) T := ⟨by linarith [hs.2], by linarith [hs.1]⟩ |
| 110 | exact (abs_le.mp (hbound (T - s) ht y)).1 |
| 111 | |
| 112 | end PoincareMT.ReducedVolume |