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.ReducedGeometry.Calculus.Local.HessianTrace |
| 2 | import PoincareLib.Geometry.RicciFlow.Generalized.ReducedGeometry.Theory |
| 3 | |
| 4 | /-! |
| 5 | # Tracing the frozen Hessian in a horizontal frame |
| 6 | |
| 7 | The actual slice tangent equivalence preserves its specified metric. |
| 8 | Consequently an orthonormal horizontal frame computes the selected |
| 9 | slice Laplacian. Morgan-Tian Proposition 6.43, p. 128. |
| 10 | -/ |
| 11 | |
| 12 | set_option autoImplicit false |
| 13 | -- Slice tangent fibers retain their ambient coordinates before metric renorming. |
| 14 | set_option backward.isDefEq.respectTransparency false |
| 15 | |
| 16 | open scoped Manifold ContDiff Bundle BigOperators |
| 17 | |
| 18 | universe u |
| 19 | |
| 20 | namespace PoincareMT.M14 |
| 21 | |
| 22 | variable {n : ℕ} {X : Type u} [TopologicalSpace X] {time : X → ℝ} |
| 23 | {I : SpacetimeInterval} {G : GeneralizedLGeometryTransport n X time I} |
| 24 | |
| 25 | /-- An actual horizontal orthonormal basis traces the selected slice |
| 26 | Hessian, Proposition 6.43, p. 128. -/ |
| 27 | theorem sliceLaplacian_eq_horizontal_hessian_trace {T τ : ℝ} |
| 28 | (q : (G.slices (T - τ)).Point) (f : G.Point → ℝ) |
| 29 | (hf : ContMDiffAt (𝓡 n) (𝓘(ℝ, ℝ)) ∞ (fun r : (G.slices (T - τ)).Point => f r.val) q) |
| 30 | (b : Module.Basis (Fin n) ℝ (G.Horizontal q.val)) |
| 31 | (hb : ∀ i j, G.spacetime.horizontalMetric.inner q.val (b i) (b j) = |
| 32 | if i = j then 1 else 0) : |
| 33 | (G.leafwise.sliceConnection (T - τ)).laplacian (fun r => f r.val) q = |
| 34 | ∑ i, M14ReducedLengthHessianPairing G q f (b i) (b i) := by |
| 35 | let : ChartedSpace (EuclideanSpace ℝ (Fin n)) (G.slices (T - τ)).Point := |
| 36 | (G.slices (T - τ)).chartedSpace |
| 37 | let : Bundle.RiemannianBundle |
| 38 | (TangentSpace (𝓡 n) : (G.slices (T - τ)).Point → Type _) := |
| 39 | ⟨(G.slices (T - τ)).metricOnPoints.toRiemannianMetric⟩ |
| 40 | let bs := b.map ((G.slices (T - τ)).tangentEquiv q).symm.toLinearEquiv |
| 41 | have hbs : Orthonormal ℝ bs := by |
| 42 | apply orthonormal_iff_ite.mpr |
| 43 | intro i j |
| 44 | change (G.slices (T - τ)).metricOnPoints.inner q (bs i) (bs j) = _ |
| 45 | rw [(G.slices (T - τ)).metric_eq] |
| 46 | simpa only [bs, Module.Basis.map_apply, ContinuousLinearEquiv.coe_toLinearEquiv, |
| 47 | ContinuousLinearEquiv.apply_symm_apply] using hb i j |
| 48 | simpa only [Module.Basis.coe_toOrthonormalBasis, bs, Module.Basis.map_apply, |
| 49 | ContinuousLinearEquiv.coe_toLinearEquiv, M14ReducedLengthHessianPairing] using |
| 50 | laplacian_eq_orthonormal_hessian_trace (G.leafwise.sliceConnection (T - τ)) |
| 51 | (fun r => f r.val) q hf (bs.toOrthonormalBasis hbs) |
| 52 | |
| 53 | /-- The raw reduced-length function restricts to its exact frozen |
| 54 | fixed-time value, Definition 6.45, p. 129. -/ |
| 55 | theorem reducedLengthAt_slice_eq {T a τ : ℝ} (x : G.Point) : |
| 56 | (fun q : (G.slices (T - τ)).Point => M14ReducedLengthAt G T a x q.val) = |
| 57 | (fun q : (G.slices (T - τ)).Point => M14ReducedLengthValue G T a τ x q.val) := by |
| 58 | funext q |
| 59 | unfold M14ReducedLengthAt |
| 60 | rw [q.property] |
| 61 | congr 1 |
| 62 | ring |
| 63 | |
| 64 | /-- The frozen reduced-length Laplacian is the trace of its frozen |
| 65 | Hessian pairings in any actual orthonormal horizontal basis, |
| 66 | Theorem 6.50, p. 131. -/ |
| 67 | theorem reducedLengthLaplacian_eq_horizontal_hessian_trace {T a τ : ℝ} |
| 68 | (x : G.Point) (q : (G.slices (T - τ)).Point) |
| 69 | (hf : ContMDiffAt (𝓡 n) (𝓘(ℝ, ℝ)) ∞ |
| 70 | (fun r : (G.slices (T - τ)).Point => M14ReducedLengthAt G T a x r.val) q) |
| 71 | (b : Module.Basis (Fin n) ℝ (G.Horizontal q.val)) |
| 72 | (hb : ∀ i j, G.spacetime.horizontalMetric.inner q.val (b i) (b j) = |
| 73 | if i = j then 1 else 0) : |
| 74 | M14ReducedLengthLaplacian (T := T) (τ₁ := a) G x q = |
| 75 | ∑ i, M14ReducedLengthHessianPairing G q (M14ReducedLengthAt G T a x) (b i) (b i) := by |
| 76 | have h := sliceLaplacian_eq_horizontal_hessian_trace q (M14ReducedLengthAt G T a x) hf b hb |
| 77 | rw [reducedLengthAt_slice_eq] at h |
| 78 | exact h |
| 79 | |
| 80 | end PoincareMT.M14 |