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 | Source: https://github.com/qinz1yang/differential-geometry |
| 4 | DifferentialGeometry/Analysis/Sobolev/Nirenberg/MasterInequality/CrossBounds.lean |
| 5 | Comparison revision: 1b535dd102b94cc42b107cca27059687888f08b3. |
| 6 | Changes: Imports, module paths, and namespaces were adapted to the subject-organized PoincareLib library. |
| 7 | License: Apache-2.0. Source licenses and notices are retained under |
| 8 | PoincareConjecture/provenance/2026-09-29/licenses/. |
| 9 | See PoincareConjecture/MODIFICATIONS.md for the reviewed source mapping. |
| 10 | -/ |
| 11 | |
| 12 | import PoincareLib.Analysis.Elliptic.Regularity.EnergyEstimate.Smooth.Coercivity |
| 13 | import PoincareLib.Analysis.Elliptic.Regularity.EnergyEstimate.Smooth.DifferenceQuotient |
| 14 | import PoincareLib.Analysis.Elliptic.Regularity.EnergyEstimate.Smooth.Integrability |
| 15 | import PoincareLib.Analysis.Elliptic.Regularity.EnergyEstimate.Smooth.Pointwise |
| 16 | |
| 17 | |
| 18 | /-! |
| 19 | # Local elliptic energy estimates |
| 20 | |
| 21 | Adapted from Chow--Liao--Qin, `Analysis/Sobolev/Nirenberg/MasterInequality/CrossBounds.lean`, |
| 22 | revision `1b535dd102b94cc42b107cca27059687888f08b3`. |
| 23 | Copyright 2026 The DifferentialGeometry contributors. Apache-2.0. |
| 24 | The adaptation changes imports and namespaces and uses smooth cutoffs. |
| 25 | -/ |
| 26 | |
| 27 | noncomputable section |
| 28 | |
| 29 | open MeasureTheory Metric Filter Topology Set Function |
| 30 | open Poincare.Analysis.Sobolev |
| 31 | open Poincare.Analysis.Sobolev.NirenbergEuclidean |
| 32 | open Poincare.Analysis.Sobolev.NirenbergTestFunction |
| 33 | open Poincare.Analysis.Sobolev.NirenbergSubstitution |
| 34 | open Poincare.Analysis.Sobolev.NirenbergCoercivity |
| 35 | open scoped ENNReal NNReal Convolution Pointwise BigOperators InnerProductSpace |
| 36 | |
| 37 | namespace Poincare.Analysis.Sobolev.NirenbergCrossBounds |
| 38 | |
| 39 | variable {d : ℕ} [NeZero d] |
| 40 | |
| 41 | local notation "E" => EuclideanSpace ℝ (Fin d) |
| 42 | |
| 43 | omit [NeZero d] in |
| 44 | private lemma integral_const_indicator_eq |
| 45 | {u : E → ℝ} (k : Fin d) (h : ℝ) (η : E → ℝ) (c : ℝ) : |
| 46 | ∫ x, c * (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 47 | (diffQuot k h u x)^2 ∂(volume : Measure E) = |
| 48 | c * ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) := by |
| 49 | have h_eq : (fun x : E => c * |
| 50 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 51 | (diffQuot k h u x)^2) = |
| 52 | (fun x : E => c * ((Set.indicator (tsupport η) |
| 53 | (fun _ : E => (1 : ℝ)) x) * (diffQuot k h u x)^2)) := by |
| 54 | funext x; ring |
| 55 | rw [h_eq, integral_const_mul] |
| 56 | congr 1 |
| 57 | rw [show (fun x : E => (Set.indicator (tsupport η) |
| 58 | (fun _ : E => (1 : ℝ)) x) * (diffQuot k h u x)^2) = |
| 59 | (fun x : E => Set.indicator (tsupport η) |
| 60 | (fun y : E => (diffQuot k h u y)^2) x) from by |
| 61 | funext x |
| 62 | by_cases hx : x ∈ tsupport η |
| 63 | · rw [Set.indicator_of_mem hx, Set.indicator_of_mem hx]; ring |
| 64 | · rw [Set.indicator_of_notMem hx, Set.indicator_of_notMem hx]; ring] |
| 65 | rw [MeasureTheory.integral_indicator (isClosed_tsupport η).measurableSet] |
| 66 | |
| 67 | |
| 68 | theorem translated_coeff_cutoff_deriv_diffQuot_cross_bound |
| 69 | {Ω : Set E} (B : SmoothEllipticBilinearForm d Ω) |
| 70 | {η : E → ℝ} (hη : ContDiff ℝ (⊤ : ℕ∞) η) (hη_supp : HasCompactSupport η) |
| 71 | (hη_range : Set.range η ⊆ Set.Icc (0 : ℝ) 1) |
| 72 | {N : ℝ} (h_fderiv_eta : ∀ x : E, ‖fderiv ℝ η x‖ ≤ N) |
| 73 | {Ω' : Set E} (hΩ' : IsOpen Ω') |
| 74 | (hΩ'_compact : IsCompact (closure Ω')) |
| 75 | {R₀ : ℝ} |
| 76 | (hh_supp_in_Ω' : ∀ {h : ℝ}, |h| ≤ R₀ → |
| 77 | Metric.cthickening |h| (tsupport η) ⊆ Ω') |
| 78 | (k : Fin d) (ε : ℝ) (hε : 0 < ε) : |
| 79 | ∃ C : ℝ, 0 ≤ C ∧ ∀ {u : E → ℝ}, ContDiff ℝ (⊤ : ℕ∞) u → |
| 80 | ∀ {h : ℝ}, h ≠ 0 → |h| ≤ R₀ → |
| 81 | |- ∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 82 | (Poincare.Analysis.Sobolev.translate k h |
| 83 | (fun y : E => B.a y i j)) x * |
| 84 | (η x) * |
| 85 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 86 | Poincare.Analysis.Sobolev.diffQuot k h |
| 87 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 88 | Poincare.Analysis.Sobolev.diffQuot k h u x |
| 89 | ∂(volume : Measure E)| ≤ |
| 90 | ε * ∫ x, (η x)^2 * |
| 91 | ∑ i : Fin d, Poincare.Analysis.Sobolev.diffQuot k h |
| 92 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x ^ 2 |
| 93 | ∂(volume : Measure E) + |
| 94 | C * ∫ x in Ω', |
| 95 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 96 | ∂(volume : Measure E) := by |
| 97 | classical |
| 98 | obtain ⟨Λ, hΛ_nn, hΛ⟩ := |
| 99 | SmoothEllipticBilinearForm.bounded_a_on_compact (d := d) B hΩ'_compact |
| 100 | set d_real : ℝ := (Fintype.card (Fin d) : ℝ) with hd_real |
| 101 | have hd_pos : 0 < d_real := by |
| 102 | rw [hd_real]; exact_mod_cast Fintype.card_pos |
| 103 | have hd_nn : 0 ≤ d_real := hd_pos.le |
| 104 | have hε'_pos : 0 < ε / d_real := div_pos hε hd_pos |
| 105 | set C : ℝ := (1 / (ε / d_real)) * Λ^2 * N^2 * d_real^2 with hC_def |
| 106 | have hC_nn : 0 ≤ C := by |
| 107 | rw [hC_def] |
| 108 | refine mul_nonneg (mul_nonneg (mul_nonneg ?_ (sq_nonneg _)) (sq_nonneg _)) (sq_nonneg _) |
| 109 | exact (one_div_pos.mpr hε'_pos).le |
| 110 | refine ⟨C, hC_nn, ?_⟩ |
| 111 | intro u hu h hh hh_le |
| 112 | have h_thick_in_Ω' : Metric.cthickening |h| (tsupport η) ⊆ Ω' := hh_supp_in_Ω' hh_le |
| 113 | have h_each_pointwise := fun (i j : Fin d) (x : E) => |
| 114 | translated_coeff_cutoff_gradient_pointwise_bound (d := d) B hu hη hη_range h_fderiv_eta |
| 115 | hΛ i j k h_thick_in_Ω' hε'_pos x |
| 116 | set S : ℝ := ∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 117 | translate k h (fun y : E => B.a y i j) x * (η x) * |
| 118 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 119 | diffQuot k h (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 120 | diffQuot k h u x |
| 121 | ∂(volume : Measure E) with hS_def |
| 122 | have h_neg_abs : |- S| = |S| := abs_neg S |
| 123 | rw [h_neg_abs] |
| 124 | have h_abs_sum : |S| ≤ |
| 125 | ∑ i : Fin d, ∑ j : Fin d, |∫ x, 2 * |
| 126 | translate k h (fun y : E => B.a y i j) x * (η x) * |
| 127 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 128 | diffQuot k h (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 129 | diffQuot k h u x |
| 130 | ∂(volume : Measure E)| := by |
| 131 | refine (Finset.abs_sum_le_sum_abs _ _).trans ?_ |
| 132 | refine Finset.sum_le_sum ?_ |
| 133 | intro i _ |
| 134 | exact Finset.abs_sum_le_sum_abs _ _ |
| 135 | refine h_abs_sum.trans ?_ |
| 136 | have h_integrand_int : ∀ i j : Fin d, Integrable (fun x : E => |
| 137 | 2 * translate k h (fun y => B.a y i j) x * (η x) * |
| 138 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 139 | diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 140 | diffQuot k h u x) volume := |
| 141 | fun i j => integrable_cross_1_summand (d := d) B hu hη hη_supp i j k hh |
| 142 | have h_first_int : ∀ i : Fin d, Integrable (fun x : E => |
| 143 | (ε / d_real) * (η x)^2 * |
| 144 | (diffQuot k h |
| 145 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2) volume := |
| 146 | fun i => integrable_const_eta_sq_diffQuot_partial_sq (d := d) hu hη hη_supp |
| 147 | i k hh (ε / d_real) |
| 148 | have h_indicator_int : Integrable (fun x : E => |
| 149 | (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 150 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 151 | (diffQuot k h u x)^2) volume := |
| 152 | integrable_const_indicator_diffQuot_sq (d := d) hu hη_supp |
| 153 | k hh ((1 / (ε / d_real)) * Λ^2 * N^2) |
| 154 | have h_pt_bound_int : ∀ i j : Fin d, Integrable (fun x : E => |
| 155 | (ε / d_real) * (η x)^2 * |
| 156 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 + |
| 157 | (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 158 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 159 | (diffQuot k h u x)^2) volume := |
| 160 | fun i _ => (h_first_int i).add h_indicator_int |
| 161 | have h_per_pair_bound : ∀ i j : Fin d, |
| 162 | |∫ x, 2 * translate k h (fun y => B.a y i j) x * (η x) * |
| 163 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 164 | diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 165 | diffQuot k h u x ∂(volume : Measure E)| ≤ |
| 166 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 167 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 + |
| 168 | (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 169 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 170 | (diffQuot k h u x)^2) ∂(volume : Measure E) := by |
| 171 | intro i j |
| 172 | have h_tri := abs_integral_le_integral_abs (μ := (volume : Measure E)) |
| 173 | (f := fun x : E => 2 * translate k h (fun y => B.a y i j) x * (η x) * |
| 174 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 175 | diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 176 | diffQuot k h u x) |
| 177 | refine h_tri.trans ?_ |
| 178 | refine integral_mono_ae ((h_integrand_int i j).abs) (h_pt_bound_int i j) ?_ |
| 179 | refine Filter.Eventually.of_forall ?_ |
| 180 | intro x |
| 181 | exact h_each_pointwise i j x |
| 182 | have h_outer_sum : |
| 183 | ∑ i : Fin d, ∑ j : Fin d, |∫ x, 2 * |
| 184 | translate k h (fun y => B.a y i j) x * (η x) * |
| 185 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 186 | diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 187 | diffQuot k h u x ∂(volume : Measure E)| ≤ |
| 188 | ∑ i : Fin d, ∑ j : Fin d, |
| 189 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 190 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 + |
| 191 | (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 192 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 193 | (diffQuot k h u x)^2) ∂(volume : Measure E) := |
| 194 | Finset.sum_le_sum (fun i _ => Finset.sum_le_sum (fun j _ => h_per_pair_bound i j)) |
| 195 | refine h_outer_sum.trans ?_ |
| 196 | have h_total_eq : |
| 197 | ∑ i : Fin d, ∑ j : Fin d, |
| 198 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 199 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 + |
| 200 | (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 201 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 202 | (diffQuot k h u x)^2) ∂(volume : Measure E) = |
| 203 | ε * ∫ x, (η x)^2 * |
| 204 | ∑ i : Fin d, (diffQuot k h |
| 205 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 206 | ∂(volume : Measure E) + |
| 207 | d_real^2 * ((1 / (ε / d_real)) * Λ^2 * N^2 * |
| 208 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E)) := by |
| 209 | have h_per_ij : ∀ i j : Fin d, |
| 210 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 211 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 + |
| 212 | (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 213 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 214 | (diffQuot k h u x)^2) ∂(volume : Measure E) = |
| 215 | ∫ x, (ε / d_real) * (η x)^2 * |
| 216 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 217 | ∂(volume : Measure E) + |
| 218 | ∫ x, (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 219 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 220 | (diffQuot k h u x)^2 ∂(volume : Measure E) := by |
| 221 | intro i j |
| 222 | rw [integral_add (h_first_int i) h_indicator_int] |
| 223 | rw [show (∑ i : Fin d, ∑ j : Fin d, |
| 224 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 225 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 + |
| 226 | (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 227 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 228 | (diffQuot k h u x)^2) ∂(volume : Measure E)) = |
| 229 | ∑ i : Fin d, ∑ j : Fin d, |
| 230 | (∫ x, (ε / d_real) * (η x)^2 * |
| 231 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 232 | ∂(volume : Measure E) + |
| 233 | ∫ x, (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 234 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 235 | (diffQuot k h u x)^2 ∂(volume : Measure E)) from |
| 236 | Finset.sum_congr rfl (fun i _ => Finset.sum_congr rfl (fun j _ => h_per_ij i j))] |
| 237 | have h_step_b : ∀ i : Fin d, ∑ _j : Fin d, |
| 238 | (∫ x, (ε / d_real) * (η x)^2 * |
| 239 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 240 | ∂(volume : Measure E) + |
| 241 | ∫ x, (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 242 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 243 | (diffQuot k h u x)^2 ∂(volume : Measure E)) = |
| 244 | d_real * (∫ x, (ε / d_real) * (η x)^2 * |
| 245 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 246 | ∂(volume : Measure E) + |
| 247 | ∫ x, (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 248 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 249 | (diffQuot k h u x)^2 ∂(volume : Measure E)) := by |
| 250 | intro i |
| 251 | rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] |
| 252 | rw [show (∑ i : Fin d, ∑ _j : Fin d, |
| 253 | (∫ x, (ε / d_real) * (η x)^2 * |
| 254 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 255 | ∂(volume : Measure E) + |
| 256 | ∫ x, (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 257 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 258 | (diffQuot k h u x)^2 ∂(volume : Measure E))) = |
| 259 | ∑ i : Fin d, d_real * (∫ x, (ε / d_real) * (η x)^2 * |
| 260 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 261 | ∂(volume : Measure E) + |
| 262 | ∫ x, (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 263 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 264 | (diffQuot k h u x)^2 ∂(volume : Measure E)) from |
| 265 | Finset.sum_congr rfl (fun i _ => h_step_b i)] |
| 266 | rw [← Finset.mul_sum] |
| 267 | rw [Finset.sum_add_distrib] |
| 268 | rw [show (∑ _i : Fin d, ∫ x, (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 269 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 270 | (diffQuot k h u x)^2 ∂(volume : Measure E)) = |
| 271 | d_real * ∫ x, (1 / (ε / d_real)) * Λ^2 * N^2 * |
| 272 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 273 | (diffQuot k h u x)^2 ∂(volume : Measure E) |
| 274 | from by rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul]] |
| 275 | have h_indicator_eq := integral_const_indicator_eq (d := d) k h η |
| 276 | ((1 / (ε / d_real)) * Λ^2 * N^2) (u := u) |
| 277 | rw [h_indicator_eq] |
| 278 | have h_eta_sq_diffQuot_int : ∀ i : Fin d, |
| 279 | ∫ x, (ε / d_real) * (η x)^2 * |
| 280 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 281 | ∂(volume : Measure E) = |
| 282 | (ε / d_real) * ∫ x, (η x)^2 * |
| 283 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 284 | ∂(volume : Measure E) := by |
| 285 | intro i |
| 286 | rw [show (fun x : E => (ε / d_real) * (η x)^2 * |
| 287 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2) = |
| 288 | fun x : E => (ε / d_real) * ((η x)^2 * |
| 289 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2) |
| 290 | from by funext x; ring] |
| 291 | rw [integral_const_mul] |
| 292 | rw [show (∑ i : Fin d, ∫ x, (ε / d_real) * (η x)^2 * |
| 293 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 294 | ∂(volume : Measure E)) = |
| 295 | ∑ i : Fin d, (ε / d_real) * ∫ x, (η x)^2 * |
| 296 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 297 | ∂(volume : Measure E) from |
| 298 | Finset.sum_congr rfl (fun i _ => h_eta_sq_diffQuot_int i)] |
| 299 | rw [← Finset.mul_sum] |
| 300 | have h_first_int_per : ∀ i : Fin d, Integrable (fun x : E => |
| 301 | (η x)^2 * (diffQuot k h |
| 302 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2) volume := |
| 303 | fun i => integrable_eta_sq_diffQuot_partial_sq (d := d) hu hη hη_supp i k hh |
| 304 | have h_swap_sum : ∑ i : Fin d, ∫ x, (η x)^2 * |
| 305 | (diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 306 | ∂(volume : Measure E) = |
| 307 | ∫ x, (η x)^2 * |
| 308 | ∑ i : Fin d, (diffQuot k h |
| 309 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 310 | ∂(volume : Measure E) := by |
| 311 | rw [← integral_finsetSum _ (fun i _ => h_first_int_per i)] |
| 312 | refine integral_congr_ae ?_ |
| 313 | filter_upwards with x |
| 314 | rw [Finset.mul_sum] |
| 315 | rw [h_swap_sum] |
| 316 | rw [mul_add] |
| 317 | congr 1 |
| 318 | · rw [← mul_assoc, mul_div_cancel₀ _ (ne_of_gt hd_pos)] |
| 319 | · ring |
| 320 | rw [h_total_eq] |
| 321 | have h_diffQuot_sq_le := integral_diffQuot_sq_on_tsupport_le_gradL2sqOn (d := d) |
| 322 | hu k hh η hΩ' hΩ'_compact h_thick_in_Ω' |
| 323 | unfold gradL2sqOn at h_diffQuot_sq_le |
| 324 | have h_factor_nn : 0 ≤ (1 / (ε / d_real)) * Λ^2 * N^2 := by |
| 325 | refine mul_nonneg (mul_nonneg ?_ (sq_nonneg _)) (sq_nonneg _) |
| 326 | exact (one_div_pos.mpr hε'_pos).le |
| 327 | have h_d_real_sq_nn : 0 ≤ d_real^2 := sq_nonneg _ |
| 328 | have h_C_eq : C = d_real^2 * ((1 / (ε / d_real)) * Λ^2 * N^2) := by |
| 329 | rw [hC_def]; ring |
| 330 | have h_combine : |
| 331 | d_real^2 * ((1 / (ε / d_real)) * Λ^2 * N^2 * |
| 332 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E)) ≤ |
| 333 | C * ∫ x in Ω', |
| 334 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 335 | ∂(volume : Measure E) := by |
| 336 | rw [show d_real^2 * ((1 / (ε / d_real)) * Λ^2 * N^2 * |
| 337 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E)) = |
| 338 | (d_real^2 * ((1 / (ε / d_real)) * Λ^2 * N^2)) * |
| 339 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) |
| 340 | from by ring, ← h_C_eq] |
| 341 | refine mul_le_mul_of_nonneg_left h_diffQuot_sq_le ?_ |
| 342 | rw [h_C_eq]; exact mul_nonneg h_d_real_sq_nn h_factor_nn |
| 343 | linarith |
| 344 | |
| 345 | |
| 346 | theorem coeff_diffQuot_cutoff_sq_gradient_cross_bound |
| 347 | {Ω : Set E} (B : SmoothEllipticBilinearForm d Ω) |
| 348 | {η : E → ℝ} (hη : ContDiff ℝ (⊤ : ℕ∞) η) (hη_supp : HasCompactSupport η) |
| 349 | (hη_range : Set.range η ⊆ Set.Icc (0 : ℝ) 1) |
| 350 | {Ω' : Set E} (hΩ' : IsOpen Ω') |
| 351 | (hΩ'_compact : IsCompact (closure Ω')) |
| 352 | {R₀ : ℝ} |
| 353 | (hh_supp_in_Ω' : ∀ {h : ℝ}, |h| ≤ R₀ → |
| 354 | Metric.cthickening |h| (tsupport η) ⊆ Ω') |
| 355 | (k : Fin d) (ε : ℝ) (hε : 0 < ε) : |
| 356 | ∃ C : ℝ, 0 ≤ C ∧ ∀ {u : E → ℝ}, ContDiff ℝ (⊤ : ℕ∞) u → |
| 357 | ∀ {h : ℝ}, h ≠ 0 → |h| ≤ R₀ → |
| 358 | |- ∑ i : Fin d, ∑ j : Fin d, ∫ x, |
| 359 | Poincare.Analysis.Sobolev.diffQuot k h |
| 360 | (fun y : E => B.a y i j) x * |
| 361 | (η x)^2 * |
| 362 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 363 | Poincare.Analysis.Sobolev.diffQuot k h |
| 364 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x |
| 365 | ∂(volume : Measure E)| ≤ |
| 366 | ε * ∫ x, (η x)^2 * |
| 367 | ∑ i : Fin d, Poincare.Analysis.Sobolev.diffQuot k h |
| 368 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x ^ 2 |
| 369 | ∂(volume : Measure E) + |
| 370 | C * ∫ x in Ω', |
| 371 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 372 | ∂(volume : Measure E) := by |
| 373 | classical |
| 374 | obtain ⟨M, hM_nn, h_M⟩ := |
| 375 | SmoothEllipticBilinearForm.bounded_fderiv_a_on_compact (d := d) B k hΩ'_compact |
| 376 | set d_real : ℝ := (Fintype.card (Fin d) : ℝ) with hd_real |
| 377 | have hd_pos : 0 < d_real := by |
| 378 | rw [hd_real]; exact_mod_cast Fintype.card_pos |
| 379 | have hd_nn : 0 ≤ d_real := hd_pos.le |
| 380 | have hε'_pos : 0 < ε / d_real := div_pos hε hd_pos |
| 381 | set C : ℝ := (M^2 / (4 * (ε / d_real))) * d_real^2 with hC_def |
| 382 | have hC_nn : 0 ≤ C := by |
| 383 | rw [hC_def] |
| 384 | refine mul_nonneg ?_ (sq_nonneg _) |
| 385 | refine mul_nonneg (sq_nonneg _) ?_ |
| 386 | refine inv_nonneg.mpr (by linarith [hε'_pos]) |
| 387 | refine ⟨C, hC_nn, ?_⟩ |
| 388 | intro u hu h hh hh_le |
| 389 | have h_thick_in_Ω' : Metric.cthickening |h| (tsupport η) ⊆ Ω' := hh_supp_in_Ω' hh_le |
| 390 | have h_each_pointwise := fun (i j : Fin d) (x : E) => |
| 391 | diffQuot_coeff_cutoff_squared_pointwise_bound (d := d) (u := u) B hη_range i j k hM_nn h_M |
| 392 | h_thick_in_Ω' hε'_pos x |
| 393 | set S : ℝ := ∑ i : Fin d, ∑ j : Fin d, ∫ x, |
| 394 | diffQuot k h (fun y : E => B.a y i j) x * (η x)^2 * |
| 395 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 396 | diffQuot k h |
| 397 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x |
| 398 | ∂(volume : Measure E) with hS_def |
| 399 | rw [abs_neg] |
| 400 | have h_abs_sum : |S| ≤ |
| 401 | ∑ i : Fin d, ∑ j : Fin d, |∫ x, |
| 402 | diffQuot k h (fun y : E => B.a y i j) x * (η x)^2 * |
| 403 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 404 | diffQuot k h |
| 405 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x |
| 406 | ∂(volume : Measure E)| := |
| 407 | (Finset.abs_sum_le_sum_abs _ _).trans |
| 408 | (Finset.sum_le_sum (fun i _ => Finset.abs_sum_le_sum_abs _ _)) |
| 409 | refine h_abs_sum.trans ?_ |
| 410 | have h_integrand_int : ∀ i j : Fin d, Integrable (fun x : E => |
| 411 | diffQuot k h (fun y => B.a y i j) x * (η x)^2 * |
| 412 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 413 | diffQuot k h (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x) |
| 414 | volume := |
| 415 | fun i j => integrable_cross_2_summand (d := d) B hu hη hη_supp i j k hh |
| 416 | have h_first_int : ∀ j : Fin d, Integrable (fun x : E => |
| 417 | (ε / d_real) * (η x)^2 * |
| 418 | (diffQuot k h |
| 419 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2) volume := |
| 420 | fun j => integrable_const_eta_sq_diffQuot_partial_sq (d := d) hu hη hη_supp |
| 421 | j k hh (ε / d_real) |
| 422 | have h_second_int : ∀ i : Fin d, Integrable (fun x : E => |
| 423 | (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 424 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 425 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) volume := |
| 426 | fun i => integrable_const_eta_sq_indicator_partial_sq (d := d) hu hη hη_supp i |
| 427 | (M^2 / (4 * (ε / d_real))) |
| 428 | have h_pt_bound_int : ∀ i j : Fin d, Integrable (fun x : E => |
| 429 | (ε / d_real) * (η x)^2 * |
| 430 | (diffQuot k h |
| 431 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 + |
| 432 | (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 433 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 434 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) volume := |
| 435 | fun i j => (h_first_int j).add (h_second_int i) |
| 436 | have h_per_pair_bound : ∀ i j : Fin d, |
| 437 | |∫ x, diffQuot k h (fun y => B.a y i j) x * (η x)^2 * |
| 438 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 439 | diffQuot k h |
| 440 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x |
| 441 | ∂(volume : Measure E)| ≤ |
| 442 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 443 | (diffQuot k h |
| 444 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 + |
| 445 | (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 446 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 447 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) ∂(volume : Measure E) := by |
| 448 | intro i j |
| 449 | have h_tri := abs_integral_le_integral_abs (μ := (volume : Measure E)) |
| 450 | (f := fun x : E => diffQuot k h (fun y => B.a y i j) x * (η x)^2 * |
| 451 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 452 | diffQuot k h |
| 453 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x) |
| 454 | refine h_tri.trans ?_ |
| 455 | refine integral_mono_ae ((h_integrand_int i j).abs) (h_pt_bound_int i j) ?_ |
| 456 | refine Filter.Eventually.of_forall ?_ |
| 457 | intro x |
| 458 | exact h_each_pointwise i j x |
| 459 | have h_outer_sum : |
| 460 | ∑ i : Fin d, ∑ j : Fin d, |∫ x, |
| 461 | diffQuot k h (fun y => B.a y i j) x * (η x)^2 * |
| 462 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 463 | diffQuot k h |
| 464 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x |
| 465 | ∂(volume : Measure E)| ≤ |
| 466 | ∑ i : Fin d, ∑ j : Fin d, |
| 467 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 468 | (diffQuot k h |
| 469 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 + |
| 470 | (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 471 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 472 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) ∂(volume : Measure E) := |
| 473 | Finset.sum_le_sum (fun i _ => Finset.sum_le_sum (fun j _ => h_per_pair_bound i j)) |
| 474 | refine h_outer_sum.trans ?_ |
| 475 | have h_total_eq : |
| 476 | ∑ i : Fin d, ∑ j : Fin d, |
| 477 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 478 | (diffQuot k h |
| 479 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 + |
| 480 | (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 481 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 482 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) ∂(volume : Measure E) = |
| 483 | ε * ∫ x, (η x)^2 * |
| 484 | ∑ j : Fin d, (diffQuot k h |
| 485 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 486 | ∂(volume : Measure E) + |
| 487 | d_real * ((M^2 / (4 * (ε / d_real))) * |
| 488 | ∫ x, (η x)^2 * |
| 489 | ∑ i : Fin d, (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 490 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 491 | ∂(volume : Measure E)) := by |
| 492 | have h_per_ij : ∀ i j : Fin d, |
| 493 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 494 | (diffQuot k h |
| 495 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 + |
| 496 | (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 497 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 498 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) ∂(volume : Measure E) = |
| 499 | ∫ x, (ε / d_real) * (η x)^2 * |
| 500 | (diffQuot k h |
| 501 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 502 | ∂(volume : Measure E) + |
| 503 | ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 504 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 505 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := by |
| 506 | intro i j |
| 507 | rw [integral_add (h_first_int j) (h_second_int i)] |
| 508 | rw [show (∑ i : Fin d, ∑ j : Fin d, |
| 509 | ∫ x, ((ε / d_real) * (η x)^2 * |
| 510 | (diffQuot k h |
| 511 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 + |
| 512 | (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 513 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 514 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) ∂(volume : Measure E)) = |
| 515 | ∑ i : Fin d, ∑ j : Fin d, |
| 516 | (∫ x, (ε / d_real) * (η x)^2 * |
| 517 | (diffQuot k h |
| 518 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 519 | ∂(volume : Measure E) + |
| 520 | ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 521 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 522 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) from |
| 523 | Finset.sum_congr rfl (fun i _ => Finset.sum_congr rfl (fun j _ => h_per_ij i j))] |
| 524 | have h_inner_step : ∀ i : Fin d, ∑ j : Fin d, |
| 525 | (∫ x, (ε / d_real) * (η x)^2 * |
| 526 | (diffQuot k h |
| 527 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 528 | ∂(volume : Measure E) + |
| 529 | ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 530 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 531 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) = |
| 532 | (∑ j : Fin d, ∫ x, (ε / d_real) * (η x)^2 * |
| 533 | (diffQuot k h |
| 534 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 535 | ∂(volume : Measure E)) + |
| 536 | d_real * ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 537 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 538 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := by |
| 539 | intro i |
| 540 | rw [Finset.sum_add_distrib, Finset.sum_const, Finset.card_univ, nsmul_eq_mul] |
| 541 | rw [show (∑ i : Fin d, ∑ j : Fin d, |
| 542 | (∫ x, (ε / d_real) * (η x)^2 * |
| 543 | (diffQuot k h |
| 544 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 545 | ∂(volume : Measure E) + |
| 546 | ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 547 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 548 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E))) = |
| 549 | ∑ i : Fin d, |
| 550 | ((∑ j : Fin d, ∫ x, (ε / d_real) * (η x)^2 * |
| 551 | (diffQuot k h |
| 552 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 553 | ∂(volume : Measure E)) + |
| 554 | d_real * ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 555 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 556 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) from |
| 557 | Finset.sum_congr rfl (fun i _ => h_inner_step i)] |
| 558 | rw [Finset.sum_add_distrib, Finset.sum_const, Finset.card_univ, nsmul_eq_mul] |
| 559 | have h_first_eq : d_real * (∑ j : Fin d, ∫ x, (ε / d_real) * (η x)^2 * |
| 560 | (diffQuot k h |
| 561 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 562 | ∂(volume : Measure E)) = |
| 563 | ε * ∫ x, (η x)^2 * |
| 564 | ∑ j : Fin d, (diffQuot k h |
| 565 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 566 | ∂(volume : Measure E) := by |
| 567 | have h_pull_const : ∀ j : Fin d, |
| 568 | ∫ x, (ε / d_real) * (η x)^2 * |
| 569 | (diffQuot k h |
| 570 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 571 | ∂(volume : Measure E) = |
| 572 | (ε / d_real) * ∫ x, (η x)^2 * |
| 573 | (diffQuot k h |
| 574 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 575 | ∂(volume : Measure E) := by |
| 576 | intro j |
| 577 | rw [show (fun x : E => (ε / d_real) * (η x)^2 * |
| 578 | (diffQuot k h |
| 579 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2) = |
| 580 | fun x : E => (ε / d_real) * ((η x)^2 * |
| 581 | (diffQuot k h |
| 582 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2) from |
| 583 | by funext x; ring] |
| 584 | rw [integral_const_mul] |
| 585 | rw [show (∑ j : Fin d, ∫ x, (ε / d_real) * (η x)^2 * |
| 586 | (diffQuot k h |
| 587 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 588 | ∂(volume : Measure E)) = |
| 589 | ∑ j : Fin d, (ε / d_real) * ∫ x, (η x)^2 * |
| 590 | (diffQuot k h |
| 591 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 592 | ∂(volume : Measure E) from |
| 593 | Finset.sum_congr rfl (fun j _ => h_pull_const j)] |
| 594 | rw [← Finset.mul_sum] |
| 595 | have h_eta_sq_diffQuot_int : ∀ j : Fin d, Integrable (fun x : E => |
| 596 | (η x)^2 * (diffQuot k h |
| 597 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2) volume := |
| 598 | fun j => integrable_eta_sq_diffQuot_partial_sq (d := d) hu hη hη_supp j k hh |
| 599 | rw [show (∑ j : Fin d, ∫ x, (η x)^2 * |
| 600 | (diffQuot k h |
| 601 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 |
| 602 | ∂(volume : Measure E)) = |
| 603 | ∫ x, ∑ j : Fin d, ((η x)^2 * |
| 604 | (diffQuot k h |
| 605 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2) |
| 606 | ∂(volume : Measure E) |
| 607 | from (integral_finsetSum _ (fun j _ => h_eta_sq_diffQuot_int j)).symm] |
| 608 | have h_swap : (fun x : E => ∑ j : Fin d, ((η x)^2 * |
| 609 | (diffQuot k h |
| 610 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2)) = |
| 611 | fun x : E => (η x)^2 * ∑ j : Fin d, (diffQuot k h |
| 612 | (fun y => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x)^2 := by |
| 613 | funext x; rw [Finset.mul_sum] |
| 614 | rw [h_swap, ← mul_assoc, mul_div_cancel₀ _ (ne_of_gt hd_pos)] |
| 615 | rw [h_first_eq] |
| 616 | have h_second_eq : |
| 617 | (∑ i : Fin d, d_real * ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 618 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 619 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) = |
| 620 | d_real * (∑ i : Fin d, ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 621 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 622 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) := |
| 623 | (Finset.mul_sum _ _ _).symm |
| 624 | rw [h_second_eq] |
| 625 | have h_pull_const_2 : ∀ i : Fin d, ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 626 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 627 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) = |
| 628 | (M^2 / (4 * (ε / d_real))) * ∫ x, (η x)^2 * |
| 629 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 630 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := by |
| 631 | intro i |
| 632 | rw [show (fun x : E => (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 633 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 634 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) = |
| 635 | fun x : E => (M^2 / (4 * (ε / d_real))) * ((η x)^2 * |
| 636 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 637 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) from by funext x; ring] |
| 638 | rw [integral_const_mul] |
| 639 | rw [show (∑ i : Fin d, ∫ x, (M^2 / (4 * (ε / d_real))) * (η x)^2 * |
| 640 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 641 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) = |
| 642 | ∑ i : Fin d, (M^2 / (4 * (ε / d_real))) * ∫ x, (η x)^2 * |
| 643 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 644 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) from |
| 645 | Finset.sum_congr rfl (fun i _ => h_pull_const_2 i)] |
| 646 | rw [← Finset.mul_sum] |
| 647 | have h_inner_int : ∀ i : Fin d, Integrable (fun x : E => |
| 648 | (η x)^2 * (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 649 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) volume := by |
| 650 | intro i |
| 651 | have h := integrable_const_eta_sq_indicator_partial_sq (d := d) hu hη hη_supp i 1 |
| 652 | have h_eq : (fun x : E => (1 : ℝ) * (η x)^2 * |
| 653 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 654 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) = |
| 655 | (fun x : E => (η x)^2 * |
| 656 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 657 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) := by |
| 658 | funext x; ring |
| 659 | rw [h_eq] at h; exact h |
| 660 | rw [show (∑ i : Fin d, ∫ x, (η x)^2 * |
| 661 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 662 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) = |
| 663 | ∫ x, ∑ i : Fin d, ((η x)^2 * |
| 664 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 665 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) ∂(volume : Measure E) from |
| 666 | (integral_finsetSum _ (fun i _ => h_inner_int i)).symm] |
| 667 | have h_swap : (fun x : E => ∑ i : Fin d, ((η x)^2 * |
| 668 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 669 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2)) = |
| 670 | fun x : E => (η x)^2 * |
| 671 | ∑ i : Fin d, ((Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 672 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) := by |
| 673 | funext x; rw [Finset.mul_sum] |
| 674 | refine Finset.sum_congr rfl ?_ |
| 675 | intro i _; ring |
| 676 | rw [h_swap] |
| 677 | rw [h_total_eq] |
| 678 | have h_M_factor_nn : 0 ≤ M^2 / (4 * (ε / d_real)) := by |
| 679 | refine div_nonneg (sq_nonneg _) (by linarith) |
| 680 | have h_d_real_ge_one : 1 ≤ d_real := by |
| 681 | rw [hd_real] |
| 682 | have hd_natpos : 0 < Fintype.card (Fin d) := Fintype.card_pos |
| 683 | exact_mod_cast hd_natpos |
| 684 | have h_ind_bound : |
| 685 | ∫ x, (η x)^2 * |
| 686 | ∑ i : Fin d, (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 687 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) ≤ |
| 688 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 689 | ∂(volume : Measure E) := by |
| 690 | have h_pointwise : ∀ x : E, |
| 691 | (η x)^2 * ∑ i : Fin d, (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 692 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ≤ |
| 693 | (Set.indicator Ω' (fun y : E => ∑ i : Fin d, |
| 694 | ((fderiv ℝ u y) (EuclideanSpace.single i 1))^2)) x := by |
| 695 | intro x |
| 696 | by_cases hx : x ∈ tsupport η |
| 697 | · have hx_Ω' : x ∈ Ω' := |
| 698 | h_thick_in_Ω' (self_subset_cthickening _ hx) |
| 699 | rw [Set.indicator_of_mem hx_Ω'] |
| 700 | have h_η_in : η x ∈ Set.Icc (0 : ℝ) 1 := hη_range ⟨x, rfl⟩ |
| 701 | have h_η_sq_le : (η x)^2 ≤ 1 := by |
| 702 | have h_η_le : η x ≤ 1 := h_η_in.2 |
| 703 | have h_η_nn : 0 ≤ η x := h_η_in.1 |
| 704 | calc (η x)^2 ≤ (1 : ℝ)^2 := by |
| 705 | refine pow_le_pow_left₀ h_η_nn h_η_le 2 |
| 706 | _ = 1 := one_pow _ |
| 707 | have h_η_sq_nn : 0 ≤ (η x)^2 := sq_nonneg _ |
| 708 | have h_indicator_le_one : ∀ y : E, |
| 709 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) y) ≤ 1 := by |
| 710 | intro y |
| 711 | by_cases hy : y ∈ tsupport η |
| 712 | · rw [Set.indicator_of_mem hy] |
| 713 | · rw [Set.indicator_of_notMem hy]; norm_num |
| 714 | have h_sum_le : ∑ i : Fin d, (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 715 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ≤ |
| 716 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 := by |
| 717 | refine Finset.sum_le_sum ?_ |
| 718 | intro i _ |
| 719 | have h_le := h_indicator_le_one x |
| 720 | have h_sq_nn : 0 ≤ ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 := sq_nonneg _ |
| 721 | have h_step : (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 722 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ≤ |
| 723 | 1 * ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 := |
| 724 | mul_le_mul_of_nonneg_right h_le h_sq_nn |
| 725 | linarith |
| 726 | have h_sum_nn : 0 ≤ ∑ i : Fin d, |
| 727 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 728 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 := by |
| 729 | refine Finset.sum_nonneg ?_ |
| 730 | intro i _ |
| 731 | have h_ind_nn : 0 ≤ Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x := by |
| 732 | by_cases hxx : x ∈ tsupport η |
| 733 | · rw [Set.indicator_of_mem hxx]; norm_num |
| 734 | · rw [Set.indicator_of_notMem hxx] |
| 735 | exact mul_nonneg h_ind_nn (sq_nonneg _) |
| 736 | calc (η x)^2 * (∑ i : Fin d, |
| 737 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 738 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) ≤ |
| 739 | 1 * (∑ i : Fin d, |
| 740 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 741 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) := |
| 742 | mul_le_mul_of_nonneg_right h_η_sq_le h_sum_nn |
| 743 | _ = ∑ i : Fin d, |
| 744 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 745 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 := by ring |
| 746 | _ ≤ ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 := h_sum_le |
| 747 | · have h_η_zero : η x = 0 := image_eq_zero_of_notMem_tsupport hx |
| 748 | rw [h_η_zero] |
| 749 | simp only [ne_eq, OfNat.ofNat_ne_zero, not_false_eq_true, zero_pow, zero_mul, ge_iff_le] |
| 750 | by_cases hx_Ω' : x ∈ Ω' |
| 751 | · rw [Set.indicator_of_mem hx_Ω'] |
| 752 | exact Finset.sum_nonneg (fun i _ => sq_nonneg _) |
| 753 | · rw [Set.indicator_of_notMem hx_Ω'] |
| 754 | have h_lhs_int : Integrable (fun x : E => |
| 755 | (η x)^2 * ∑ i : Fin d, (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 756 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) volume := by |
| 757 | have h_each_int : ∀ i : Fin d, Integrable (fun x : E => |
| 758 | (η x)^2 * ((Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 759 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2)) volume := by |
| 760 | intro i |
| 761 | have h := integrable_const_eta_sq_indicator_partial_sq (d := d) hu hη hη_supp i 1 |
| 762 | have h_eq : (fun x : E => (1 : ℝ) * (η x)^2 * |
| 763 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 764 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) = |
| 765 | (fun x : E => (η x)^2 * |
| 766 | ((Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 767 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2)) := by |
| 768 | funext x; ring |
| 769 | rw [h_eq] at h; exact h |
| 770 | have h_sum_int : Integrable (fun x : E => ∑ i : Fin d, (η x)^2 * |
| 771 | ((Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 772 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2)) volume := |
| 773 | integrable_finsetSum (Finset.univ : Finset (Fin d)) (fun i _ => h_each_int i) |
| 774 | have h_eq : (fun x : E => ∑ i : Fin d, (η x)^2 * |
| 775 | ((Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 776 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2)) = |
| 777 | (fun x : E => (η x)^2 * ∑ i : Fin d, |
| 778 | ((Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 779 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2)) := by |
| 780 | funext x; rw [Finset.mul_sum] |
| 781 | rw [h_eq] at h_sum_int; exact h_sum_int |
| 782 | have h_rhs_int : Integrable (fun y : E => |
| 783 | Set.indicator Ω' (fun z : E => ∑ i : Fin d, |
| 784 | ((fderiv ℝ u z) (EuclideanSpace.single i 1))^2) y) volume := by |
| 785 | have h_partial_sq_cont : ∀ i : Fin d, |
| 786 | Continuous (fun x : E => ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) := |
| 787 | fun i => (continuous_partial_u (d := d) hu i).pow 2 |
| 788 | have h_sum_cont : Continuous (fun x : E => |
| 789 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) := |
| 790 | continuous_finsetSum _ (fun i _ => h_partial_sq_cont i) |
| 791 | have h_int_clΩ' : IntegrableOn (fun x : E => |
| 792 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) (closure Ω') volume := |
| 793 | ContinuousOn.integrableOn_compact hΩ'_compact h_sum_cont.continuousOn |
| 794 | have h_int_Ω' : IntegrableOn (fun x : E => |
| 795 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) Ω' volume := |
| 796 | h_int_clΩ'.mono_set subset_closure |
| 797 | exact h_int_Ω'.integrable_indicator hΩ'.measurableSet |
| 798 | have h_int_le := integral_mono h_lhs_int h_rhs_int h_pointwise |
| 799 | refine h_int_le.trans ?_ |
| 800 | rw [show (fun y : E => Set.indicator Ω' (fun z : E => ∑ i : Fin d, |
| 801 | ((fderiv ℝ u z) (EuclideanSpace.single i 1))^2) y) = |
| 802 | Set.indicator Ω' (fun z : E => ∑ i : Fin d, |
| 803 | ((fderiv ℝ u z) (EuclideanSpace.single i 1))^2) from rfl] |
| 804 | rw [MeasureTheory.integral_indicator hΩ'.measurableSet] |
| 805 | have h_combine : |
| 806 | d_real * ((M^2 / (4 * (ε / d_real))) * |
| 807 | ∫ x, (η x)^2 * |
| 808 | ∑ i : Fin d, (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 809 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) ≤ |
| 810 | C * ∫ x in Ω', |
| 811 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 812 | ∂(volume : Measure E) := by |
| 813 | have h_step1 : d_real * ((M^2 / (4 * (ε / d_real))) * |
| 814 | ∫ x, (η x)^2 * |
| 815 | ∑ i : Fin d, (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 816 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) ≤ |
| 817 | d_real * ((M^2 / (4 * (ε / d_real))) * |
| 818 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 819 | ∂(volume : Measure E)) := by |
| 820 | refine mul_le_mul_of_nonneg_left ?_ hd_nn |
| 821 | exact mul_le_mul_of_nonneg_left h_ind_bound h_M_factor_nn |
| 822 | refine h_step1.trans ?_ |
| 823 | have h_J_nn : 0 ≤ ∫ x in Ω', |
| 824 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 825 | ∂(volume : Measure E) := by |
| 826 | refine integral_nonneg ?_ |
| 827 | intro x |
| 828 | exact Finset.sum_nonneg (fun i _ => sq_nonneg _) |
| 829 | have h_step2 : |
| 830 | d_real * ((M^2 / (4 * (ε / d_real))) * |
| 831 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 832 | ∂(volume : Measure E)) ≤ |
| 833 | d_real^2 * ((M^2 / (4 * (ε / d_real))) * |
| 834 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 835 | ∂(volume : Measure E)) := by |
| 836 | have h_factor_nn : |
| 837 | 0 ≤ (M^2 / (4 * (ε / d_real))) * |
| 838 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 839 | ∂(volume : Measure E) := |
| 840 | mul_nonneg h_M_factor_nn h_J_nn |
| 841 | have h_d_le_d_sq : d_real ≤ d_real^2 := by |
| 842 | have h := h_d_real_ge_one |
| 843 | nlinarith |
| 844 | exact mul_le_mul_of_nonneg_right h_d_le_d_sq h_factor_nn |
| 845 | refine h_step2.trans ?_ |
| 846 | have h_C_eq : C = d_real^2 * (M^2 / (4 * (ε / d_real))) := by |
| 847 | rw [hC_def]; ring |
| 848 | rw [show d_real^2 * ((M^2 / (4 * (ε / d_real))) * |
| 849 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 850 | ∂(volume : Measure E)) = |
| 851 | (d_real^2 * (M^2 / (4 * (ε / d_real)))) * |
| 852 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 853 | ∂(volume : Measure E) from by ring] |
| 854 | rw [← h_C_eq] |
| 855 | linarith |
| 856 | |
| 857 | |
| 858 | theorem coeff_diffQuot_cutoff_deriv_cross_bound |
| 859 | {Ω : Set E} (B : SmoothEllipticBilinearForm d Ω) |
| 860 | {η : E → ℝ} (hη : ContDiff ℝ (⊤ : ℕ∞) η) (hη_supp : HasCompactSupport η) |
| 861 | (hη_range : Set.range η ⊆ Set.Icc (0 : ℝ) 1) |
| 862 | {N : ℝ} (hN : 0 ≤ N) (h_fderiv_eta : ∀ x : E, ‖fderiv ℝ η x‖ ≤ N) |
| 863 | {Ω' : Set E} (hΩ' : IsOpen Ω') |
| 864 | (hΩ'_compact : IsCompact (closure Ω')) |
| 865 | {R₀ : ℝ} |
| 866 | (hh_supp_in_Ω' : ∀ {h : ℝ}, |h| ≤ R₀ → |
| 867 | Metric.cthickening |h| (tsupport η) ⊆ Ω') |
| 868 | (k : Fin d) : |
| 869 | ∃ C : ℝ, 0 ≤ C ∧ ∀ {u : E → ℝ}, ContDiff ℝ (⊤ : ℕ∞) u → |
| 870 | ∀ {h : ℝ}, h ≠ 0 → |h| ≤ R₀ → |
| 871 | |- ∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 872 | Poincare.Analysis.Sobolev.diffQuot k h |
| 873 | (fun y : E => B.a y i j) x * |
| 874 | (η x) * |
| 875 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 876 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 877 | Poincare.Analysis.Sobolev.diffQuot k h u x |
| 878 | ∂(volume : Measure E)| ≤ |
| 879 | C * ∫ x in Ω', |
| 880 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 881 | ∂(volume : Measure E) := by |
| 882 | classical |
| 883 | obtain ⟨M, hM_nn, h_M⟩ := |
| 884 | SmoothEllipticBilinearForm.bounded_fderiv_a_on_compact (d := d) B k hΩ'_compact |
| 885 | set d_real : ℝ := (Fintype.card (Fin d) : ℝ) with hd_real |
| 886 | have hd_pos : 0 < d_real := by |
| 887 | rw [hd_real]; exact_mod_cast Fintype.card_pos |
| 888 | have hd_ge_one : 1 ≤ d_real := by |
| 889 | rw [hd_real]; exact_mod_cast Fintype.card_pos |
| 890 | have hd_nn : 0 ≤ d_real := hd_pos.le |
| 891 | set C : ℝ := 2 * M * N * d_real^2 with hC_def |
| 892 | have hC_nn : 0 ≤ C := by |
| 893 | rw [hC_def] |
| 894 | refine mul_nonneg ?_ (sq_nonneg _) |
| 895 | refine mul_nonneg ?_ hN |
| 896 | exact mul_nonneg (by linarith) hM_nn |
| 897 | refine ⟨C, hC_nn, ?_⟩ |
| 898 | intro u hu h hh hh_le |
| 899 | have h_thick_in_Ω' : Metric.cthickening |h| (tsupport η) ⊆ Ω' := hh_supp_in_Ω' hh_le |
| 900 | have h_each_pointwise := fun (i j : Fin d) (x : E) => |
| 901 | diffQuot_coeff_cutoff_gradient_pointwise_bound (d := d) B (u := u) hη_range h_fderiv_eta i j k |
| 902 | hM_nn h_M |
| 903 | h_thick_in_Ω' x |
| 904 | set S : ℝ := ∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 905 | diffQuot k h (fun y : E => B.a y i j) x * (η x) * |
| 906 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 907 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 908 | diffQuot k h u x |
| 909 | ∂(volume : Measure E) with hS_def |
| 910 | rw [abs_neg] |
| 911 | have h_abs_sum : |S| ≤ |
| 912 | ∑ i : Fin d, ∑ j : Fin d, |∫ x, 2 * |
| 913 | diffQuot k h (fun y : E => B.a y i j) x * (η x) * |
| 914 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 915 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 916 | diffQuot k h u x ∂(volume : Measure E)| := |
| 917 | (Finset.abs_sum_le_sum_abs _ _).trans |
| 918 | (Finset.sum_le_sum (fun i _ => Finset.abs_sum_le_sum_abs _ _)) |
| 919 | refine h_abs_sum.trans ?_ |
| 920 | have h_integrand_int : ∀ i j : Fin d, Integrable (fun x : E => |
| 921 | 2 * diffQuot k h (fun y => B.a y i j) x * (η x) * |
| 922 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 923 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 924 | diffQuot k h u x) volume := |
| 925 | fun i j => integrable_cross_3_summand (d := d) B hu hη hη_supp i j k hh |
| 926 | have h_pt_bound1_int : ∀ i : Fin d, Integrable (fun x : E => |
| 927 | M * N * |
| 928 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 929 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) volume := by |
| 930 | intro i |
| 931 | have h := integrable_const_eta_sq_indicator_partial_sq (d := d) hu hη hη_supp i 1 |
| 932 | have h_partial_cont : Continuous |
| 933 | (fun x : E => (fderiv ℝ u x) (EuclideanSpace.single i 1)) := |
| 934 | continuous_partial_u (d := d) hu i |
| 935 | have h_partial_sq_cont : Continuous |
| 936 | (fun x : E => ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) := |
| 937 | h_partial_cont.pow 2 |
| 938 | have h_tsupp_meas : MeasurableSet (tsupport η) := |
| 939 | isClosed_tsupport η |>.measurableSet |
| 940 | have h_tsupp_compact : IsCompact (tsupport η) := hη_supp |
| 941 | have h_eq : (fun x : E => M * N * |
| 942 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 943 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) = |
| 944 | Set.indicator (tsupport η) |
| 945 | (fun y : E => M * N * ((fderiv ℝ u y) (EuclideanSpace.single i 1))^2) := by |
| 946 | funext x |
| 947 | by_cases hx : x ∈ tsupport η |
| 948 | · rw [Set.indicator_of_mem hx, Set.indicator_of_mem hx]; ring |
| 949 | · rw [Set.indicator_of_notMem hx, Set.indicator_of_notMem hx]; ring |
| 950 | rw [h_eq] |
| 951 | have h_inner_cont : Continuous (fun y : E => |
| 952 | M * N * ((fderiv ℝ u y) (EuclideanSpace.single i 1))^2) := |
| 953 | continuous_const.mul h_partial_sq_cont |
| 954 | exact (ContinuousOn.integrableOn_compact h_tsupp_compact |
| 955 | h_inner_cont.continuousOn).integrable_indicator |
| 956 | h_tsupp_meas |
| 957 | have h_pt_bound2_int : Integrable (fun x : E => |
| 958 | M * N * |
| 959 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 960 | (diffQuot k h u x)^2) volume := |
| 961 | integrable_const_indicator_diffQuot_sq (d := d) hu hη_supp k hh (M * N) |
| 962 | have h_pt_bound_int : ∀ i j : Fin d, Integrable (fun x : E => |
| 963 | M * N * |
| 964 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 965 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 + |
| 966 | M * N * |
| 967 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 968 | (diffQuot k h u x)^2) volume := |
| 969 | fun i j => (h_pt_bound1_int i).add h_pt_bound2_int |
| 970 | have h_per_pair_bound : ∀ i j : Fin d, |
| 971 | |∫ x, 2 * diffQuot k h (fun y => B.a y i j) x * (η x) * |
| 972 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 973 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 974 | diffQuot k h u x ∂(volume : Measure E)| ≤ |
| 975 | ∫ x, (M * N * |
| 976 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 977 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 + |
| 978 | M * N * |
| 979 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 980 | (diffQuot k h u x)^2) ∂(volume : Measure E) := by |
| 981 | intro i j |
| 982 | have h_tri := abs_integral_le_integral_abs (μ := (volume : Measure E)) |
| 983 | (f := fun x : E => 2 * diffQuot k h (fun y => B.a y i j) x * (η x) * |
| 984 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 985 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 986 | diffQuot k h u x) |
| 987 | refine h_tri.trans ?_ |
| 988 | refine integral_mono_ae ((h_integrand_int i j).abs) (h_pt_bound_int i j) ?_ |
| 989 | refine Filter.Eventually.of_forall ?_ |
| 990 | intro x |
| 991 | exact h_each_pointwise i j x |
| 992 | have h_outer_sum : |
| 993 | ∑ i : Fin d, ∑ j : Fin d, |∫ x, 2 * |
| 994 | diffQuot k h (fun y => B.a y i j) x * (η x) * |
| 995 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 996 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 997 | diffQuot k h u x ∂(volume : Measure E)| ≤ |
| 998 | ∑ i : Fin d, ∑ j : Fin d, |
| 999 | ∫ x, (M * N * |
| 1000 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1001 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 + |
| 1002 | M * N * |
| 1003 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1004 | (diffQuot k h u x)^2) ∂(volume : Measure E) := |
| 1005 | Finset.sum_le_sum (fun i _ => Finset.sum_le_sum (fun j _ => h_per_pair_bound i j)) |
| 1006 | refine h_outer_sum.trans ?_ |
| 1007 | have h_total_bound : |
| 1008 | ∑ i : Fin d, ∑ j : Fin d, |
| 1009 | ∫ x, (M * N * |
| 1010 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1011 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 + |
| 1012 | M * N * |
| 1013 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1014 | (diffQuot k h u x)^2) ∂(volume : Measure E) ≤ |
| 1015 | C * ∫ x in Ω', |
| 1016 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 1017 | ∂(volume : Measure E) := by |
| 1018 | have h_split_integral : ∀ i j : Fin d, |
| 1019 | ∫ x, (M * N * |
| 1020 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1021 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 + |
| 1022 | M * N * |
| 1023 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1024 | (diffQuot k h u x)^2) ∂(volume : Measure E) = |
| 1025 | ∫ x, M * N * |
| 1026 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1027 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) + |
| 1028 | ∫ x, M * N * |
| 1029 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1030 | (diffQuot k h u x)^2 ∂(volume : Measure E) := by |
| 1031 | intro i j |
| 1032 | rw [integral_add (h_pt_bound1_int i) h_pt_bound2_int] |
| 1033 | have h_A_factor : ∀ i : Fin d, |
| 1034 | ∫ x, M * N * |
| 1035 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1036 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) = |
| 1037 | M * N * ∫ x in tsupport η, |
| 1038 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := by |
| 1039 | intro i |
| 1040 | rw [show (fun x : E => M * N * |
| 1041 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1042 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) = |
| 1043 | fun x : E => M * N * ((Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1044 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) from by funext x; ring] |
| 1045 | rw [integral_const_mul] |
| 1046 | congr 1 |
| 1047 | rw [show (fun x : E => (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1048 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) = |
| 1049 | (fun x : E => Set.indicator (tsupport η) |
| 1050 | (fun y : E => ((fderiv ℝ u y) (EuclideanSpace.single i 1))^2) x) from by |
| 1051 | funext x |
| 1052 | by_cases hx : x ∈ tsupport η |
| 1053 | · rw [Set.indicator_of_mem hx, Set.indicator_of_mem hx]; ring |
| 1054 | · rw [Set.indicator_of_notMem hx, Set.indicator_of_notMem hx]; ring] |
| 1055 | rw [MeasureTheory.integral_indicator (isClosed_tsupport η).measurableSet] |
| 1056 | have h_B_factor : |
| 1057 | ∫ x, M * N * |
| 1058 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1059 | (diffQuot k h u x)^2 ∂(volume : Measure E) = |
| 1060 | M * N * ∫ x in tsupport η, |
| 1061 | (diffQuot k h u x)^2 ∂(volume : Measure E) := |
| 1062 | integral_const_indicator_eq (d := d) k h η (M * N) (u := u) |
| 1063 | rw [show (∑ i : Fin d, ∑ j : Fin d, ∫ x, (M * N * |
| 1064 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1065 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 + |
| 1066 | M * N * |
| 1067 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1068 | (diffQuot k h u x)^2) ∂(volume : Measure E)) = |
| 1069 | ∑ i : Fin d, ∑ j : Fin d, |
| 1070 | (∫ x, M * N * |
| 1071 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1072 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) + |
| 1073 | ∫ x, M * N * |
| 1074 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1075 | (diffQuot k h u x)^2 ∂(volume : Measure E)) from |
| 1076 | Finset.sum_congr rfl (fun i _ => Finset.sum_congr rfl (fun j _ => h_split_integral i j))] |
| 1077 | rw [show (∑ i : Fin d, ∑ j : Fin d, |
| 1078 | (∫ x, M * N * |
| 1079 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1080 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) + |
| 1081 | ∫ x, M * N * |
| 1082 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1083 | (diffQuot k h u x)^2 ∂(volume : Measure E))) = |
| 1084 | ∑ i : Fin d, (∑ j : Fin d, ∫ x, M * N * |
| 1085 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1086 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) + |
| 1087 | ∑ i : Fin d, (∑ j : Fin d, ∫ x, M * N * |
| 1088 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1089 | (diffQuot k h u x)^2 ∂(volume : Measure E)) from by |
| 1090 | rw [← Finset.sum_add_distrib] |
| 1091 | refine Finset.sum_congr rfl ?_ |
| 1092 | intro i _ |
| 1093 | rw [Finset.sum_add_distrib]] |
| 1094 | have h_step1 : (∑ i : Fin d, (∑ _j : Fin d, ∫ x, M * N * |
| 1095 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1096 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E))) = |
| 1097 | d_real * ∑ i : Fin d, ∫ x, M * N * |
| 1098 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1099 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := by |
| 1100 | rw [show (∑ i : Fin d, (∑ _j : Fin d, ∫ x, M * N * |
| 1101 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1102 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E))) = |
| 1103 | ∑ i : Fin d, d_real * ∫ x, M * N * |
| 1104 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1105 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) from |
| 1106 | Finset.sum_congr rfl (fun i _ => by |
| 1107 | rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul])] |
| 1108 | rw [← Finset.mul_sum] |
| 1109 | have h_step2 : (∑ _i : Fin d, (∑ _j : Fin d, ∫ x, M * N * |
| 1110 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1111 | (diffQuot k h u x)^2 ∂(volume : Measure E))) = |
| 1112 | d_real^2 * ∫ x, M * N * |
| 1113 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1114 | (diffQuot k h u x)^2 ∂(volume : Measure E) := by |
| 1115 | have h_inner : ∀ _i : Fin d, (∑ _j : Fin d, ∫ x, M * N * |
| 1116 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1117 | (diffQuot k h u x)^2 ∂(volume : Measure E)) = |
| 1118 | d_real * ∫ x, M * N * |
| 1119 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1120 | (diffQuot k h u x)^2 ∂(volume : Measure E) := by |
| 1121 | intro _i |
| 1122 | rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] |
| 1123 | rw [show (∑ _i : Fin d, (∑ _j : Fin d, ∫ x, M * N * |
| 1124 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1125 | (diffQuot k h u x)^2 ∂(volume : Measure E))) = |
| 1126 | ∑ _i : Fin d, d_real * ∫ x, M * N * |
| 1127 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1128 | (diffQuot k h u x)^2 ∂(volume : Measure E) from |
| 1129 | Finset.sum_congr rfl (fun i _ => h_inner i)] |
| 1130 | rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul] |
| 1131 | rw [← mul_assoc, ← hd_real] |
| 1132 | ring |
| 1133 | rw [h_step1, h_step2] |
| 1134 | rw [show (∑ i : Fin d, ∫ x, M * N * |
| 1135 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1136 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) = |
| 1137 | ∑ i : Fin d, M * N * ∫ x in tsupport η, |
| 1138 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) from |
| 1139 | Finset.sum_congr rfl (fun i _ => h_A_factor i)] |
| 1140 | rw [h_B_factor] |
| 1141 | have h_MN_nn : 0 ≤ M * N := mul_nonneg hM_nn hN |
| 1142 | have h_d_le_d_sq : d_real ≤ d_real^2 := by nlinarith |
| 1143 | have h_J_nn : 0 ≤ ∫ x in Ω', |
| 1144 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1145 | ∂(volume : Measure E) := |
| 1146 | integral_nonneg (fun x => Finset.sum_nonneg (fun i _ => sq_nonneg _)) |
| 1147 | have h_partial_sq_cont : ∀ i : Fin d, |
| 1148 | Continuous (fun x : E => ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) := |
| 1149 | fun i => (continuous_partial_u (d := d) hu i).pow 2 |
| 1150 | have h_int_clΩ' : ∀ i : Fin d, IntegrableOn |
| 1151 | (fun x : E => ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) (closure Ω') volume := |
| 1152 | fun i => ContinuousOn.integrableOn_compact hΩ'_compact (h_partial_sq_cont i).continuousOn |
| 1153 | have h_int_Ω' : ∀ i : Fin d, IntegrableOn |
| 1154 | (fun x : E => ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) Ω' volume := |
| 1155 | fun i => (h_int_clΩ' i).mono_set subset_closure |
| 1156 | have h_tsupp_subset_Ω' : tsupport η ⊆ Ω' := |
| 1157 | fun x hx => h_thick_in_Ω' (self_subset_cthickening _ hx) |
| 1158 | have h_int_tsupp : ∀ i : Fin d, IntegrableOn |
| 1159 | (fun x : E => ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2) (tsupport η) volume := |
| 1160 | fun i => (h_int_Ω' i).mono_set h_tsupp_subset_Ω' |
| 1161 | have h_part_bound : ∀ i : Fin d, |
| 1162 | ∫ x in tsupport η, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) ≤ |
| 1163 | ∫ x in Ω', ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := by |
| 1164 | intro i |
| 1165 | refine setIntegral_mono_set (h_int_Ω' i) ?_ ?_ |
| 1166 | · exact Filter.Eventually.of_forall (fun x => sq_nonneg _) |
| 1167 | · exact Filter.Eventually.of_forall h_tsupp_subset_Ω' |
| 1168 | have h_sum_part_bound : |
| 1169 | ∑ i : Fin d, ∫ x in tsupport η, |
| 1170 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) ≤ |
| 1171 | ∫ x in Ω', |
| 1172 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := by |
| 1173 | have h_sum_eq : |
| 1174 | ∫ x in Ω', |
| 1175 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1176 | ∂(volume : Measure E) = |
| 1177 | ∑ i : Fin d, ∫ x in Ω', |
| 1178 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := by |
| 1179 | exact integral_finsetSum (Finset.univ : Finset (Fin d)) (fun i _ => h_int_Ω' i) |
| 1180 | rw [h_sum_eq] |
| 1181 | exact Finset.sum_le_sum (fun i _ => h_part_bound i) |
| 1182 | have h_diff_bound : |
| 1183 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) ≤ |
| 1184 | ∫ x in Ω', |
| 1185 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) := |
| 1186 | integral_diffQuot_sq_on_tsupport_le_gradL2sqOn (d := d) hu k hh η hΩ' |
| 1187 | hΩ'_compact h_thick_in_Ω' |
| 1188 | have h_term1 : |
| 1189 | d_real * ∑ i : Fin d, M * N * |
| 1190 | ∫ x in tsupport η, |
| 1191 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) ≤ |
| 1192 | d_real^2 * (M * N * ∫ x in Ω', |
| 1193 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1194 | ∂(volume : Measure E)) := by |
| 1195 | rw [show (d_real * ∑ i : Fin d, M * N * |
| 1196 | ∫ x in tsupport η, |
| 1197 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) = |
| 1198 | (d_real * (M * N)) * (∑ i : Fin d, ∫ x in tsupport η, |
| 1199 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) from by |
| 1200 | rw [← Finset.mul_sum]; ring] |
| 1201 | have h_step_a : (d_real * (M * N)) * (∑ i : Fin d, ∫ x in tsupport η, |
| 1202 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E)) ≤ |
| 1203 | (d_real * (M * N)) * (∫ x in Ω', |
| 1204 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1205 | ∂(volume : Measure E)) := by |
| 1206 | refine mul_le_mul_of_nonneg_left h_sum_part_bound ?_ |
| 1207 | exact mul_nonneg hd_nn h_MN_nn |
| 1208 | refine h_step_a.trans ?_ |
| 1209 | rw [show d_real^2 * (M * N * ∫ x in Ω', |
| 1210 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1211 | ∂(volume : Measure E)) = |
| 1212 | (d_real^2 * (M * N)) * (∫ x in Ω', |
| 1213 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1214 | ∂(volume : Measure E)) from by ring] |
| 1215 | refine mul_le_mul_of_nonneg_right ?_ h_J_nn |
| 1216 | exact mul_le_mul_of_nonneg_right h_d_le_d_sq h_MN_nn |
| 1217 | have h_term2 : |
| 1218 | d_real^2 * (M * N * ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E)) ≤ |
| 1219 | d_real^2 * (M * N * ∫ x in Ω', |
| 1220 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1221 | ∂(volume : Measure E)) := by |
| 1222 | refine mul_le_mul_of_nonneg_left ?_ (sq_nonneg _) |
| 1223 | exact mul_le_mul_of_nonneg_left h_diff_bound h_MN_nn |
| 1224 | have h_sum_le : d_real * ∑ i : Fin d, M * N * |
| 1225 | ∫ x in tsupport η, |
| 1226 | ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 ∂(volume : Measure E) + |
| 1227 | d_real^2 * (M * N * ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E)) ≤ |
| 1228 | 2 * (d_real^2 * (M * N * ∫ x in Ω', |
| 1229 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1230 | ∂(volume : Measure E))) := by linarith |
| 1231 | refine h_sum_le.trans ?_ |
| 1232 | have h_C_eq : C = 2 * d_real^2 * M * N := by |
| 1233 | rw [hC_def]; ring |
| 1234 | rw [show 2 * (d_real^2 * (M * N * ∫ x in Ω', |
| 1235 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1236 | ∂(volume : Measure E))) = |
| 1237 | (2 * d_real^2 * M * N) * |
| 1238 | ∫ x in Ω', |
| 1239 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1240 | ∂(volume : Measure E) from by ring] |
| 1241 | rw [← h_C_eq] |
| 1242 | exact h_total_bound |
| 1243 | |
| 1244 | |
| 1245 | omit [NeZero d] in |
| 1246 | private theorem nirenbergTestFunction_sq_integral_le |
| 1247 | {u : E → ℝ} (hu : ContDiff ℝ (⊤ : ℕ∞) u) |
| 1248 | {η : E → ℝ} (hη : ContDiff ℝ (⊤ : ℕ∞) η) (hη_supp : HasCompactSupport η) |
| 1249 | (hη_range : Set.range η ⊆ Set.Icc (0 : ℝ) 1) |
| 1250 | {N : ℝ} (h_fderiv_eta : ∀ x : E, ‖fderiv ℝ η x‖ ≤ N) |
| 1251 | (k : Fin d) {h : ℝ} (hh : h ≠ 0) : |
| 1252 | ∫ x, (Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 1253 | k h η u x)^2 ∂(volume : Measure E) ≤ |
| 1254 | 8 * N^2 * |
| 1255 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) + |
| 1256 | 2 * ∫ x, (η x)^2 * |
| 1257 | (diffQuot k h |
| 1258 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1259 | ∂(volume : Measure E) := by |
| 1260 | set g : E → ℝ := fun y : E => η y ^ 2 * diffQuot k h u y with hg_def |
| 1261 | have hg_smooth : ContDiff ℝ 1 g := by |
| 1262 | have h1 : ContDiff ℝ (⊤ : ℕ∞) (fun y : E => η y ^ 2) := hη.pow 2 |
| 1263 | have h2 : ContDiff ℝ (⊤ : ℕ∞) (Poincare.Analysis.Sobolev.diffQuot k h u) := |
| 1264 | contDiff_diffQuot_of_contDiff (d := d) hu k hh |
| 1265 | exact (h1.mul h2).of_le (by norm_cast) |
| 1266 | have hg_supp : HasCompactSupport g := by |
| 1267 | have h_eta_sq_supp : HasCompactSupport (fun y : E => η y ^ 2) := by |
| 1268 | have heq : (fun y : E => η y ^ 2) = (fun y : E => η y * η y) := by |
| 1269 | funext y; ring |
| 1270 | rw [heq]; exact hη_supp.mul_right |
| 1271 | exact h_eta_sq_supp.mul_right |
| 1272 | have hnh : (-h) ≠ 0 := neg_ne_zero.mpr hh |
| 1273 | have h_thick_int : Integrable |
| 1274 | (fun y : E => ((fderiv ℝ g y) (EuclideanSpace.single k 1)) ^ 2) |
| 1275 | ((volume : Measure E).restrict (Metric.cthickening |-h| (Set.univ : Set E))) := by |
| 1276 | have h_fderiv_g_cont : Continuous (fderiv ℝ g) := |
| 1277 | hg_smooth.continuous_fderiv (by norm_num) |
| 1278 | have h_partial_cont : Continuous (fun y : E => (fderiv ℝ g y) (EuclideanSpace.single k 1)) := |
| 1279 | h_fderiv_g_cont.clm_apply continuous_const |
| 1280 | have h_partial_sq_cont : Continuous |
| 1281 | (fun y : E => ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2) := |
| 1282 | h_partial_cont.pow 2 |
| 1283 | have h_partial_supp : HasCompactSupport |
| 1284 | (fun y : E => (fderiv ℝ g y) (EuclideanSpace.single k 1)) := |
| 1285 | HasCompactSupport.fderiv_apply (𝕜 := ℝ) hg_supp (EuclideanSpace.single k 1) |
| 1286 | have h_partial_sq_supp : HasCompactSupport |
| 1287 | (fun y : E => ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2) := by |
| 1288 | have : (fun y : E => ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2) = |
| 1289 | (fun x : ℝ => x^2) ∘ (fun y : E => (fderiv ℝ g y) (EuclideanSpace.single k 1)) := by |
| 1290 | funext y; rfl |
| 1291 | rw [this] |
| 1292 | exact HasCompactSupport.comp_left h_partial_supp (by simp : (0 : ℝ)^2 = 0) |
| 1293 | exact (h_partial_sq_cont.integrable_of_hasCompactSupport h_partial_sq_supp).integrableOn |
| 1294 | have h_local := integral_sq_diffQuot_le_local (d := d) hg_smooth k hnh |
| 1295 | MeasurableSet.univ h_thick_int |
| 1296 | have h_v_test_eq : (fun x : E => |
| 1297 | (Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 1298 | k h η u x)^2) = |
| 1299 | fun x : E => (diffQuot k (-h) g x)^2 := by |
| 1300 | funext x |
| 1301 | unfold Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 1302 | rfl |
| 1303 | rw [h_v_test_eq] |
| 1304 | have h_lhs : ∫ x, (diffQuot k (-h) g x)^2 ∂(volume : Measure E) ≤ |
| 1305 | ∫ y, ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2 ∂(volume : Measure E) := by |
| 1306 | have h_lhs_restrict : ∫ x in (Set.univ : Set E), |
| 1307 | (diffQuot k (-h) g x)^2 ∂(volume : Measure E) = |
| 1308 | ∫ x, (diffQuot k (-h) g x)^2 ∂(volume : Measure E) := by |
| 1309 | rw [Measure.restrict_univ] |
| 1310 | have h_rhs_restrict : ∫ y in Metric.cthickening |-h| (Set.univ : Set E), |
| 1311 | ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2 ∂(volume : Measure E) = |
| 1312 | ∫ y, ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2 ∂(volume : Measure E) := by |
| 1313 | have h_eq : Metric.cthickening |-h| (Set.univ : Set E) = Set.univ := by |
| 1314 | ext y |
| 1315 | constructor |
| 1316 | · intro _; trivial |
| 1317 | · intro _ |
| 1318 | exact Metric.self_subset_cthickening _ trivial |
| 1319 | rw [h_eq, Measure.restrict_univ] |
| 1320 | rw [← h_lhs_restrict, ← h_rhs_restrict] |
| 1321 | exact h_local |
| 1322 | refine h_lhs.trans ?_ |
| 1323 | have h_pointwise_bound : ∀ x : E, |
| 1324 | ((fderiv ℝ g x) (EuclideanSpace.single k 1))^2 ≤ |
| 1325 | 8 * N^2 * |
| 1326 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1327 | (diffQuot k h u x)^2 + |
| 1328 | 2 * (η x)^2 * |
| 1329 | (diffQuot k h |
| 1330 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 := by |
| 1331 | intro x |
| 1332 | exact fderiv_eta_sq_diffQuot_sq_bound (d := d) hu hη hη_range h_fderiv_eta k hh x |
| 1333 | have h_lhs_int : Integrable (fun x : E => |
| 1334 | ((fderiv ℝ g x) (EuclideanSpace.single k 1))^2) volume := by |
| 1335 | have h_fderiv_g_cont : Continuous (fderiv ℝ g) := |
| 1336 | hg_smooth.continuous_fderiv (by norm_num) |
| 1337 | have h_partial_cont : Continuous (fun y : E => (fderiv ℝ g y) (EuclideanSpace.single k 1)) := |
| 1338 | h_fderiv_g_cont.clm_apply continuous_const |
| 1339 | have h_partial_sq_cont : Continuous |
| 1340 | (fun y : E => ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2) := |
| 1341 | h_partial_cont.pow 2 |
| 1342 | have h_partial_supp : HasCompactSupport |
| 1343 | (fun y : E => (fderiv ℝ g y) (EuclideanSpace.single k 1)) := |
| 1344 | HasCompactSupport.fderiv_apply (𝕜 := ℝ) hg_supp (EuclideanSpace.single k 1) |
| 1345 | have h_partial_sq_supp : HasCompactSupport |
| 1346 | (fun y : E => ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2) := by |
| 1347 | have : (fun y : E => ((fderiv ℝ g y) (EuclideanSpace.single k 1))^2) = |
| 1348 | (fun x : ℝ => x^2) ∘ (fun y : E => (fderiv ℝ g y) (EuclideanSpace.single k 1)) := by |
| 1349 | funext y; rfl |
| 1350 | rw [this] |
| 1351 | exact HasCompactSupport.comp_left h_partial_supp (by simp : (0 : ℝ)^2 = 0) |
| 1352 | exact h_partial_sq_cont.integrable_of_hasCompactSupport h_partial_sq_supp |
| 1353 | have h_t1_int : Integrable (fun x : E => |
| 1354 | 8 * N^2 * |
| 1355 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1356 | (diffQuot k h u x)^2) volume := |
| 1357 | integrable_const_indicator_diffQuot_sq (d := d) hu hη_supp k hh (8 * N^2) |
| 1358 | have h_t2_int : Integrable (fun x : E => |
| 1359 | 2 * (η x)^2 * |
| 1360 | (diffQuot k h |
| 1361 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2) volume := |
| 1362 | integrable_const_eta_sq_diffQuot_partial_sq (d := d) hu hη hη_supp k k hh 2 |
| 1363 | have h_rhs_int : Integrable (fun x : E => |
| 1364 | 8 * N^2 * |
| 1365 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1366 | (diffQuot k h u x)^2 + |
| 1367 | 2 * (η x)^2 * |
| 1368 | (diffQuot k h |
| 1369 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2) volume := |
| 1370 | h_t1_int.add h_t2_int |
| 1371 | have h_int_le := integral_mono h_lhs_int h_rhs_int h_pointwise_bound |
| 1372 | refine h_int_le.trans ?_ |
| 1373 | rw [integral_add h_t1_int h_t2_int] |
| 1374 | have h_t1_eq : ∫ x, 8 * N^2 * |
| 1375 | (Set.indicator (tsupport η) (fun _ : E => (1 : ℝ)) x) * |
| 1376 | (diffQuot k h u x)^2 ∂(volume : Measure E) = |
| 1377 | 8 * N^2 * ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) := |
| 1378 | integral_const_indicator_eq (d := d) k h η (8 * N^2) (u := u) |
| 1379 | rw [h_t1_eq] |
| 1380 | have h_t2_eq : ∫ x, 2 * (η x)^2 * |
| 1381 | (diffQuot k h |
| 1382 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 ∂(volume : Measure E) = |
| 1383 | 2 * ∫ x, (η x)^2 * |
| 1384 | (diffQuot k h |
| 1385 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 ∂(volume : Measure E) := by |
| 1386 | rw [show (fun x : E => 2 * (η x)^2 * |
| 1387 | (diffQuot k h |
| 1388 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2) = |
| 1389 | fun x : E => 2 * ((η x)^2 * |
| 1390 | (diffQuot k h |
| 1391 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2) from by |
| 1392 | funext x; ring] |
| 1393 | rw [integral_const_mul] |
| 1394 | rw [h_t2_eq] |
| 1395 | |
| 1396 | |
| 1397 | theorem c_term_bound |
| 1398 | {Ω : Set E} (B : SmoothEllipticBilinearForm d Ω) |
| 1399 | {η : E → ℝ} (hη : ContDiff ℝ (⊤ : ℕ∞) η) (hη_supp : HasCompactSupport η) |
| 1400 | (hη_range : Set.range η ⊆ Set.Icc (0 : ℝ) 1) |
| 1401 | {N : ℝ} (h_fderiv_eta : ∀ x : E, ‖fderiv ℝ η x‖ ≤ N) |
| 1402 | {Ω' : Set E} (hΩ' : IsOpen Ω') (hΩ'_closure : closure Ω' ⊆ Ω) |
| 1403 | (hΩ'_compact : IsCompact (closure Ω')) |
| 1404 | {R₀ : ℝ} |
| 1405 | (hh_supp_in_Ω' : ∀ {h : ℝ}, |h| ≤ R₀ → |
| 1406 | Metric.cthickening |h| (tsupport η) ⊆ Ω') |
| 1407 | (k : Fin d) (ε : ℝ) (hε : 0 < ε) : |
| 1408 | ∃ C : ℝ, 0 ≤ C ∧ ∀ {u : E → ℝ}, ContDiff ℝ (⊤ : ℕ∞) u → |
| 1409 | ∀ {h : ℝ}, h ≠ 0 → |h| ≤ R₀ → |
| 1410 | |∫ x in Ω, B.c x * u x * |
| 1411 | Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 1412 | k h η u x| ≤ |
| 1413 | ε * ∫ x, (η x)^2 * |
| 1414 | ∑ i : Fin d, Poincare.Analysis.Sobolev.diffQuot k h |
| 1415 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x ^ 2 |
| 1416 | ∂(volume : Measure E) + |
| 1417 | C * (∫ x in Ω', |
| 1418 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 1419 | ∂(volume : Measure E) + |
| 1420 | ∫ x in Ω', (u x)^2 ∂(volume : Measure E)) := by |
| 1421 | classical |
| 1422 | obtain ⟨Mc, hMc_nn, h_Mc⟩ := |
| 1423 | SmoothEllipticBilinearForm.bounded_c_on_compact (d := d) B hΩ'_compact |
| 1424 | set C : ℝ := max (4 * ε * N^2) (Mc^2 / (2 * ε)) with hC_def |
| 1425 | have hC_nn : 0 ≤ C := by |
| 1426 | rw [hC_def] |
| 1427 | refine le_max_of_le_left ?_ |
| 1428 | refine mul_nonneg ?_ (sq_nonneg _) |
| 1429 | exact mul_nonneg (by linarith) hε.le |
| 1430 | refine ⟨C, hC_nn, ?_⟩ |
| 1431 | intro u hu h hh hh_le |
| 1432 | have h_thick_in_Ω' : Metric.cthickening |h| (tsupport η) ⊆ Ω' := hh_supp_in_Ω' hh_le |
| 1433 | set v_test : E → ℝ := |
| 1434 | Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 1435 | k h η u with hv_test_def |
| 1436 | have h_v_test_supp : tsupport v_test ⊆ Ω' := v_test_supported_in_Ω' hh_supp_in_Ω' k hh_le |
| 1437 | have h_v_test_in_Ω : tsupport v_test ⊆ Ω := fun x hx => |
| 1438 | hΩ'_closure (subset_closure (h_v_test_supp hx)) |
| 1439 | have h_v_test_cont : Continuous v_test := continuous_v_test (d := d) hu hη k hh |
| 1440 | have h_v_test_supp_cmp : HasCompactSupport v_test := |
| 1441 | hasCompactSupport_v_test (d := d) hη_supp k h |
| 1442 | have h_c_cont : Continuous B.c := B.continuous_c |
| 1443 | have h_u_cont : Continuous u := hu.continuous |
| 1444 | have h_v_test_zero_outside : ∀ x ∉ Ω, v_test x = 0 := fun x hx => |
| 1445 | image_eq_zero_of_notMem_tsupport (fun hy => hx (h_v_test_in_Ω hy)) |
| 1446 | have h_int_E : ∫ x in Ω, B.c x * u x * v_test x ∂(volume : Measure E) = |
| 1447 | ∫ x, B.c x * u x * v_test x ∂(volume : Measure E) := by |
| 1448 | have h_eq_zero : ∀ x, x ∉ Ω → B.c x * u x * v_test x = 0 := by |
| 1449 | intro x hx |
| 1450 | rw [h_v_test_zero_outside x hx]; ring |
| 1451 | exact setIntegral_eq_integral_of_forall_compl_eq_zero h_eq_zero |
| 1452 | rw [h_int_E] |
| 1453 | have h_v_test_zero_outside_Ω' : ∀ x ∉ Ω', v_test x = 0 := fun x hx => |
| 1454 | image_eq_zero_of_notMem_tsupport (fun hy => hx (h_v_test_supp hy)) |
| 1455 | have h_int_Ω' : ∫ x, B.c x * u x * v_test x ∂(volume : Measure E) = |
| 1456 | ∫ x in Ω', B.c x * u x * v_test x ∂(volume : Measure E) := by |
| 1457 | have h_eq_zero : ∀ x, x ∉ Ω' → B.c x * u x * v_test x = 0 := by |
| 1458 | intro x hx |
| 1459 | rw [h_v_test_zero_outside_Ω' x hx]; ring |
| 1460 | exact (setIntegral_eq_integral_of_forall_compl_eq_zero h_eq_zero).symm |
| 1461 | rw [h_int_Ω'] |
| 1462 | have h_pointwise_cu_v : ∀ x : E, |
| 1463 | |B.c x * u x * v_test x| ≤ (ε/2) * (v_test x)^2 + (1/(2*ε)) * (B.c x * u x)^2 := by |
| 1464 | intro x |
| 1465 | have h_y := two_abs_mul_le_eps_sq_add (v_test x) (B.c x * u x) ε hε |
| 1466 | have h_abs_eq : |B.c x * u x * v_test x| = |v_test x| * |B.c x * u x| := by |
| 1467 | rw [show (B.c x * u x * v_test x) = v_test x * (B.c x * u x) from by ring, |
| 1468 | abs_mul] |
| 1469 | rw [h_abs_eq] |
| 1470 | have h_ε_pos_inv : (1 : ℝ) / ε > 0 := one_div_pos.mpr hε |
| 1471 | have h_div_eq : (1 / ε) * (B.c x * u x)^2 = 2 * ((1 / (2 * ε)) * (B.c x * u x)^2) := by |
| 1472 | have hε_ne : ε ≠ 0 := ne_of_gt hε |
| 1473 | field_simp |
| 1474 | have h_ε_eq : ε * (v_test x)^2 = 2 * ((ε / 2) * (v_test x)^2) := by ring |
| 1475 | linarith [h_y, h_div_eq, h_ε_eq] |
| 1476 | have h_v_test_sq_int_Ω' : IntegrableOn (fun x : E => (v_test x)^2) Ω' volume := by |
| 1477 | have h_square_supp : HasCompactSupport (fun x : E => (v_test x) ^ 2) := by |
| 1478 | exact HasCompactSupport.intro' h_v_test_supp_cmp (isClosed_tsupport v_test) |
| 1479 | (fun x hx => by |
| 1480 | rw [image_eq_zero_of_notMem_tsupport hx] |
| 1481 | norm_num) |
| 1482 | have h_int : Integrable (fun x : E => (v_test x)^2) volume := |
| 1483 | (h_v_test_cont.pow 2).integrable_of_hasCompactSupport |
| 1484 | h_square_supp |
| 1485 | exact h_int.integrableOn |
| 1486 | have h_cu_sq_int_Ω' : IntegrableOn (fun x : E => (B.c x * u x)^2) Ω' volume := by |
| 1487 | have h_cont : Continuous (fun x : E => (B.c x * u x)^2) := |
| 1488 | (h_c_cont.mul h_u_cont).pow 2 |
| 1489 | have h_cont_on : ContinuousOn (fun x : E => (B.c x * u x)^2) (closure Ω') := |
| 1490 | h_cont.continuousOn |
| 1491 | exact (ContinuousOn.integrableOn_compact hΩ'_compact h_cont_on).mono_set subset_closure |
| 1492 | have h_cu_v_int_Ω' : IntegrableOn (fun x : E => B.c x * u x * v_test x) Ω' volume := by |
| 1493 | have h_cont : Continuous (fun x : E => B.c x * u x * v_test x) := |
| 1494 | (h_c_cont.mul h_u_cont).mul h_v_test_cont |
| 1495 | have h_supp : HasCompactSupport (fun x : E => B.c x * u x * v_test x) := |
| 1496 | h_v_test_supp_cmp.mul_left |
| 1497 | exact (h_cont.integrable_of_hasCompactSupport h_supp).integrableOn |
| 1498 | have h_rhs_int_Ω' : IntegrableOn (fun x : E => |
| 1499 | (ε/2) * (v_test x)^2 + (1/(2*ε)) * (B.c x * u x)^2) Ω' volume := by |
| 1500 | refine (h_v_test_sq_int_Ω'.const_mul (ε/2)).add (h_cu_sq_int_Ω'.const_mul (1/(2*ε))) |
| 1501 | have h_step1 : |∫ x in Ω', B.c x * u x * v_test x ∂(volume : Measure E)| ≤ |
| 1502 | ∫ x in Ω', |B.c x * u x * v_test x| ∂(volume : Measure E) := |
| 1503 | abs_integral_le_integral_abs (μ := (volume : Measure E).restrict Ω') |
| 1504 | have h_step2 : ∫ x in Ω', |B.c x * u x * v_test x| ∂(volume : Measure E) ≤ |
| 1505 | ∫ x in Ω', |
| 1506 | ((ε/2) * (v_test x)^2 + (1/(2*ε)) * (B.c x * u x)^2) |
| 1507 | ∂(volume : Measure E) := by |
| 1508 | refine integral_mono_ae h_cu_v_int_Ω'.abs h_rhs_int_Ω' ?_ |
| 1509 | refine Filter.Eventually.of_forall ?_ |
| 1510 | intro x; exact h_pointwise_cu_v x |
| 1511 | refine (h_step1.trans h_step2).trans ?_ |
| 1512 | rw [integral_add (h_v_test_sq_int_Ω'.const_mul (ε/2)) (h_cu_sq_int_Ω'.const_mul (1/(2*ε)))] |
| 1513 | rw [show (fun x : E => (ε/2) * (v_test x)^2) = |
| 1514 | (fun x : E => (ε/2) * (v_test x)^2) from rfl] |
| 1515 | rw [integral_const_mul, integral_const_mul] |
| 1516 | have h_v_test_sq_Ω'_le_E : |
| 1517 | ∫ x in Ω', (v_test x)^2 ∂(volume : Measure E) ≤ |
| 1518 | ∫ x, (v_test x)^2 ∂(volume : Measure E) := by |
| 1519 | have h_square_supp : HasCompactSupport (fun x : E => (v_test x) ^ 2) := by |
| 1520 | exact HasCompactSupport.intro' h_v_test_supp_cmp (isClosed_tsupport v_test) |
| 1521 | (fun x hx => by |
| 1522 | rw [image_eq_zero_of_notMem_tsupport hx] |
| 1523 | norm_num) |
| 1524 | have h_int_E : Integrable (fun x : E => (v_test x)^2) volume := |
| 1525 | (h_v_test_cont.pow 2).integrable_of_hasCompactSupport |
| 1526 | h_square_supp |
| 1527 | have h_v_test_sq_eq : ∫ x, (v_test x)^2 ∂(volume : Measure E) = |
| 1528 | ∫ x in Ω', (v_test x)^2 ∂(volume : Measure E) := by |
| 1529 | have h_eq_zero : ∀ x, x ∉ Ω' → (v_test x)^2 = 0 := by |
| 1530 | intro x hx |
| 1531 | rw [h_v_test_zero_outside_Ω' x hx]; ring |
| 1532 | exact (setIntegral_eq_integral_of_forall_compl_eq_zero h_eq_zero).symm |
| 1533 | rw [h_v_test_sq_eq] |
| 1534 | have h_v_test_bound := nirenbergTestFunction_sq_integral_le (d := d) hu hη hη_supp hη_range |
| 1535 | h_fderiv_eta k hh |
| 1536 | have h_cu_sq_bound : ∀ x ∈ Ω', (B.c x * u x)^2 ≤ Mc^2 * (u x)^2 := by |
| 1537 | intro x hx |
| 1538 | have h_x_in_clΩ' : x ∈ closure Ω' := subset_closure hx |
| 1539 | have h_c_le : |B.c x| ≤ Mc := h_Mc x h_x_in_clΩ' |
| 1540 | have h_c_sq_le : (B.c x)^2 ≤ Mc^2 := by |
| 1541 | rw [← sq_abs (B.c x)]; exact pow_le_pow_left₀ (abs_nonneg _) h_c_le 2 |
| 1542 | have h_u_sq_nn : 0 ≤ (u x)^2 := sq_nonneg _ |
| 1543 | calc (B.c x * u x)^2 = (B.c x)^2 * (u x)^2 := by ring |
| 1544 | _ ≤ Mc^2 * (u x)^2 := mul_le_mul_of_nonneg_right h_c_sq_le h_u_sq_nn |
| 1545 | have h_cu_sq_int_Ω'_le : ∫ x in Ω', (B.c x * u x)^2 ∂(volume : Measure E) ≤ |
| 1546 | Mc^2 * ∫ x in Ω', (u x)^2 ∂(volume : Measure E) := by |
| 1547 | have h_u_sq_int_Ω' : IntegrableOn (fun x : E => (u x)^2) Ω' volume := by |
| 1548 | have h_cont : Continuous (fun x : E => (u x)^2) := h_u_cont.pow 2 |
| 1549 | have h_cont_on : ContinuousOn (fun x : E => (u x)^2) (closure Ω') := h_cont.continuousOn |
| 1550 | exact (ContinuousOn.integrableOn_compact hΩ'_compact h_cont_on).mono_set subset_closure |
| 1551 | have h_const_int : IntegrableOn (fun x : E => Mc^2 * (u x)^2) Ω' volume := |
| 1552 | h_u_sq_int_Ω'.const_mul (Mc^2) |
| 1553 | have h_step : ∫ x in Ω', (B.c x * u x)^2 ∂(volume : Measure E) ≤ |
| 1554 | ∫ x in Ω', Mc^2 * (u x)^2 ∂(volume : Measure E) := |
| 1555 | setIntegral_mono_on h_cu_sq_int_Ω' h_const_int hΩ'.measurableSet h_cu_sq_bound |
| 1556 | rw [integral_const_mul] at h_step |
| 1557 | exact h_step |
| 1558 | have h_v_sq_le_8N_2I : |
| 1559 | ∫ x in Ω', (v_test x)^2 ∂(volume : Measure E) ≤ |
| 1560 | 8 * N^2 * |
| 1561 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) + |
| 1562 | 2 * ∫ x, (η x)^2 * |
| 1563 | (diffQuot k h |
| 1564 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1565 | ∂(volume : Measure E) := |
| 1566 | h_v_test_sq_Ω'_le_E.trans h_v_test_bound |
| 1567 | have h_diff_bound : |
| 1568 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) ≤ |
| 1569 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1570 | ∂(volume : Measure E) := |
| 1571 | integral_diffQuot_sq_on_tsupport_le_gradL2sqOn (d := d) hu k hh η hΩ' |
| 1572 | hΩ'_compact h_thick_in_Ω' |
| 1573 | have h_partial_le_sum : ∀ x : E, |
| 1574 | (η x)^2 * |
| 1575 | (diffQuot k h |
| 1576 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 ≤ |
| 1577 | (η x)^2 * |
| 1578 | ∑ i : Fin d, (diffQuot k h |
| 1579 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 := by |
| 1580 | intro x |
| 1581 | refine mul_le_mul_of_nonneg_left ?_ (sq_nonneg _) |
| 1582 | exact Finset.single_le_sum (f := fun i => (diffQuot k h |
| 1583 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2) |
| 1584 | (fun i _ => sq_nonneg _) (Finset.mem_univ k) |
| 1585 | have h_eta_sq_partial_int : Integrable (fun x : E => |
| 1586 | (η x)^2 * |
| 1587 | (diffQuot k h |
| 1588 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2) volume := |
| 1589 | integrable_eta_sq_diffQuot_partial_sq (d := d) hu hη hη_supp k k hh |
| 1590 | have h_eta_sq_sum_int : Integrable (fun x : E => |
| 1591 | (η x)^2 * |
| 1592 | ∑ i : Fin d, (diffQuot k h |
| 1593 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2) volume := |
| 1594 | integrable_eta_sq_diffQuot_sum (d := d) hu hη hη_supp k hh |
| 1595 | have h_partial_int_le : |
| 1596 | ∫ x, (η x)^2 * |
| 1597 | (diffQuot k h |
| 1598 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1599 | ∂(volume : Measure E) ≤ |
| 1600 | ∫ x, (η x)^2 * |
| 1601 | ∑ i : Fin d, (diffQuot k h |
| 1602 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 1603 | ∂(volume : Measure E) := |
| 1604 | integral_mono h_eta_sq_partial_int h_eta_sq_sum_int h_partial_le_sum |
| 1605 | have h_gradL2_nn : 0 ≤ ∫ x in Ω', |
| 1606 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1607 | ∂(volume : Measure E) := |
| 1608 | integral_nonneg (fun x => Finset.sum_nonneg (fun i _ => sq_nonneg _)) |
| 1609 | have h_uL2_nn : 0 ≤ ∫ x in Ω', (u x)^2 ∂(volume : Measure E) := |
| 1610 | integral_nonneg (fun x => sq_nonneg _) |
| 1611 | have h_v_full_bound : |
| 1612 | (ε/2) * ∫ x in Ω', (v_test x)^2 ∂(volume : Measure E) ≤ |
| 1613 | 4 * ε * N^2 * |
| 1614 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1615 | ∂(volume : Measure E) + |
| 1616 | ε * ∫ x, (η x)^2 * |
| 1617 | ∑ i : Fin d, (diffQuot k h |
| 1618 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 1619 | ∂(volume : Measure E) := by |
| 1620 | have h_step_a := mul_le_mul_of_nonneg_left h_v_sq_le_8N_2I (by linarith : 0 ≤ ε/2) |
| 1621 | have h_step_b : (ε/2) * (8 * N^2 * |
| 1622 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) + |
| 1623 | 2 * ∫ x, (η x)^2 * |
| 1624 | (diffQuot k h |
| 1625 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1626 | ∂(volume : Measure E)) ≤ |
| 1627 | 4 * ε * N^2 * |
| 1628 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1629 | ∂(volume : Measure E) + |
| 1630 | ε * ∫ x, (η x)^2 * |
| 1631 | ∑ i : Fin d, (diffQuot k h |
| 1632 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 1633 | ∂(volume : Measure E) := by |
| 1634 | have h1 : (ε/2) * (8 * N^2 * |
| 1635 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E)) = |
| 1636 | 4 * ε * N^2 * |
| 1637 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) := by ring |
| 1638 | have h2 : (ε/2) * (2 * ∫ x, (η x)^2 * |
| 1639 | (diffQuot k h |
| 1640 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1641 | ∂(volume : Measure E)) = |
| 1642 | ε * ∫ x, (η x)^2 * |
| 1643 | (diffQuot k h |
| 1644 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1645 | ∂(volume : Measure E) := by ring |
| 1646 | have h_diff_pos : 0 ≤ 4 * ε * N^2 := by |
| 1647 | refine mul_nonneg ?_ (sq_nonneg _) |
| 1648 | exact mul_nonneg (by linarith) hε.le |
| 1649 | have h_step_c : 4 * ε * N^2 * |
| 1650 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) ≤ |
| 1651 | 4 * ε * N^2 * |
| 1652 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1653 | ∂(volume : Measure E) := |
| 1654 | mul_le_mul_of_nonneg_left h_diff_bound h_diff_pos |
| 1655 | have h_step_d : ε * ∫ x, (η x)^2 * |
| 1656 | (diffQuot k h |
| 1657 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1658 | ∂(volume : Measure E) ≤ |
| 1659 | ε * ∫ x, (η x)^2 * |
| 1660 | ∑ i : Fin d, (diffQuot k h |
| 1661 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 1662 | ∂(volume : Measure E) := |
| 1663 | mul_le_mul_of_nonneg_left h_partial_int_le hε.le |
| 1664 | linarith [h1, h2] |
| 1665 | linarith |
| 1666 | have h_cu_full_bound : |
| 1667 | (1/(2*ε)) * ∫ x in Ω', (B.c x * u x)^2 ∂(volume : Measure E) ≤ |
| 1668 | (Mc^2 / (2 * ε)) * ∫ x in Ω', (u x)^2 ∂(volume : Measure E) := by |
| 1669 | have h_div_pos : 0 < 1/(2*ε) := by |
| 1670 | refine one_div_pos.mpr ?_; linarith |
| 1671 | have h_step := mul_le_mul_of_nonneg_left h_cu_sq_int_Ω'_le h_div_pos.le |
| 1672 | have h_eq : (1 / (2 * ε)) * (Mc ^ 2 * ∫ x in Ω', u x ^ 2 ∂(volume : Measure E)) = |
| 1673 | Mc^2 / (2*ε) * ∫ x in Ω', (u x)^2 ∂(volume : Measure E) := by |
| 1674 | ring |
| 1675 | linarith [h_step, h_eq] |
| 1676 | have h_C_grad_le : 4 * ε * N^2 ≤ C := le_max_left _ _ |
| 1677 | have h_C_uL2_le : Mc^2 / (2*ε) ≤ C := le_max_right _ _ |
| 1678 | have h_combine : |
| 1679 | 4 * ε * N^2 * |
| 1680 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1681 | ∂(volume : Measure E) + |
| 1682 | (Mc^2 / (2 * ε)) * ∫ x in Ω', (u x)^2 ∂(volume : Measure E) ≤ |
| 1683 | C * (∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1684 | ∂(volume : Measure E) + |
| 1685 | ∫ x in Ω', (u x)^2 ∂(volume : Measure E)) := by |
| 1686 | have h_left_le := mul_le_mul_of_nonneg_right h_C_grad_le h_gradL2_nn |
| 1687 | have h_right_le := mul_le_mul_of_nonneg_right h_C_uL2_le h_uL2_nn |
| 1688 | have h_C_dist : C * (∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1689 | ∂(volume : Measure E) + |
| 1690 | ∫ x in Ω', (u x)^2 ∂(volume : Measure E)) = |
| 1691 | C * (∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1692 | ∂(volume : Measure E)) + |
| 1693 | C * ∫ x in Ω', (u x)^2 ∂(volume : Measure E) := by ring |
| 1694 | linarith |
| 1695 | linarith |
| 1696 | |
| 1697 | |
| 1698 | omit [NeZero d] in |
| 1699 | theorem f_term_bound |
| 1700 | {Ω : Set E} |
| 1701 | {η : E → ℝ} (hη : ContDiff ℝ (⊤ : ℕ∞) η) (hη_supp : HasCompactSupport η) |
| 1702 | (hη_range : Set.range η ⊆ Set.Icc (0 : ℝ) 1) |
| 1703 | {N : ℝ} (h_fderiv_eta : ∀ x : E, ‖fderiv ℝ η x‖ ≤ N) |
| 1704 | {Ω' : Set E} (hΩ' : IsOpen Ω') (hΩ'_closure : closure Ω' ⊆ Ω) |
| 1705 | (hΩ'_compact : IsCompact (closure Ω')) |
| 1706 | {R₀ : ℝ} |
| 1707 | (hh_supp_in_Ω' : ∀ {h : ℝ}, |h| ≤ R₀ → |
| 1708 | Metric.cthickening |h| (tsupport η) ⊆ Ω') |
| 1709 | (k : Fin d) (ε : ℝ) (hε : 0 < ε) : |
| 1710 | ∃ C : ℝ, 0 ≤ C ∧ |
| 1711 | ∀ {f : E → ℝ}, (∀ {Ω' : Set E}, IsCompact (closure Ω') → |
| 1712 | MemLp f 2 (volume.restrict Ω')) → |
| 1713 | ∀ {u : E → ℝ}, ContDiff ℝ (⊤ : ℕ∞) u → |
| 1714 | ∀ {h : ℝ}, h ≠ 0 → |h| ≤ R₀ → |
| 1715 | |∫ x in Ω, f x * |
| 1716 | Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 1717 | k h η u x| ≤ |
| 1718 | ε * ∫ x, (η x)^2 * |
| 1719 | ∑ i : Fin d, Poincare.Analysis.Sobolev.diffQuot k h |
| 1720 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x ^ 2 |
| 1721 | ∂(volume : Measure E) + |
| 1722 | C * (∫ x in Ω', |
| 1723 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 1724 | ∂(volume : Measure E) + |
| 1725 | ∫ x in Ω', (f x)^2 ∂(volume : Measure E)) := by |
| 1726 | classical |
| 1727 | set C : ℝ := max (4 * ε * N^2) (1 / (2 * ε)) with hC_def |
| 1728 | have hC_nn : 0 ≤ C := by |
| 1729 | rw [hC_def] |
| 1730 | refine le_max_of_le_left ?_ |
| 1731 | refine mul_nonneg ?_ (sq_nonneg _) |
| 1732 | exact mul_nonneg (by linarith) hε.le |
| 1733 | refine ⟨C, hC_nn, ?_⟩ |
| 1734 | intro f hf_l2_loc u hu h hh hh_le |
| 1735 | have h_thick_in_Ω' : Metric.cthickening |h| (tsupport η) ⊆ Ω' := hh_supp_in_Ω' hh_le |
| 1736 | set v_test : E → ℝ := |
| 1737 | Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 1738 | k h η u with hv_test_def |
| 1739 | have h_v_test_supp : tsupport v_test ⊆ Ω' := v_test_supported_in_Ω' hh_supp_in_Ω' k hh_le |
| 1740 | have h_v_test_cont : Continuous v_test := continuous_v_test (d := d) hu hη k hh |
| 1741 | have h_v_test_supp_cmp : HasCompactSupport v_test := |
| 1742 | hasCompactSupport_v_test (d := d) hη_supp k h |
| 1743 | have h_v_test_zero_outside : ∀ x ∉ Ω, v_test x = 0 := fun x hx => |
| 1744 | image_eq_zero_of_notMem_tsupport |
| 1745 | (fun hy => hx (hΩ'_closure (subset_closure (h_v_test_supp hy)))) |
| 1746 | have h_v_test_zero_outside_Ω' : ∀ x ∉ Ω', v_test x = 0 := fun x hx => |
| 1747 | image_eq_zero_of_notMem_tsupport (fun hy => hx (h_v_test_supp hy)) |
| 1748 | have hf_memLp : MemLp f 2 (volume.restrict Ω') := hf_l2_loc hΩ'_compact |
| 1749 | have hf_sq_int_Ω' : IntegrableOn (fun x : E => (f x)^2) Ω' volume := hf_memLp.integrable_sq |
| 1750 | have h_int_E : ∫ x in Ω, f x * v_test x ∂(volume : Measure E) = |
| 1751 | ∫ x in Ω', f x * v_test x ∂(volume : Measure E) := by |
| 1752 | have h_eq_zero_Ω : ∀ x, x ∉ Ω → f x * v_test x = 0 := by |
| 1753 | intro x hx; rw [h_v_test_zero_outside x hx]; ring |
| 1754 | have h_eq_zero_Ω' : ∀ x, x ∉ Ω' → f x * v_test x = 0 := by |
| 1755 | intro x hx; rw [h_v_test_zero_outside_Ω' x hx]; ring |
| 1756 | rw [setIntegral_eq_integral_of_forall_compl_eq_zero h_eq_zero_Ω, |
| 1757 | ← setIntegral_eq_integral_of_forall_compl_eq_zero h_eq_zero_Ω'] |
| 1758 | rw [h_int_E] |
| 1759 | have h_pointwise : ∀ x : E, |
| 1760 | |f x * v_test x| ≤ (ε/2) * (v_test x)^2 + (1/(2*ε)) * (f x)^2 := by |
| 1761 | intro x |
| 1762 | have h_y := two_abs_mul_le_eps_sq_add (v_test x) (f x) ε hε |
| 1763 | have h_abs_eq : |f x * v_test x| = |v_test x| * |f x| := by |
| 1764 | rw [show (f x * v_test x) = v_test x * f x from by ring, abs_mul] |
| 1765 | rw [h_abs_eq] |
| 1766 | have h_div_eq : (1 / ε) * (f x)^2 = 2 * ((1 / (2 * ε)) * (f x)^2) := by |
| 1767 | have hε_ne : ε ≠ 0 := ne_of_gt hε |
| 1768 | field_simp |
| 1769 | have h_ε_eq : ε * (v_test x)^2 = 2 * ((ε / 2) * (v_test x)^2) := by ring |
| 1770 | linarith [h_y, h_div_eq, h_ε_eq] |
| 1771 | have h_v_test_sq_int_Ω' : IntegrableOn (fun x : E => (v_test x)^2) Ω' volume := by |
| 1772 | have h_square_supp : HasCompactSupport (fun x : E => (v_test x) ^ 2) := by |
| 1773 | exact HasCompactSupport.intro' h_v_test_supp_cmp (isClosed_tsupport v_test) |
| 1774 | (fun x hx => by |
| 1775 | rw [image_eq_zero_of_notMem_tsupport hx] |
| 1776 | norm_num) |
| 1777 | have h_int : Integrable (fun x : E => (v_test x)^2) volume := |
| 1778 | (h_v_test_cont.pow 2).integrable_of_hasCompactSupport |
| 1779 | h_square_supp |
| 1780 | exact h_int.integrableOn |
| 1781 | have h_f_v_int_Ω' : IntegrableOn (fun x : E => f x * v_test x) Ω' volume := by |
| 1782 | have h_pointwise_abs : ∀ x : E, |
| 1783 | |f x * v_test x| ≤ (1/2) * ((f x)^2 + (v_test x)^2) := by |
| 1784 | intro x |
| 1785 | have h_y := two_abs_mul_le_eps_sq_add (f x) (v_test x) 1 zero_lt_one |
| 1786 | simp only [one_mul, div_one] at h_y |
| 1787 | have h_abs : |f x * v_test x| = |f x| * |v_test x| := abs_mul _ _ |
| 1788 | linarith |
| 1789 | have h_rhs_int : IntegrableOn (fun x : E => (1/2) * ((f x)^2 + (v_test x)^2)) Ω' volume := |
| 1790 | (hf_sq_int_Ω'.add h_v_test_sq_int_Ω').const_mul (1/2) |
| 1791 | have h_f_AEStrong : AEStronglyMeasurable f (volume.restrict Ω') := |
| 1792 | hf_memLp.aestronglyMeasurable |
| 1793 | have h_v_AEStrong : AEStronglyMeasurable v_test (volume.restrict Ω') := |
| 1794 | h_v_test_cont.aestronglyMeasurable |
| 1795 | have h_prod_AEStrong : AEStronglyMeasurable (fun x : E => f x * v_test x) |
| 1796 | (volume.restrict Ω') := h_f_AEStrong.mul h_v_AEStrong |
| 1797 | refine ⟨h_prod_AEStrong, ?_⟩ |
| 1798 | refine HasFiniteIntegral.mono' h_rhs_int.hasFiniteIntegral ?_ |
| 1799 | refine Filter.Eventually.of_forall ?_ |
| 1800 | intro x |
| 1801 | rw [Real.norm_eq_abs] |
| 1802 | have h_pt := h_pointwise_abs x |
| 1803 | have h_rhs_nn : 0 ≤ (1 : ℝ) / 2 * ((f x)^2 + (v_test x)^2) := |
| 1804 | mul_nonneg (by norm_num) (add_nonneg (sq_nonneg _) (sq_nonneg _)) |
| 1805 | exact h_pt |
| 1806 | have h_rhs_int_Ω' : IntegrableOn (fun x : E => |
| 1807 | (ε/2) * (v_test x)^2 + (1/(2*ε)) * (f x)^2) Ω' volume := by |
| 1808 | refine (h_v_test_sq_int_Ω'.const_mul (ε/2)).add (hf_sq_int_Ω'.const_mul (1/(2*ε))) |
| 1809 | have h_step1 : |∫ x in Ω', f x * v_test x ∂(volume : Measure E)| ≤ |
| 1810 | ∫ x in Ω', |f x * v_test x| ∂(volume : Measure E) := |
| 1811 | abs_integral_le_integral_abs (μ := (volume : Measure E).restrict Ω') |
| 1812 | have h_step2 : ∫ x in Ω', |f x * v_test x| ∂(volume : Measure E) ≤ |
| 1813 | ∫ x in Ω', ((ε/2) * (v_test x)^2 + (1/(2*ε)) * (f x)^2) ∂(volume : Measure E) := by |
| 1814 | refine integral_mono_ae h_f_v_int_Ω'.abs h_rhs_int_Ω' ?_ |
| 1815 | refine Filter.Eventually.of_forall ?_ |
| 1816 | intro x; exact h_pointwise x |
| 1817 | refine (h_step1.trans h_step2).trans ?_ |
| 1818 | rw [integral_add (h_v_test_sq_int_Ω'.const_mul (ε/2)) (hf_sq_int_Ω'.const_mul (1/(2*ε)))] |
| 1819 | rw [integral_const_mul, integral_const_mul] |
| 1820 | have h_v_test_sq_Ω'_le_E : |
| 1821 | ∫ x in Ω', (v_test x)^2 ∂(volume : Measure E) ≤ |
| 1822 | ∫ x, (v_test x)^2 ∂(volume : Measure E) := by |
| 1823 | have h_v_test_sq_eq : ∫ x, (v_test x)^2 ∂(volume : Measure E) = |
| 1824 | ∫ x in Ω', (v_test x)^2 ∂(volume : Measure E) := by |
| 1825 | have h_eq_zero : ∀ x, x ∉ Ω' → (v_test x)^2 = 0 := by |
| 1826 | intro x hx |
| 1827 | rw [h_v_test_zero_outside_Ω' x hx]; ring |
| 1828 | exact (setIntegral_eq_integral_of_forall_compl_eq_zero h_eq_zero).symm |
| 1829 | rw [h_v_test_sq_eq] |
| 1830 | have h_v_test_bound := nirenbergTestFunction_sq_integral_le (d := d) hu hη hη_supp hη_range |
| 1831 | h_fderiv_eta k hh |
| 1832 | have h_v_sq_le_8N_2I : |
| 1833 | ∫ x in Ω', (v_test x)^2 ∂(volume : Measure E) ≤ |
| 1834 | 8 * N^2 * |
| 1835 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) + |
| 1836 | 2 * ∫ x, (η x)^2 * |
| 1837 | (diffQuot k h |
| 1838 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1839 | ∂(volume : Measure E) := |
| 1840 | h_v_test_sq_Ω'_le_E.trans h_v_test_bound |
| 1841 | have h_diff_bound : |
| 1842 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) ≤ |
| 1843 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1844 | ∂(volume : Measure E) := |
| 1845 | integral_diffQuot_sq_on_tsupport_le_gradL2sqOn (d := d) hu k hh η hΩ' |
| 1846 | hΩ'_compact h_thick_in_Ω' |
| 1847 | have h_partial_le_sum : ∀ x : E, |
| 1848 | (η x)^2 * |
| 1849 | (diffQuot k h |
| 1850 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 ≤ |
| 1851 | (η x)^2 * |
| 1852 | ∑ i : Fin d, (diffQuot k h |
| 1853 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 := by |
| 1854 | intro x |
| 1855 | refine mul_le_mul_of_nonneg_left ?_ (sq_nonneg _) |
| 1856 | exact Finset.single_le_sum (f := fun i => (diffQuot k h |
| 1857 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2) |
| 1858 | (fun i _ => sq_nonneg _) (Finset.mem_univ k) |
| 1859 | have h_eta_sq_partial_int : Integrable (fun x : E => |
| 1860 | (η x)^2 * |
| 1861 | (diffQuot k h |
| 1862 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2) volume := |
| 1863 | integrable_eta_sq_diffQuot_partial_sq (d := d) hu hη hη_supp k k hh |
| 1864 | have h_eta_sq_sum_int : Integrable (fun x : E => |
| 1865 | (η x)^2 * |
| 1866 | ∑ i : Fin d, (diffQuot k h |
| 1867 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2) volume := |
| 1868 | integrable_eta_sq_diffQuot_sum (d := d) hu hη hη_supp k hh |
| 1869 | have h_partial_int_le : |
| 1870 | ∫ x, (η x)^2 * |
| 1871 | (diffQuot k h |
| 1872 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1873 | ∂(volume : Measure E) ≤ |
| 1874 | ∫ x, (η x)^2 * |
| 1875 | ∑ i : Fin d, (diffQuot k h |
| 1876 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 1877 | ∂(volume : Measure E) := |
| 1878 | integral_mono h_eta_sq_partial_int h_eta_sq_sum_int h_partial_le_sum |
| 1879 | have h_gradL2_nn : 0 ≤ ∫ x in Ω', |
| 1880 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1881 | ∂(volume : Measure E) := |
| 1882 | integral_nonneg (fun x => Finset.sum_nonneg (fun i _ => sq_nonneg _)) |
| 1883 | have h_fL2_nn : 0 ≤ ∫ x in Ω', (f x)^2 ∂(volume : Measure E) := |
| 1884 | integral_nonneg (fun x => sq_nonneg _) |
| 1885 | have h_v_full_bound : |
| 1886 | (ε/2) * ∫ x in Ω', (v_test x)^2 ∂(volume : Measure E) ≤ |
| 1887 | 4 * ε * N^2 * |
| 1888 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1889 | ∂(volume : Measure E) + |
| 1890 | ε * ∫ x, (η x)^2 * |
| 1891 | ∑ i : Fin d, (diffQuot k h |
| 1892 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 1893 | ∂(volume : Measure E) := by |
| 1894 | have h_step_a := mul_le_mul_of_nonneg_left h_v_sq_le_8N_2I (by linarith : 0 ≤ ε/2) |
| 1895 | have h_step_b : (ε/2) * (8 * N^2 * |
| 1896 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) + |
| 1897 | 2 * ∫ x, (η x)^2 * |
| 1898 | (diffQuot k h |
| 1899 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1900 | ∂(volume : Measure E)) ≤ |
| 1901 | 4 * ε * N^2 * |
| 1902 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1903 | ∂(volume : Measure E) + |
| 1904 | ε * ∫ x, (η x)^2 * |
| 1905 | ∑ i : Fin d, (diffQuot k h |
| 1906 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 1907 | ∂(volume : Measure E) := by |
| 1908 | have h1 : (ε/2) * (8 * N^2 * |
| 1909 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E)) = |
| 1910 | 4 * ε * N^2 * |
| 1911 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) := by ring |
| 1912 | have h2 : (ε/2) * (2 * ∫ x, (η x)^2 * |
| 1913 | (diffQuot k h |
| 1914 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1915 | ∂(volume : Measure E)) = |
| 1916 | ε * ∫ x, (η x)^2 * |
| 1917 | (diffQuot k h |
| 1918 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1919 | ∂(volume : Measure E) := by ring |
| 1920 | have h_diff_pos : 0 ≤ 4 * ε * N^2 := by |
| 1921 | refine mul_nonneg ?_ (sq_nonneg _) |
| 1922 | exact mul_nonneg (by linarith) hε.le |
| 1923 | have h_step_c : 4 * ε * N^2 * |
| 1924 | ∫ x in tsupport η, (diffQuot k h u x)^2 ∂(volume : Measure E) ≤ |
| 1925 | 4 * ε * N^2 * |
| 1926 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1927 | ∂(volume : Measure E) := |
| 1928 | mul_le_mul_of_nonneg_left h_diff_bound h_diff_pos |
| 1929 | have h_step_d : ε * ∫ x, (η x)^2 * |
| 1930 | (diffQuot k h |
| 1931 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single k 1)) x)^2 |
| 1932 | ∂(volume : Measure E) ≤ |
| 1933 | ε * ∫ x, (η x)^2 * |
| 1934 | ∑ i : Fin d, (diffQuot k h |
| 1935 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x)^2 |
| 1936 | ∂(volume : Measure E) := |
| 1937 | mul_le_mul_of_nonneg_left h_partial_int_le hε.le |
| 1938 | linarith [h1, h2] |
| 1939 | linarith |
| 1940 | have h_C_grad_le : 4 * ε * N^2 ≤ C := le_max_left _ _ |
| 1941 | have h_C_fL2_le : 1 / (2 * ε) ≤ C := le_max_right _ _ |
| 1942 | have h_combine : |
| 1943 | 4 * ε * N^2 * |
| 1944 | ∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1945 | ∂(volume : Measure E) + |
| 1946 | (1 / (2 * ε)) * ∫ x in Ω', (f x)^2 ∂(volume : Measure E) ≤ |
| 1947 | C * (∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1948 | ∂(volume : Measure E) + |
| 1949 | ∫ x in Ω', (f x)^2 ∂(volume : Measure E)) := by |
| 1950 | have h_left_le := mul_le_mul_of_nonneg_right h_C_grad_le h_gradL2_nn |
| 1951 | have h_right_le := mul_le_mul_of_nonneg_right h_C_fL2_le h_fL2_nn |
| 1952 | have h_C_dist : C * (∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1953 | ∂(volume : Measure E) + |
| 1954 | ∫ x in Ω', (f x)^2 ∂(volume : Measure E)) = |
| 1955 | C * (∫ x in Ω', ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1))^2 |
| 1956 | ∂(volume : Measure E)) + |
| 1957 | C * ∫ x in Ω', (f x)^2 ∂(volume : Measure E) := by ring |
| 1958 | linarith |
| 1959 | linarith |
| 1960 | |
| 1961 | theorem nirenberg_master_inequality_after_young |
| 1962 | {Ω : Set E} (B : SmoothEllipticBilinearForm d Ω) |
| 1963 | {η : E → ℝ} (hη : ContDiff ℝ (⊤ : ℕ∞) η) (hη_supp : HasCompactSupport η) |
| 1964 | (hη_range : Set.range η ⊆ Set.Icc (0 : ℝ) 1) |
| 1965 | {N : ℝ} (hN : 0 ≤ N) (h_fderiv_eta : ∀ x : E, ‖fderiv ℝ η x‖ ≤ N) |
| 1966 | {Ω' : Set E} (hΩ' : IsOpen Ω') (hΩ'_closure : closure Ω' ⊆ Ω) |
| 1967 | (hΩ'_compact : IsCompact (closure Ω')) |
| 1968 | {R₀ : ℝ} |
| 1969 | (hh_supp_in_Ω' : ∀ {h : ℝ}, |h| ≤ R₀ → |
| 1970 | Metric.cthickening |h| (tsupport η) ⊆ Ω') |
| 1971 | (k : Fin d) : |
| 1972 | ∃ C : ℝ, 0 ≤ C ∧ |
| 1973 | ∀ {u f : E → ℝ}, B.IsSmoothWeakSolution u f → |
| 1974 | (∀ {Ω' : Set E}, IsCompact (closure Ω') → |
| 1975 | MemLp f 2 (volume.restrict Ω')) → |
| 1976 | ∀ {h : ℝ}, h ≠ 0 → |h| ≤ R₀ → |
| 1977 | B.lam * ∫ x, (η x)^2 * |
| 1978 | ∑ i : Fin d, Poincare.Analysis.Sobolev.diffQuot k h |
| 1979 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x ^ 2 |
| 1980 | ∂(volume : Measure E) ≤ |
| 1981 | (B.lam / 2) * ∫ x, (η x)^2 * |
| 1982 | ∑ i : Fin d, Poincare.Analysis.Sobolev.diffQuot k h |
| 1983 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x ^ 2 |
| 1984 | ∂(volume : Measure E) + |
| 1985 | C * (∫ x in Ω', |
| 1986 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 1987 | ∂(volume : Measure E) + |
| 1988 | ∫ x in Ω', (u x)^2 ∂(volume : Measure E) + |
| 1989 | ∫ x in Ω', (f x)^2 ∂(volume : Measure E)) := by |
| 1990 | classical |
| 1991 | set ε_eff : ℝ := B.lam / 8 with hε_eff_def |
| 1992 | have hε_eff_pos : 0 < ε_eff := by |
| 1993 | rw [hε_eff_def]; exact div_pos B.hlam_pos (by norm_num) |
| 1994 | obtain ⟨C1, hC1_nn, hC1⟩ := translated_coeff_cutoff_deriv_diffQuot_cross_bound (d := d) B hη |
| 1995 | hη_supp hη_range h_fderiv_eta hΩ' hΩ'_compact hh_supp_in_Ω' k ε_eff hε_eff_pos |
| 1996 | obtain ⟨C2, hC2_nn, hC2⟩ := coeff_diffQuot_cutoff_sq_gradient_cross_bound (d := d) B hη hη_supp |
| 1997 | hη_range |
| 1998 | hΩ' hΩ'_compact hh_supp_in_Ω' k ε_eff hε_eff_pos |
| 1999 | obtain ⟨C3, hC3_nn, hC3⟩ := coeff_diffQuot_cutoff_deriv_cross_bound (d := d) B hη hη_supp hη_range |
| 2000 | hN |
| 2001 | h_fderiv_eta hΩ' hΩ'_compact hh_supp_in_Ω' k |
| 2002 | obtain ⟨Cc, hCc_nn, hCc⟩ := c_term_bound (d := d) B hη hη_supp hη_range |
| 2003 | h_fderiv_eta hΩ' hΩ'_closure hΩ'_compact hh_supp_in_Ω' k ε_eff hε_eff_pos |
| 2004 | obtain ⟨Cf, hCf_nn, hCf⟩ := f_term_bound (d := d) hη hη_supp hη_range |
| 2005 | h_fderiv_eta hΩ' hΩ'_closure hΩ'_compact hh_supp_in_Ω' k ε_eff hε_eff_pos |
| 2006 | set C : ℝ := max (C1 + C2 + C3 + Cc + Cf) (max Cc Cf) with hC_def |
| 2007 | have hC_nn : 0 ≤ C := by |
| 2008 | rw [hC_def] |
| 2009 | refine le_max_of_le_left ?_ |
| 2010 | refine add_nonneg (add_nonneg (add_nonneg (add_nonneg hC1_nn hC2_nn) hC3_nn) hCc_nn) hCf_nn |
| 2011 | refine ⟨C, hC_nn, ?_⟩ |
| 2012 | intro u f h_weak hf_l2_loc h hh hh_le |
| 2013 | have hu : ContDiff ℝ (⊤ : ℕ∞) u := h_weak.1 |
| 2014 | set I : ℝ := ∫ x, (η x)^2 * |
| 2015 | ∑ i : Fin d, Poincare.Analysis.Sobolev.diffQuot k h |
| 2016 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x ^ 2 |
| 2017 | ∂(volume : Measure E) with hI_def |
| 2018 | set G : ℝ := ∫ x in Ω', |
| 2019 | ∑ i : Fin d, ((fderiv ℝ u x) (EuclideanSpace.single i 1)) ^ 2 |
| 2020 | ∂(volume : Measure E) with hG_def |
| 2021 | set U : ℝ := ∫ x in Ω', (u x)^2 ∂(volume : Measure E) with hU_def |
| 2022 | set F : ℝ := ∫ x in Ω', (f x)^2 ∂(volume : Measure E) with hF_def |
| 2023 | have hI_nn : 0 ≤ I := absorbingIntegral_nonneg (d := d) k h η u |
| 2024 | have hG_nn : 0 ≤ G := integral_nonneg |
| 2025 | (fun x => Finset.sum_nonneg (fun i _ => sq_nonneg _)) |
| 2026 | have hU_nn : 0 ≤ U := integral_nonneg (fun x => sq_nonneg _) |
| 2027 | have hF_nn : 0 ≤ F := integral_nonneg (fun x => sq_nonneg _) |
| 2028 | have h_thick_in_Ω : Metric.cthickening |h| (tsupport η) ⊆ Ω := |
| 2029 | (hh_supp_in_Ω' hh_le).trans (subset_closure.trans hΩ'_closure) |
| 2030 | have h_master := nirenberg_master_inequality (d := d) B h_weak hη hη_supp k hh h_thick_in_Ω |
| 2031 | have hC1_h := hC1 hu hh hh_le |
| 2032 | have hC2_h := hC2 hu hh hh_le |
| 2033 | have hC3_h := hC3 hu hh hh_le |
| 2034 | have hCc_h := hCc hu hh hh_le |
| 2035 | have hCf_h := hCf hf_l2_loc hu hh hh_le |
| 2036 | have h_4ε_eq : 4 * ε_eff = B.lam / 2 := by |
| 2037 | rw [hε_eff_def]; ring |
| 2038 | have h_combine : B.lam * I ≤ |
| 2039 | 4 * ε_eff * I + (C1 + C2 + C3 + Cc + Cf) * G + Cc * U + Cf * F := by |
| 2040 | have h_sum_bound : |
| 2041 | |∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 2042 | Poincare.Analysis.Sobolev.translate k h |
| 2043 | (fun y : E => B.a y i j) x * (η x) * |
| 2044 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 2045 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2046 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 2047 | Poincare.Analysis.Sobolev.diffQuot k h u x |
| 2048 | ∂(volume : Measure E)| + |
| 2049 | |∑ i : Fin d, ∑ j : Fin d, ∫ x, |
| 2050 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2051 | (fun y : E => B.a y i j) x * (η x)^2 * |
| 2052 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 2053 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2054 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x |
| 2055 | ∂(volume : Measure E)| + |
| 2056 | |∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 2057 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2058 | (fun y : E => B.a y i j) x * (η x) * |
| 2059 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 2060 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 2061 | Poincare.Analysis.Sobolev.diffQuot k h u x |
| 2062 | ∂(volume : Measure E)| + |
| 2063 | |∫ x in Ω, f x * |
| 2064 | Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 2065 | k h η u x| + |
| 2066 | |∫ x in Ω, B.c x * u x * |
| 2067 | Poincare.Analysis.Sobolev.NirenbergTestFunction.nirenbergTestFunction |
| 2068 | k h η u x| ≤ |
| 2069 | (ε_eff * I + C1 * G) + (ε_eff * I + C2 * G) + (C3 * G) + |
| 2070 | (ε_eff * I + Cf * (G + F)) + (ε_eff * I + Cc * (G + U)) := by |
| 2071 | have h1 : |- ∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 2072 | Poincare.Analysis.Sobolev.translate k h |
| 2073 | (fun y : E => B.a y i j) x * (η x) * |
| 2074 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 2075 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2076 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 2077 | Poincare.Analysis.Sobolev.diffQuot k h u x |
| 2078 | ∂(volume : Measure E)| ≤ ε_eff * I + C1 * G := hC1_h |
| 2079 | have h1' : |
| 2080 | |∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 2081 | Poincare.Analysis.Sobolev.translate k h |
| 2082 | (fun y : E => B.a y i j) x * (η x) * |
| 2083 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 2084 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2085 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single i 1)) x * |
| 2086 | Poincare.Analysis.Sobolev.diffQuot k h u x |
| 2087 | ∂(volume : Measure E)| ≤ ε_eff * I + C1 * G := by |
| 2088 | rw [← abs_neg]; exact h1 |
| 2089 | have h2 : |- ∑ i : Fin d, ∑ j : Fin d, ∫ x, |
| 2090 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2091 | (fun y : E => B.a y i j) x * (η x)^2 * |
| 2092 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 2093 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2094 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x |
| 2095 | ∂(volume : Measure E)| ≤ ε_eff * I + C2 * G := hC2_h |
| 2096 | have h2' : |
| 2097 | |∑ i : Fin d, ∑ j : Fin d, ∫ x, |
| 2098 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2099 | (fun y : E => B.a y i j) x * (η x)^2 * |
| 2100 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 2101 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2102 | (fun y : E => (fderiv ℝ u y) (EuclideanSpace.single j 1)) x |
| 2103 | ∂(volume : Measure E)| ≤ ε_eff * I + C2 * G := by |
| 2104 | rw [← abs_neg]; exact h2 |
| 2105 | have h3 : |- ∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 2106 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2107 | (fun y : E => B.a y i j) x * (η x) * |
| 2108 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 2109 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 2110 | Poincare.Analysis.Sobolev.diffQuot k h u x |
| 2111 | ∂(volume : Measure E)| ≤ C3 * G := hC3_h |
| 2112 | have h3' : |
| 2113 | |∑ i : Fin d, ∑ j : Fin d, ∫ x, 2 * |
| 2114 | Poincare.Analysis.Sobolev.diffQuot k h |
| 2115 | (fun y : E => B.a y i j) x * (η x) * |
| 2116 | ((fderiv ℝ η x) (EuclideanSpace.single j 1)) * |
| 2117 | ((fderiv ℝ u x) (EuclideanSpace.single i 1)) * |
| 2118 | Poincare.Analysis.Sobolev.diffQuot k h u x |
| 2119 | ∂(volume : Measure E)| ≤ C3 * G := by |
| 2120 | rw [← abs_neg]; exact h3 |
| 2121 | linarith |
| 2122 | refine h_master.trans (h_sum_bound.trans ?_) |
| 2123 | have hCc_distrib : Cc * (G + U) = Cc * G + Cc * U := by ring |
| 2124 | have hCf_distrib : Cf * (G + F) = Cf * G + Cf * F := by ring |
| 2125 | linarith [hCc_distrib, hCf_distrib] |
| 2126 | rw [show (4 * ε_eff * I) = (B.lam / 2) * I from by rw [h_4ε_eq]] at h_combine |
| 2127 | have hC_grad_le : C1 + C2 + C3 + Cc + Cf ≤ C := le_max_left _ _ |
| 2128 | have hC_Cc_le : Cc ≤ C := le_trans (le_max_left _ _) (le_max_right _ _) |
| 2129 | have hC_Cf_le : Cf ≤ C := le_trans (le_max_right _ _) (le_max_right _ _) |
| 2130 | have h_step1 : (C1 + C2 + C3 + Cc + Cf) * G ≤ C * G := |
| 2131 | mul_le_mul_of_nonneg_right hC_grad_le hG_nn |
| 2132 | have h_step2 : Cc * U ≤ C * U := |
| 2133 | mul_le_mul_of_nonneg_right hC_Cc_le hU_nn |
| 2134 | have h_step3 : Cf * F ≤ C * F := |
| 2135 | mul_le_mul_of_nonneg_right hC_Cf_le hF_nn |
| 2136 | have h_C_dist : C * (G + U + F) = C * G + C * U + C * F := by ring |
| 2137 | linarith |
| 2138 | |
| 2139 | end Poincare.Analysis.Sobolev.NirenbergCrossBounds |