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.Regularity.Lipschitz.IntrinsicLipschitz |
| 2 | import Mathlib.Analysis.Normed.Module.HahnBanach |
| 3 | |
| 4 | /-! |
| 5 | # Vector-valued comparison in intrinsic balls |
| 6 | |
| 7 | A norming real functional reduces the two-point estimate to the scalar |
| 8 | upper-support theorem. Its short-path confinement argument preserves the |
| 9 | sharp differential bound, without a dimension-dependent factor. |
| 10 | -/ |
| 11 | |
| 12 | set_option autoImplicit false |
| 13 | |
| 14 | open Set Filter |
| 15 | open scoped Manifold ContDiff Bundle Topology ENNReal NNReal |
| 16 | |
| 17 | universe u |
| 18 | |
| 19 | namespace PoincareMT.ReducedVolume |
| 20 | |
| 21 | variable {n : ℕ} {M : Type u} [TopologicalSpace M] |
| 22 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 23 | {E : Type*} [NormedAddCommGroup E] [NormedSpace ℝ E] |
| 24 | |
| 25 | set_option backward.isDefEq.respectTransparency false in |
| 26 | /-- A vector-valued differential bound gives the same intrinsic two-point bound. -/ |
| 27 | theorem edist_le_mul_riemannianEDist_of_vector_differential |
| 28 | (g : RiemannianMetric n M) {f : M → E} {U : Set M} |
| 29 | (hf : ContinuousOn f U) (hfd : ∀ q ∈ U, |
| 30 | MDifferentiableAt (𝓡 n) 𝓘(ℝ, E) f q) {C : ℝ≥0} |
| 31 | (hbound : ∀ q ∈ U, ∀ v : TangentSpace (𝓡 n) q, |
| 32 | ‖mvfderiv (𝓡 n) f q v‖ ≤ C * g.tangentNorm q v) |
| 33 | {x₀ x y : M} {r : ℝ≥0} |
| 34 | (hball : ∀ q, g.edist x₀ q < (r : ℝ≥0∞) + r + r → q ∈ U) |
| 35 | (hx : g.edist x₀ x < r) (hy : g.edist x₀ y < r) : |
| 36 | edist (f x) (f y) ≤ (C : ℝ≥0∞) * g.edist x y := by |
| 37 | obtain ⟨ℓ, hℓ, heval⟩ := exists_dual_vector'' ℝ (f x - f y) |
| 38 | rw [RCLike.ofReal_real_eq_id, id_eq] at heval |
| 39 | have h := edist_le_mul_riemannianEDist_of_upper_supports g |
| 40 | (ℓ.continuous.comp_continuousOn hf) (C := C) (fun q hq ↦ ?_) hball hx hy |
| 41 | · have hdist : edist (ℓ (f x)) (ℓ (f y)) = edist (f x) (f y) := by |
| 42 | rw [edist_dist, edist_dist, Real.dist_eq, dist_eq_norm, ← map_sub, heval, |
| 43 | abs_of_nonneg (norm_nonneg _)] |
| 44 | exact hdist ▸ h |
| 45 | refine ⟨ℓ ∘ f, ℓ.differentiableAt.mdifferentiableAt.comp q (hfd q hq), |
| 46 | rfl, Filter.Eventually.of_forall (fun _ ↦ le_rfl), ?_⟩ |
| 47 | intro v |
| 48 | have hchain : mvfderiv (𝓡 n) (ℓ ∘ f) q v = ℓ (mvfderiv (𝓡 n) f q v) := by |
| 49 | rw [mvfderiv_comp q ℓ.differentiableAt.mdifferentiableAt (hfd q hq)] |
| 50 | simp only [mvfderiv, mfderiv_eq_fderiv, ℓ.fderiv, |
| 51 | ContinuousLinearMap.comp_apply] |
| 52 | rfl |
| 53 | rw [hchain, ← Real.norm_eq_abs] |
| 54 | exact (ℓ.le_opNorm _).trans <| calc |
| 55 | ‖ℓ‖ * ‖mvfderiv (𝓡 n) f q v‖ ≤ 1 * ‖mvfderiv (𝓡 n) f q v‖ := |
| 56 | mul_le_mul_of_nonneg_right hℓ (norm_nonneg _) |
| 57 | _ ≤ C * g.tangentNorm q v := by simpa only [one_mul] using hbound q hq v |
| 58 | |
| 59 | end PoincareMT.ReducedVolume |