Poincaré conjecture: the Lean proof, cleaned up together
The 2026 Lean proof of the Poincaré conjecture after Morgan and Tian, 3 million lines, cleaned up together: smaller, faster to build, more readable, the theorems unchanged

| 1 | /- |
| 2 | Provenance and modification notice (recorded 2026-09-29). |
| 3 | Notices for the adapted source: |
| 4 | Copyright 2026 The DifferentialGeometry contributors |
| 5 | Source: https://github.com/qinz1yang/differential-geometry |
| 6 | DifferentialGeometry/Analysis/Sobolev/Manifold/IteratedSobolevEmbedding.lean |
| 7 | Comparison revision: 1b535dd102b94cc42b107cca27059687888f08b3. |
| 8 | Changes: Imports, module paths, and namespaces were adapted to the subject-organized PoincareLib library. The local file extracts a subset of the upstream development. |
| 9 | License: Apache-2.0. Source licenses and notices are retained under |
| 10 | PoincareConjecture/provenance/2026-09-29/licenses/. |
| 11 | See PoincareConjecture/MODIFICATIONS.md for the reviewed source mapping. |
| 12 | -/ |
| 13 | |
| 14 | import PoincareLib.Analysis.Elliptic.Regularity.Sobolev.Embedding.Subcritical |
| 15 | |
| 16 | /-! |
| 17 | Adapted from Chow--Liao--Qin, revision `1b535dd102b94cc42b107cca27059687888f08b3`, |
| 18 | `DifferentialGeometry/Analysis/Sobolev/Manifold/IteratedSobolevEmbedding.lean`. |
| 19 | Apache-2.0; see `PoincareConjecture/provenance/2026-09-29/licenses/DifferentialGeometry/LICENSE`. |
| 20 | -/ |
| 21 | |
| 22 | noncomputable section |
| 23 | |
| 24 | open MeasureTheory Set Filter Topology Metric Function |
| 25 | open scoped ENNReal NNReal ContDiff |
| 26 | |
| 27 | namespace Poincare.Analysis.Sobolev.EuclideanEmbedding |
| 28 | |
| 29 | namespace EuclideanIterated |
| 30 | |
| 31 | variable {d : ℕ} |
| 32 | |
| 33 | local notation "EuN" => EuclideanSpace ℝ (Fin d) |
| 34 | |
| 35 | theorem wkpNorm_mono_order |
| 36 | {j k : ℕ} (hjk : j ≤ k) {p : ℝ≥0∞} {f : EuN → ℝ} {Ω : Set EuN} : |
| 37 | Poincare.Analysis.Sobolev.Euclidean.iteratedWeakSobolevNorm |
| 38 | (d := d) j p f Ω ≤ |
| 39 | Poincare.Analysis.Sobolev.Euclidean.iteratedWeakSobolevNorm |
| 40 | (d := d) k p f Ω := by |
| 41 | classical |
| 42 | unfold Poincare.Analysis.Sobolev.Euclidean.iteratedWeakSobolevNorm |
| 43 | refine Finset.sum_le_sum_of_subset ?_ |
| 44 | intro i hi |
| 45 | rw [Finset.mem_range] at hi |
| 46 | rw [Finset.mem_range] |
| 47 | omega |
| 48 | |
| 49 | theorem chosenWeakPartial'_cross_exponent_ae_eq |
| 50 | {p q : ℝ≥0∞} (hp : 1 ≤ p) (hq : 1 ≤ q) {Ω : Set EuN} |
| 51 | (hΩ_open : IsOpen Ω) {f : EuN → ℝ} |
| 52 | (hfp : Poincare.Analysis.Sobolev.Weak.MemW1p p f Ω) (hfq : Poincare.Analysis.Sobolev.Weak.MemW1p q f Ω) (i : Fin d) : |
| 53 | Poincare.Analysis.Sobolev.Euclidean.chosenWeakPartial' (d := d) |
| 54 | p i f Ω |
| 55 | =ᵐ[volume.restrict Ω] |
| 56 | Poincare.Analysis.Sobolev.Euclidean.chosenWeakPartial' (d := d) |
| 57 | q i f Ω := by |
| 58 | classical |
| 59 | have h_p_isWeak := |
| 60 | Poincare.Analysis.Sobolev.Euclidean.chosenWeakPartial'_isWeakPartial_of_mem |
| 61 | (d := d) hfp i |
| 62 | have h_q_isWeak := |
| 63 | Poincare.Analysis.Sobolev.Euclidean.chosenWeakPartial'_isWeakPartial_of_mem |
| 64 | (d := d) hfq i |
| 65 | have h_p_loc : LocallyIntegrable |
| 66 | (Poincare.Analysis.Sobolev.Euclidean.chosenWeakPartial' p i f Ω) |
| 67 | (volume.restrict Ω) := |
| 68 | (Poincare.Analysis.Sobolev.Euclidean.chosenWeakPartial'_memLp_of_mem |
| 69 | (d := d) hfp i).locallyIntegrable hp |
| 70 | have h_q_loc : LocallyIntegrable |
| 71 | (Poincare.Analysis.Sobolev.Euclidean.chosenWeakPartial' q i f Ω) |
| 72 | (volume.restrict Ω) := |
| 73 | (Poincare.Analysis.Sobolev.Euclidean.chosenWeakPartial'_memLp_of_mem |
| 74 | (d := d) hfq i).locallyIntegrable hq |
| 75 | exact Poincare.Analysis.Sobolev.Weak.HasWeakPartialDeriv.ae_eq hΩ_open h_p_isWeak h_q_isWeak |
| 76 | h_p_loc h_q_loc |
| 77 | |
| 78 | open Poincare.Analysis.Sobolev.Euclidean in |
| 79 | theorem wkpNorm_succ_eq |
| 80 | (k : ℕ) (p : ℝ≥0∞) (u : EuN → ℝ) (Ω : Set EuN) : |
| 81 | iteratedWeakSobolevNorm (d := d) (k + 1) p u Ω = |
| 82 | eLpNorm u p (volume.restrict Ω) + |
| 83 | ∑ i : Fin d, |
| 84 | iteratedWeakSobolevNorm (d := d) k p (chosenWeakPartial' p i u Ω) Ω := by |
| 85 | classical |
| 86 | unfold iteratedWeakSobolevNorm |
| 87 | rw [Finset.sum_range_succ' (n := k + 1) |
| 88 | (f := fun j => |
| 89 | ∑ α : Fin j → Fin d, |
| 90 | eLpNorm (iterWeakPartial (d := d) p j α u Ω) p (volume.restrict Ω))] |
| 91 | have h_zero_term : |
| 92 | (∑ α : Fin 0 → Fin d, |
| 93 | eLpNorm (iterWeakPartial (d := d) p 0 α u Ω) p (volume.restrict Ω)) = |
| 94 | eLpNorm u p (volume.restrict Ω) := by |
| 95 | have hUniq : ∀ α : Fin 0 → Fin d, α = (fun i : Fin 0 => i.elim0) := fun α => by |
| 96 | funext i; exact i.elim0 |
| 97 | have : Unique (Fin 0 → Fin d) := |
| 98 | { default := fun i : Fin 0 => i.elim0 |
| 99 | uniq := fun α => (hUniq α).symm ▸ rfl } |
| 100 | rw [Fintype.sum_unique |
| 101 | (f := fun α : Fin 0 → Fin d => |
| 102 | eLpNorm (iterWeakPartial (d := d) p 0 α u Ω) p (volume.restrict Ω))] |
| 103 | simp [iterWeakPartial_zero] |
| 104 | rw [h_zero_term, add_comm] |
| 105 | congr 1 |
| 106 | rw [Finset.sum_comm] |
| 107 | refine Finset.sum_congr rfl ?_ |
| 108 | intro j _ |
| 109 | have h_unfold : ∀ α : Fin (j + 1) → Fin d, |
| 110 | iterWeakPartial (d := d) p (j + 1) α u Ω = |
| 111 | iterWeakPartial (d := d) p j (fun i : Fin j => α i.succ) |
| 112 | (chosenWeakPartial' p (α 0) u Ω) Ω := |
| 113 | fun α => iterWeakPartial_succ p j α u Ω |
| 114 | let e : Fin d × (Fin j → Fin d) ≃ (Fin (j + 1) → Fin d) := |
| 115 | { toFun := fun p => Fin.cons p.1 p.2 |
| 116 | invFun := fun α => (α 0, fun i : Fin j => α i.succ) |
| 117 | left_inv := fun p => by |
| 118 | refine Prod.ext ?_ ?_ |
| 119 | · simp |
| 120 | · funext i |
| 121 | change (Fin.cons p.1 p.2 : Fin (j + 1) → Fin d) i.succ = p.2 i |
| 122 | rw [Fin.cons_succ] |
| 123 | right_inv := fun α => by |
| 124 | funext i |
| 125 | refine Fin.cases ?_ ?_ i |
| 126 | · simp |
| 127 | · intro k |
| 128 | change (Fin.cons (α 0) (fun i : Fin j => α i.succ) : Fin (j + 1) → Fin d) k.succ |
| 129 | = α k.succ |
| 130 | rw [Fin.cons_succ] } |
| 131 | rw [show |
| 132 | ∑ α : Fin (j + 1) → Fin d, |
| 133 | eLpNorm (iterWeakPartial (d := d) p (j + 1) α u Ω) p (volume.restrict Ω) = |
| 134 | ∑ p' : Fin d × (Fin j → Fin d), |
| 135 | eLpNorm (iterWeakPartial (d := d) p (j + 1) (e p') u Ω) p (volume.restrict Ω) from |
| 136 | (Fintype.sum_equiv e |
| 137 | (fun p' => eLpNorm (iterWeakPartial (d := d) p (j + 1) (e p') u Ω) p |
| 138 | (volume.restrict Ω)) |
| 139 | (fun α => eLpNorm (iterWeakPartial (d := d) p (j + 1) α u Ω) p |
| 140 | (volume.restrict Ω)) |
| 141 | (fun _ => rfl)).symm] |
| 142 | rw [show |
| 143 | ∑ p' : Fin d × (Fin j → Fin d), |
| 144 | eLpNorm (iterWeakPartial (d := d) p (j + 1) (e p') u Ω) p (volume.restrict Ω) = |
| 145 | ∑ i : Fin d, ∑ α' : Fin j → Fin d, |
| 146 | eLpNorm (iterWeakPartial (d := d) p (j + 1) (e (i, α')) u Ω) p (volume.restrict Ω) from |
| 147 | Fintype.sum_prod_type _] |
| 148 | refine Finset.sum_congr rfl ?_ |
| 149 | intro i _ |
| 150 | refine Finset.sum_congr rfl ?_ |
| 151 | intro α' _ |
| 152 | have hcons_zero : (Fin.cons i α' : Fin (j + 1) → Fin d) 0 = i := Fin.cons_zero _ _ |
| 153 | have hcons_succ : ∀ k : Fin j, (Fin.cons i α' : Fin (j + 1) → Fin d) k.succ = α' k := |
| 154 | fun k => Fin.cons_succ _ _ _ |
| 155 | have hiter_eq : |
| 156 | iterWeakPartial (d := d) p (j + 1) (e (i, α')) u Ω = |
| 157 | iterWeakPartial (d := d) p j α' (chosenWeakPartial' p i u Ω) Ω := by |
| 158 | change iterWeakPartial (d := d) p (j + 1) (Fin.cons i α') u Ω = |
| 159 | iterWeakPartial (d := d) p j α' (chosenWeakPartial' p i u Ω) Ω |
| 160 | rw [iterWeakPartial_succ] |
| 161 | have h_tail : (fun k : Fin j => (Fin.cons i α' : Fin (j + 1) → Fin d) k.succ) = α' := by |
| 162 | funext k; exact hcons_succ k |
| 163 | rw [h_tail, hcons_zero] |
| 164 | rw [hiter_eq] |
| 165 | |
| 166 | open Poincare.Analysis.Sobolev.Euclidean in |
| 167 | theorem wkpNorm_chosenWeakPartial_le_wkpNorm_succ |
| 168 | (k : ℕ) (p : ℝ≥0∞) (u : EuN → ℝ) (Ω : Set EuN) (i : Fin d) : |
| 169 | iteratedWeakSobolevNorm (d := d) k p (chosenWeakPartial' p i u Ω) Ω ≤ |
| 170 | iteratedWeakSobolevNorm (d := d) (k + 1) p u Ω := by |
| 171 | classical |
| 172 | rw [wkpNorm_succ_eq (d := d) k p u Ω] |
| 173 | have h_single : iteratedWeakSobolevNorm (d := d) k p (chosenWeakPartial' p i u Ω) Ω ≤ |
| 174 | ∑ i : Fin d, iteratedWeakSobolevNorm (d := d) k p (chosenWeakPartial' p i u Ω) Ω := |
| 175 | Finset.single_le_sum |
| 176 | (f := fun i : Fin d => |
| 177 | iteratedWeakSobolevNorm (d := d) k p (chosenWeakPartial' p i u Ω) Ω) |
| 178 | (s := (Finset.univ : Finset (Fin d))) |
| 179 | (fun _ _ => zero_le) |
| 180 | (Finset.mem_univ i) |
| 181 | exact le_trans h_single (le_add_self) |
| 182 | |
| 183 | open Poincare.Analysis.Sobolev.Euclidean in |
| 184 | theorem eLpNorm_le_wkpNorm |
| 185 | (k : ℕ) (p : ℝ≥0∞) (u : EuN → ℝ) (Ω : Set EuN) : |
| 186 | eLpNorm u p (volume.restrict Ω) ≤ iteratedWeakSobolevNorm (d := d) k p u Ω := by |
| 187 | have h := wkpNorm_mono_order (d := d) (Nat.zero_le k) (p := p) (f := u) (Ω := Ω) |
| 188 | rwa [wkpNorm_zero] at h |
| 189 | |
| 190 | end EuclideanIterated |
| 191 | namespace TowerStep |
| 192 | |
| 193 | variable {d : ℕ} [NeZero d] |
| 194 | |
| 195 | def pOne (d : ℕ) (p : ℝ) : ℝ := (d : ℝ) * p / ((d : ℝ) - p) |
| 196 | |
| 197 | lemma pOne_pos {p : ℝ} (hp_one : 1 ≤ p) (hp_dim : p < (d : ℝ)) : |
| 198 | 0 < pOne d p := by |
| 199 | unfold pOne |
| 200 | have hp_pos : 0 < p := by linarith |
| 201 | have hd_pos : 0 < (d : ℝ) := by exact_mod_cast NeZero.pos d |
| 202 | have hd_p_pos : 0 < (d : ℝ) - p := by linarith |
| 203 | exact div_pos (mul_pos hd_pos hp_pos) hd_p_pos |
| 204 | |
| 205 | lemma pOne_ge_p {p : ℝ} (hp_one : 1 ≤ p) (hp_dim : p < (d : ℝ)) : |
| 206 | p ≤ pOne d p := by |
| 207 | unfold pOne |
| 208 | have hp_pos : 0 < p := by linarith |
| 209 | have hd_pos : 0 < (d : ℝ) := by exact_mod_cast NeZero.pos d |
| 210 | have hd_p_pos : 0 < (d : ℝ) - p := by linarith |
| 211 | rw [le_div_iff₀ hd_p_pos] |
| 212 | nlinarith [hp_pos] |
| 213 | |
| 214 | lemma pOne_ge_one {p : ℝ} (hp_one : 1 ≤ p) (hp_dim : p < (d : ℝ)) : |
| 215 | 1 ≤ pOne d p := |
| 216 | le_trans hp_one (pOne_ge_p hp_one hp_dim) |
| 217 | |
| 218 | noncomputable def subcriticalConstantBase (d : ℕ) [NeZero d] (p : ℝ) : ℝ := |
| 219 | Poincare.Analysis.Sobolev.Weak.CGns d p * (d : ℝ) |
| 220 | |
| 221 | lemma subcriticalConstantBase_nonneg (d : ℕ) [NeZero d] (p : ℝ) : |
| 222 | 0 ≤ subcriticalConstantBase d p := by |
| 223 | unfold subcriticalConstantBase |
| 224 | exact mul_nonneg (Poincare.Analysis.Sobolev.Weak.C_gns_nonneg d p) (Nat.cast_nonneg _) |
| 225 | |
| 226 | noncomputable def subcriticalConstant : ∀ (_k : ℕ) (d : ℕ) [NeZero d] (_p : ℝ), ℝ |
| 227 | | 0, d, _, p => subcriticalConstantBase d p |
| 228 | | k + 1, d, _, p => subcriticalConstantBase d p + (d : ℝ) * subcriticalConstant k d p |
| 229 | |
| 230 | lemma subcriticalConstant_zero (d : ℕ) [NeZero d] (p : ℝ) : |
| 231 | subcriticalConstant 0 d p = subcriticalConstantBase d p := rfl |
| 232 | |
| 233 | lemma subcriticalConstant_succ (k d : ℕ) [NeZero d] (p : ℝ) : |
| 234 | subcriticalConstant (k + 1) d p = |
| 235 | subcriticalConstantBase d p + (d : ℝ) * subcriticalConstant k d p := rfl |
| 236 | |
| 237 | lemma subcriticalConstant_nonneg (k d : ℕ) [NeZero d] (p : ℝ) : |
| 238 | 0 ≤ subcriticalConstant k d p := by |
| 239 | induction k with |
| 240 | | zero => exact subcriticalConstantBase_nonneg d p |
| 241 | | succ k ih => |
| 242 | rw [subcriticalConstant_succ] |
| 243 | exact add_nonneg (subcriticalConstantBase_nonneg d p) |
| 244 | (mul_nonneg (Nat.cast_nonneg _) ih) |
| 245 | |
| 246 | local notation "EuN" => EuclideanSpace ℝ (Fin d) |
| 247 | |
| 248 | open Poincare.Analysis.Sobolev.Euclidean |
| 249 | EuclideanSubcritical EuclideanIterated |
| 250 | |
| 251 | theorem MemWkp_subcritical_iterated |
| 252 | (k : ℕ) {p : ℝ} (hp_one : 1 ≤ p) (hp_dim : p < (d : ℝ)) |
| 253 | {Ω : Set EuN} (hΩ_open : IsOpen Ω) : |
| 254 | ∀ {f : EuN → ℝ}, |
| 255 | HasCompactSupport f → tsupport f ⊆ Ω → |
| 256 | MemWkp (d := d) (k + 1) (ENNReal.ofReal p) f Ω → |
| 257 | MemWkp (d := d) k (ENNReal.ofReal (pOne d p)) f Ω ∧ |
| 258 | iteratedWeakSobolevNorm (d := d) k (ENNReal.ofReal (pOne d p)) f Ω ≤ |
| 259 | ENNReal.ofReal (subcriticalConstant k d p) * |
| 260 | iteratedWeakSobolevNorm (d := d) (k + 1) (ENNReal.ofReal p) f Ω := by |
| 261 | classical |
| 262 | set p_enn : ℝ≥0∞ := ENNReal.ofReal p with hp_enn_def |
| 263 | set p_1_enn : ℝ≥0∞ := ENNReal.ofReal (pOne d p) with hp_1_enn_def |
| 264 | have hp_pos : 0 < p := by linarith |
| 265 | have hp_1_pos : 0 < pOne d p := pOne_pos hp_one hp_dim |
| 266 | have hp_1_one : 1 ≤ pOne d p := pOne_ge_one hp_one hp_dim |
| 267 | have hp_enn_one : (1 : ℝ≥0∞) ≤ p_enn := by |
| 268 | rw [hp_enn_def, ← ENNReal.ofReal_one]; exact ENNReal.ofReal_le_ofReal hp_one |
| 269 | have hp_1_enn_one : (1 : ℝ≥0∞) ≤ p_1_enn := by |
| 270 | rw [hp_1_enn_def, ← ENNReal.ofReal_one]; exact ENNReal.ofReal_le_ofReal hp_1_one |
| 271 | induction k with |
| 272 | | zero => |
| 273 | intro f hf_compact hf_supp hf |
| 274 | have h_subcritical : |
| 275 | eLpNorm f p_1_enn (volume.restrict Ω) ≤ |
| 276 | ENNReal.ofReal (Poincare.Analysis.Sobolev.Weak.CGns d p) * (d : ℝ≥0∞) * |
| 277 | iteratedWeakSobolevNorm (d := d) 1 p_enn f Ω := by |
| 278 | have h := eLpNorm_p_star_le_const_mul_wkpNorm_of_memWkp (d := d) |
| 279 | hp_one hp_dim hΩ_open (f := f) hf hf_compact hf_supp |
| 280 | change eLpNorm f (ENNReal.ofReal ((d : ℝ) * p / ((d : ℝ) - p))) |
| 281 | (volume.restrict Ω) ≤ _ at h |
| 282 | have hpOne_eq : pOne d p = (d : ℝ) * p / ((d : ℝ) - p) := rfl |
| 283 | rw [show p_1_enn = ENNReal.ofReal ((d : ℝ) * p / ((d : ℝ) - p)) from by |
| 284 | rw [hp_1_enn_def, hpOne_eq]] |
| 285 | exact h |
| 286 | have hf_W1p : Poincare.Analysis.Sobolev.Weak.MemW1p p_enn f Ω := MemWkp.one_iff_memW1p.mp hf |
| 287 | have hf_aem : AEStronglyMeasurable f (volume.restrict Ω) := hf.memLp.aestronglyMeasurable |
| 288 | have h_eLp_lt_top : eLpNorm f p_1_enn (volume.restrict Ω) < ⊤ := by |
| 289 | refine lt_of_le_of_lt h_subcritical ?_ |
| 290 | have h_wkp_lt_top : iteratedWeakSobolevNorm (d := d) 1 p_enn f Ω < ⊤ := |
| 291 | wkpNorm_lt_top_of_memWkp hf |
| 292 | have h_first : (ENNReal.ofReal (Poincare.Analysis.Sobolev.Weak.CGns d p) : ℝ≥0∞) ≠ ⊤ := ENNReal.ofReal_ne_top |
| 293 | have h_d_top : (d : ℝ≥0∞) ≠ ⊤ := ENNReal.natCast_ne_top _ |
| 294 | refine ENNReal.mul_lt_top ?_ h_wkp_lt_top |
| 295 | exact ENNReal.mul_lt_top h_first.lt_top h_d_top.lt_top |
| 296 | have hf_memLp_p1 : MemLp f p_1_enn (volume.restrict Ω) := |
| 297 | ⟨hf_aem, h_eLp_lt_top⟩ |
| 298 | refine ⟨?_, ?_⟩ |
| 299 | · rw [MemWkp_zero] |
| 300 | exact hf_memLp_p1 |
| 301 | · rw [wkpNorm_zero] |
| 302 | rw [subcriticalConstant_zero] |
| 303 | unfold subcriticalConstantBase |
| 304 | have hC_nn : 0 ≤ Poincare.Analysis.Sobolev.Weak.CGns d p := Poincare.Analysis.Sobolev.Weak.C_gns_nonneg d p |
| 305 | have hd_nn : 0 ≤ (d : ℝ) := Nat.cast_nonneg _ |
| 306 | rw [show ENNReal.ofReal (Poincare.Analysis.Sobolev.Weak.CGns d p * (d : ℝ)) = |
| 307 | ENNReal.ofReal (Poincare.Analysis.Sobolev.Weak.CGns d p) * (d : ℝ≥0∞) from by |
| 308 | rw [ENNReal.ofReal_mul hC_nn, ENNReal.ofReal_natCast]] |
| 309 | exact h_subcritical |
| 310 | | succ k ih => |
| 311 | intro f hf_compact hf_supp hf |
| 312 | set K : Set EuN := tsupport f with hK_def |
| 313 | have hK_compact : IsCompact K := hf_compact |
| 314 | have hK_closed : IsClosed K := isClosed_tsupport f |
| 315 | have hKΩ : K ⊆ Ω := hf_supp |
| 316 | have hf_W1p : Poincare.Analysis.Sobolev.Weak.MemW1p p_enn f Ω := hf.memW1p |
| 317 | have h_base : |
| 318 | MemWkp (d := d) 0 p_1_enn f Ω ∧ |
| 319 | iteratedWeakSobolevNorm (d := d) 0 p_1_enn f Ω ≤ |
| 320 | ENNReal.ofReal (subcriticalConstant 0 d p) * |
| 321 | iteratedWeakSobolevNorm (d := d) 1 p_enn f Ω := by |
| 322 | have hf1 : MemWkp (d := d) 1 p_enn f Ω := |
| 323 | MemWkp.le_of_le (Nat.succ_le_succ (Nat.zero_le _)) hf |
| 324 | have h_subcritical : |
| 325 | eLpNorm f p_1_enn (volume.restrict Ω) ≤ |
| 326 | ENNReal.ofReal (Poincare.Analysis.Sobolev.Weak.CGns d p) * (d : ℝ≥0∞) * |
| 327 | iteratedWeakSobolevNorm (d := d) 1 p_enn f Ω := by |
| 328 | have h := eLpNorm_p_star_le_const_mul_wkpNorm_of_memWkp (d := d) |
| 329 | hp_one hp_dim hΩ_open (f := f) hf1 hf_compact hf_supp |
| 330 | change eLpNorm f (ENNReal.ofReal ((d : ℝ) * p / ((d : ℝ) - p))) |
| 331 | (volume.restrict Ω) ≤ _ at h |
| 332 | have hpOne_eq : pOne d p = (d : ℝ) * p / ((d : ℝ) - p) := rfl |
| 333 | rw [show p_1_enn = ENNReal.ofReal ((d : ℝ) * p / ((d : ℝ) - p)) from by |
| 334 | rw [hp_1_enn_def, hpOne_eq]] |
| 335 | exact h |
| 336 | have hf_aem : AEStronglyMeasurable f (volume.restrict Ω) := |
| 337 | hf.memLp.aestronglyMeasurable |
| 338 | have h_eLp_lt_top : eLpNorm f p_1_enn (volume.restrict Ω) < ⊤ := by |
| 339 | refine lt_of_le_of_lt h_subcritical ?_ |
| 340 | have h_wkp_lt_top : iteratedWeakSobolevNorm (d := d) 1 p_enn f Ω < ⊤ := |
| 341 | wkpNorm_lt_top_of_memWkp hf1 |
| 342 | refine ENNReal.mul_lt_top ?_ h_wkp_lt_top |
| 343 | exact ENNReal.mul_lt_top |
| 344 | (ENNReal.ofReal_lt_top) (ENNReal.natCast_lt_top _) |
| 345 | refine ⟨?_, ?_⟩ |
| 346 | · rw [MemWkp_zero]; exact ⟨hf_aem, h_eLp_lt_top⟩ |
| 347 | · rw [wkpNorm_zero, subcriticalConstant_zero] |
| 348 | unfold subcriticalConstantBase |
| 349 | have hC_nn : 0 ≤ Poincare.Analysis.Sobolev.Weak.CGns d p := Poincare.Analysis.Sobolev.Weak.C_gns_nonneg d p |
| 350 | rw [show ENNReal.ofReal (Poincare.Analysis.Sobolev.Weak.CGns d p * (d : ℝ)) = |
| 351 | ENNReal.ofReal (Poincare.Analysis.Sobolev.Weak.CGns d p) * (d : ℝ≥0∞) from by |
| 352 | rw [ENNReal.ofReal_mul hC_nn, ENNReal.ofReal_natCast]] |
| 353 | exact h_subcritical |
| 354 | let g : Fin d → EuN → ℝ := |
| 355 | fun i => K.indicator (chosenWeakPartial' p_enn i f Ω) |
| 356 | have hg_eq_iter : ∀ i, |
| 357 | g i = iteratedZeroExtension (d := d) p_enn Ω K 1 (fun _ : Fin 1 => i) f := by |
| 358 | intro i |
| 359 | change K.indicator (chosenWeakPartial' p_enn i f Ω) = _ |
| 360 | rw [iteratedZeroExtension_one] |
| 361 | have hg_supp : ∀ i, tsupport (g i) ⊆ K := by |
| 362 | intro i |
| 363 | rw [hg_eq_iter i] |
| 364 | exact tsupport_iteratedZeroExtension_subset (d := d) hK_closed |
| 365 | (subset_refl K) 1 (fun _ : Fin 1 => i) |
| 366 | have hg_compact : ∀ i, HasCompactSupport (g i) := by |
| 367 | intro i |
| 368 | exact hK_compact.of_isClosed_subset (isClosed_tsupport _) (hg_supp i) |
| 369 | have hg_supp_Ω : ∀ i, tsupport (g i) ⊆ Ω := fun i => (hg_supp i).trans hKΩ |
| 370 | have hf_chosen_mem : ∀ i, |
| 371 | MemWkp (d := d) (k + 1) p_enn (chosenWeakPartial' p_enn i f Ω) Ω := |
| 372 | fun i => hf.chosenWeakPartial_mem i |
| 373 | have h_iterWP_one : ∀ i, |
| 374 | iterWeakPartial (d := d) p_enn 1 (fun _ : Fin 1 => i) f Ω |
| 375 | = chosenWeakPartial' p_enn i f Ω := by |
| 376 | intro i |
| 377 | rw [iterWeakPartial_succ] |
| 378 | simp [iterWeakPartial_zero] |
| 379 | have hg_ae : ∀ i, |
| 380 | g i =ᵐ[volume.restrict Ω] chosenWeakPartial' p_enn i f Ω := by |
| 381 | intro i |
| 382 | rw [hg_eq_iter i] |
| 383 | have h := iteratedZeroExtension_ae_eq_iterWeakPartial (d := d) hp_enn_one |
| 384 | hΩ_open hK_closed 1 (k + 1 + 1) (by omega : 1 ≤ k + 1 + 1) |
| 385 | (fun _ : Fin 1 => i) (u := f) hf (subset_refl _) |
| 386 | rw [h_iterWP_one] at h |
| 387 | exact h |
| 388 | have hg_mem_kplus1 : ∀ i, |
| 389 | MemWkp (d := d) (k + 1) p_enn (g i) Ω := by |
| 390 | intro i |
| 391 | exact (MemWkp_congr_ae (d := d) hp_enn_one hΩ_open (hg_ae i)).mpr (hf_chosen_mem i) |
| 392 | have h_ih_g : ∀ i, |
| 393 | MemWkp (d := d) k p_1_enn (g i) Ω ∧ |
| 394 | iteratedWeakSobolevNorm (d := d) k p_1_enn (g i) Ω ≤ |
| 395 | ENNReal.ofReal (subcriticalConstant k d p) * |
| 396 | iteratedWeakSobolevNorm (d := d) (k + 1) p_enn (g i) Ω := |
| 397 | fun i => ih (hg_compact i) (hg_supp_Ω i) (hg_mem_kplus1 i) |
| 398 | have hf_chosen_mem_p1 : ∀ i, |
| 399 | MemWkp (d := d) k p_1_enn (chosenWeakPartial' p_enn i f Ω) Ω := by |
| 400 | intro i |
| 401 | exact (MemWkp_congr_ae (d := d) hp_1_enn_one hΩ_open (hg_ae i)).mp (h_ih_g i).1 |
| 402 | have h_wkp_eq : ∀ i, |
| 403 | iteratedWeakSobolevNorm (d := d) k p_1_enn (chosenWeakPartial' p_enn i f Ω) Ω = |
| 404 | iteratedWeakSobolevNorm (d := d) k p_1_enn (g i) Ω := fun i => |
| 405 | (wkpNorm_congr_ae (d := d) hp_1_enn_one hΩ_open (hg_ae i)).symm |
| 406 | have h_wkp_eq_p : ∀ i, |
| 407 | iteratedWeakSobolevNorm (d := d) (k + 1) p_enn (chosenWeakPartial' p_enn i f Ω) Ω = |
| 408 | iteratedWeakSobolevNorm (d := d) (k + 1) p_enn (g i) Ω := fun i => |
| 409 | (wkpNorm_congr_ae (d := d) hp_enn_one hΩ_open (hg_ae i)).symm |
| 410 | have hf_W1p_p1 : Poincare.Analysis.Sobolev.Weak.MemW1p p_1_enn f Ω := by |
| 411 | refine ⟨?_, ?_⟩ |
| 412 | · exact h_base.1 |
| 413 | · intro i |
| 414 | refine ⟨chosenWeakPartial' p_enn i f Ω, ?_, ?_⟩ |
| 415 | · exact (hf_chosen_mem_p1 i).memLp |
| 416 | · exact chosenWeakPartial'_isWeakPartial_of_mem hf_W1p i |
| 417 | have hf_mem_p1 : MemWkp (d := d) (k + 1) p_1_enn f Ω := by |
| 418 | rw [MemWkp_succ] |
| 419 | refine ⟨hf_W1p_p1, ?_⟩ |
| 420 | intro i |
| 421 | have h_cross : chosenWeakPartial' p_1_enn i f Ω |
| 422 | =ᵐ[volume.restrict Ω] chosenWeakPartial' p_enn i f Ω := |
| 423 | chosenWeakPartial'_cross_exponent_ae_eq (d := d) |
| 424 | hp_1_enn_one hp_enn_one hΩ_open hf_W1p_p1 hf_W1p i |
| 425 | exact (MemWkp_congr_ae (d := d) hp_1_enn_one hΩ_open h_cross).mpr (hf_chosen_mem_p1 i) |
| 426 | refine ⟨hf_mem_p1, ?_⟩ |
| 427 | rw [wkpNorm_succ_eq (d := d) k p_1_enn f Ω] |
| 428 | have h_eLp_bound : |
| 429 | eLpNorm f p_1_enn (volume.restrict Ω) ≤ |
| 430 | ENNReal.ofReal (subcriticalConstantBase d p) * |
| 431 | iteratedWeakSobolevNorm (d := d) 1 p_enn f Ω := by |
| 432 | have h := h_base.2 |
| 433 | rw [wkpNorm_zero, subcriticalConstant_zero] at h |
| 434 | exact h |
| 435 | have h_sum_term_bound : ∀ i, |
| 436 | iteratedWeakSobolevNorm (d := d) k p_1_enn (chosenWeakPartial' p_1_enn i f Ω) Ω ≤ |
| 437 | ENNReal.ofReal (subcriticalConstant k d p) * |
| 438 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω := by |
| 439 | intro i |
| 440 | have h_cross : chosenWeakPartial' p_1_enn i f Ω |
| 441 | =ᵐ[volume.restrict Ω] chosenWeakPartial' p_enn i f Ω := |
| 442 | chosenWeakPartial'_cross_exponent_ae_eq (d := d) |
| 443 | hp_1_enn_one hp_enn_one hΩ_open hf_W1p_p1 hf_W1p i |
| 444 | rw [wkpNorm_congr_ae (d := d) hp_1_enn_one hΩ_open h_cross] |
| 445 | rw [h_wkp_eq i] |
| 446 | refine le_trans (h_ih_g i).2 ?_ |
| 447 | rw [← h_wkp_eq_p i] |
| 448 | gcongr |
| 449 | exact wkpNorm_chosenWeakPartial_le_wkpNorm_succ (d := d) |
| 450 | (k + 1) p_enn f Ω i |
| 451 | have h_sum_bound : |
| 452 | ∑ i : Fin d, |
| 453 | iteratedWeakSobolevNorm (d := d) k p_1_enn (chosenWeakPartial' p_1_enn i f Ω) Ω ≤ |
| 454 | ∑ _i : Fin d, |
| 455 | ENNReal.ofReal (subcriticalConstant k d p) * |
| 456 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω := |
| 457 | Finset.sum_le_sum (fun i _ => h_sum_term_bound i) |
| 458 | have h_sum_const : |
| 459 | ∑ _i : Fin d, |
| 460 | ENNReal.ofReal (subcriticalConstant k d p) * |
| 461 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω = |
| 462 | (d : ℝ≥0∞) * |
| 463 | (ENNReal.ofReal (subcriticalConstant k d p) * |
| 464 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω) := by |
| 465 | rw [Finset.sum_const, Finset.card_univ, Fintype.card_fin] |
| 466 | rw [nsmul_eq_mul] |
| 467 | have h_eLp_full : eLpNorm f p_1_enn (volume.restrict Ω) ≤ |
| 468 | ENNReal.ofReal (subcriticalConstantBase d p) * |
| 469 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω := by |
| 470 | refine le_trans h_eLp_bound ?_ |
| 471 | gcongr |
| 472 | exact wkpNorm_mono_order (d := d) (by omega : 1 ≤ k + 1 + 1) |
| 473 | (p := p_enn) (f := f) (Ω := Ω) |
| 474 | calc |
| 475 | eLpNorm f p_1_enn (volume.restrict Ω) + |
| 476 | ∑ i : Fin d, iteratedWeakSobolevNorm (d := d) k p_1_enn |
| 477 | (chosenWeakPartial' p_1_enn i f Ω) Ω |
| 478 | ≤ ENNReal.ofReal (subcriticalConstantBase d p) * |
| 479 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω + |
| 480 | ∑ _i : Fin d, |
| 481 | ENNReal.ofReal (subcriticalConstant k d p) * |
| 482 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω := |
| 483 | add_le_add h_eLp_full h_sum_bound |
| 484 | _ = ENNReal.ofReal (subcriticalConstantBase d p) * |
| 485 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω + |
| 486 | (d : ℝ≥0∞) * |
| 487 | (ENNReal.ofReal (subcriticalConstant k d p) * |
| 488 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω) := by |
| 489 | rw [h_sum_const] |
| 490 | _ = (ENNReal.ofReal (subcriticalConstantBase d p) + |
| 491 | (d : ℝ≥0∞) * ENNReal.ofReal (subcriticalConstant k d p)) * |
| 492 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω := by |
| 493 | rw [add_mul, mul_assoc] |
| 494 | _ = ENNReal.ofReal (subcriticalConstant (k + 1) d p) * |
| 495 | iteratedWeakSobolevNorm (d := d) (k + 1 + 1) p_enn f Ω := by |
| 496 | rw [subcriticalConstant_succ] |
| 497 | rw [ENNReal.ofReal_add (subcriticalConstantBase_nonneg d p) |
| 498 | (mul_nonneg (Nat.cast_nonneg _) (subcriticalConstant_nonneg k d p))] |
| 499 | rw [ENNReal.ofReal_mul (Nat.cast_nonneg _)] |
| 500 | rw [ENNReal.ofReal_natCast] |
| 501 | |
| 502 | theorem MemWkp_succ_subcritical_step |
| 503 | {k : ℕ} {p : ℝ} (hp_one : 1 ≤ p) (hp_dim : p < (d : ℝ)) |
| 504 | {Ω : Set EuN} (hΩ_open : IsOpen Ω) |
| 505 | {f : EuN → ℝ} |
| 506 | (hf_compact : HasCompactSupport f) (hf_supp : tsupport f ⊆ Ω) |
| 507 | (hf : MemWkp (d := d) (k + 1) (ENNReal.ofReal p) f Ω) : |
| 508 | MemWkp (d := d) k (ENNReal.ofReal ((d : ℝ) * p / ((d : ℝ) - p))) f Ω ∧ |
| 509 | ∃ C : ℝ, 0 ≤ C ∧ |
| 510 | iteratedWeakSobolevNorm (d := d) k |
| 511 | (ENNReal.ofReal ((d : ℝ) * p / ((d : ℝ) - p))) f Ω ≤ |
| 512 | ENNReal.ofReal C * |
| 513 | iteratedWeakSobolevNorm (d := d) (k + 1) (ENNReal.ofReal p) f Ω := by |
| 514 | obtain ⟨h_mem, h_norm⟩ := |
| 515 | MemWkp_subcritical_iterated (d := d) k hp_one hp_dim hΩ_open |
| 516 | hf_compact hf_supp hf |
| 517 | have hpOne_eq : pOne d p = (d : ℝ) * p / ((d : ℝ) - p) := rfl |
| 518 | refine ⟨?_, ?_⟩ |
| 519 | · rw [show (ENNReal.ofReal ((d : ℝ) * p / ((d : ℝ) - p))) = |
| 520 | ENNReal.ofReal (pOne d p) from by rw [hpOne_eq]] |
| 521 | exact h_mem |
| 522 | · refine ⟨subcriticalConstant k d p, subcriticalConstant_nonneg k d p, ?_⟩ |
| 523 | rw [show (ENNReal.ofReal ((d : ℝ) * p / ((d : ℝ) - p))) = |
| 524 | ENNReal.ofReal (pOne d p) from by rw [hpOne_eq]] |
| 525 | exact h_norm |
| 526 | |
| 527 | end TowerStep |
| 528 | namespace IterationCalc |
| 529 | |
| 530 | private lemma kp1_gt_n_of_kp1p_gt_n |
| 531 | (n : ℝ) (k : ℕ) (p : ℝ) (hp_pos : 0 < p) (hp_dim : p < n) |
| 532 | (hkp : n < (k + 1 : ℝ) * p) : |
| 533 | n < (k : ℝ) * (n * p / (n - p)) := by |
| 534 | have hn_pos : 0 < n := lt_of_lt_of_le hp_pos hp_dim.le |
| 535 | have hn_p_pos : 0 < n - p := by linarith |
| 536 | have hkp_gt : (k : ℝ) * p > n - p := by |
| 537 | have : (k + 1 : ℝ) * p = (k : ℝ) * p + p := by ring |
| 538 | linarith [hkp] |
| 539 | have h_eq : (k : ℝ) * (n * p / (n - p)) = n * ((k : ℝ) * p) / (n - p) := by |
| 540 | field_simp |
| 541 | rw [h_eq] |
| 542 | rw [lt_div_iff₀ hn_p_pos] |
| 543 | have h_factor : n * ((k : ℝ) * p) - n * (n - p) = n * ((k : ℝ) * p - (n - p)) := by |
| 544 | ring |
| 545 | nlinarith [hkp_gt, hn_pos] |
| 546 | |
| 547 | lemma kp1_real_gt_d_of_kp1p_gt_d |
| 548 | (d : ℕ) (k : ℕ) (p : ℝ) (hp_pos : 0 < p) (hp_dim : p < (d : ℝ)) |
| 549 | (hkp : (d : ℝ) < (k + 1 : ℝ) * p) : |
| 550 | (d : ℝ) < (k : ℝ) * ((d : ℝ) * p / ((d : ℝ) - p)) := |
| 551 | kp1_gt_n_of_kp1p_gt_n (d : ℝ) k p hp_pos hp_dim hkp |
| 552 | |
| 553 | end IterationCalc |
| 554 | namespace RegularExponent |
| 555 | |
| 556 | def IsRegular (n : ℝ) (p : ℝ) (k : ℕ) : Prop := |
| 557 | ∀ m : ℕ, 1 ≤ m → m ≤ k → ((m : ℝ) * p ≠ n) |
| 558 | |
| 559 | lemma IsRegular.zero (n : ℝ) (p : ℝ) : IsRegular n p 0 := by |
| 560 | intro m hm hm_le |
| 561 | exact absurd hm_le (by omega) |
| 562 | |
| 563 | lemma IsRegular.le_of_succ {n p : ℝ} {k : ℕ} |
| 564 | (h : IsRegular n p (k + 1)) : IsRegular n p k := by |
| 565 | intro m hm hm_le |
| 566 | exact h m hm (by omega) |
| 567 | |
| 568 | lemma IsRegular.p_ne_n_of_one_le {n p : ℝ} {k : ℕ} |
| 569 | (h : IsRegular n p k) (hk : 1 ≤ k) : p ≠ n := by |
| 570 | intro hp_eq |
| 571 | have h1 : ((1 : ℕ) : ℝ) * p ≠ n := h 1 (le_refl 1) hk |
| 572 | have : (1 : ℝ) * p = p := by ring |
| 573 | rw [Nat.cast_one] at h1 |
| 574 | rw [this] at h1 |
| 575 | exact h1 hp_eq |
| 576 | |
| 577 | lemma IsRegular.tower_step |
| 578 | {n p : ℝ} {k : ℕ} |
| 579 | (hp_one : 1 ≤ p) (hp_lt : p < n) (h : IsRegular n p (k + 1)) : |
| 580 | IsRegular n (n * p / (n - p)) k := by |
| 581 | intro m hm hm_le |
| 582 | have hp_pos : 0 < p := by linarith |
| 583 | have hd_pos : 0 < n := lt_of_lt_of_le hp_pos hp_lt.le |
| 584 | have hd_p_pos : 0 < n - p := by linarith |
| 585 | have h_succ : ((m + 1 : ℕ) : ℝ) * p ≠ n := h (m + 1) (by omega) (by omega) |
| 586 | intro h_eq |
| 587 | have h_eq' : (m : ℝ) * (n * p) = n * (n - p) := by |
| 588 | have : (m : ℝ) * (n * p / (n - p)) * (n - p) = n * (n - p) := by |
| 589 | rw [h_eq] |
| 590 | rw [show (m : ℝ) * (n * p / (n - p)) * (n - p) = |
| 591 | (m : ℝ) * (n * p) by |
| 592 | field_simp] at this |
| 593 | exact this |
| 594 | have h_eq2 : ((m + 1 : ℕ) : ℝ) * p = n := by |
| 595 | have h_mul : (m : ℝ) * (n * p) = n * (n - p) := h_eq' |
| 596 | have hn_ne : n ≠ 0 := hd_pos.ne' |
| 597 | push_cast |
| 598 | have : (m : ℝ) * (n * p) + n * p = n * (n - p) + n * p := by rw [h_mul] |
| 599 | nlinarith [hn_ne] |
| 600 | exact h_succ h_eq2 |
| 601 | |
| 602 | end RegularExponent |
| 603 | namespace RegularExponent |
| 604 | |
| 605 | private noncomputable def borderlineSet (n : ℝ) (k : ℕ) : Finset ℝ := |
| 606 | (Finset.Icc 1 k).image (fun m : ℕ => n / (m : ℝ)) |
| 607 | |
| 608 | private lemma isRegular_iff_notMem_borderlineSet |
| 609 | {n p : ℝ} {k : ℕ} : |
| 610 | IsRegular n p k ↔ p ∉ borderlineSet n k := by |
| 611 | classical |
| 612 | unfold IsRegular borderlineSet |
| 613 | refine ⟨fun h hmem => ?_, fun hnot m hm_one hm_le hmp_eq => ?_⟩ |
| 614 | · rw [Finset.mem_image] at hmem |
| 615 | obtain ⟨m, hm_mem, hm_eq⟩ := hmem |
| 616 | rw [Finset.mem_Icc] at hm_mem |
| 617 | obtain ⟨hm_one, hm_le⟩ := hm_mem |
| 618 | have hm_pos : 0 < (m : ℝ) := by exact_mod_cast (by omega : 0 < m) |
| 619 | have hjp : (m : ℝ) * p = n := by |
| 620 | have hp_eq : p = n / (m : ℝ) := hm_eq.symm |
| 621 | rw [hp_eq]; field_simp |
| 622 | exact h m hm_one hm_le hjp |
| 623 | · apply hnot |
| 624 | rw [Finset.mem_image] |
| 625 | refine ⟨m, ?_, ?_⟩ |
| 626 | · rw [Finset.mem_Icc]; exact ⟨hm_one, hm_le⟩ |
| 627 | · have hm_pos : 0 < (m : ℝ) := by exact_mod_cast (by omega : 0 < m) |
| 628 | field_simp |
| 629 | linarith [hmp_eq] |
| 630 | |
| 631 | private lemma exists_notMem_finset_in_open_interval |
| 632 | {lb p : ℝ} (hlb_lt_p : lb < p) (S : Finset ℝ) : |
| 633 | ∃ p' : ℝ, lb < p' ∧ p' < p ∧ p' ∉ S := by |
| 634 | classical |
| 635 | set T : Finset ℝ := S.filter (fun x => lb < x ∧ x < p) with hT_def |
| 636 | by_cases hT : T = ∅ |
| 637 | · refine ⟨(lb + p) / 2, by linarith, by linarith, ?_⟩ |
| 638 | intro hmem |
| 639 | have : (lb + p) / 2 ∈ T := by |
| 640 | rw [hT_def, Finset.mem_filter] |
| 641 | exact ⟨hmem, by linarith, by linarith⟩ |
| 642 | rw [hT] at this |
| 643 | exact (Finset.notMem_empty _) this |
| 644 | · have hT_nonempty : T.Nonempty := Finset.nonempty_iff_ne_empty.mpr hT |
| 645 | set M : ℝ := T.max' hT_nonempty with hM_def |
| 646 | have hM_mem : M ∈ T := T.max'_mem hT_nonempty |
| 647 | have hM_lt_p : M < p := (Finset.mem_filter.mp hM_mem).2.2 |
| 648 | have hM_gt_lb : lb < M := (Finset.mem_filter.mp hM_mem).2.1 |
| 649 | refine ⟨(M + p) / 2, by linarith, by linarith, ?_⟩ |
| 650 | intro hmem |
| 651 | have h_in_T : (M + p) / 2 ∈ T := by |
| 652 | rw [hT_def, Finset.mem_filter] |
| 653 | exact ⟨hmem, by linarith, by linarith⟩ |
| 654 | have h_le : (M + p) / 2 ≤ M := T.le_max' _ h_in_T |
| 655 | linarith |
| 656 | |
| 657 | lemma exists_regular_exponent_below |
| 658 | (n : ℝ) (k : ℕ) (hk : 1 ≤ k) {p : ℝ} (hp_one : 1 < p) |
| 659 | (hkp : n < (k : ℝ) * p) : |
| 660 | ∃ p' : ℝ, 1 ≤ p' ∧ p' < p ∧ n < (k : ℝ) * p' ∧ |
| 661 | IsRegular n p' k := by |
| 662 | classical |
| 663 | have hk_pos : 0 < (k : ℝ) := by exact_mod_cast (by omega : 0 < k) |
| 664 | set lb : ℝ := max 1 (n / (k : ℝ)) with hlb_def |
| 665 | have hnk_lt_p : n / (k : ℝ) < p := by |
| 666 | rw [div_lt_iff₀ hk_pos]; linarith |
| 667 | have hlb_lt_p : lb < p := by |
| 668 | rw [hlb_def, max_lt_iff]; exact ⟨hp_one, hnk_lt_p⟩ |
| 669 | obtain ⟨p', hp'_lb, hp'_lt, hp'_notMem⟩ := |
| 670 | exists_notMem_finset_in_open_interval hlb_lt_p (borderlineSet n k) |
| 671 | refine ⟨p', ?_, hp'_lt, ?_, ?_⟩ |
| 672 | · have h1_le_lb : (1 : ℝ) ≤ lb := by rw [hlb_def]; exact le_max_left _ _ |
| 673 | linarith |
| 674 | · have hnk_le_lb : n / (k : ℝ) ≤ lb := by rw [hlb_def]; exact le_max_right _ _ |
| 675 | have h_n_lt_kp' : n / (k : ℝ) < p' := lt_of_le_of_lt hnk_le_lb hp'_lb |
| 676 | rw [div_lt_iff₀ hk_pos] at h_n_lt_kp'; linarith |
| 677 | · exact (isRegular_iff_notMem_borderlineSet (n := n) (p := p') (k := k)).mpr |
| 678 | hp'_notMem |
| 679 | |
| 680 | end RegularExponent |
| 681 | |
| 682 | namespace EuclideanIteratedMonoExp |
| 683 | |
| 684 | variable {d : ℕ} [NeZero d] |
| 685 | |
| 686 | local notation "EuN" => EuclideanSpace ℝ (Fin d) |
| 687 | |
| 688 | open Poincare.Analysis.Sobolev.Euclidean |
| 689 | |
| 690 | omit [NeZero d] in |
| 691 | private lemma diff_K_subset_diff_subset |
| 692 | {S K Ω : Set EuN} (hSK : S ⊆ K) : |
| 693 | Ω \ K ⊆ Ω \ S := fun _ ⟨hx_Ω, hx_notK⟩ => |
| 694 | ⟨hx_Ω, fun h => hx_notK (hSK h)⟩ |
| 695 | |
| 696 | omit [NeZero d] in |
| 697 | private lemma ae_eq_indicator_of_ae_zero_off_subset |
| 698 | {Ω : Set EuN} (hΩ_open : IsOpen Ω) {S K : Set EuN} (hSK : S ⊆ K) |
| 699 | (hK_meas : MeasurableSet K) |
| 700 | {g : EuN → ℝ} |
| 701 | (hg_ae_zero : g =ᵐ[(MeasureTheory.volume : |
| 702 | MeasureTheory.Measure EuN).restrict (Ω \ S)] (fun _ : EuN => (0 : ℝ))) : |
| 703 | g =ᵐ[(MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω] |
| 704 | K.indicator g := by |
| 705 | classical |
| 706 | have hΩ_meas : MeasurableSet Ω := hΩ_open.measurableSet |
| 707 | have hΩK_meas : MeasurableSet (Ω \ K) := hΩ_meas.diff hK_meas |
| 708 | have h_ae_zero_diffK : ∀ᵐ x ∂((MeasureTheory.volume : |
| 709 | MeasureTheory.Measure EuN).restrict (Ω \ K)), g x = 0 := by |
| 710 | have h := MeasureTheory.ae_restrict_of_ae_restrict_of_subset |
| 711 | (s := Ω \ K) (t := Ω \ S) |
| 712 | (diff_K_subset_diff_subset (Ω := Ω) hSK) hg_ae_zero |
| 713 | exact h |
| 714 | rw [MeasureTheory.ae_restrict_iff' hΩK_meas] at h_ae_zero_diffK |
| 715 | rw [Filter.EventuallyEq, MeasureTheory.ae_restrict_iff' hΩ_meas] |
| 716 | filter_upwards [h_ae_zero_diffK] with x hx hx_Ω |
| 717 | by_cases h_in_K : x ∈ K |
| 718 | · simp [Set.indicator_of_mem h_in_K] |
| 719 | · have hx_diff : x ∈ Ω \ K := ⟨hx_Ω, h_in_K⟩ |
| 720 | have : g x = 0 := hx hx_diff |
| 721 | simp [Set.indicator_of_notMem h_in_K, this] |
| 722 | |
| 723 | omit [NeZero d] in |
| 724 | private lemma chosenWeakPartial'_ae_eq_indicator_of_tsupport_subset |
| 725 | {p : ℝ≥0∞} (hp_one : 1 ≤ p) |
| 726 | {Ω : Set EuN} (hΩ_open : IsOpen Ω) |
| 727 | {K : Set EuN} (hK_meas : MeasurableSet K) |
| 728 | {f : EuN → ℝ} |
| 729 | (hf_W1p : Poincare.Analysis.Sobolev.Weak.MemW1p p f Ω) |
| 730 | (hf_supp : tsupport f ⊆ K) (i : Fin d) : |
| 731 | chosenWeakPartial' (d := d) p i f Ω |
| 732 | =ᵐ[(MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω] |
| 733 | K.indicator (chosenWeakPartial' (d := d) p i f Ω) := by |
| 734 | have h_ae_zero_sdiff : |
| 735 | chosenWeakPartial' (d := d) p i f Ω |
| 736 | =ᵐ[(MeasureTheory.volume : MeasureTheory.Measure EuN).restrict |
| 737 | (Ω \ tsupport f)] (fun _ : EuN => (0 : ℝ)) := |
| 738 | chosenWeakPartial'_ae_zero_on_sdiff_tsupport (d := d) hp_one hΩ_open |
| 739 | hf_W1p i |
| 740 | exact ae_eq_indicator_of_ae_zero_off_subset (Ω := Ω) hΩ_open |
| 741 | (S := tsupport f) (K := K) hf_supp hK_meas h_ae_zero_sdiff |
| 742 | |
| 743 | omit [NeZero d] in |
| 744 | theorem memWkp_mono_exponent_of_tsupport_subset |
| 745 | (k : ℕ) {Ω : Set EuN} (hΩ_open : IsOpen Ω) |
| 746 | {K : Set EuN} (hK_closed : IsClosed K) |
| 747 | (hK_meas_lt_top : MeasureTheory.volume K ≠ ⊤) |
| 748 | {p p' : ℝ≥0∞} (hp'_one : 1 ≤ p') (hp'_le_p : p' ≤ p) |
| 749 | {f : EuN → ℝ} |
| 750 | (hf_supp : tsupport f ⊆ K) |
| 751 | (hfp : MemWkp (d := d) k p f Ω) : |
| 752 | MemWkp (d := d) k p' f Ω := by |
| 753 | have hp_one : (1 : ℝ≥0∞) ≤ p := le_trans hp'_one hp'_le_p |
| 754 | have hK_meas : MeasurableSet K := hK_closed.measurableSet |
| 755 | have hKΩ_meas_lt_top : |
| 756 | ((MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω) K ≠ ⊤ := |
| 757 | ne_top_of_le_ne_top hK_meas_lt_top |
| 758 | (MeasureTheory.Measure.restrict_apply_le _ _) |
| 759 | have memLp_mono : ∀ {q q' : ℝ≥0∞} (_hq_le : q' ≤ q) {h : EuN → ℝ}, |
| 760 | h =ᵐ[(MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω] |
| 761 | K.indicator h → |
| 762 | MeasureTheory.MemLp h q |
| 763 | ((MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω) → |
| 764 | MeasureTheory.MemLp h q' |
| 765 | ((MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω) := by |
| 766 | intro q q' hq_le h h_eq h_memLp |
| 767 | have h_zero_off : ∀ x, x ∉ K → K.indicator h x = 0 := fun x hx => |
| 768 | Set.indicator_of_notMem hx _ |
| 769 | have h_clean_memLp_q : MeasureTheory.MemLp (K.indicator h) q |
| 770 | ((MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω) := |
| 771 | (MeasureTheory.memLp_congr_ae h_eq).mp h_memLp |
| 772 | have h_clean_memLp_q' : MeasureTheory.MemLp (K.indicator h) q' |
| 773 | ((MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω) := |
| 774 | h_clean_memLp_q.mono_exponent_of_measure_support_ne_top h_zero_off |
| 775 | hKΩ_meas_lt_top hq_le |
| 776 | exact (MeasureTheory.memLp_congr_ae h_eq).mpr h_clean_memLp_q' |
| 777 | have indicator_tsupport_subset : ∀ (g : EuN → ℝ), |
| 778 | tsupport (K.indicator g) ⊆ K := by |
| 779 | intro g |
| 780 | have h_supp_sub : Function.support (K.indicator g) ⊆ K := by |
| 781 | intro x hx |
| 782 | by_contra hxK |
| 783 | have h_zero : K.indicator g x = 0 := Set.indicator_of_notMem hxK _ |
| 784 | exact (Function.mem_support.mp hx) h_zero |
| 785 | calc tsupport (K.indicator g) |
| 786 | = closure (Function.support (K.indicator g)) := rfl |
| 787 | _ ⊆ closure K := closure_mono h_supp_sub |
| 788 | _ = K := hK_closed.closure_eq |
| 789 | have ae_eq_indicator_of_tsupport : ∀ {h : EuN → ℝ}, tsupport h ⊆ K → |
| 790 | h =ᵐ[(MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω] |
| 791 | K.indicator h := by |
| 792 | intro h hh_supp |
| 793 | refine MeasureTheory.ae_of_all _ ?_ |
| 794 | intro x |
| 795 | by_cases h_in_K : x ∈ K |
| 796 | · rw [Set.indicator_of_mem h_in_K] |
| 797 | · have hx_not_supp : x ∉ tsupport h := fun hsx => h_in_K (hh_supp hsx) |
| 798 | have hh_x_zero : h x = 0 := image_eq_zero_of_notMem_tsupport hx_not_supp |
| 799 | rw [Set.indicator_of_notMem h_in_K, hh_x_zero] |
| 800 | induction k generalizing f with |
| 801 | | zero => |
| 802 | rw [MemWkp_zero] at hfp ⊢ |
| 803 | exact memLp_mono hp'_le_p (ae_eq_indicator_of_tsupport hf_supp) hfp |
| 804 | | succ k ih => |
| 805 | rw [MemWkp_succ] at hfp ⊢ |
| 806 | obtain ⟨hf_W1p, hf_recursive⟩ := hfp |
| 807 | have hf_ae_eq_indicator := ae_eq_indicator_of_tsupport hf_supp |
| 808 | have hf_W1p' : Poincare.Analysis.Sobolev.Weak.MemW1p p' f Ω := by |
| 809 | refine ⟨memLp_mono hp'_le_p hf_ae_eq_indicator hf_W1p.1, ?_⟩ |
| 810 | intro i |
| 811 | set g : EuN → ℝ := chosenWeakPartial' (d := d) p i f Ω with hg_def |
| 812 | have hg_memLp_p : MeasureTheory.MemLp g p |
| 813 | ((MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω) := |
| 814 | chosenWeakPartial'_memLp_of_mem (d := d) hf_W1p i |
| 815 | have hg_weak : Poincare.Analysis.Sobolev.Weak.HasWeakPartialDeriv i g f Ω := |
| 816 | chosenWeakPartial'_isWeakPartial_of_mem (d := d) hf_W1p i |
| 817 | have hg_ae_eq_indicator : g =ᵐ[(MeasureTheory.volume : |
| 818 | MeasureTheory.Measure EuN).restrict Ω] K.indicator g := |
| 819 | chosenWeakPartial'_ae_eq_indicator_of_tsupport_subset |
| 820 | (d := d) hp_one hΩ_open hK_meas hf_W1p hf_supp i |
| 821 | exact ⟨g, memLp_mono hp'_le_p hg_ae_eq_indicator hg_memLp_p, hg_weak⟩ |
| 822 | refine ⟨hf_W1p', ?_⟩ |
| 823 | intro i |
| 824 | set g_p : EuN → ℝ := chosenWeakPartial' (d := d) p i f Ω with hg_p_def |
| 825 | have hg_p_mem : MemWkp (d := d) k p g_p Ω := hf_recursive i |
| 826 | have hg_p_ae_eq_indicator : g_p =ᵐ[(MeasureTheory.volume : |
| 827 | MeasureTheory.Measure EuN).restrict Ω] K.indicator g_p := |
| 828 | chosenWeakPartial'_ae_eq_indicator_of_tsupport_subset |
| 829 | (d := d) hp_one hΩ_open hK_meas hf_W1p hf_supp i |
| 830 | have h_indicator_tsupport : tsupport (K.indicator g_p) ⊆ K := |
| 831 | indicator_tsupport_subset g_p |
| 832 | have h_indicator_memWkp_p : MemWkp (d := d) k p (K.indicator g_p) Ω := |
| 833 | (MemWkp_congr_ae (d := d) hp_one hΩ_open hg_p_ae_eq_indicator).mp hg_p_mem |
| 834 | have h_indicator_memWkp_p' : MemWkp (d := d) k p' (K.indicator g_p) Ω := |
| 835 | ih h_indicator_tsupport h_indicator_memWkp_p |
| 836 | have hg_p_memWkp_p' : MemWkp (d := d) k p' g_p Ω := |
| 837 | (MemWkp_congr_ae (d := d) hp'_one hΩ_open hg_p_ae_eq_indicator).mpr |
| 838 | h_indicator_memWkp_p' |
| 839 | have h_cross_ae : chosenWeakPartial' (d := d) p' i f Ω |
| 840 | =ᵐ[(MeasureTheory.volume : MeasureTheory.Measure EuN).restrict Ω] g_p := |
| 841 | Analysis.Sobolev.EuclideanEmbedding.EuclideanIterated.chosenWeakPartial'_cross_exponent_ae_eq |
| 842 | (d := d) hp'_one hp_one hΩ_open hf_W1p' hf_W1p i |
| 843 | exact (MemWkp_congr_ae (d := d) hp'_one hΩ_open h_cross_ae).mpr hg_p_memWkp_p' |
| 844 | |
| 845 | end EuclideanIteratedMonoExp |
| 846 | |
| 847 | end Poincare.Analysis.Sobolev.EuclideanEmbedding |