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.ReducedLength.Basic |
| 2 | import Mathlib.Geometry.Manifold.ContMDiff.NormedSpace |
| 3 | |
| 4 | /-! |
| 5 | # Smooth slices of the actual exponential family |
| 6 | |
| 7 | The initial-vector metric is the selected time-T metric from the frozen |
| 8 | joint smoothness fields. Square-time slices include time zero. |
| 9 | -/ |
| 10 | |
| 11 | set_option autoImplicit false |
| 12 | set_option maxSynthPendingDepth 3 |
| 13 | |
| 14 | open scoped Manifold ContDiff Bundle |
| 15 | |
| 16 | universe u |
| 17 | |
| 18 | namespace PoincareMT.ReducedLength |
| 19 | |
| 20 | variable {n : ℕ} {M : Type u} [TopologicalSpace M] |
| 21 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] |
| 22 | [IsManifold (𝓡 n) ∞ M] |
| 23 | {J : Set ℝ} {F : RicciFlow n M J} {T τmax : ℝ} {p : M} |
| 24 | |
| 25 | set_option backward.isDefEq.respectTransparency false in |
| 26 | theorem lExponentialFamily_squareSlice_contMDiffAt (A : LExponentialFamily F T τmax p) |
| 27 | (Z : TangentSpace (𝓡 n) p) (s : ℝ) (hs : s ∈ Set.Ico 0 (Real.sqrt τmax)) : |
| 28 | ContMDiffAt (𝓘(ℝ, ℝ)) (𝓡 n) ∞ (A.squareFamily Z) s := by |
| 29 | letI : Bundle.RiemannianBundle (TangentSpace (𝓡 n) : M → Type _) := |
| 30 | ⟨(F.metric T).toRiemannianMetric⟩ |
| 31 | let E := TangentSpace (𝓡 n) p |
| 32 | have hf : ContMDiffOn (𝓘(ℝ, E × ℝ)) (𝓡 n) ∞ |
| 33 | (fun z ↦ A.squareFamily z.1 z.2) A.squareDomain := by |
| 34 | convert! A.square_smooth using 1 <;> |
| 35 | simp only [E, modelWithCornersSelf_prod, chartedSpaceSelf_prod] |
| 36 | have hi : ContMDiff (𝓘(ℝ, ℝ)) (𝓘(ℝ, E × ℝ)) ∞ (fun r : ℝ ↦ (Z, r)) := |
| 37 | (contDiff_const.prodMk contDiff_id).contMDiff |
| 38 | exact (hf.contMDiffAt (A.square_open.mem_nhds |
| 39 | (A.square_contains ⟨Set.mem_univ _, hs⟩))).comp s hi.contMDiffAt |
| 40 | |
| 41 | set_option backward.isDefEq.respectTransparency false in |
| 42 | theorem lExponentialFamily_gammaSlice_contMDiffAt (A : LExponentialFamily F T τmax p) |
| 43 | (Z : TangentSpace (𝓡 n) p) (τ : ℝ) (hτ : 0 < τ) (hmax : τ < τmax) : |
| 44 | ContMDiffAt (𝓘(ℝ, ℝ)) (𝓡 n) ∞ (A.gamma Z) τ := by |
| 45 | letI : Bundle.RiemannianBundle (TangentSpace (𝓡 n) : M → Type _) := |
| 46 | ⟨(F.metric T).toRiemannianMetric⟩ |
| 47 | let E := TangentSpace (𝓡 n) p |
| 48 | have hf : ContMDiffOn (𝓘(ℝ, E × ℝ)) (𝓡 n) ∞ |
| 49 | (fun z ↦ A.gamma z.1 z.2) (Set.univ ×ˢ Set.Ioo 0 τmax) := by |
| 50 | convert! A.gamma_smooth using 1 <;> |
| 51 | simp only [E, modelWithCornersSelf_prod, chartedSpaceSelf_prod] |
| 52 | have hi : ContMDiff (𝓘(ℝ, ℝ)) (𝓘(ℝ, E × ℝ)) ∞ (fun r : ℝ ↦ (Z, r)) := |
| 53 | (contDiff_const.prodMk contDiff_id).contMDiff |
| 54 | exact (hf.contMDiffAt ((isOpen_univ.prod isOpen_Ioo).mem_nhds |
| 55 | ⟨Set.mem_univ _, hτ, hmax⟩)).comp τ hi.contMDiffAt |
| 56 | |
| 57 | set_option backward.isDefEq.respectTransparency false in |
| 58 | theorem lExponentialFamily_initialSlice_contMDiffAt (A : LExponentialFamily F T τmax p) |
| 59 | (Z : TangentSpace (𝓡 n) p) (τ : ℝ) (hτ : 0 < τ) (hmax : τ < τmax) : |
| 60 | letI : Bundle.RiemannianBundle (TangentSpace (𝓡 n) : M → Type _) := |
| 61 | ⟨(F.metric T).toRiemannianMetric⟩ |
| 62 | ContMDiffAt (𝓘(ℝ, TangentSpace (𝓡 n) p)) (𝓡 n) ∞ (fun V ↦ A.gamma V τ) Z := by |
| 63 | letI : Bundle.RiemannianBundle (TangentSpace (𝓡 n) : M → Type _) := |
| 64 | ⟨(F.metric T).toRiemannianMetric⟩ |
| 65 | let E := TangentSpace (𝓡 n) p |
| 66 | have hf : ContMDiffOn (𝓘(ℝ, E × ℝ)) (𝓡 n) ∞ |
| 67 | (fun z ↦ A.gamma z.1 z.2) (Set.univ ×ˢ Set.Ioo 0 τmax) := by |
| 68 | convert! A.gamma_smooth using 1 <;> |
| 69 | simp only [E, modelWithCornersSelf_prod, chartedSpaceSelf_prod] |
| 70 | have hi : ContMDiff (𝓘(ℝ, E)) (𝓘(ℝ, E × ℝ)) ∞ (fun V : E ↦ (V, τ)) := |
| 71 | (contDiff_id.prodMk contDiff_const).contMDiff |
| 72 | exact (hf.contMDiffAt ((isOpen_univ.prod isOpen_Ioo).mem_nhds |
| 73 | ⟨Set.mem_univ _, hτ, hmax⟩)).comp Z hi.contMDiffAt |
| 74 | |
| 75 | end PoincareMT.ReducedLength |