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.PartialLimits.RetainedCurvatureBounds |
| 2 | import PoincareLib.Geometry.RicciFlow.Blowup.Construction.PartialLimits.RetainedMixedBounds |
| 3 | import PoincareLib.Geometry.RicciFlow.Blowup.Construction.PartialLimits.RetainedExtension |
| 4 | import PoincareLib.Geometry.RicciFlow.Harnack.Regularity |
| 5 | |
| 6 | /-! |
| 7 | # Finite terminal extension from larger-window bounds |
| 8 | |
| 9 | The actual larger source flows supply retained curvature derivatives, |
| 10 | closed mixed coefficient bounds, and an actual closed flow on the same |
| 11 | limit carrier. Restriction preserves the total source metric and |
| 12 | connection, so the final jets use the original source functions. |
| 13 | |
| 14 | Reference: Morgan--Tian Definition 5.12, Proposition 5.14 and Theorem |
| 15 | 5.15, pp. 90-91, used on the Theorem 11.8 route, pp. 272-279. The two |
| 16 | lower analytic services and larger-window geometric bounds are inputs. |
| 17 | -/ |
| 18 | |
| 19 | set_option autoImplicit false |
| 20 | set_option backward.isDefEq.respectTransparency false |
| 21 | |
| 22 | open Set Filter |
| 23 | open scoped Manifold ContDiff Bundle Topology |
| 24 | |
| 25 | namespace PoincareMT.M30 |
| 26 | |
| 27 | attribute [local instance] FlowCarrier.topologicalSpace FlowCarrier.chartedSpace |
| 28 | FlowCarrier.isManifold FlowCarrier.t2Space FlowCarrier.t3Space |
| 29 | FlowCarrier.secondCountable |
| 30 | |
| 31 | set_option synthInstance.maxHeartbeats 100000 in |
| 32 | -- The closed bilinear jets retain the dependent source-carrier instances. |
| 33 | /-- Larger-window curvature and compact-ball bounds produce the actual |
| 34 | retained closed flow and its original full-domain jets |
| 35 | (Proposition 5.14 and Theorem 5.15, pp. 90-91). -/ |
| 36 | theorem exists_finite_terminal_extension_of_big_window_bounds |
| 37 | (hShi : LocalCurvatureDerivativeEstimates.{0}) |
| 38 | (hMixed : WithinFlowJetBoundsService.{0, 0}) |
| 39 | (hFlow : WithinBilinearFlowService.{0}) |
| 40 | {T Tbig tau B : ℝ} (htau : 0 < tau) (htauT : tau < T) |
| 41 | (hT1 : T ≤ 1) (hTT : T < Tbig) |
| 42 | {S : PointedFlowSequence 3 (-T / 2) (T / 2)} |
| 43 | (G : PointedGeometricConvergence S) |
| 44 | (hcomplete : G.limitCarrier.metricComplete (G.limitFlow.metricAt 0)) |
| 45 | (Fbig : ∀ k, RicciFlow 3 (S.carrier k).carrier (Icc (-Tbig) 0)) |
| 46 | (hmetric : ∀ k t, (Fbig k).metric t = |
| 47 | (S.flow k).flow.metric (t + T / 2)) |
| 48 | (hcurv : ∀ᶠ k : ℕ in atTop, ∀ t ∈ Icc (-Tbig) 0, |
| 49 | ∀ x : (S.carrier k).carrier, |
| 50 | ((Fbig k).connection t).curvatureTensorNorm x ≤ B) |
| 51 | (hcompact : ∀ R : ℝ, 0 < R → ∀ᶠ k : ℕ in atTop, |
| 52 | IsCompact (closure (((Fbig k).metric 0).ball (S.flow k).base R))) : |
| 53 | let f := fun (q : G.limitCarrier.carrier) (k : ℕ) |
| 54 | (z : ℝ × EuclideanSpace ℝ (Fin 3)) => |
| 55 | ((Fbig (G.subsequence k)).metric z.1).pullbackCoefficients |
| 56 | ((fun y => ((G.embedding k).toFun (0, y)).2) ∘ |
| 57 | (extChartAt (𝓡 3) q).symm) z.2 |
| 58 | ∃ F : RicciFlow 3 G.limitCarrier.carrier (Icc (-tau) 0), |
| 59 | (∀ t ∈ Ico (-tau) 0, |
| 60 | F.metric t = G.limitFlow.flow.metric (t + T / 2)) ∧ |
| 61 | ∀ (q : G.limitCarrier.carrier) (m : ℕ) |
| 62 | (K : Set (ℝ × EuclideanSpace ℝ (Fin 3))), |
| 63 | IsCompact K → K ⊆ Icc (-tau) 0 ×ˢ (extChartAt (𝓡 3) q).target → |
| 64 | TendstoUniformlyOn |
| 65 | (fun k => iteratedFDerivWithin ℝ m (f q k) |
| 66 | (Icc (-tau) 0 ×ˢ (extChartAt (𝓡 3) q).target)) |
| 67 | (iteratedFDerivWithin ℝ m |
| 68 | (fun z : ℝ × EuclideanSpace ℝ (Fin 3) => |
| 69 | (F.metric z.1).pullbackCoefficients (extChartAt (𝓡 3) q).symm z.2) |
| 70 | (Icc (-tau) 0 ×ˢ (extChartAt (𝓡 3) q).target)) atTop K := by |
| 71 | intro f |
| 72 | have hT : 0 < T := htau.trans htauT |
| 73 | have hsmall : Icc (-T) (0 : ℝ) ⊆ Icc (-Tbig) 0 := by |
| 74 | intro t ht |
| 75 | exact ⟨by linarith [ht.1], ht.2⟩ |
| 76 | have hne : (Icc (-T) (0 : ℝ)).Nontrivial := |
| 77 | ⟨-T, ⟨le_rfl, by linarith⟩, 0, ⟨by linarith, le_rfl⟩, by linarith⟩ |
| 78 | let Fsrc (k : ℕ) : RicciFlow 3 (S.carrier k).carrier (Icc (-T) 0) := |
| 79 | Poincare.Geometry.RicciFlow.Harnack.restrictFlow (Fbig k) hsmall ordConnected_Icc hne |
| 80 | have hm : ∀ k t, (Fsrc k).metric t = (S.flow k).flow.metric (t + T / 2) := hmetric |
| 81 | have href (k : ℕ) : (Fbig k).metric (-T / 2) = (S.flow k).metricAt 0 := by |
| 82 | change (Fbig k).metric (-T / 2) = (S.flow k).flow.metric 0 |
| 83 | rw [hmetric] |
| 84 | congr 1 |
| 85 | ring |
| 86 | apply exists_finite_terminal_extension_on_retained_carrier hFlow htau htauT G Fsrc hm |
| 87 | apply exists_retained_local_coefficient_bounds hMixed htau htauT hT1 G Fsrc hm |
| 88 | intro q K hK hKc j |
| 89 | have himage := hK.image_of_continuousOn |
| 90 | ((contMDiffOn_extChartAt_symm (n := ∞) q).continuousOn.mono hKc) |
| 91 | obtain ⟨D, hD, hbound⟩ := exists_eventually_retained_curvature_derivative_bound |
| 92 | hShi hT hTT G hcomplete Fbig href hcurv hcompact himage j |
| 93 | refine ⟨D, hD.le, ?_⟩ |
| 94 | filter_upwards [hbound] with k hk t ht x hx |
| 95 | exact hk t ht ((extChartAt (𝓡 3) q).symm x) (mem_image_of_mem _ hx) |
| 96 | |
| 97 | end PoincareMT.M30 |