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.Surgery.StandardCap.Persistence.Limit.Exponential.StandardPoleBalls |
| 2 | import PoincareLib.Geometry.RicciFlow.Surgery.StandardCap.Persistence.Limit.Exponential.InitialExponential |
| 3 | |
| 4 | /-! |
| 5 | # The standard exponential with the limiting initial frame |
| 6 | |
| 7 | The explicit standard pole supplies a smooth global model phase solving |
| 8 | the actual standard geodesic equation. Morgan--Tian, Claim 16.6 and |
| 9 | Corollary 16.7, pp. 371-372; see |
| 10 | `derivations/20-exponential-model-and-convergence.md`. |
| 11 | -/ |
| 12 | |
| 13 | set_option autoImplicit false |
| 14 | set_option backward.isDefEq.respectTransparency false |
| 15 | |
| 16 | open Set Filter |
| 17 | open scoped Manifold ContDiff Topology |
| 18 | |
| 19 | namespace PoincareMT.M44 |
| 20 | |
| 21 | local notation "E" => StandardCapSpace |
| 22 | |
| 23 | /-- Every radial curve of the standard pole is a geodesic for all real |
| 24 | times. Source: the model in Claim 16.6, pp. 371-372. -/ |
| 25 | theorem standardRadialExponential_isGeodesicOn (g₀ : StandardInitialMetric) (v : E) : |
| 26 | g₀.metric.IsGeodesicOn (fun t : ℝ => standardRadialExponential g₀ (t • v)) univ := by |
| 27 | intro t _ |
| 28 | let R := ‖v‖ + ‖t • v‖ + 1 |
| 29 | have hexp : ∀ w ∈ Metric.ball (0 : E) R, ∃ epsilon : ℝ, 0 < epsilon ∧ ∃ γ : ℝ → E, |
| 30 | g₀.metric.IsGeodesicOn γ (Ioo (-epsilon) (1 + epsilon)) ∧ γ 0 = 0 ∧ |
| 31 | HasDerivAt (fun s => extChartAt (𝓡 3) (0 : E) (γ s)) |
| 32 | ((ContinuousLinearEquiv.refl ℝ E) w) 0 ∧ |
| 33 | γ 1 = standardRadialExponential g₀ w := by |
| 34 | intro w _ |
| 35 | simpa only [StandardCapSpace, extChartAt_self_eq, modelWithCornersSelf_coe, |
| 36 | id_eq, ContinuousLinearEquiv.refl_apply] using exists_standard_radial_geodesic g₀ w |
| 37 | apply g₀.metric.isGeodesicOn_radial_of_initial_data 0 (ContinuousLinearEquiv.refl ℝ E) |
| 38 | (standardRadialExponential g₀) hexp (v := v) |
| 39 | · simp only [Metric.mem_ball, dist_zero_right, R] |
| 40 | linarith [norm_nonneg (t • v)] |
| 41 | · simp only [mem_ofPred_eq, Metric.mem_ball, dist_zero_right, R] |
| 42 | linarith [norm_nonneg v] |
| 43 | |
| 44 | /-- The standard exponential expressed in a fixed initial frame. |
| 45 | Source: Corollary 16.7, p. 372. -/ |
| 46 | noncomputable def standardFrameExponential (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) : |
| 47 | E → E := standardRadialExponential g₀ ∘ L |
| 48 | |
| 49 | /-- The fixed-frame model endpoint is globally smooth. |
| 50 | Source: Claim 16.6, pp. 371-372. -/ |
| 51 | theorem standardFrameExponential_contDiff (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) : |
| 52 | ContDiff ℝ ∞ (standardFrameExponential g₀ L) := |
| 53 | (standardRadialExponential_contDiff g₀).comp L.contDiff |
| 54 | |
| 55 | /-- The fixed-frame model endpoint fixes the tip. |
| 56 | Source: Claim 16.6, pp. 371-372. -/ |
| 57 | theorem standardFrameExponential_zero (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) : |
| 58 | standardFrameExponential g₀ L 0 = 0 := by |
| 59 | simp only [standardFrameExponential, Function.comp_apply, map_zero, |
| 60 | standardRadialExponential_zero] |
| 61 | |
| 62 | /-- The derivative of the model endpoint at zero is the fixed frame. |
| 63 | Source: Corollary 16.7, p. 372. -/ |
| 64 | theorem standardFrameExponential_hasFDerivAt_zero |
| 65 | (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) : |
| 66 | HasFDerivAt (standardFrameExponential g₀ L) L.toContinuousLinearMap 0 := by |
| 67 | have hd : HasFDerivAt (standardRadialExponential g₀) (ContinuousLinearMap.id ℝ E) (L 0) := |
| 68 | by simpa only [map_zero] using standardRadialExponential_hasFDerivAt_zero g₀ |
| 69 | simpa only [standardFrameExponential, ContinuousLinearMap.id_comp] using |
| 70 | hd.comp 0 L.hasFDerivAt |
| 71 | |
| 72 | /-- The actual position and radial velocity of the fixed model. |
| 73 | Source: Claim 16.6, pp. 371-372. -/ |
| 74 | noncomputable def standardFramePhase (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) |
| 75 | (z : E × ℝ) : E × E := |
| 76 | (standardFrameExponential g₀ L (z.2 • z.1), |
| 77 | fderiv ℝ (standardFrameExponential g₀ L) (z.2 • z.1) z.1) |
| 78 | |
| 79 | /-- The model phase is jointly smooth with no parameter or time |
| 80 | restriction. Source: Claim 16.6, pp. 371-372. -/ |
| 81 | theorem standardFramePhase_contDiff (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) : |
| 82 | ContDiff ℝ ∞ (standardFramePhase g₀ L) := by |
| 83 | have he := standardFrameExponential_contDiff g₀ L |
| 84 | have harg : ContDiff ℝ ∞ (fun z : E × ℝ => z.2 • z.1) := by fun_prop |
| 85 | exact (he.comp harg).prodMk |
| 86 | (((he.fderiv_right (m := ∞) (by simp)).comp harg).clm_apply contDiff_fst) |
| 87 | |
| 88 | /-- The displayed model velocity is its actual time derivative. |
| 89 | Source: Claim 16.6, pp. 371-372. -/ |
| 90 | theorem standardFramePhase_eq_curve_velocity |
| 91 | (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) (v : E) (t : ℝ) : |
| 92 | standardFramePhase g₀ L (v, t) = |
| 93 | (standardFrameExponential g₀ L (t • v), |
| 94 | deriv (fun s => standardFrameExponential g₀ L (s • v)) t) := by |
| 95 | have hd := ((standardFrameExponential_contDiff g₀ L).differentiable (by simp) |
| 96 | (t • v)).hasFDerivAt.comp_hasDerivAt t ((hasDerivAt_id t).smul_const v) |
| 97 | refine Prod.ext rfl ?_ |
| 98 | simpa only [standardFramePhase, Function.comp_def, id_eq, one_smul] using hd.deriv.symm |
| 99 | |
| 100 | /-- The actual initial phase data use the limiting frame. |
| 101 | Source: Corollary 16.7, p. 372. -/ |
| 102 | theorem standardFramePhase_initial (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) (v : E) : |
| 103 | standardFramePhase g₀ L (v, 0) = (0, L v) := by |
| 104 | simp only [standardFramePhase, zero_smul, standardFrameExponential_zero, |
| 105 | (standardFrameExponential_hasFDerivAt_zero g₀ L).fderiv, |
| 106 | ContinuousLinearEquiv.coe_coe] |
| 107 | |
| 108 | /-- The actual model phase satisfies the fixed standard geodesic field, |
| 109 | including both endpoints of every comparison interval. |
| 110 | Source: Claim 16.6, pp. 371-372. -/ |
| 111 | theorem standardFramePhase_hasDerivAt (g₀ : StandardInitialMetric) (L : E ≃L[ℝ] E) |
| 112 | (v : E) (t : ℝ) : |
| 113 | HasDerivAt (fun s => standardFramePhase g₀ L (v, s)) |
| 114 | (coordinateGeodesicField g₀.metric.euclideanCoefficients |
| 115 | (standardFramePhase g₀ L (v, t))) t := by |
| 116 | have hgeo : g₀.metric.IsGeodesicOn |
| 117 | (fun s => standardFrameExponential g₀ L (s • v)) univ := by |
| 118 | simpa only [standardFrameExponential, Function.comp_apply, map_smul] using |
| 119 | standardRadialExponential_isGeodesicOn g₀ (L v) |
| 120 | have hphase := hgeo.hasDerivAt_chart_at (t := t) (mem_univ t) (0 : E) |
| 121 | (by simp [StandardCapSpace]) |
| 122 | simp only [StandardCapSpace, extChartAt_self_eq, modelWithCornersSelf_coe, |
| 123 | id_eq] at hphase |
| 124 | have hcoeff : g₀.metric.pullbackCoefficients (extChartAt (𝓡 3) (0 : E)).symm = |
| 125 | g₀.metric.euclideanCoefficients := by |
| 126 | ext x a b |
| 127 | simp [StandardCapSpace, RiemannianMetric.pullbackCoefficients, |
| 128 | RiemannianMetric.euclideanCoefficients] |
| 129 | rfl |
| 130 | rw [hcoeff] at hphase |
| 131 | have heq : (fun s => standardFramePhase g₀ L (v, s)) = |
| 132 | (fun s => (standardFrameExponential g₀ L (s • v), |
| 133 | deriv (fun u => standardFrameExponential g₀ L (u • v)) s)) := by |
| 134 | funext s |
| 135 | exact standardFramePhase_eq_curve_velocity g₀ L v s |
| 136 | rw [heq, standardFramePhase_eq_curve_velocity] |
| 137 | exact hphase.1.prodMk hphase.2 |
| 138 | |
| 139 | end PoincareMT.M44 |