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 | /- |
| 2 | Provenance and modification notice (recorded 2026-09-29). |
| 3 | Notices for the adapted source: |
| 4 | Copyright 2026 The DifferentialGeometry contributors |
| 5 | Source: https://github.com/qinz1yang/differential-geometry |
| 6 | DifferentialGeometry/Analysis/Sobolev/Tools/DifferenceQuotientWeakLimitLoc.lean |
| 7 | Comparison revision: 1b535dd102b94cc42b107cca27059687888f08b3. |
| 8 | Changes: Imports, module paths, and namespaces were adapted to the subject-organized PoincareLib library. The local file extracts a subset of the upstream development. |
| 9 | License: Apache-2.0. Source licenses and notices are retained under |
| 10 | PoincareConjecture/provenance/2026-09-29/licenses/. |
| 11 | See PoincareConjecture/MODIFICATIONS.md for the reviewed source mapping. |
| 12 | -/ |
| 13 | |
| 14 | import PoincareLib.Analysis.Elliptic.Regularity.DifferenceQuotient.TestSpace |
| 15 | import Mathlib.Analysis.Normed.Operator.Extend |
| 16 | import Mathlib.Analysis.InnerProductSpace.Dual |
| 17 | import Mathlib.MeasureTheory.Function.L2Space |
| 18 | |
| 19 | /-! |
| 20 | # Local bounded functionals from difference quotients |
| 21 | |
| 22 | Adapted from Chow--Liao--Qin, `Analysis/Sobolev/Tools/DifferenceQuotientWeakLimitLoc.lean`, |
| 23 | revision `1b535dd102b94cc42b107cca27059687888f08b3`. |
| 24 | Apache-2.0; see `PoincareConjecture/provenance/2026-09-29/licenses/DifferentialGeometry/LICENSE`. |
| 25 | -/ |
| 26 | |
| 27 | noncomputable section |
| 28 | |
| 29 | open MeasureTheory Metric Filter Topology Set Function |
| 30 | open scoped ENNReal NNReal Convolution Pointwise BigOperators InnerProductSpace |
| 31 | RealInnerProductSpace |
| 32 | |
| 33 | namespace Poincare.Analysis.Sobolev |
| 34 | |
| 35 | variable {d : ℕ} [NeZero d] |
| 36 | |
| 37 | local notation "E" => EuclideanSpace ℝ (Fin d) |
| 38 | |
| 39 | omit [NeZero d] in |
| 40 | lemma integrable_w_partial_phi_loc |
| 41 | {Ω : Set E} {w : E → ℝ} |
| 42 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 43 | {φ : E → ℝ} (hφ_smooth : ContDiff ℝ (⊤ : ℕ∞) φ) |
| 44 | (hφ_supp : HasCompactSupport φ) (k : Fin d) : |
| 45 | Integrable (fun x => w x * (fderiv ℝ φ x) (EuclideanSpace.single k 1)) |
| 46 | ((volume : Measure E).restrict Ω) := by |
| 47 | have h_partial_cont : Continuous |
| 48 | (fun x : E => (fderiv ℝ φ x) (EuclideanSpace.single k 1)) := |
| 49 | (hφ_smooth.continuous_fderiv (by simp : ((⊤ : ℕ∞) : WithTop ℕ∞) ≠ 0)).clm_apply |
| 50 | continuous_const |
| 51 | have h_partial_supp : |
| 52 | HasCompactSupport (fun x : E => (fderiv ℝ φ x) (EuclideanSpace.single k 1)) := |
| 53 | hφ_supp.fderiv_apply (𝕜 := ℝ) (EuclideanSpace.single k 1) |
| 54 | have h_partial_memLp : |
| 55 | MemLp (fun x : E => (fderiv ℝ φ x) (EuclideanSpace.single k 1)) 2 |
| 56 | ((volume : Measure E).restrict Ω) := |
| 57 | (h_partial_cont.memLp_of_hasCompactSupport h_partial_supp).restrict _ |
| 58 | exact MemLp.integrable_mul hw_l2 h_partial_memLp |
| 59 | |
| 60 | def smoothTestFunctionalLoc |
| 61 | {Ω Ω'' : Set E} {w : E → ℝ} |
| 62 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 63 | (k : Fin d) : |
| 64 | smoothCSSupportedInSubmodule (d := d) Ω'' →ₗ[ℝ] ℝ where |
| 65 | toFun φ := |
| 66 | -∫ x in Ω, w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) |
| 67 | ∂(volume : Measure E) |
| 68 | map_add' φ ψ := by |
| 69 | change |
| 70 | -∫ x in Ω, w x * |
| 71 | (fderiv ℝ ((φ + ψ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 72 | (EuclideanSpace.single k 1) ∂(volume : Measure E) = |
| 73 | (-∫ x in Ω, w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) |
| 74 | ∂(volume : Measure E)) + |
| 75 | (-∫ x in Ω, w x * (fderiv ℝ ψ.1 x) (EuclideanSpace.single k 1) |
| 76 | ∂(volume : Measure E)) |
| 77 | have hφ_diff : Differentiable ℝ φ.1 := φ.2.1.differentiable (by simp) |
| 78 | have hψ_diff : Differentiable ℝ ψ.1 := ψ.2.1.differentiable (by simp) |
| 79 | have h_fderiv_sum : ∀ x : E, |
| 80 | (fderiv ℝ ((φ + ψ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 81 | (EuclideanSpace.single k 1) = |
| 82 | (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) + |
| 83 | (fderiv ℝ ψ.1 x) (EuclideanSpace.single k 1) := by |
| 84 | intro x |
| 85 | have hcoe : ((φ + ψ : smoothCSSupportedInSubmodule (d := d) Ω'').1 : E → ℝ) = |
| 86 | φ.1 + ψ.1 := rfl |
| 87 | rw [hcoe] |
| 88 | rw [show (φ.1 + ψ.1 : E → ℝ) = fun y => φ.1 y + ψ.1 y from rfl] |
| 89 | rw [fderiv_fun_add (hφ_diff.differentiableAt) (hψ_diff.differentiableAt)] |
| 90 | simp |
| 91 | have hint_sum : ∀ x : E, |
| 92 | w x * (fderiv ℝ ((φ + ψ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 93 | (EuclideanSpace.single k 1) = |
| 94 | w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) + |
| 95 | w x * (fderiv ℝ ψ.1 x) (EuclideanSpace.single k 1) := by |
| 96 | intro x; rw [h_fderiv_sum x]; ring |
| 97 | have hφ_int := integrable_w_partial_phi_loc (d := d) hw_l2 φ.2.1 φ.2.2.1 k |
| 98 | have hψ_int := integrable_w_partial_phi_loc (d := d) hw_l2 ψ.2.1 ψ.2.2.1 k |
| 99 | have h_int_eq : |
| 100 | ∫ x in Ω, w x * |
| 101 | (fderiv ℝ ((φ + ψ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 102 | (EuclideanSpace.single k 1) ∂(volume : Measure E) = |
| 103 | (∫ x in Ω, w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) |
| 104 | ∂(volume : Measure E)) + |
| 105 | ∫ x in Ω, w x * (fderiv ℝ ψ.1 x) (EuclideanSpace.single k 1) |
| 106 | ∂(volume : Measure E) := by |
| 107 | rw [show (fun x => w x * |
| 108 | (fderiv ℝ ((φ + ψ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 109 | (EuclideanSpace.single k 1)) = |
| 110 | (fun x => |
| 111 | w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) + |
| 112 | w x * (fderiv ℝ ψ.1 x) (EuclideanSpace.single k 1)) from by |
| 113 | ext x; exact hint_sum x] |
| 114 | exact integral_add hφ_int hψ_int |
| 115 | rw [h_int_eq]; ring |
| 116 | map_smul' c φ := by |
| 117 | change |
| 118 | -∫ x in Ω, w x * |
| 119 | (fderiv ℝ ((c • φ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 120 | (EuclideanSpace.single k 1) ∂(volume : Measure E) = |
| 121 | c • (-∫ x in Ω, w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) |
| 122 | ∂(volume : Measure E)) |
| 123 | have hφ_diff : Differentiable ℝ φ.1 := φ.2.1.differentiable (by simp) |
| 124 | have h_fderiv_smul : ∀ x : E, |
| 125 | (fderiv ℝ ((c • φ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 126 | (EuclideanSpace.single k 1) = |
| 127 | c * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) := by |
| 128 | intro x |
| 129 | have hcoe : ((c • φ : smoothCSSupportedInSubmodule (d := d) Ω'').1 |
| 130 | : E → ℝ) = c • φ.1 := rfl |
| 131 | rw [hcoe] |
| 132 | have heq2 : (c • φ.1 : E → ℝ) = fun y => c * φ.1 y := by ext y; rfl |
| 133 | rw [heq2] |
| 134 | rw [fderiv_const_mul (hφ_diff.differentiableAt) c] |
| 135 | simp |
| 136 | have hint_smul : ∀ x : E, |
| 137 | w x * (fderiv ℝ ((c • φ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 138 | (EuclideanSpace.single k 1) = |
| 139 | c * (w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1)) := by |
| 140 | intro x; rw [h_fderiv_smul x]; ring |
| 141 | have h_int_eq : |
| 142 | ∫ x in Ω, w x * (fderiv ℝ ((c • φ : smoothCSSupportedInSubmodule |
| 143 | (d := d) Ω'').1) x) |
| 144 | (EuclideanSpace.single k 1) ∂(volume : Measure E) = |
| 145 | c * ∫ x in Ω, w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) |
| 146 | ∂(volume : Measure E) := by |
| 147 | rw [show (fun x => w x * |
| 148 | (fderiv ℝ ((c • φ : smoothCSSupportedInSubmodule (d := d) Ω'').1) x) |
| 149 | (EuclideanSpace.single k 1)) = |
| 150 | (fun x => c * (w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1))) |
| 151 | from by ext x; exact hint_smul x] |
| 152 | exact integral_const_mul _ _ |
| 153 | rw [h_int_eq] |
| 154 | rw [smul_eq_mul]; ring |
| 155 | |
| 156 | omit [NeZero d] in |
| 157 | @[simp] lemma smoothTestFunctional_loc_apply |
| 158 | {Ω Ω'' : Set E} {w : E → ℝ} |
| 159 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 160 | (k : Fin d) (φ : smoothCSSupportedInSubmodule (d := d) Ω'') : |
| 161 | smoothTestFunctionalLoc (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k φ = |
| 162 | -∫ x in Ω, w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) |
| 163 | ∂(volume : Measure E) := rfl |
| 164 | |
| 165 | omit [NeZero d] in |
| 166 | lemma diffQuot_eq_zero_of_notMem_cthickening_loc |
| 167 | {φ : E → ℝ} (_hφ_supp : HasCompactSupport φ) |
| 168 | (k : Fin d) {h₀ : ℝ} (_hh₀ : 0 ≤ h₀) {h : ℝ} (hh_bd : |h| ≤ h₀) : |
| 169 | ∀ x : E, x ∉ Metric.cthickening h₀ (tsupport φ) → |
| 170 | diffQuot k h φ x = 0 := by |
| 171 | intro x hx |
| 172 | have hxnot : x ∉ tsupport φ := fun h => hx (Metric.self_subset_cthickening _ h) |
| 173 | have hφx : φ x = 0 := image_eq_zero_of_notMem_tsupport hxnot |
| 174 | have hxhe : x + h • EuclideanSpace.single k 1 ∉ tsupport φ := by |
| 175 | intro hin |
| 176 | apply hx |
| 177 | have hnorm : |
| 178 | dist x (x + h • EuclideanSpace.single k 1) = |h| := by |
| 179 | rw [dist_eq_norm] |
| 180 | have heq : x - (x + h • EuclideanSpace.single k 1) = |
| 181 | -(h • EuclideanSpace.single k 1) := by abel |
| 182 | rw [heq, norm_neg, norm_smul] |
| 183 | rw [show ‖(EuclideanSpace.single k (1 : ℝ) : E)‖ = 1 by simp] |
| 184 | rw [Real.norm_eq_abs, mul_one] |
| 185 | have h_dist_le : dist x (x + h • EuclideanSpace.single k 1) ≤ h₀ := by |
| 186 | rw [hnorm]; exact hh_bd |
| 187 | exact Metric.mem_cthickening_of_dist_le x |
| 188 | (x + h • EuclideanSpace.single k 1) h₀ (tsupport φ) hin h_dist_le |
| 189 | have hφxhe : φ (x + h • EuclideanSpace.single k 1) = 0 := |
| 190 | image_eq_zero_of_notMem_tsupport hxhe |
| 191 | by_cases hh : h = 0 |
| 192 | · rw [hh]; simp [diffQuot] |
| 193 | · rw [diffQuot_apply_of_ne (d := d) k hh φ x] |
| 194 | rw [hφx, hφxhe] |
| 195 | simp |
| 196 | |
| 197 | omit [NeZero d] in |
| 198 | lemma tendsto_integral_w_diffQuot_phi_loc |
| 199 | {Ω : Set E} {w : E → ℝ} |
| 200 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 201 | {φ : E → ℝ} (hφ_smooth : ContDiff ℝ (⊤ : ℕ∞) φ) |
| 202 | (hφ_supp : HasCompactSupport φ) (k : Fin d) |
| 203 | {hₙ : ℕ → ℝ} (hₙ_ne : ∀ n, hₙ n ≠ 0) |
| 204 | (hₙ_tendsto : Tendsto hₙ atTop (𝓝 0)) : |
| 205 | Tendsto (fun n => |
| 206 | ∫ x in Ω, w x * diffQuot k (-(hₙ n)) φ x ∂(volume : Measure E)) |
| 207 | atTop |
| 208 | (𝓝 (∫ x in Ω, w x * (fderiv ℝ φ x) (EuclideanSpace.single k 1) |
| 209 | ∂(volume : Measure E))) := by |
| 210 | have hφ_C1 : ContDiff ℝ 1 φ := hφ_smooth.of_le (by norm_cast) |
| 211 | have h_lip : ∃ L : ℝ, 0 ≤ L ∧ ∀ h : ℝ, ∀ x : E, |diffQuot k h φ x| ≤ L := by |
| 212 | obtain ⟨L, hL_nn, hLip⟩ := |
| 213 | lipschitz_of_contDiff_compactSupport (d := d) hφ_C1 hφ_supp |
| 214 | refine ⟨L, hL_nn, fun h x => ?_⟩ |
| 215 | by_cases hh : h = 0 |
| 216 | · rw [hh, diffQuot_zero_h]; simpa using hL_nn |
| 217 | · rw [diffQuot_apply_of_ne (d := d) k hh φ x] |
| 218 | have hLip_apply : |
| 219 | ‖φ (x + h • EuclideanSpace.single k 1) - φ x‖ ≤ |
| 220 | L * ‖x + h • EuclideanSpace.single k 1 - x‖ := hLip _ _ |
| 221 | have hsimp : x + h • EuclideanSpace.single k 1 - x = |
| 222 | h • EuclideanSpace.single k 1 := by |
| 223 | rw [add_sub_cancel_left] |
| 224 | rw [hsimp] at hLip_apply |
| 225 | have hsing_norm : |
| 226 | ‖(EuclideanSpace.single k (1 : ℝ) : E)‖ = 1 := by simp |
| 227 | have hnorm_smul : |
| 228 | ‖h • EuclideanSpace.single k (1 : ℝ)‖ = |h| := by |
| 229 | rw [norm_smul, hsing_norm, mul_one, Real.norm_eq_abs] |
| 230 | rw [hnorm_smul] at hLip_apply |
| 231 | rw [abs_div] |
| 232 | have habs_h : 0 < |h| := abs_pos.mpr hh |
| 233 | rw [div_le_iff₀ habs_h] |
| 234 | have h_lhs_norm : |
| 235 | |φ (x + h • EuclideanSpace.single k 1) - φ x| = |
| 236 | ‖φ (x + h • EuclideanSpace.single k 1) - φ x‖ := |
| 237 | (Real.norm_eq_abs _).symm |
| 238 | rw [h_lhs_norm] |
| 239 | exact hLip_apply |
| 240 | obtain ⟨L, _hL_nn, hLip⟩ := h_lip |
| 241 | set h₀ : ℝ := 1 with h₀_def |
| 242 | have hh₀_nn : (0 : ℝ) ≤ h₀ := by simp [h₀_def] |
| 243 | have hN : ∀ᶠ n in atTop, |hₙ n| ≤ h₀ := by |
| 244 | have hAbs : Tendsto (fun n => |hₙ n|) atTop (𝓝 0) := by |
| 245 | have := hₙ_tendsto.abs; simpa using this |
| 246 | have h_ev : |
| 247 | ∀ᶠ n in atTop, dist (|hₙ n|) 0 < 1 := |
| 248 | hAbs.eventually (Metric.ball_mem_nhds 0 (by norm_num)) |
| 249 | filter_upwards [h_ev] with n hn |
| 250 | have h_dist : dist (|hₙ n|) 0 = |hₙ n| := by |
| 251 | rw [Real.dist_eq, sub_zero, abs_abs] |
| 252 | rw [h_dist] at hn |
| 253 | exact hn.le |
| 254 | set K_thick : Set E := Metric.cthickening h₀ (tsupport φ) with hKt_def |
| 255 | have hK_compact : IsCompact (tsupport φ) := hφ_supp |
| 256 | have hK_thick_compact : IsCompact K_thick := hK_compact.cthickening |
| 257 | have hK_thick_meas : MeasurableSet K_thick := |
| 258 | hK_thick_compact.measurableSet |
| 259 | set bound : E → ℝ := fun x => K_thick.indicator (fun y => L * |w y|) x |
| 260 | have hw_meas : AEStronglyMeasurable w ((volume : Measure E).restrict Ω) := |
| 261 | hw_l2.aestronglyMeasurable |
| 262 | have h_indicator_memLp_2 : |
| 263 | MemLp (fun x : E => K_thick.indicator (fun _ => (1 : ℝ)) x) 2 |
| 264 | ((volume : Measure E).restrict Ω) := by |
| 265 | have h_finite : ((volume : Measure E).restrict Ω) K_thick ≠ ∞ := by |
| 266 | have h₁ : ((volume : Measure E).restrict Ω) K_thick ≤ |
| 267 | (volume : Measure E) K_thick := Measure.restrict_le_self _ |
| 268 | exact ne_top_of_le_ne_top hK_thick_compact.measure_lt_top.ne h₁ |
| 269 | refine memLp_indicator_const _ hK_thick_meas (1 : ℝ) (Or.inr h_finite) |
| 270 | have h_abs_eq_norm : (fun x => |w x|) = fun x => ‖w x‖ := by |
| 271 | funext x; rw [Real.norm_eq_abs] |
| 272 | have h_abs_w_memLp : MemLp (fun x => |w x|) 2 |
| 273 | ((volume : Measure E).restrict Ω) := by |
| 274 | rw [h_abs_eq_norm] |
| 275 | exact hw_l2.norm |
| 276 | have h_Labsw_memLp : |
| 277 | MemLp (fun x => L * |w x|) 2 ((volume : Measure E).restrict Ω) := |
| 278 | h_abs_w_memLp.const_mul L |
| 279 | have h_bound_eq : |
| 280 | bound = (fun x => (L * |w x|) * |
| 281 | K_thick.indicator (fun _ => (1 : ℝ)) x) := by |
| 282 | funext x |
| 283 | simp only [bound] |
| 284 | by_cases hx : x ∈ K_thick |
| 285 | · rw [Set.indicator_of_mem hx, Set.indicator_of_mem hx, mul_one] |
| 286 | · rw [Set.indicator_of_notMem hx, Set.indicator_of_notMem hx, mul_zero] |
| 287 | have h_bound_int : Integrable bound ((volume : Measure E).restrict Ω) := by |
| 288 | rw [h_bound_eq] |
| 289 | exact MemLp.integrable_mul h_Labsw_memLp h_indicator_memLp_2 |
| 290 | have h_pointwise_bound : |
| 291 | ∀ᶠ n in atTop, ∀ᵐ x ∂((volume : Measure E).restrict Ω), |
| 292 | ‖w x * diffQuot k (-(hₙ n)) φ x‖ ≤ bound x := by |
| 293 | filter_upwards [hN] with n hn |
| 294 | refine Filter.Eventually.of_forall fun x => ?_ |
| 295 | by_cases hx : x ∈ K_thick |
| 296 | · simp only [bound, Set.indicator_of_mem hx] |
| 297 | rw [Real.norm_eq_abs, abs_mul] |
| 298 | have hL_dq : |diffQuot k (-(hₙ n)) φ x| ≤ L := hLip _ x |
| 299 | have h_abs_w_nn : 0 ≤ |w x| := abs_nonneg _ |
| 300 | have h_LL : |w x| * |diffQuot k (-(hₙ n)) φ x| ≤ |w x| * L := |
| 301 | mul_le_mul_of_nonneg_left hL_dq h_abs_w_nn |
| 302 | linarith |
| 303 | · have h_neg_h_bd : |-(hₙ n)| ≤ h₀ := by rw [abs_neg]; exact hn |
| 304 | have hdq_zero : diffQuot k (-(hₙ n)) φ x = 0 := |
| 305 | diffQuot_eq_zero_of_notMem_cthickening_loc (d := d) hφ_supp k hh₀_nn |
| 306 | h_neg_h_bd x hx |
| 307 | rw [hdq_zero, mul_zero, norm_zero] |
| 308 | simp [bound, Set.indicator_of_notMem hx] |
| 309 | have h_pointwise_conv : |
| 310 | ∀ᵐ x ∂((volume : Measure E).restrict Ω), |
| 311 | Tendsto (fun n => w x * diffQuot k (-(hₙ n)) φ x) atTop |
| 312 | (𝓝 (w x * (fderiv ℝ φ x) (EuclideanSpace.single k 1))) := by |
| 313 | refine Filter.Eventually.of_forall fun x => ?_ |
| 314 | have h_minus_tendsto : Tendsto (fun n => -(hₙ n)) atTop (𝓝 0) := by |
| 315 | have := hₙ_tendsto.neg; simpa using this |
| 316 | have h_minus_ne : ∀ n, -(hₙ n) ≠ 0 := fun n hn => |
| 317 | hₙ_ne n (neg_eq_zero.mp hn) |
| 318 | have h_dq_nhdsWithin : |
| 319 | Tendsto (fun h : ℝ => diffQuot k h φ x) (𝓝[≠] 0) |
| 320 | (𝓝 ((fderiv ℝ φ x) (EuclideanSpace.single k 1))) := |
| 321 | tendsto_diffQuot_of_contDiff (d := d) hφ_C1 k x |
| 322 | have h_tendsto_within : |
| 323 | Tendsto (fun n => -(hₙ n)) atTop (𝓝[≠] 0) := by |
| 324 | rw [tendsto_nhdsWithin_iff] |
| 325 | refine ⟨h_minus_tendsto, ?_⟩ |
| 326 | exact Filter.Eventually.of_forall fun n => h_minus_ne n |
| 327 | have h_dq_tendsto : |
| 328 | Tendsto (fun n => diffQuot k (-(hₙ n)) φ x) atTop |
| 329 | (𝓝 ((fderiv ℝ φ x) (EuclideanSpace.single k 1))) := |
| 330 | h_dq_nhdsWithin.comp h_tendsto_within |
| 331 | exact h_dq_tendsto.const_mul (w x) |
| 332 | have h_aesm_seq : ∀ n, AEStronglyMeasurable |
| 333 | (fun x => w x * diffQuot k (-(hₙ n)) φ x) |
| 334 | ((volume : Measure E).restrict Ω) := by |
| 335 | intro n |
| 336 | have hdq_global : AEStronglyMeasurable (diffQuot k (-(hₙ n)) φ) |
| 337 | (volume : Measure E) := |
| 338 | aestronglyMeasurable_diffQuot (d := d) k _ |
| 339 | hφ_smooth.continuous.aestronglyMeasurable |
| 340 | have hdq_meas : AEStronglyMeasurable (diffQuot k (-(hₙ n)) φ) |
| 341 | ((volume : Measure E).restrict Ω) := hdq_global.restrict |
| 342 | exact hw_meas.mul hdq_meas |
| 343 | exact tendsto_integral_filter_of_dominated_convergence |
| 344 | bound (Filter.Eventually.of_forall h_aesm_seq) |
| 345 | h_pointwise_bound h_bound_int h_pointwise_conv |
| 346 | |
| 347 | omit [NeZero d] in |
| 348 | lemma abs_integral_mul_le_eLpNorm_two_loc |
| 349 | {μ : Measure E} {f g : E → ℝ} (hf : MemLp f 2 μ) (hg : MemLp g 2 μ) : |
| 350 | ENNReal.ofReal |∫ x, f x * g x ∂μ| ≤ eLpNorm f 2 μ * eLpNorm g 2 μ := by |
| 351 | have h_abs_le_lintegral : |
| 352 | ENNReal.ofReal |∫ x, f x * g x ∂μ| ≤ ∫⁻ x, ‖f x * g x‖ₑ ∂μ := by |
| 353 | rw [← Real.norm_eq_abs] |
| 354 | have hint : ‖∫ x, f x * g x ∂μ‖ₑ ≤ ∫⁻ x, ‖f x * g x‖ₑ ∂μ := |
| 355 | enorm_integral_le_lintegral_enorm _ |
| 356 | have hofreal : ENNReal.ofReal ‖∫ x, f x * g x ∂μ‖ = ‖∫ x, f x * g x ∂μ‖ₑ := |
| 357 | ofReal_norm _ |
| 358 | rw [hofreal]; exact hint |
| 359 | have h_lintegral_eq : |
| 360 | ∫⁻ x, ‖f x * g x‖ₑ ∂μ = eLpNorm (fun x => g x * f x) 1 μ := by |
| 361 | rw [eLpNorm_one_eq_lintegral_enorm] |
| 362 | refine lintegral_congr (fun x => ?_) |
| 363 | simp [enorm_mul, mul_comm] |
| 364 | have : ENNReal.HolderTriple (2 : ℝ≥0∞) (2 : ℝ≥0∞) 1 := by |
| 365 | constructor |
| 366 | rw [show (1 : ℝ≥0∞)⁻¹ = 1 from inv_one] |
| 367 | rw [ENNReal.inv_two_add_inv_two] |
| 368 | have h_smul_bound : |
| 369 | eLpNorm (fun x => g x * f x) 1 μ ≤ eLpNorm g 2 μ * eLpNorm f 2 μ := by |
| 370 | have h_mul_eq : |
| 371 | (fun x => g x * f x) = (g : E → ℝ) • (f : E → ℝ) := by |
| 372 | funext x; simp [smul_eq_mul] |
| 373 | rw [h_mul_eq] |
| 374 | have : ENNReal.HolderTriple (2 : ℝ≥0∞) (2 : ℝ≥0∞) 1 := inferInstance |
| 375 | exact eLpNorm_smul_le_mul_eLpNorm hf.aestronglyMeasurable hg.aestronglyMeasurable |
| 376 | calc |
| 377 | ENNReal.ofReal |∫ x, f x * g x ∂μ| |
| 378 | ≤ ∫⁻ x, ‖f x * g x‖ₑ ∂μ := h_abs_le_lintegral |
| 379 | _ = eLpNorm (fun x => g x * f x) 1 μ := h_lintegral_eq |
| 380 | _ ≤ eLpNorm g 2 μ * eLpNorm f 2 μ := h_smul_bound |
| 381 | _ = eLpNorm f 2 μ * eLpNorm g 2 μ := mul_comm _ _ |
| 382 | |
| 383 | omit [NeZero d] in |
| 384 | lemma abs_integral_mul_le_norm_lp_mul_norm_lp_loc |
| 385 | {μ : Measure E} {f g : E → ℝ} (hf : MemLp f 2 μ) (hg : MemLp g 2 μ) : |
| 386 | |∫ x, f x * g x ∂μ| ≤ |
| 387 | (eLpNorm f 2 μ).toReal * (eLpNorm g 2 μ).toReal := by |
| 388 | have h_ennreal := abs_integral_mul_le_eLpNorm_two_loc (μ := μ) hf hg |
| 389 | have h_finite_f : eLpNorm f 2 μ ≠ ∞ := hf.eLpNorm_lt_top.ne |
| 390 | have h_finite_g : eLpNorm g 2 μ ≠ ∞ := hg.eLpNorm_lt_top.ne |
| 391 | have h_finite : eLpNorm f 2 μ * eLpNorm g 2 μ ≠ ∞ := |
| 392 | ENNReal.mul_ne_top h_finite_f h_finite_g |
| 393 | have h_toReal := ENNReal.toReal_mono h_finite h_ennreal |
| 394 | have hnn : 0 ≤ |∫ x, f x * g x ∂μ| := abs_nonneg _ |
| 395 | rw [ENNReal.toReal_ofReal hnn] at h_toReal |
| 396 | rw [ENNReal.toReal_mul] at h_toReal |
| 397 | exact h_toReal |
| 398 | |
| 399 | omit [NeZero d] in |
| 400 | lemma abs_smoothTestFunctional_loc_le |
| 401 | {Ω : Set E} (hΩ_open : IsOpen Ω) |
| 402 | {Ω'' : Set E} (hΩ''_open : IsOpen Ω'') |
| 403 | (hΩ''_compact_closure : IsCompact (closure Ω'')) |
| 404 | {h₀ : ℝ} (hh₀ : 0 < h₀) |
| 405 | (h_room : Metric.cthickening h₀ (closure Ω'') ⊆ Ω) |
| 406 | {w : E → ℝ} |
| 407 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 408 | (k : Fin d) {M : ℝ} (hM_nn : 0 ≤ M) |
| 409 | (h_bdd : ∀ h : ℝ, 0 < |h| → |h| ≤ h₀ → |
| 410 | eLpNorm (diffQuot k h w) 2 ((volume : Measure E).restrict Ω'') |
| 411 | ≤ ENNReal.ofReal M) |
| 412 | (φ : smoothCSSupportedInSubmodule (d := d) Ω'') : |
| 413 | |smoothTestFunctionalLoc (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k φ| ≤ |
| 414 | M * (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal := by |
| 415 | let _ := hΩ_open |
| 416 | let _ := hΩ''_open |
| 417 | let _ := hΩ''_compact_closure |
| 418 | rw [smoothTestFunctional_loc_apply] |
| 419 | rw [abs_neg] |
| 420 | set hₙ : ℕ → ℝ := fun n => h₀ / (n + 1) |
| 421 | have hₙ_pos : ∀ n, 0 < hₙ n := fun n => by |
| 422 | apply div_pos hh₀ |
| 423 | have : (0 : ℝ) < n + 1 := by exact_mod_cast Nat.zero_lt_succ n |
| 424 | exact this |
| 425 | have hₙ_ne : ∀ n, hₙ n ≠ 0 := fun n => (hₙ_pos n).ne' |
| 426 | have hₙ_bd : ∀ n, |hₙ n| ≤ h₀ := fun n => by |
| 427 | rw [abs_of_pos (hₙ_pos n)] |
| 428 | have h1 : (1 : ℝ) ≤ n + 1 := by |
| 429 | have h0 : (0 : ℝ) ≤ n := by exact_mod_cast Nat.zero_le (n := n) |
| 430 | linarith |
| 431 | rw [div_le_iff₀ (by exact_mod_cast Nat.zero_lt_succ n : (0 : ℝ) < n + 1)] |
| 432 | have : h₀ ≤ h₀ * (n + 1) := by nlinarith [hh₀.le] |
| 433 | linarith |
| 434 | have hₙ_pos_abs : ∀ n, 0 < |hₙ n| := fun n => by |
| 435 | rw [abs_of_pos (hₙ_pos n)]; exact hₙ_pos n |
| 436 | have hₙ_tendsto : Tendsto hₙ atTop (𝓝 0) := by |
| 437 | have hh0 : Tendsto (fun n : ℕ => (1 : ℝ) / (↑n + 1)) atTop (𝓝 (0 : ℝ)) := by |
| 438 | have := tendsto_one_div_add_atTop_nhds_zero_nat (𝕜 := ℝ) |
| 439 | exact this |
| 440 | have h_eq : ∀ n, hₙ n = h₀ * (1 / ((n : ℝ) + 1)) := fun n => by |
| 441 | simp only [hₙ]; ring |
| 442 | rw [show hₙ = fun n : ℕ => h₀ * (1 / ((↑n : ℝ) + 1)) from funext h_eq] |
| 443 | have hmul := hh0.const_mul h₀ |
| 444 | simpa using hmul |
| 445 | have hφ_memLp : MemLp φ.1 2 ((volume : Measure E).restrict Ω'') := |
| 446 | memLp_two_restrict_of_smoothCS (d := d) (Ω'' := Ω'') φ.2.1 φ.2.2.1 |
| 447 | have hφ_memLp_global : MemLp φ.1 2 (volume : Measure E) := |
| 448 | φ.2.1.continuous.memLp_of_hasCompactSupport φ.2.2.1 |
| 449 | have h_conv : Tendsto (fun n => |
| 450 | ∫ x in Ω, w x * diffQuot k (-(hₙ n)) φ.1 x ∂(volume : Measure E)) atTop |
| 451 | (𝓝 (∫ x in Ω, w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) |
| 452 | ∂(volume : Measure E))) := |
| 453 | tendsto_integral_w_diffQuot_phi_loc (d := d) hw_l2 φ.2.1 φ.2.2.1 k hₙ_ne hₙ_tendsto |
| 454 | have h_dq_l2_bound : ∀ n, |
| 455 | eLpNorm (diffQuot k (hₙ n) w) 2 ((volume : Measure E).restrict Ω'') |
| 456 | ≤ ENNReal.ofReal M := fun n => |
| 457 | h_bdd (hₙ n) (hₙ_pos_abs n) (hₙ_bd n) |
| 458 | set w_ext : E → ℝ := fun x => Ω.indicator w x with hw_ext_def |
| 459 | have hw_ext_eq_w_on_Ω : ∀ x ∈ Ω, w_ext x = w x := by |
| 460 | intro x hx |
| 461 | simp only [w_ext, Set.indicator_of_mem hx] |
| 462 | have hw_ext_zero_off_Ω : ∀ x ∉ Ω, w_ext x = 0 := by |
| 463 | intro x hx |
| 464 | simp only [w_ext, Set.indicator_of_notMem hx] |
| 465 | have hw_ext_memLp : MemLp w_ext 2 (volume : Measure E) := by |
| 466 | have h_aesm : AEStronglyMeasurable w_ext (volume : Measure E) := by |
| 467 | have h_w_aesm : AEStronglyMeasurable w ((volume : Measure E).restrict Ω) := |
| 468 | hw_l2.aestronglyMeasurable |
| 469 | exact (aestronglyMeasurable_indicator_iff hΩ_open.measurableSet).mpr h_w_aesm |
| 470 | refine ⟨h_aesm, ?_⟩ |
| 471 | have h_eLpNorm_eq : |
| 472 | eLpNorm w_ext 2 (volume : Measure E) = |
| 473 | eLpNorm w 2 ((volume : Measure E).restrict Ω) := by |
| 474 | rw [show w_ext = fun x => Ω.indicator w x from rfl] |
| 475 | rw [show eLpNorm w 2 ((volume : Measure E).restrict Ω) = |
| 476 | eLpNorm (Ω.indicator w) 2 (volume : Measure E) from |
| 477 | (eLpNorm_indicator_eq_eLpNorm_restrict hΩ_open.measurableSet).symm] |
| 478 | rw [h_eLpNorm_eq] |
| 479 | exact hw_l2.eLpNorm_lt_top |
| 480 | have h_dq_eq_on_tsupport : ∀ n : ℕ, ∀ x ∈ tsupport φ.1, |
| 481 | diffQuot k (hₙ n) w_ext x = diffQuot k (hₙ n) w x := by |
| 482 | intro n x hx |
| 483 | have hx_Ω'' : x ∈ Ω'' := φ.2.2.2 hx |
| 484 | have hx_closure_Ω'' : x ∈ closure Ω'' := subset_closure hx_Ω'' |
| 485 | have hx_in_Ω : x ∈ Ω := by |
| 486 | have h1 : x ∈ Metric.cthickening h₀ (closure Ω'') := |
| 487 | Metric.self_subset_cthickening _ hx_closure_Ω'' |
| 488 | exact h_room h1 |
| 489 | have hx_he_in_Ω : x + (hₙ n) • EuclideanSpace.single k 1 ∈ Ω := by |
| 490 | have h_dist : dist x (x + (hₙ n) • EuclideanSpace.single k 1) = |hₙ n| := by |
| 491 | rw [dist_eq_norm] |
| 492 | have heq : x - (x + (hₙ n) • EuclideanSpace.single k 1) = |
| 493 | -((hₙ n) • EuclideanSpace.single k 1) := by abel |
| 494 | rw [heq, norm_neg, norm_smul] |
| 495 | rw [show ‖(EuclideanSpace.single k (1 : ℝ) : E)‖ = 1 by simp] |
| 496 | rw [Real.norm_eq_abs, mul_one] |
| 497 | have h_in_thick : x + (hₙ n) • EuclideanSpace.single k 1 ∈ |
| 498 | Metric.cthickening h₀ (closure Ω'') := by |
| 499 | refine Metric.mem_cthickening_of_dist_le _ x h₀ (closure Ω'') hx_closure_Ω'' ?_ |
| 500 | rw [dist_comm]; rw [h_dist]; exact hₙ_bd n |
| 501 | exact h_room h_in_thick |
| 502 | have h_dq_apply : diffQuot k (hₙ n) w_ext x = |
| 503 | (w_ext (x + (hₙ n) • EuclideanSpace.single k 1) - w_ext x) / (hₙ n) := by |
| 504 | rw [diffQuot_apply_of_ne (d := d) k (hₙ_ne n) w_ext x] |
| 505 | have h_dq_w_apply : diffQuot k (hₙ n) w x = |
| 506 | (w (x + (hₙ n) • EuclideanSpace.single k 1) - w x) / (hₙ n) := by |
| 507 | rw [diffQuot_apply_of_ne (d := d) k (hₙ_ne n) w x] |
| 508 | rw [h_dq_apply, h_dq_w_apply] |
| 509 | rw [hw_ext_eq_w_on_Ω _ hx_in_Ω, hw_ext_eq_w_on_Ω _ hx_he_in_Ω] |
| 510 | have h_neg_h_int_eq_restrict : ∀ n, |
| 511 | ∫ x, w_ext x * diffQuot k (-(hₙ n)) φ.1 x ∂(volume : Measure E) = |
| 512 | ∫ x in Ω, w x * diffQuot k (-(hₙ n)) φ.1 x ∂(volume : Measure E) := by |
| 513 | intro n |
| 514 | have h_compl_zero : ∀ x ∉ Ω, w_ext x * diffQuot k (-(hₙ n)) φ.1 x = 0 := by |
| 515 | intro x hx |
| 516 | rw [hw_ext_zero_off_Ω x hx, zero_mul] |
| 517 | have h_split : ∫ x, w_ext x * diffQuot k (-(hₙ n)) φ.1 x |
| 518 | ∂(volume : Measure E) = |
| 519 | ∫ x in Ω, w_ext x * diffQuot k (-(hₙ n)) φ.1 x |
| 520 | ∂(volume : Measure E) := by |
| 521 | symm |
| 522 | rw [show (∫ x in Ω, w_ext x * diffQuot k (-(hₙ n)) φ.1 x |
| 523 | ∂(volume : Measure E)) = |
| 524 | ∫ x, Ω.indicator (fun y => w_ext y * diffQuot k (-(hₙ n)) φ.1 y) x |
| 525 | ∂(volume : Measure E) from |
| 526 | (integral_indicator hΩ_open.measurableSet).symm] |
| 527 | refine integral_congr_ae ?_ |
| 528 | refine Filter.Eventually.of_forall ?_ |
| 529 | intro x |
| 530 | by_cases hx : x ∈ Ω |
| 531 | · rw [Set.indicator_of_mem hx] |
| 532 | · rw [Set.indicator_of_notMem hx] |
| 533 | exact (h_compl_zero x hx).symm |
| 534 | rw [h_split] |
| 535 | refine integral_congr_ae ?_ |
| 536 | have h_ae : ∀ᵐ x ∂((volume : Measure E).restrict Ω), |
| 537 | w_ext x * diffQuot k (-(hₙ n)) φ.1 x = w x * diffQuot k (-(hₙ n)) φ.1 x := by |
| 538 | rw [ae_restrict_iff' hΩ_open.measurableSet] |
| 539 | refine Filter.Eventually.of_forall ?_ |
| 540 | intro x hx |
| 541 | rw [hw_ext_eq_w_on_Ω x hx] |
| 542 | exact h_ae |
| 543 | have hIBP : ∀ n, |
| 544 | ∫ x, diffQuot k (hₙ n) w_ext x * φ.1 x ∂(volume : Measure E) = |
| 545 | -∫ x, w_ext x * diffQuot k (-(hₙ n)) φ.1 x ∂(volume : Measure E) := by |
| 546 | intro n |
| 547 | exact integral_diffQuot_mul_eq_neg_integral_mul_diffQuot |
| 548 | (d := d) k (hₙ_ne n) hw_ext_memLp hφ_memLp_global |
| 549 | have h_LHS_restrict : ∀ n, |
| 550 | ∫ x, diffQuot k (hₙ n) w_ext x * φ.1 x ∂(volume : Measure E) = |
| 551 | ∫ x in Ω'', diffQuot k (hₙ n) w_ext x * φ.1 x |
| 552 | ∂(volume : Measure E) := by |
| 553 | intro n |
| 554 | symm |
| 555 | rw [show (∫ x in Ω'', diffQuot k (hₙ n) w_ext x * φ.1 x |
| 556 | ∂(volume : Measure E)) = |
| 557 | ∫ x, Ω''.indicator (fun y => diffQuot k (hₙ n) w_ext y * φ.1 y) x |
| 558 | ∂(volume : Measure E) from |
| 559 | (integral_indicator hΩ''_open.measurableSet).symm] |
| 560 | refine integral_congr_ae ?_ |
| 561 | refine Filter.Eventually.of_forall ?_ |
| 562 | intro x |
| 563 | by_cases hx : x ∈ Ω'' |
| 564 | · rw [Set.indicator_of_mem hx] |
| 565 | · rw [Set.indicator_of_notMem hx] |
| 566 | have hxnot : x ∉ tsupport φ.1 := fun hxt => hx (φ.2.2.2 hxt) |
| 567 | have hφx : φ.1 x = 0 := image_eq_zero_of_notMem_tsupport hxnot |
| 568 | change (0 : ℝ) = diffQuot k (hₙ n) w_ext x * φ.1 x |
| 569 | rw [hφx, mul_zero] |
| 570 | have h_LHS_on_tsupport : ∀ n, |
| 571 | ∫ x in Ω'', diffQuot k (hₙ n) w_ext x * φ.1 x ∂(volume : Measure E) = |
| 572 | ∫ x in Ω'', diffQuot k (hₙ n) w x * φ.1 x |
| 573 | ∂(volume : Measure E) := by |
| 574 | intro n |
| 575 | refine integral_congr_ae ?_ |
| 576 | have h_ae : ∀ᵐ x ∂((volume : Measure E).restrict Ω''), |
| 577 | diffQuot k (hₙ n) w_ext x * φ.1 x = diffQuot k (hₙ n) w x * φ.1 x := by |
| 578 | rw [ae_restrict_iff' hΩ''_open.measurableSet] |
| 579 | refine Filter.Eventually.of_forall ?_ |
| 580 | intro x _hx |
| 581 | by_cases hxt : x ∈ tsupport φ.1 |
| 582 | · rw [h_dq_eq_on_tsupport n x hxt] |
| 583 | · have hφx : φ.1 x = 0 := image_eq_zero_of_notMem_tsupport hxt |
| 584 | rw [hφx, mul_zero, mul_zero] |
| 585 | exact h_ae |
| 586 | have h_dq_aesm_global : ∀ n, AEStronglyMeasurable (diffQuot k (hₙ n) w_ext) |
| 587 | (volume : Measure E) := |
| 588 | fun n => aestronglyMeasurable_diffQuot (d := d) k _ hw_ext_memLp.aestronglyMeasurable |
| 589 | have h_dq_aesm_restrict : ∀ n, AEStronglyMeasurable (diffQuot k (hₙ n) w_ext) |
| 590 | ((volume : Measure E).restrict Ω'') := |
| 591 | fun n => (h_dq_aesm_global n).restrict |
| 592 | have h_dq_eq_on_Ω'' : ∀ n : ℕ, ∀ x ∈ Ω'', |
| 593 | diffQuot k (hₙ n) w_ext x = diffQuot k (hₙ n) w x := by |
| 594 | intro n x hx_Ω'' |
| 595 | have hx_closure : x ∈ closure Ω'' := subset_closure hx_Ω'' |
| 596 | have hx_in_Ω : x ∈ Ω := |
| 597 | h_room (Metric.self_subset_cthickening _ hx_closure) |
| 598 | have hx_he_in_Ω : x + (hₙ n) • EuclideanSpace.single k 1 ∈ Ω := by |
| 599 | have h_dist : dist x (x + (hₙ n) • EuclideanSpace.single k 1) = |hₙ n| := by |
| 600 | rw [dist_eq_norm] |
| 601 | have heq : x - (x + (hₙ n) • EuclideanSpace.single k 1) = |
| 602 | -((hₙ n) • EuclideanSpace.single k 1) := by abel |
| 603 | rw [heq, norm_neg, norm_smul] |
| 604 | rw [show ‖(EuclideanSpace.single k (1 : ℝ) : E)‖ = 1 by simp] |
| 605 | rw [Real.norm_eq_abs, mul_one] |
| 606 | have h_in_thick : x + (hₙ n) • EuclideanSpace.single k 1 ∈ |
| 607 | Metric.cthickening h₀ (closure Ω'') := by |
| 608 | refine Metric.mem_cthickening_of_dist_le _ x h₀ (closure Ω'') hx_closure ?_ |
| 609 | rw [dist_comm]; rw [h_dist]; exact hₙ_bd n |
| 610 | exact h_room h_in_thick |
| 611 | have h_dq_apply : diffQuot k (hₙ n) w_ext x = |
| 612 | (w_ext (x + (hₙ n) • EuclideanSpace.single k 1) - w_ext x) / (hₙ n) := by |
| 613 | rw [diffQuot_apply_of_ne (d := d) k (hₙ_ne n) w_ext x] |
| 614 | have h_dq_w_apply : diffQuot k (hₙ n) w x = |
| 615 | (w (x + (hₙ n) • EuclideanSpace.single k 1) - w x) / (hₙ n) := by |
| 616 | rw [diffQuot_apply_of_ne (d := d) k (hₙ_ne n) w x] |
| 617 | rw [h_dq_apply, h_dq_w_apply] |
| 618 | rw [hw_ext_eq_w_on_Ω _ hx_in_Ω, hw_ext_eq_w_on_Ω _ hx_he_in_Ω] |
| 619 | have h_dq_ae_eq_restrict : ∀ n, diffQuot k (hₙ n) w_ext =ᵐ[ |
| 620 | (volume : Measure E).restrict Ω''] diffQuot k (hₙ n) w := by |
| 621 | intro n |
| 622 | rw [Filter.EventuallyEq, ae_restrict_iff' hΩ''_open.measurableSet] |
| 623 | refine Filter.Eventually.of_forall ?_ |
| 624 | intro x hx |
| 625 | exact h_dq_eq_on_Ω'' n x hx |
| 626 | have h_dq_aesm_restrict_w : ∀ n, AEStronglyMeasurable (diffQuot k (hₙ n) w) |
| 627 | ((volume : Measure E).restrict Ω'') := fun n => |
| 628 | (h_dq_aesm_restrict n).congr (h_dq_ae_eq_restrict n) |
| 629 | have h_dq_memLp_restrict_w : ∀ n, MemLp (diffQuot k (hₙ n) w) 2 |
| 630 | ((volume : Measure E).restrict Ω'') := fun n => |
| 631 | ⟨h_dq_aesm_restrict_w n, lt_of_le_of_lt (h_dq_l2_bound n) ENNReal.ofReal_lt_top⟩ |
| 632 | have h_CS_bound : ∀ n, |
| 633 | |∫ x in Ω'', diffQuot k (hₙ n) w x * φ.1 x ∂(volume : Measure E)| ≤ |
| 634 | M * (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal := by |
| 635 | intro n |
| 636 | have h_cs := abs_integral_mul_le_norm_lp_mul_norm_lp_loc |
| 637 | (μ := (volume : Measure E).restrict Ω'') (h_dq_memLp_restrict_w n) hφ_memLp |
| 638 | have h_dq_bound : |
| 639 | (eLpNorm (diffQuot k (hₙ n) w) 2 ((volume : Measure E).restrict Ω'')).toReal |
| 640 | ≤ M := by |
| 641 | have hMto : (ENNReal.ofReal M).toReal = M := ENNReal.toReal_ofReal hM_nn |
| 642 | calc (eLpNorm (diffQuot k (hₙ n) w) 2 ((volume : Measure E).restrict Ω'')).toReal |
| 643 | ≤ (ENNReal.ofReal M).toReal := by |
| 644 | refine ENNReal.toReal_mono ENNReal.ofReal_ne_top ?_ |
| 645 | exact h_dq_l2_bound n |
| 646 | _ = M := hMto |
| 647 | have h_phi_nn : 0 ≤ (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal := |
| 648 | ENNReal.toReal_nonneg |
| 649 | have hMul : |
| 650 | (eLpNorm (diffQuot k (hₙ n) w) 2 ((volume : Measure E).restrict Ω'')).toReal * |
| 651 | (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal ≤ |
| 652 | M * (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal := |
| 653 | mul_le_mul_of_nonneg_right h_dq_bound h_phi_nn |
| 654 | have h_int_eq : |
| 655 | ∫ x in Ω'', diffQuot k (hₙ n) w x * φ.1 x ∂(volume : Measure E) = |
| 656 | ∫ x, diffQuot k (hₙ n) w x * φ.1 x ∂((volume : Measure E).restrict Ω'') := |
| 657 | rfl |
| 658 | rw [h_int_eq] |
| 659 | linarith |
| 660 | have h_dual_bound : ∀ n, |
| 661 | |∫ x, w_ext x * diffQuot k (-(hₙ n)) φ.1 x ∂(volume : Measure E)| ≤ |
| 662 | M * (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal := by |
| 663 | intro n |
| 664 | have h_IBP_n := hIBP n |
| 665 | have h_LHS_eq : ∫ x, diffQuot k (hₙ n) w_ext x * φ.1 x ∂(volume : Measure E) = |
| 666 | ∫ x in Ω'', diffQuot k (hₙ n) w x * φ.1 x ∂(volume : Measure E) := by |
| 667 | rw [h_LHS_restrict n, h_LHS_on_tsupport n] |
| 668 | have h_LHS_abs : |∫ x, diffQuot k (hₙ n) w_ext x * φ.1 x ∂(volume : Measure E)| = |
| 669 | |∫ x in Ω'', diffQuot k (hₙ n) w x * φ.1 x ∂(volume : Measure E)| := by |
| 670 | rw [h_LHS_eq] |
| 671 | have h_LHS_le_bound : |
| 672 | |∫ x, diffQuot k (hₙ n) w_ext x * φ.1 x ∂(volume : Measure E)| ≤ |
| 673 | M * (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal := by |
| 674 | rw [h_LHS_abs]; exact h_CS_bound n |
| 675 | have h_RHS_eq_LHS : |∫ x, w_ext x * diffQuot k (-(hₙ n)) φ.1 x ∂(volume : Measure E)| = |
| 676 | |∫ x, diffQuot k (hₙ n) w_ext x * φ.1 x ∂(volume : Measure E)| := by |
| 677 | rw [h_IBP_n, abs_neg] |
| 678 | rw [h_RHS_eq_LHS] |
| 679 | exact h_LHS_le_bound |
| 680 | have h_dual_bound_restrict : ∀ n, |
| 681 | |∫ x in Ω, w x * diffQuot k (-(hₙ n)) φ.1 x ∂(volume : Measure E)| ≤ |
| 682 | M * (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal := by |
| 683 | intro n |
| 684 | rw [← h_neg_h_int_eq_restrict n] |
| 685 | exact h_dual_bound n |
| 686 | have h_abs_conv : |
| 687 | Tendsto (fun n => |
| 688 | |∫ x in Ω, w x * diffQuot k (-(hₙ n)) φ.1 x ∂(volume : Measure E)|) |
| 689 | atTop |
| 690 | (𝓝 |∫ x in Ω, w x * (fderiv ℝ φ.1 x) (EuclideanSpace.single k 1) |
| 691 | ∂(volume : Measure E)|) := by |
| 692 | have := h_conv.abs |
| 693 | simpa using this |
| 694 | exact le_of_tendsto_of_tendsto' |
| 695 | h_abs_conv tendsto_const_nhds (fun n => h_dual_bound_restrict n) |
| 696 | |
| 697 | omit [NeZero d] in |
| 698 | lemma abs_smoothTestFunctional_loc_le_lpNorm |
| 699 | {Ω : Set E} (hΩ_open : IsOpen Ω) |
| 700 | {Ω'' : Set E} (hΩ''_open : IsOpen Ω'') |
| 701 | (hΩ''_compact_closure : IsCompact (closure Ω'')) |
| 702 | {h₀ : ℝ} (hh₀ : 0 < h₀) |
| 703 | (h_room : Metric.cthickening h₀ (closure Ω'') ⊆ Ω) |
| 704 | {w : E → ℝ} |
| 705 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 706 | (k : Fin d) {M : ℝ} (hM_nn : 0 ≤ M) |
| 707 | (h_bdd : ∀ h : ℝ, 0 < |h| → |h| ≤ h₀ → |
| 708 | eLpNorm (diffQuot k h w) 2 ((volume : Measure E).restrict Ω'') |
| 709 | ≤ ENNReal.ofReal M) |
| 710 | (φ : smoothCSSupportedInSubmodule (d := d) Ω'') : |
| 711 | |smoothTestFunctionalLoc (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k φ| ≤ |
| 712 | M * ‖smoothCSSupportedInToLp (d := d) Ω'' φ‖ := by |
| 713 | have h := abs_smoothTestFunctional_loc_le (d := d) hΩ_open hΩ''_open |
| 714 | hΩ''_compact_closure hh₀ h_room hw_l2 k hM_nn h_bdd φ |
| 715 | have h_norm_eq : |
| 716 | ‖smoothCSSupportedInToLp (d := d) Ω'' φ‖ = |
| 717 | (eLpNorm φ.1 2 ((volume : Measure E).restrict Ω'')).toReal := by |
| 718 | rw [show (smoothCSSupportedInToLp (d := d) Ω'' φ : |
| 719 | Lp ℝ 2 ((volume : Measure E).restrict Ω'')) = |
| 720 | (memLp_two_restrict_of_smoothCS (d := d) (Ω'' := Ω'') φ.2.1 φ.2.2.1).toLp |
| 721 | φ.1 from rfl] |
| 722 | exact Lp.norm_toLp _ _ |
| 723 | rw [h_norm_eq] |
| 724 | exact h |
| 725 | |
| 726 | def smoothTestFunctionalLocExt |
| 727 | {Ω Ω'' : Set E} |
| 728 | {w : E → ℝ} |
| 729 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 730 | (k : Fin d) : |
| 731 | Lp ℝ 2 ((volume : Measure E).restrict Ω'') →L[ℝ] ℝ := |
| 732 | (smoothTestFunctionalLoc (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k).extendOfNorm |
| 733 | (smoothCSSupportedInToLp (d := d) Ω'') |
| 734 | |
| 735 | omit [NeZero d] in |
| 736 | lemma opNorm_smoothTestFunctional_loc_ext_le |
| 737 | {Ω : Set E} (hΩ_open : IsOpen Ω) |
| 738 | {Ω'' : Set E} (hΩ''_open : IsOpen Ω'') |
| 739 | (hΩ''_compact_closure : IsCompact (closure Ω'')) |
| 740 | {h₀ : ℝ} (hh₀ : 0 < h₀) |
| 741 | (h_room : Metric.cthickening h₀ (closure Ω'') ⊆ Ω) |
| 742 | {w : E → ℝ} |
| 743 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 744 | (k : Fin d) {M : ℝ} (hM_nn : 0 ≤ M) |
| 745 | (h_bdd : ∀ h : ℝ, 0 < |h| → |h| ≤ h₀ → |
| 746 | eLpNorm (diffQuot k h w) 2 ((volume : Measure E).restrict Ω'') |
| 747 | ≤ ENNReal.ofReal M) : |
| 748 | ‖smoothTestFunctionalLocExt (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k‖ ≤ M := by |
| 749 | unfold smoothTestFunctionalLocExt |
| 750 | refine LinearMap.opNorm_extendOfNorm_le |
| 751 | (denseRange_smoothCSSupportedInToLp (d := d) hΩ''_open hΩ''_compact_closure) |
| 752 | hM_nn ?_ |
| 753 | intro φ |
| 754 | exact abs_smoothTestFunctional_loc_le_lpNorm (d := d) hΩ_open hΩ''_open |
| 755 | hΩ''_compact_closure hh₀ h_room hw_l2 k hM_nn h_bdd φ |
| 756 | |
| 757 | omit [NeZero d] in |
| 758 | lemma smoothTestFunctional_loc_ext_apply |
| 759 | {Ω : Set E} (hΩ_open : IsOpen Ω) |
| 760 | {Ω'' : Set E} (hΩ''_open : IsOpen Ω'') |
| 761 | (hΩ''_compact_closure : IsCompact (closure Ω'')) |
| 762 | {h₀ : ℝ} (hh₀ : 0 < h₀) |
| 763 | (h_room : Metric.cthickening h₀ (closure Ω'') ⊆ Ω) |
| 764 | {w : E → ℝ} |
| 765 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 766 | (k : Fin d) {M : ℝ} (hM_nn : 0 ≤ M) |
| 767 | (h_bdd : ∀ h : ℝ, 0 < |h| → |h| ≤ h₀ → |
| 768 | eLpNorm (diffQuot k h w) 2 ((volume : Measure E).restrict Ω'') |
| 769 | ≤ ENNReal.ofReal M) |
| 770 | (φ : smoothCSSupportedInSubmodule (d := d) Ω'') : |
| 771 | smoothTestFunctionalLocExt (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k |
| 772 | (smoothCSSupportedInToLp (d := d) Ω'' φ) = |
| 773 | smoothTestFunctionalLoc (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k φ := by |
| 774 | unfold smoothTestFunctionalLocExt |
| 775 | refine LinearMap.extendOfNorm_eq |
| 776 | (denseRange_smoothCSSupportedInToLp (d := d) hΩ''_open hΩ''_compact_closure) |
| 777 | ⟨M, ?_⟩ φ |
| 778 | intro ψ |
| 779 | exact abs_smoothTestFunctional_loc_le_lpNorm (d := d) hΩ_open hΩ''_open |
| 780 | hΩ''_compact_closure hh₀ h_room hw_l2 k hM_nn h_bdd ψ |
| 781 | |
| 782 | def smoothTestFunctionalLocRiesz |
| 783 | {Ω Ω'' : Set E} |
| 784 | {w : E → ℝ} |
| 785 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 786 | (k : Fin d) : |
| 787 | Lp ℝ 2 ((volume : Measure E).restrict Ω'') := |
| 788 | (InnerProductSpace.toDual ℝ |
| 789 | (Lp ℝ 2 ((volume : Measure E).restrict Ω''))).symm |
| 790 | (smoothTestFunctionalLocExt (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k) |
| 791 | |
| 792 | omit [NeZero d] in |
| 793 | lemma norm_smoothTestFunctional_loc_riesz |
| 794 | {Ω Ω'' : Set E} |
| 795 | {w : E → ℝ} |
| 796 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 797 | (k : Fin d) : |
| 798 | ‖smoothTestFunctionalLocRiesz (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k‖ = |
| 799 | ‖smoothTestFunctionalLocExt (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k‖ := by |
| 800 | unfold smoothTestFunctionalLocRiesz |
| 801 | exact (InnerProductSpace.toDual ℝ |
| 802 | (Lp ℝ 2 ((volume : Measure E).restrict Ω''))).symm.norm_map _ |
| 803 | |
| 804 | omit [NeZero d] in |
| 805 | lemma smoothTestFunctional_loc_ext_eq_inner |
| 806 | {Ω Ω'' : Set E} |
| 807 | {w : E → ℝ} |
| 808 | (hw_l2 : MemLp w 2 ((volume : Measure E).restrict Ω)) |
| 809 | (k : Fin d) |
| 810 | (f : Lp ℝ 2 ((volume : Measure E).restrict Ω'')) : |
| 811 | smoothTestFunctionalLocExt (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k f = |
| 812 | ⟪smoothTestFunctionalLocRiesz (d := d) (Ω := Ω) (Ω'' := Ω'') hw_l2 k, f⟫_ℝ := by |
| 813 | unfold smoothTestFunctionalLocRiesz |
| 814 | rw [InnerProductSpace.toDual_symm_apply] |
| 815 | |
| 816 | |
| 817 | end Poincare.Analysis.Sobolev |
| 818 |