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.Generalized.BoundedDistance.Spacetime.StrongNecks.Curvature.StrongNeckCurvatureOperator |
| 2 | import Mathlib.Topology.UniformSpace.UniformConvergence |
| 3 | |
| 4 | /-! |
| 5 | # Uniform two-jet and full-curvature readout |
| 6 | |
| 7 | Parameterized spatial jets retain uniform convergence when assembled into |
| 8 | the actual metric two-jet. The promoted finite curvature operator then |
| 9 | gives uniform convergence of the native full curvature norm near a compact |
| 10 | family of invertible target jets. Source: Morgan--Tian Proposition 5.14 |
| 11 | and Theorem 11.8, pp. 90--91 and 272; M30 derivation |
| 12 | `generalized-uniform-curvature.md`, Section 4. |
| 13 | -/ |
| 14 | |
| 15 | set_option autoImplicit false |
| 16 | set_option backward.isDefEq.respectTransparency false |
| 17 | set_option maxSynthPendingDepth 12 |
| 18 | |
| 19 | open Set Filter |
| 20 | open scoped ContDiff Topology |
| 21 | |
| 22 | namespace PoincareMT.M30 |
| 23 | |
| 24 | open SpacetimeBounds |
| 25 | |
| 26 | set_option maxHeartbeats 800000 in |
| 27 | -- The nested continuous-linear-map jet norms need additional reduction. |
| 28 | /-- The first three spatial jets assemble uniformly into the literal |
| 29 | metric two-jet with arbitrary parameters and index filter |
| 30 | (Proposition 5.14 and Theorem 11.8, pp. 90--91 and 272). -/ |
| 31 | theorem tendstoUniformlyOn_metricTwoJet_of_uniform_spatial_jets |
| 32 | {ι A : Type*} {n : ℕ} {l : Filter ι} |
| 33 | {f : ι → A → EuclideanSpace ℝ (Fin n) → MetricCoefficient n} |
| 34 | {g : A → EuclideanSpace ℝ (Fin n) → MetricCoefficient n} |
| 35 | {K : Set (A × EuclideanSpace ℝ (Fin n))} |
| 36 | (h : ∀ m ≤ 2, TendstoUniformlyOn |
| 37 | (fun k p => iteratedFDeriv ℝ m (f k p.1) p.2) |
| 38 | (fun p => iteratedFDeriv ℝ m (g p.1) p.2) l K) : |
| 39 | TendstoUniformlyOn |
| 40 | (fun k p => metricTwoJet (f k p.1) p.2) |
| 41 | (fun p => metricTwoJet (g p.1) p.2) l K := by |
| 42 | let E := EuclideanSpace ℝ (Fin n) |
| 43 | have hshift {F : Type} [NormedAddCommGroup F] [NormedSpace ℝ F] |
| 44 | {a : ι → A → E → F} {a0 : A → E → F} {m : ℕ} |
| 45 | (ha : TendstoUniformlyOn (fun k p => iteratedFDeriv ℝ (m + 1) (a k p.1) p.2) |
| 46 | (fun p => iteratedFDeriv ℝ (m + 1) (a0 p.1) p.2) l K) : |
| 47 | TendstoUniformlyOn (fun k p => iteratedFDeriv ℝ m (fderiv ℝ (a k p.1)) p.2) |
| 48 | (fun p => iteratedFDeriv ℝ m (fderiv ℝ (a0 p.1)) p.2) l K := by |
| 49 | have heq (q : E → F) (x : E) : continuousMultilinearCurryRightEquiv' ℝ m E F |
| 50 | (iteratedFDeriv ℝ (m + 1) q x) = iteratedFDeriv ℝ m (fderiv ℝ q) x := by |
| 51 | rw [iteratedFDeriv_succ_eq_comp_right, Function.comp_apply, |
| 52 | LinearIsometryEquiv.apply_symm_apply] |
| 53 | have H := (continuousMultilinearCurryRightEquiv' ℝ m E F).isometry.uniformContinuous |
| 54 | |>.comp_tendstoUniformlyOn ha |
| 55 | simpa only [Function.comp_def, heq] using H |
| 56 | have h0 := (ContinuousMultilinearMap.uniformContinuous_eval_const |
| 57 | (0 : Fin 0 → E)).comp_tendstoUniformlyOn (h 0 (by omega)) |
| 58 | have hd1 := hshift (a := f) (a0 := g) (m := 0) (h 1 (by omega)) |
| 59 | have hd2 := hshift (a := f) (a0 := g) (m := 1) (h 2 (by omega)) |
| 60 | have hdd := hshift (a := fun k t => fderiv ℝ (f k t)) |
| 61 | (a0 := fun t => fderiv ℝ (g t)) (m := 0) hd2 |
| 62 | have h1 := (ContinuousMultilinearMap.uniformContinuous_eval_const |
| 63 | (0 : Fin 0 → E)).comp_tendstoUniformlyOn hd1 |
| 64 | have h2 := (ContinuousMultilinearMap.uniformContinuous_eval_const |
| 65 | (0 : Fin 0 → E)).comp_tendstoUniformlyOn hdd |
| 66 | apply Metric.tendstoUniformlyOn_iff.mpr |
| 67 | intro delta hdelta |
| 68 | filter_upwards [Metric.tendstoUniformlyOn_iff.mp h0 delta hdelta, |
| 69 | Metric.tendstoUniformlyOn_iff.mp h1 delta hdelta, |
| 70 | Metric.tendstoUniformlyOn_iff.mp h2 delta hdelta] with k hk0 hk1 hk2 |
| 71 | intro p hp |
| 72 | exact max_lt (hk0 p hp) (max_lt (hk1 p hp) (hk2 p hp)) |
| 73 | |
| 74 | /-- Compact invertible target two-jets give uniform convergence of the |
| 75 | native four-tensor curvature norm, including nearby source jets outside |
| 76 | that compact image (Proposition 5.14 and Theorem 11.8, pp. 90--91, 272). -/ |
| 77 | theorem tendstoUniformlyOn_jetCurvatureNorm_of_uniform_jets |
| 78 | {ι X : Type*} [TopologicalSpace X] {l : Filter ι} |
| 79 | {A : ι → X → MetricTwoJet 3} {A0 : X → MetricTwoJet 3} {K : Set X} |
| 80 | (hK : IsCompact K) (hcontinuous : ContinuousOn A0 K) |
| 81 | (hinvertible : ∀ x ∈ K, (A0 x).1.IsInvertible) |
| 82 | (hjets : TendstoUniformlyOn A A0 l K) : |
| 83 | TendstoUniformlyOn (fun k x => M28.jetCurvatureNorm (A k x)) |
| 84 | (fun x => M28.jetCurvatureNorm (A0 x)) l K := by |
| 85 | apply Metric.tendstoUniformlyOn_iff.mpr |
| 86 | intro delta hdelta |
| 87 | obtain ⟨eta, heta, hmodulus⟩ := M28.exists_jetCurvatureNorm_uniform_modulus |
| 88 | (hK.image_of_continuousOn hcontinuous) |
| 89 | (by rintro _ ⟨x, hx, rfl⟩; exact hinvertible x hx) hdelta |
| 90 | filter_upwards [Metric.tendstoUniformlyOn_iff.mp hjets eta heta] with k hk |
| 91 | intro x hx |
| 92 | simpa only [Real.dist_eq, abs_sub_comm] using |
| 93 | hmodulus (A0 x) (mem_image_of_mem _ hx) (A k x) |
| 94 | (by simpa only [dist_comm] using hk x hx) |
| 95 | |
| 96 | end PoincareMT.M30 |