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 | /- Adapted from Mapher `PoincareMT/Proofs/M03/Existence/DeTurckPullbackResponseNative.lean` at |
| 2 | f927d9e1f0810042766d3b5f64d3f4da02ee93cc. See |
| 3 | `references/ricci-flow/mapher/local-theory/port.json`. -/ |
| 4 | |
| 5 | import PoincareLib.Geometry.RicciFlow.Local.DeTurck.Forcing.DeTurckParameterForcing |
| 6 | import PoincareLib.Geometry.RicciFlow.Local.DeTurck.Gauge.DeTurckStatePullback |
| 7 | import Mathlib.Analysis.ODE.Gronwall |
| 8 | |
| 9 | /-! |
| 10 | # Transport of the actual zero-initial DeTurck response |
| 11 | |
| 12 | The commutator forcing transports the Bochner integral defining the response. |
| 13 | Scalar integral uniqueness then identifies the full continuous path. |
| 14 | -/ |
| 15 | |
| 16 | set_option autoImplicit false |
| 17 | set_option maxHeartbeats 1800000 |
| 18 | set_option backward.isDefEq.respectTransparency false |
| 19 | |
| 20 | noncomputable section |
| 21 | |
| 22 | open MeasureTheory Set Filter |
| 23 | open scoped Manifold ContDiff Bundle Topology |
| 24 | |
| 25 | namespace PoincareMT.DeTurckPullbackResponseNative |
| 26 | |
| 27 | open SpectralHeatNative QuasilinearDeTurckNative DeTurckParameterForcingNative |
| 28 | |
| 29 | section LinearTransport |
| 30 | |
| 31 | variable {iota : Type*} [Countable iota] {T : ℝ} (lambda : iota → NNReal) |
| 32 | |
| 33 | def pullbackCommutator (PB PH : State iota →L[ℝ] State iota) : |
| 34 | State iota →L[ℝ] State iota := |
| 35 | (highGenerator lambda).comp PH - PB.comp (highGenerator lambda) |
| 36 | |
| 37 | def pullbackForcing (hT : 0 ≤ T) (PB PH : State iota →L[ℝ] State iota) |
| 38 | (F : ForcingSpace iota T) : ForcingSpace iota T := |
| 39 | PB.compLpL 2 (timeMeasure T) F + |
| 40 | (pullbackCommutator lambda PB PH).compLpL 2 (timeMeasure T) |
| 41 | (shiftedHighOperator hT lambda F) |
| 42 | |
| 43 | theorem pullbackForcing_coe (hT : 0 ≤ T) (PB PH : State iota →L[ℝ] State iota) |
| 44 | (F : ForcingSpace iota T) : |
| 45 | pullbackForcing lambda hT PB PH F =ᵐ[timeMeasure T] fun t => |
| 46 | PB (F t) + highGenerator lambda (PH (shiftedHighOperator hT lambda F t)) - |
| 47 | PB (highGenerator lambda (shiftedHighOperator hT lambda F t)) := by |
| 48 | filter_upwards [PB.coeFn_compLpL F, |
| 49 | (pullbackCommutator lambda PB PH).coeFn_compLpL (shiftedHighOperator hT lambda F), |
| 50 | Lp.coeFn_add (PB.compLpL 2 (timeMeasure T) F) |
| 51 | ((pullbackCommutator lambda PB PH).compLpL 2 (timeMeasure T) |
| 52 | (shiftedHighOperator hT lambda F))] with t hP hC hadd |
| 53 | change (PB.compLpL 2 (timeMeasure T) F + |
| 54 | (pullbackCommutator lambda PB PH).compLpL 2 (timeMeasure T) |
| 55 | (shiftedHighOperator hT lambda F)) t = _ |
| 56 | rw [hadd, Pi.add_apply, hP, hC] |
| 57 | change PB (F t) + (highGenerator lambda (PH (shiftedHighOperator hT lambda F t)) - |
| 58 | PB (highGenerator lambda (shiftedHighOperator hT lambda F t))) = _ |
| 59 | abel |
| 60 | |
| 61 | theorem highGenerator_eq_mul_decode (x : State iota) (i : iota) : |
| 62 | highGenerator lambda x i = (lambda i : ℝ) * scaleDecode lambda 2 x i := by |
| 63 | rw [highGenerator_apply, scaleDecode_apply, scaleWeight_two] |
| 64 | simp only [div_eq_mul_inv, mul_assoc] |
| 65 | |
| 66 | theorem highGenerator_shiftedHigh_ae (hT : 0 ≤ T) (F : ForcingSpace iota T) : |
| 67 | (fun t => highGenerator lambda (shiftedHighOperator hT lambda F t)) =ᵐ[timeMeasure T] |
| 68 | generatorState lambda F := by |
| 69 | filter_upwards [scaleDecode_shiftedHigh hT lambda F, |
| 70 | ae_generatorState_apply_of_memLp hT (Lp.memLp F) lambda] with t hdecode hgen |
| 71 | apply lp.ext |
| 72 | funext i |
| 73 | rw [highGenerator_eq_mul_decode, hdecode, hgen i] |
| 74 | |
| 75 | /-- The commutator identity is first an identity of actual integrable derivatives. -/ |
| 76 | theorem derivative_difference_ae (hT : 0 ≤ T) |
| 77 | (PB PH : State iota →L[ℝ] State iota) |
| 78 | (hcompat : ∀ z, PB (scaleDecode lambda 2 z) = scaleDecode lambda 2 (PH z)) |
| 79 | (F : ForcingSpace iota T) : |
| 80 | ∀ᵐ t ∂timeMeasure T, ∀ i, |
| 81 | derivativeState lambda (pullbackForcing lambda hT PB PH F) t i - |
| 82 | PB (derivativeState lambda F t) i = |
| 83 | -(lambda i : ℝ) * (responseState lambda (pullbackForcing lambda hT PB PH F) t i - |
| 84 | PB (responseState lambda F t) i) := by |
| 85 | let G := pullbackForcing lambda hT PB PH F |
| 86 | filter_upwards [pullbackForcing_coe lambda hT PB PH F, |
| 87 | highGenerator_shiftedHigh_ae lambda hT F, scaleDecode_shiftedHigh hT lambda F, |
| 88 | derivativeState_add_generatorState_of_memLp hT (Lp.memLp F) lambda, |
| 89 | derivativeState_add_generatorState_of_memLp hT (Lp.memLp G) lambda, |
| 90 | ae_generatorState_apply_of_memLp hT (Lp.memLp G) lambda] |
| 91 | with t hforce hhigh hdecode hD hDG hGG |
| 92 | have hforce' : G t = PB (derivativeState lambda F t) + |
| 93 | highGenerator lambda (PH (shiftedHighOperator hT lambda F t)) := by |
| 94 | change G t = _ at hforce |
| 95 | rw [hhigh, ← hD, map_add] at hforce |
| 96 | exact hforce.trans (by abel) |
| 97 | have hdiff : derivativeState lambda G t - PB (derivativeState lambda F t) = |
| 98 | highGenerator lambda (PH (shiftedHighOperator hT lambda F t)) - generatorState lambda G t := by |
| 99 | rw [eq_sub_of_add_eq hDG, hforce'] |
| 100 | abel |
| 101 | intro i |
| 102 | have hscalar := congrArg (fun z : State iota => z i) hdiff |
| 103 | change derivativeState lambda G t i - PB (derivativeState lambda F t) i = |
| 104 | highGenerator lambda (PH (shiftedHighOperator hT lambda F t)) i - |
| 105 | generatorState lambda G t i at hscalar |
| 106 | rw [highGenerator_eq_mul_decode, ← hcompat, hdecode, hGG i] at hscalar |
| 107 | exact hscalar.trans (by ring) |
| 108 | |
| 109 | private theorem intervalIntegrable_derivative_prefix (hT : 0 ≤ T) |
| 110 | (F : ForcingSpace iota T) {t : ℝ} (ht : t ∈ Icc (0 : ℝ) T) : |
| 111 | IntervalIntegrable (derivativeState lambda F) volume 0 t := by |
| 112 | apply (intervalIntegrable_iff_integrableOn_Ioc_of_le ht.1).mpr |
| 113 | exact ((intervalIntegrable_iff_integrableOn_Ioc_of_le hT).mp |
| 114 | (intervalIntegrable_derivativeState_of_memLp hT (Lp.memLp F) lambda)).mono_set |
| 115 | (Ioc_subset_Ioc le_rfl ht.2) |
| 116 | |
| 117 | private theorem scalar_integral_unique_zero {f : ℝ → ℝ} (hT : 0 ≤ T) |
| 118 | (hf : ContinuousOn f (Icc (0 : ℝ) T)) (c : ℝ) |
| 119 | (hint : ∀ t ∈ Icc (0 : ℝ) T, f t = ∫ s in (0 : ℝ)..t, c * f s) : |
| 120 | ∀ t ∈ Icc (0 : ℝ) T, f t = 0 := by |
| 121 | have hsrc : ContinuousOn (fun t => c * f t) (Icc (0 : ℝ) T) := |
| 122 | continuousOn_const.mul hf |
| 123 | have hvolterra : ∀ t ∈ Icc (0 : ℝ) T, |
| 124 | f t = volterraPath (0 : ℝ) (fun s => c * f s) t := by |
| 125 | simpa only [volterraPath, zero_add] using hint |
| 126 | apply eq_zero_of_abs_deriv_le_mul_abs_self_of_eq_zero_right hf |
| 127 | · intro t ht |
| 128 | have hd := (hasDerivWithinAt_volterraPath_Icc (x₀ := (0 : ℝ)) hsrc |
| 129 | (Ico_subset_Icc_self ht)).congr_of_mem hvolterra (Ico_subset_Icc_self ht) |
| 130 | exact hd.mono_of_mem_nhdsWithin (Icc_mem_nhdsGE_of_mem ht) |
| 131 | · simpa only [intervalIntegral.integral_same] using hint 0 ⟨le_rfl, hT⟩ |
| 132 | · intro t _ |
| 133 | exact le_of_eq (norm_mul c (f t)) |
| 134 | |
| 135 | /-- The coefficient difference satisfies an all-time integral equation. -/ |
| 136 | theorem response_difference_integral (hT : 0 ≤ T) |
| 137 | (PB PH : State iota →L[ℝ] State iota) |
| 138 | (hcompat : ∀ z, PB (scaleDecode lambda 2 z) = scaleDecode lambda 2 (PH z)) |
| 139 | (F : ForcingSpace iota T) {t : ℝ} (ht : t ∈ Icc (0 : ℝ) T) (i : iota) : |
| 140 | responseState lambda (pullbackForcing lambda hT PB PH F) t i - |
| 141 | PB (responseState lambda F t) i = |
| 142 | ∫ s in (0 : ℝ)..t, -(lambda i : ℝ) * |
| 143 | (responseState lambda (pullbackForcing lambda hT PB PH F) s i - |
| 144 | PB (responseState lambda F s) i) := by |
| 145 | let G := pullbackForcing lambda hT PB PH F |
| 146 | let ev : State iota →L[ℝ] ℝ := lp.evalCLM ℝ (fun _ : iota => ℝ) 2 i |
| 147 | have hDF := intervalIntegrable_derivative_prefix lambda hT F ht |
| 148 | have hDG := intervalIntegrable_derivative_prefix lambda hT G ht |
| 149 | have hFscalar : IntervalIntegrable (fun s => PB (derivativeState lambda F s) i) volume 0 t := |
| 150 | ⟨(ev.comp PB).integrable_comp hDF.1, (ev.comp PB).integrable_comp hDF.2⟩ |
| 151 | have hGscalar : IntervalIntegrable (fun s => derivativeState lambda G s i) volume 0 t := |
| 152 | ⟨ev.integrable_comp hDG.1, ev.integrable_comp hDG.2⟩ |
| 153 | have hFint : PB (responseState lambda F t) i = |
| 154 | ∫ s in (0 : ℝ)..t, PB (derivativeState lambda F s) i := |
| 155 | ((ev.comp PB).intervalIntegral_comp_comm hDF).symm |
| 156 | have hGint : responseState lambda G t i = |
| 157 | ∫ s in (0 : ℝ)..t, derivativeState lambda G s i := |
| 158 | (ev.intervalIntegral_comp_comm hDG).symm |
| 159 | rw [hGint, hFint, ← intervalIntegral.integral_sub hGscalar hFscalar] |
| 160 | apply intervalIntegral.integral_congr_ae_restrict |
| 161 | rw [uIoc_of_le ht.1] |
| 162 | filter_upwards [ae_restrict_of_ae_restrict_of_subset |
| 163 | (Ioc_subset_Ioc le_rfl ht.2) (derivative_difference_ae lambda hT PB PH hcompat F)] |
| 164 | with s hs |
| 165 | exact hs i |
| 166 | |
| 167 | /-- Integral uniqueness identifies the response at every time, including zero. -/ |
| 168 | theorem responseState_pullbackForcing (hT : 0 ≤ T) |
| 169 | (PB PH : State iota →L[ℝ] State iota) |
| 170 | (hcompat : ∀ z, PB (scaleDecode lambda 2 z) = scaleDecode lambda 2 (PH z)) |
| 171 | (F : ForcingSpace iota T) {t : ℝ} (ht : t ∈ Icc (0 : ℝ) T) : |
| 172 | responseState lambda (pullbackForcing lambda hT PB PH F) t = |
| 173 | PB (responseState lambda F t) := by |
| 174 | let G := pullbackForcing lambda hT PB PH F |
| 175 | have hF := continuousOn_responseState_of_memLp hT (Lp.memLp F) lambda |
| 176 | have hG := continuousOn_responseState_of_memLp hT (Lp.memLp G) lambda |
| 177 | apply lp.ext |
| 178 | funext i |
| 179 | let ev : State iota →L[ℝ] ℝ := lp.evalCLM ℝ (fun _ : iota => ℝ) 2 i |
| 180 | have hw : ContinuousOn (fun s => responseState lambda G s i - |
| 181 | PB (responseState lambda F s) i) (Icc (0 : ℝ) T) := |
| 182 | (ev.continuous.comp_continuousOn hG).sub |
| 183 | ((ev.comp PB).continuous.comp_continuousOn hF) |
| 184 | exact sub_eq_zero.mp (scalar_integral_unique_zero hT hw (-(lambda i : ℝ)) |
| 185 | (fun s hs => response_difference_integral lambda hT PB PH hcompat F hs i) t ht) |
| 186 | |
| 187 | theorem shiftedHigh_pullbackForcing_ae (hT : 0 ≤ T) |
| 188 | (PB PH : State iota →L[ℝ] State iota) |
| 189 | (hcompat : ∀ z, PB (scaleDecode lambda 2 z) = scaleDecode lambda 2 (PH z)) |
| 190 | (F : ForcingSpace iota T) : |
| 191 | shiftedHighOperator hT lambda (pullbackForcing lambda hT PB PH F) =ᵐ[timeMeasure T] |
| 192 | fun t => PH (shiftedHighOperator hT lambda F t) := by |
| 193 | filter_upwards [scaleDecode_shiftedHigh hT lambda (pullbackForcing lambda hT PB PH F), |
| 194 | scaleDecode_shiftedHigh hT lambda F, ae_restrict_mem measurableSet_Ioc] |
| 195 | with t hnew hold ht |
| 196 | apply scaleDecode_injective lambda 2 |
| 197 | rw [hnew, ← hcompat, hold] |
| 198 | exact responseState_pullbackForcing lambda hT PB PH hcompat F (Ioc_subset_Icc_self ht) |
| 199 | |
| 200 | theorem shiftedTrace_pullbackForcing_ae (hT : 0 ≤ T) |
| 201 | (PB PH : State iota →L[ℝ] State iota) |
| 202 | (hcompat : ∀ z, PB (scaleDecode lambda 2 z) = scaleDecode lambda 2 (PH z)) |
| 203 | (F : ForcingSpace iota T) : |
| 204 | ∀ᵐ t ∂timeMeasure T, ∀ ht : t ∈ Icc (0 : ℝ) T, |
| 205 | shiftedTracePath hT lambda (pullbackForcing lambda hT PB PH F) ⟨t, ht⟩ = |
| 206 | shiftedBaseMultiplier lambda (PH (shiftedHighOperator hT lambda F t)) := by |
| 207 | filter_upwards [intermediate_high_eq_trace hT lambda (pullbackForcing lambda hT PB PH F), |
| 208 | shiftedHigh_pullbackForcing_ae lambda hT PB PH hcompat F] with t htrace hhigh |
| 209 | intro ht |
| 210 | exact (htrace ht).symm.trans (congrArg (shiftedBaseMultiplier lambda) hhigh) |
| 211 | |
| 212 | end LinearTransport |
| 213 | |
| 214 | section NativeTransport |
| 215 | |
| 216 | open TensorHilbertNative NativeChartScalarLocalization DeTurckStatePullbackNative ChartMeasureNative |
| 217 | |
| 218 | variable {n : ℕ} {M : Type*} [TopologicalSpace M] [T2Space M] |
| 219 | [ChartedSpace (EuclideanSpace ℝ (Fin n)) M] [IsManifold (𝓡 n) ∞ M] |
| 220 | [CompactSpace M] [SecondCountableTopology M] [MeasurableSpace M] [BorelSpace M] |
| 221 | {g0 : RiemannianMetric n M} (d : Data g0) (L : FiniteChartLocalizationData d.charts) |
| 222 | (Phi : Diffeomorph (𝓡 n) (𝓡 n) M M ∞) {C : ENNReal} |
| 223 | (hC : C ≠ ⊤) (hdom : d.charts.measure.map Phi ≤ C • d.charts.measure) |
| 224 | |
| 225 | def nativePullbackForcing (r : ℕ) {T : ℝ} (hT : 0 ≤ T) |
| 226 | (F : ForcingSpace d.SymmetricIndex T) : ForcingSpace d.SymmetricIndex T := |
| 227 | pullbackForcing d.symmetricParameters hT |
| 228 | (evenPullback d Phi hC hdom L r) (evenPullback d Phi hC hdom L (r + 1)) F |
| 229 | |
| 230 | theorem responseState_nativePullbackForcing (r : ℕ) {T : ℝ} (hT : 0 ≤ T) |
| 231 | (F : ForcingSpace d.SymmetricIndex T) {t : ℝ} (ht : t ∈ Icc (0 : ℝ) T) : |
| 232 | responseState d.symmetricParameters (nativePullbackForcing d L Phi hC hdom r hT F) t = |
| 233 | evenPullback d Phi hC hdom L r (responseState d.symmetricParameters F t) := |
| 234 | responseState_pullbackForcing d.symmetricParameters hT |
| 235 | (evenPullback d Phi hC hdom L r) (evenPullback d Phi hC hdom L (r + 1)) |
| 236 | (evenPullback_scaleDecode_two d L Phi hC hdom r) F ht |
| 237 | |
| 238 | theorem shiftedHigh_nativePullbackForcing_ae (r : ℕ) {T : ℝ} (hT : 0 ≤ T) |
| 239 | (F : ForcingSpace d.SymmetricIndex T) : |
| 240 | shiftedHighOperator hT d.symmetricParameters |
| 241 | (nativePullbackForcing d L Phi hC hdom r hT F) =ᵐ[timeMeasure T] |
| 242 | fun t => evenPullback d Phi hC hdom L (r + 1) (shiftedHighOperator hT d.symmetricParameters F t) := |
| 243 | shiftedHigh_pullbackForcing_ae d.symmetricParameters hT |
| 244 | (evenPullback d Phi hC hdom L r) (evenPullback d Phi hC hdom L (r + 1)) |
| 245 | (evenPullback_scaleDecode_two d L Phi hC hdom r) F |
| 246 | |
| 247 | theorem shiftedTrace_nativePullbackForcing_ae (r : ℕ) {T : ℝ} (hT : 0 ≤ T) |
| 248 | (F : ForcingSpace d.SymmetricIndex T) : |
| 249 | ∀ᵐ t ∂timeMeasure T, ∀ ht : t ∈ Icc (0 : ℝ) T, |
| 250 | shiftedTracePath hT d.symmetricParameters |
| 251 | (nativePullbackForcing d L Phi hC hdom r hT F) ⟨t, ht⟩ = |
| 252 | shiftedBaseMultiplier d.symmetricParameters |
| 253 | (evenPullback d Phi hC hdom L (r + 1) (shiftedHighOperator hT d.symmetricParameters F t)) := |
| 254 | shiftedTrace_pullbackForcing_ae d.symmetricParameters hT |
| 255 | (evenPullback d Phi hC hdom L r) (evenPullback d Phi hC hdom L (r + 1)) |
| 256 | (evenPullback_scaleDecode_two d L Phi hC hdom r) F |
| 257 | |
| 258 | end NativeTransport |
| 259 | |
| 260 | end PoincareMT.DeTurckPullbackResponseNative |
| 261 | |
| 262 | end |