Download data/lean/OAI/MeasureTheory/Falconer/Shells/DistanceLinearization.lean from introvoyz045/math: direct link, hf CLI and curl.
- Browser
- Download file 3.43 kB
-
https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/MeasureTheory/Falconer/Shells/DistanceLinearization.lean
- Command line
-
hf download hf://datasets/introvoyz045/math/data/lean/OAI/MeasureTheory/Falconer/Shells/DistanceLinearization.lean
-
curl -L -o DistanceLinearization.lean https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/MeasureTheory/Falconer/Shells/DistanceLinearization.lean
3.43 kB
| import OAI.MeasureTheory.Falconer.Geometry.DyadicCube | |
| import Mathlib.Analysis.InnerProductSpace.Basic | |
| namespace OAI | |
| /-! # The actual distance Taylor error for the suffix reduction | |
| The error estimate is dimension independent before insertion of the cube | |
| diameter. Its proof is the exact squared-norm identity, so no differentiable | |
| extension across the diagonal is needed. | |
| -/ | |
| namespace Falconer | |
| open Set | |
| variable {E : Type*} [NormedAddCommGroup E] [InnerProductSpace β E] | |
| theorem norm_linearization_bounds (u v : E) (hu : 0 < βuβ) : | |
| 0 β€ βvβ-inner β (βuββ»ΒΉ β’ u) v β§ | |
| βvβ-inner β (βuββ»ΒΉ β’ u) v β€ βv-uβ^2/(2*βuβ) := by | |
| have hi : inner β (βuββ»ΒΉ β’ u) v = inner β u v/βuβ := by | |
| rw [real_inner_smul_left] | |
| ring | |
| rw [hi] | |
| have hb : inner β u v/βuβ β€ βvβ := by | |
| apply (div_le_iffβ hu).mpr | |
| exact (real_inner_le_norm u v).trans_eq (mul_comm _ _) | |
| have he : 2*βuβ*(βvβ-inner β u v/βuβ) = | |
| βv-uβ^2-(βvβ-βuβ)^2 := by | |
| have hs := norm_sub_sq_real v u | |
| rw [real_inner_comm u v] at hs | |
| field_simp | |
| nlinarith | |
| refine β¨sub_nonneg.mpr hb,?_β© | |
| apply (le_div_iffβ (mul_pos (by norm_num) hu)).mpr | |
| nlinarith [sq_nonneg (βvβ-βuβ)] | |
| theorem norm_linearization_abs_le (u v : E) (hu : 0 < βuβ) : | |
| |βvβ-inner β (βuββ»ΒΉ β’ u) v| β€ βv-uβ^2/(2*βuβ) := by | |
| rw [abs_of_nonneg (norm_linearization_bounds u v hu).1] | |
| exact (norm_linearization_bounds u v hu).2 | |
| omit [InnerProductSpace β E] in | |
| theorem pair_displacement_bound (x y cβ cβ : E) {Ξ΄β Ξ΄β : β} | |
| (hβ : βx-cββ β€ Ξ΄β) (hβ : βy-cββ β€ Ξ΄β) : | |
| β(x-y)-(cβ-cβ)β β€ Ξ΄β+Ξ΄β := by | |
| have he : (x-y)-(cβ-cβ) = (x-cβ)-(y-cβ) := by abel | |
| rw [he] | |
| exact (norm_sub_le _ _).trans (add_le_add hβ hβ) | |
| /-- Original distances on a pair of small cubes have the required | |
| quadratic error relative to their center direction. -/ | |
| theorem DyadicCube.distance_linearization {d : β} (P Q : DyadicCube d) | |
| (hP : 0 < P.side) (hQ : Q.side = P.side) | |
| {g : β} (hg : 0 < g) (hsep : g β€ βP.center-Q.centerβ) | |
| {x y : Space d} (hx : x β P.carrier) (hy : y β Q.carrier) : | |
| |dist x y-inner β (βP.center-Q.centerββ»ΒΉ β’ (P.center-Q.center)) (x-y)| β€ | |
| 2*(d:β)*P.side^2/g := by | |
| have hQp : 0 < Q.side := by rw [hQ]; exact hP | |
| have hΞ΄ : β(x-y)-(P.center-Q.center)β β€ 2*Real.sqrt d*P.side := by | |
| have hβ := P.dist_le hP.le hx (P.center_mem hP) | |
| have hβ := Q.dist_le hQp.le hy (Q.center_mem hQp) | |
| rw [hQ] at hβ | |
| simpa only [dist_eq_norm,two_mul,mul_add,add_mul] using | |
| pair_displacement_bound x y P.center Q.center hβ hβ | |
| have hsquare : β(x-y)-(P.center-Q.center)β^2 β€ 4*(d:β)*P.side^2 := by | |
| have hh := (sq_le_sqβ (norm_nonneg _) (by positivity)).mpr hΞ΄ | |
| nlinarith [Real.sq_sqrt (Nat.cast_nonneg (Ξ± := β) d)] | |
| have hnorm : 0 < βP.center-Q.centerβ := hg.trans_le hsep | |
| rw [dist_eq_norm] | |
| apply (norm_linearization_abs_le _ _ hnorm).trans | |
| calc | |
| _ β€ (4*(d:β)*P.side^2)/(2*βP.center-Q.centerβ) := | |
| div_le_div_of_nonneg_right hsquare (by positivity) | |
| _ β€ (4*(d:β)*P.side^2)/(2*g) := | |
| div_le_div_of_nonneg_left (by positivity) (by positivity) | |
| (mul_le_mul_of_nonneg_left hsep (by norm_num)) | |
| _ = _ := by ring | |
| end Falconer | |
| end OAI | |