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.Blowup.Construction.LongTime.GeneralizedLimit.GeneralizedCompactImages |
| 2 | import PoincareLib.Geometry.RicciFlow.Blowup.Construction.LongTime.GeneralizedLimit.GeneralizedScalarConvergence |
| 3 | import PoincareLib.Geometry.RicciFlow.Blowup.Construction.LongTime.FiniteSlab.FiniteHarnack |
| 4 | |
| 5 | /-! |
| 6 | # One terminal scalar coefficient for every extracted limit |
| 7 | |
| 8 | A fixed source bound on all terminal balls passes to any extracted limit. |
| 9 | Finite Harnack then controls its strict time prefixes using that same |
| 10 | coefficient. This keeps the constants uniform when horizons approach their |
| 11 | supremum in Theorem 11.8 (Claim 11.12, pp. 273--274). |
| 12 | -/ |
| 13 | |
| 14 | set_option autoImplicit false |
| 15 | |
| 16 | open Set Filter |
| 17 | open scoped Manifold ContDiff Bundle ENNReal Topology |
| 18 | |
| 19 | universe u |
| 20 | |
| 21 | namespace PoincareMT.M30 |
| 22 | |
| 23 | attribute [local instance] FlowCarrier.topologicalSpace FlowCarrier.chartedSpace |
| 24 | FlowCarrier.isManifold FlowCarrier.t2Space FlowCarrier.t3Space FlowCarrier.secondCountable |
| 25 | |
| 26 | /-- A fixed eventual source scalar bound at zero passes to every point of |
| 27 | any retained limit, independently of the choice of subsequence. -/ |
| 28 | theorem generalized_limit_terminal_scalar_le |
| 29 | {S : GeneralizedBlowupSequence.{u}} {J : Set ℝ} {B : ℝ} |
| 30 | (G : GeneralizedBlowupConvergence S J) |
| 31 | (hbound : ∀ A : ℝ, 0 < A → ∀ᶠ k : ℕ in atTop, |
| 32 | ∀ x ∈ S.baseBall k A, (S.flow k).scalar ⟨(S.base k).1, x⟩ ≤ B * S.scale k) : |
| 33 | ∀ x, (G.limit.flow.connection 0).scalarCurvature x ≤ B := by |
| 34 | intro x |
| 35 | by_contra h |
| 36 | have hgap : 0 < ((G.limit.flow.connection 0).scalarCurvature x - B) / 2 := |
| 37 | half_pos (sub_pos.mpr (lt_of_not_ge h)) |
| 38 | obtain ⟨A, hA, hcapture⟩ := |
| 39 | exists_eventually_generalized_terminal_image_baseBall G |
| 40 | (isCompact_singleton (x := x)) |
| 41 | have herr := eventually_generalized_scalar_error G isCompact_singleton |
| 42 | (singleton_subset_iff.mpr G.limit.zero_mem) (isCompact_singleton (x := x)) hgap |
| 43 | obtain ⟨k, hkcap, hkerr, hkbound⟩ := |
| 44 | (hcapture.and (herr.and |
| 45 | (G.subsequence_strictMono.tendsto_atTop.eventually (hbound A hA)))).exists |
| 46 | have hzero := hkerr.1 (mem_singleton (0 : ℝ)) |
| 47 | obtain ⟨y, hy, hpoint⟩ := hkcap x (mem_singleton x) |
| 48 | have herror := hkerr.2.2 0 (mem_singleton 0) hzero x (mem_singleton x) |
| 49 | rw [hpoint hzero] at herror |
| 50 | have hscalar := (div_le_iff₀ (S.base_scalar_pos (G.subsequence k))).mpr (hkbound y hy) |
| 51 | change (S.flow (G.subsequence k)).scalar ⟨(S.base (G.subsequence k)).1, y⟩ / |
| 52 | S.scale (G.subsequence k) ≤ B at hscalar |
| 53 | have hlow := (abs_lt.mp herror).1 |
| 54 | linarith |
| 55 | |
| 56 | /-- The curvature coefficient of the initial short source family gives one |
| 57 | terminal scalar coefficient for every later finite extraction. -/ |
| 58 | theorem generalized_limit_terminal_scalar_le_of_short_controls |
| 59 | {S : GeneralizedBlowupSequence.{u}} {J : Set ℝ} {kappa r0 : ℝ} |
| 60 | (H : ShortControlledBlowupHypotheses S kappa r0) |
| 61 | (G : GeneralizedBlowupConvergence S J) : |
| 62 | ∀ x, (G.limit.flow.connection 0).scalarCurvature x ≤ 9 * H.curvature_bound := by |
| 63 | apply generalized_limit_terminal_scalar_le G |
| 64 | intro A hA |
| 65 | filter_upwards [H.cylinders A hA 1 zero_lt_one] with k hk |
| 66 | obtain ⟨E⟩ := hk |
| 67 | intro x hx |
| 68 | have hzero : (0 : ℝ) ∈ Icc (-H.backward_time) 0 := |
| 69 | ⟨neg_nonpos.mpr H.backward_time_pos.le, le_rfl⟩ |
| 70 | have hcurv := E.curvature_bound 0 hzero x hx |
| 71 | rw [E.zero_identity hzero x hx] at hcurv |
| 72 | have hscalar := (le_abs_self _).trans |
| 73 | (((S.flow k).connection (S.base k).1).abs_scalarCurvature_le_curvatureTensorNorm x) |
| 74 | have hnorm : ((S.flow k).connection (S.base k).1).curvatureTensorNorm x ≤ |
| 75 | H.curvature_bound * S.scale k := (le_abs_self _).trans hcurv |
| 76 | norm_num only [Nat.cast_ofNat, sq] at hscalar |
| 77 | exact hscalar.trans (by nlinarith [S.base_scalar_pos k]) |
| 78 | |
| 79 | /-- Finite Harnack with a prescribed terminal coefficient, so the same |
| 80 | coefficient can be used for distinct extractions (Claim 11.12, pp. 273--274). -/ |
| 81 | theorem finite_limit_scalar_le_of_terminal_bound |
| 82 | (hC : RicciFlowCurvatureTheory.{u}) (hH : HarnackAncientTheory.{u}) |
| 83 | {T B : ℝ} (L : BlowupLimitFlow.{u} (Ioc (-T) 0)) |
| 84 | (hterminal : ∀ x, (L.flow.connection 0).scalarCurvature x ≤ B) : |
| 85 | ∀ t ∈ Ioc (-T) 0, ∀ x, |
| 86 | (L.flow.connection t).scalarCurvature x ≤ B * T / (t + T) := by |
| 87 | have hT : 0 < T := by linarith [L.zero_mem.1] |
| 88 | have hbounded (t : ℝ) (ht : t ∈ Ioc (-T) 0) : |
| 89 | ∃ K : ℝ, 0 ≤ K ∧ ∀ x, (L.flow.connection t).curvatureTensorNorm x ≤ K := by |
| 90 | obtain ⟨K, hK, hnorm⟩ := L.curvature_locally_bounded_in_time {t} |
| 91 | isCompact_singleton (singleton_subset_iff.mpr ht) |
| 92 | exact ⟨K, hK, fun x => (le_abs_self _).trans (hnorm t (mem_singleton t) x)⟩ |
| 93 | intro t ht x |
| 94 | have hmono := monotoneOn_weighted_scalar_on_Ioc hC hH |
| 95 | (show -T < 0 by linarith) L.flow L.complete |
| 96 | L.nonnegative_curvature_operator hbounded x ht L.zero_mem ht.2 |
| 97 | have hweight := mul_le_mul_of_nonneg_left (hterminal x) hT.le |
| 98 | apply (le_div_iff₀ (show 0 < t + T by linarith [ht.1])).mpr |
| 99 | simp only [sub_neg_eq_add, zero_add] at hmono |
| 100 | nlinarith |
| 101 | |
| 102 | end PoincareMT.M30 |