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.Harnack.Basic |
| 2 | import PoincareLib.Geometry.RicciFlow.Curvature.Theory |
| 3 | |
| 4 | /-! This is the unchanged frozen M06 conclusion structure. Only imports and |
| 5 | module placement differ from the reviewed snapshot; see |
| 6 | `references/ricci-flow/mapher/harnack-interface.json`. -/ |
| 7 | |
| 8 | /-! |
| 9 | # Differential Harnack and ancient-flow conclusions |
| 10 | |
| 11 | The finite integrated estimate retains the initial-time factor omitted by the |
| 12 | printed finite-interval statement. Ancient flows use the endpoint-safe form. |
| 13 | No kappa-noncollapsing or surgery-flow premise is hidden here. |
| 14 | -/ |
| 15 | |
| 16 | set_option autoImplicit false |
| 17 | |
| 18 | open scoped Manifold ContDiff Bundle |
| 19 | |
| 20 | universe u |
| 21 | |
| 22 | namespace PoincareMT |
| 23 | |
| 24 | structure HarnackAncientTheory : Prop where |
| 25 | metric_edist_transport : |
| 26 | ∀ (n : ℕ) (M : Type u) [TopologicalSpace M] |
| 27 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 28 | [T3Space M] (g : RiemannianMetric n M) (x y : M), |
| 29 | letI : Bundle.RiemannianBundle (TangentSpace (𝓡 n) : M → Type _) := |
| 30 | ⟨g.toRiemannianMetric⟩ |
| 31 | letI : IsContinuousRiemannianBundle (EuclideanSpace ℝ (Fin n)) |
| 32 | (TangentSpace (𝓡 n) : M → Type _) := |
| 33 | ⟨⟨g.inner, g.toContinuousRiemannianMetric.continuous, fun _ _ _ ↦ rfl⟩⟩ |
| 34 | letI : EMetricSpace M := EMetricSpace.ofRiemannianMetric (𝓡 n) M |
| 35 | edist x y = g.edist x y |
| 36 | finite_differential : |
| 37 | ∀ (n : ℕ) (M : Type u) [TopologicalSpace M] |
| 38 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 39 | [T2Space M] [T3Space M] [SecondCountableTopology M], |
| 40 | ∀ T₀ T₁ : ℝ, T₀ < T₁ → |
| 41 | ∀ F : RicciFlow n M (Set.Ioo T₀ T₁), |
| 42 | (∀ t ∈ Set.Ioo T₀ T₁, MetricComplete (F.metric t)) → |
| 43 | (∀ t ∈ Set.Ioo T₀ T₁, ∀ x : M, |
| 44 | LeviCivitaData.NonnegativeCurvatureOperator (F.connection t) x) → |
| 45 | (∀ t ∈ Set.Ioo T₀ T₁, ∃ K : ℝ, 0 ≤ K ∧ |
| 46 | ∀ x : M, LeviCivitaData.CurvatureOperatorBound (F.connection t) K x) → |
| 47 | ∀ t ∈ Set.Ioo T₀ T₁, ∀ x : M, ∀ v : TangentSpace (𝓡 n) x, |
| 48 | ∃ dR : ℝ, |
| 49 | HasDerivWithinAt (fun s ↦ (F.connection s).scalarCurvature x) dR |
| 50 | (Set.Ioo T₀ T₁) t ∧ |
| 51 | dR + (F.connection t).scalarCurvature x / (t - T₀) + |
| 52 | 2 * (mvfderiv (𝓡 n) |
| 53 | (fun y ↦ (F.connection t).scalarCurvature y) x) v + |
| 54 | 2 * (F.connection t).ricci x v v ≥ 0 |
| 55 | finite_integrated : |
| 56 | ∀ (n : ℕ) (M : Type u) [TopologicalSpace M] |
| 57 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 58 | [T2Space M] [T3Space M] [SecondCountableTopology M], |
| 59 | ∀ T₀ T₁ t₁ t₂ : ℝ, T₀ < t₁ → t₁ < t₂ → t₂ < T₁ → |
| 60 | ∀ F : RicciFlow n M (Set.Ioo T₀ T₁), |
| 61 | (∀ t ∈ Set.Ioo T₀ T₁, MetricComplete (F.metric t)) → |
| 62 | (∀ t ∈ Set.Ioo T₀ T₁, ∀ x : M, |
| 63 | LeviCivitaData.NonnegativeCurvatureOperator (F.connection t) x) → |
| 64 | (∀ t ∈ Set.Ioo T₀ T₁, ∃ K : ℝ, 0 ≤ K ∧ |
| 65 | ∀ x : M, LeviCivitaData.CurvatureOperatorBound (F.connection t) K x) → |
| 66 | ∀ γ : ℝ → M, ContMDiffOn (𝓘(ℝ, ℝ)) (𝓡 n) 1 γ (Set.Icc t₁ t₂) → |
| 67 | ∀ x₁ x₂ : M, γ t₁ = x₁ → γ t₂ = x₂ → |
| 68 | (F.connection t₂).scalarCurvature x₂ * (t₂ - T₀) ≥ |
| 69 | (F.connection t₁).scalarCurvature x₁ * (t₁ - T₀) * |
| 70 | Real.exp (-spacetimeEnergy F γ t₁ t₂ / 2) |
| 71 | ancient_differential : |
| 72 | ∀ (n : ℕ) (M : Type u) [TopologicalSpace M] |
| 73 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 74 | [T2Space M] [T3Space M] [SecondCountableTopology M] [ConnectedSpace M], |
| 75 | ∀ F : RicciFlow n M (Set.Iic 0), |
| 76 | (∀ t ≤ 0, MetricComplete (F.metric t)) → |
| 77 | (∀ t ≤ 0, ∀ x : M, |
| 78 | LeviCivitaData.NonnegativeCurvatureOperator (F.connection t) x) → |
| 79 | (∀ t ≤ 0, ∃ K : ℝ, 0 ≤ K ∧ |
| 80 | ∀ x : M, LeviCivitaData.CurvatureOperatorBound (F.connection t) K x) → |
| 81 | (∀ t ≤ 0, ∃ x : M, (F.connection t).curvatureTensorNorm x ≠ 0) → |
| 82 | ∀ t ≤ 0, ∀ x : M, ∀ v : TangentSpace (𝓡 n) x, |
| 83 | ∃ dR : ℝ, |
| 84 | HasDerivWithinAt (fun s ↦ (F.connection s).scalarCurvature x) dR |
| 85 | (Set.Iic 0) t ∧ |
| 86 | dR + 2 * (mvfderiv (𝓡 n) |
| 87 | (fun y ↦ (F.connection t).scalarCurvature y) x) v + |
| 88 | 2 * (F.connection t).ricci x v v ≥ 0 |
| 89 | ancient_integrated : |
| 90 | ∀ (n : ℕ) (M : Type u) [TopologicalSpace M] |
| 91 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 92 | [T2Space M] [T3Space M] [SecondCountableTopology M] [ConnectedSpace M], |
| 93 | ∀ F : RicciFlow n M (Set.Iic 0), |
| 94 | (∀ t ≤ 0, MetricComplete (F.metric t)) → |
| 95 | (∀ t ≤ 0, ∀ x : M, |
| 96 | LeviCivitaData.NonnegativeCurvatureOperator (F.connection t) x) → |
| 97 | (∀ t ≤ 0, ∃ K : ℝ, 0 ≤ K ∧ |
| 98 | ∀ x : M, LeviCivitaData.CurvatureOperatorBound (F.connection t) K x) → |
| 99 | (∀ t ≤ 0, ∃ x : M, (F.connection t).curvatureTensorNorm x ≠ 0) → |
| 100 | ∀ t₁ t₂ : ℝ, t₁ < t₂ → t₂ ≤ 0 → ∀ γ : ℝ → M, |
| 101 | ContMDiffOn (𝓘(ℝ, ℝ)) (𝓡 n) 1 γ (Set.Icc t₁ t₂) → |
| 102 | ∀ x₁ x₂ : M, γ t₁ = x₁ → γ t₂ = x₂ → |
| 103 | (F.connection t₂).scalarCurvature x₂ ≥ |
| 104 | (F.connection t₁).scalarCurvature x₁ * |
| 105 | Real.exp (-spacetimeEnergy F γ t₁ t₂ / 2) |
| 106 | |
| 107 | end PoincareMT |