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.GeometryImports |
| 2 | import PoincareLib.Geometry.RicciFlow.Generalized.BoundedDistance.SourceNames |
| 3 | import PoincareLib.Geometry.RicciFlow.Generalized.BoundedDistance.Tube.SourceGeometry.CriticalBall.SourceCriticalBallBackwardRestriction |
| 4 | import PoincareLib.Geometry.RicciFlow.Generalized.BoundedDistance.Spacetime.StrongNecks.Curvature.StrongNeckPinching |
| 5 | import PoincareLib.Geometry.RicciFlow.Generalized.BoundedDistance.Tube.SourceGeometry.Geometry.SourceFamilyScales |
| 6 | |
| 7 | /-! |
| 8 | # Vanishing pinching error on the actual backward source family |
| 9 | |
| 10 | The original base scalar diverges through the retained strict indices. |
| 11 | Original logarithmic pinching therefore makes the normalized negative |
| 12 | part tend to zero at every selected source point in the common backward |
| 13 | window. Morgan--Tian Claim 10.11, p. 255; M28 derivation 78. |
| 14 | -/ |
| 15 | |
| 16 | noncomputable section |
| 17 | set_option autoImplicit false |
| 18 | set_option backward.isDefEq.respectTransparency false |
| 19 | |
| 20 | open Set Filter |
| 21 | open scoped Manifold ContDiff Bundle Topology |
| 22 | |
| 23 | universe u |
| 24 | |
| 25 | namespace PoincareMT.M28.CounterexampleNeckFamily.CriticalBallBackwardChartData |
| 26 | |
| 27 | variable {epsilon C A : ℝ} |
| 28 | {E : ∀ n : ℕ, SameTimeCounterexample.{u} epsilon C A |
| 29 | ((n : ℝ) + 1) ((n : ℝ) + 1)} |
| 30 | {H : CounterexampleNeckFamily E} {T : ∀ k, SourceTubeData (H.segment k)} |
| 31 | {A1 : ℝ} {hA1 : 0 < A1} {phi : ℕ → ℕ} |
| 32 | {G : RegularPointedMetricConvergence |
| 33 | (fun k => H.tubeCriticalMetric T A1 (phi k)) |
| 34 | (fun k => H.tubeCriticalBase T A1 hA1 (phi k))} |
| 35 | {q : G.limitCarrier.carrier} {a : ℝ} |
| 36 | (D : CriticalBallBackwardChartData H T A1 hA1 phi G q a) |
| 37 | |
| 38 | /-- The original base scalar used by the actual source normalization. |
| 39 | The family shift occurs exactly once (Claim 10.11; derivation 78). -/ |
| 40 | def sourceBaseScalar (k : ℕ) : ℝ := |
| 41 | (E (D.sourceIndex k + H.shift)).flow.scalar |
| 42 | ⟨(E (D.sourceIndex k + H.shift)).time, (E (D.sourceIndex k + H.shift)).basepoint⟩ |
| 43 | |
| 44 | /-- Every retained source has a positive normalization factor. -/ |
| 45 | theorem sourceBaseScalar_pos (k : ℕ) : 0 < D.sourceBaseScalar k := |
| 46 | H.base_scalar_pos (D.sourceIndex k) |
| 47 | |
| 48 | /-- Strict source selection, spatial extraction and finite-prefix removal |
| 49 | preserve divergence of the original base scalar (derivation 78). -/ |
| 50 | theorem sourceBaseScalar_tendsto_atTop (hphi : StrictMono phi) : |
| 51 | Tendsto D.sourceBaseScalar atTop atTop := by |
| 52 | have hi : StrictMono D.sourceIndex := |
| 53 | hphi.comp (G.subsequence_strictMono.comp (fun _ _ h => Nat.add_lt_add_right h D.offset)) |
| 54 | exact H.base_scalar_tendsto_atTop.comp hi.tendsto_atTop |
| 55 | |
| 56 | /-- The original physical point for a source flow at an included backward |
| 57 | time. Its dependent slice is retained literally (derivation 78). -/ |
| 58 | def originalPoint (k : ℕ) (t : ℝ) (ht : t ∈ Icc (-(a / 8)) 0) |
| 59 | (x : strongNeckOpen (D.neck k)) : (E (D.sourceIndex k + H.shift)).flow.point := |
| 60 | GeneralizedStrongNeck.global_original_point (D.neck k) (D.sourceBaseScalar k) |
| 61 | (D.sourceBaseScalar_pos k) (a / 8) (D.common_window k) t ht x |
| 62 | |
| 63 | /-- The original negative part divided by the actual base scalar. -/ |
| 64 | def pinchingError (k : ℕ) (t : ℝ) (ht : t ∈ Icc (-(a / 8)) 0) |
| 65 | (x : strongNeckOpen (D.neck k)) : ℝ := |
| 66 | LeviCivitaData.negativeCurvaturePart |
| 67 | ((E (D.sourceIndex k + H.shift)).flow.connection (D.originalPoint k t ht x).1) |
| 68 | (D.originalPoint k t ht x).2 / D.sourceBaseScalar k |
| 69 | |
| 70 | set_option maxHeartbeats 1200000 in |
| 71 | -- The original point and connection retain the dependent selected slice. |
| 72 | /-- A uniform actual source curvature bound makes the original pinching |
| 73 | error vanish along arbitrary selected neck points, with time included. |
| 74 | Only equation (10.1) is used, in the original clock (derivation 78). -/ |
| 75 | theorem pinchingError_tendsto_zero (P : RicciFlowCurvatureTheory.{u}) |
| 76 | (hphi : StrictMono phi) {K : ℝ} (hK : 0 ≤ K) |
| 77 | (hcurv : ∀ k t, t ∈ Icc (-(a / 8)) 0 → ∀ x : strongNeckOpen (D.neck k), |
| 78 | ((D.sourceFlow k).connection t).curvatureTensorNorm x ≤ K) |
| 79 | (t : ℝ) (ht : t ∈ Icc (-(a / 8)) 0) |
| 80 | (x : ∀ k, strongNeckOpen (D.neck k)) : |
| 81 | Tendsto (fun k => D.pinchingError k t ht (x k)) atTop (𝓝 0) := by |
| 82 | apply Real.tendsto_zero_of_log_pinching (B := 9 * K) (by positivity) |
| 83 | (D.sourceBaseScalar_tendsto_atTop hphi) |
| 84 | · exact Eventually.of_forall fun _ => le_max_right _ _ |
| 85 | · apply Eventually.of_forall |
| 86 | intro k |
| 87 | exact GeneralizedStrongNeck.global_original_scalar_le_of_curvature_bound |
| 88 | (D.neck k) (D.raw k) (D.sourceBaseScalar k) (D.sourceBaseScalar_pos k) P |
| 89 | (a / 8) (by linarith [D.scale_pos]) (D.common_window k) t ht (x k) (hcurv k t ht (x k)) |
| 90 | · apply Eventually.of_forall |
| 91 | intro k |
| 92 | have htime := GeneralizedStrongNeck.global_original_point_time_mem |
| 93 | (D.neck k) (D.sourceBaseScalar k) (D.sourceBaseScalar_pos k) |
| 94 | (a / 8) (D.common_window k) t ht (x k) |
| 95 | exact ((E (D.sourceIndex k + H.shift)).pinched _ htime |
| 96 | (D.originalPoint k t ht (x k)).2).2 |
| 97 | |
| 98 | /-- The exact error controls source plane tensors with their actual metric |
| 99 | Gram determinant, including dependent vectors (Claim 10.11; derivation 78). -/ |
| 100 | theorem sourceFlow_plane_lower (P : RicciFlowCurvatureTheory.{u}) |
| 101 | (k : ℕ) (t : ℝ) (ht : t ∈ Icc (-(a / 8)) 0) |
| 102 | (x : strongNeckOpen (D.neck k)) (v w : TangentSpace (𝓡 3) x) : |
| 103 | -D.pinchingError k t ht x * M04.metricGram ((D.sourceFlow k).metric t) x v w ≤ |
| 104 | ((D.sourceFlow k).connection t).curvatureTensor x v w v w := |
| 105 | GeneralizedStrongNeck.global_flow_plane_lower (D.neck k) (D.raw k) |
| 106 | (D.sourceBaseScalar k) (D.sourceBaseScalar_pos k) P (a / 8) |
| 107 | (by linarith [D.scale_pos]) (D.common_window k) t ht x v w |
| 108 | |
| 109 | end PoincareMT.M28.CounterexampleNeckFamily.CriticalBallBackwardChartData |