Download data/lean/OAI/Geometry/Perimeter/Regularity/EllipticCurl.lean from introvoyz045/math: direct link, hf CLI and curl.
- Browser
- Download file 5.65 kB
-
https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Geometry/Perimeter/Regularity/EllipticCurl.lean
- Command line
-
hf download hf://datasets/introvoyz045/math/data/lean/OAI/Geometry/Perimeter/Regularity/EllipticCurl.lean
-
curl -L -o EllipticCurl.lean https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Geometry/Perimeter/Regularity/EllipticCurl.lean
5.65 kB
| import OAI.Geometry.Perimeter.Regularity.SmoothFlatOrder | |
| import OAI.Geometry.Perimeter.Regularity.EllipticTestSpace | |
| namespace OAI | |
| noncomputable section | |
| open Set Filter MeasureTheory | |
| open scoped Topology ENNReal ContDiff InnerProductSpace | |
| namespace RPISingularHarnack | |
| variable {n : β} | |
| def scalarDirection (Ο : Euc n β β) (a : Euc n) (x : Euc n) := fderiv β Ο x a | |
| theorem scalarDirection_contDiff {Ο : Euc n β β} (hΟ : ContDiff β β Ο) (a : Euc n) : | |
| ContDiff β β (scalarDirection Ο a) := | |
| (hΟ.fderiv_right (by simp)).clm_apply contDiff_const | |
| theorem scalarDirection_tsupport (Ο : Euc n β β) (a : Euc n) : | |
| tsupport (scalarDirection Ο a) β tsupport Ο := by | |
| apply closure_minimal _ (isClosed_tsupport _) | |
| intro x hx | |
| by_contra hh | |
| exact hx (by simp [scalarDirection,fderiv_of_notMem_tsupport β hh]) | |
| theorem scalarDirection_fderiv {Ο : Euc n β β} (hΟ : ContDiff β β Ο) | |
| (a x b : Euc n) : | |
| fderiv β (scalarDirection Ο a) x b=fderiv β (fderiv β Ο) x b a := by | |
| have hd : ContDiff β β (fderiv β Ο) := hΟ.fderiv_right (by simp) | |
| have h := ((ContinuousLinearMap.apply β β a).hasFDerivAt.comp x | |
| ((hd.differentiable (by simp)) x).hasFDerivAt).fderiv | |
| exact congrArg (fun L : Euc n βL[β] β β¦ L b) h | |
| def directionLocalTest {U : Set (Euc n)} (Ο : SmoothLocalTest U) (a : Euc n) : SmoothLocalTest U := | |
| β¨scalarDirection Ο.val a,scalarDirection_contDiff Ο.property.1 a, | |
| Ο.property.2.1.of_isClosed_subset (isClosed_tsupport _) (scalarDirection_tsupport _ _), | |
| (scalarDirection_tsupport _ _).trans Ο.property.2.2β© | |
| def curlTest (Ο : Euc n β β) (a b : Euc n) (x : Euc n) : Euc n := | |
| scalarDirection Ο a x β’ b - scalarDirection Ο b x β’ a | |
| theorem curlTest_contDiff {Ο : Euc n β β} (hΟ : ContDiff β β Ο) (a b : Euc n) : | |
| ContDiff β β (curlTest Ο a b) := | |
| ((scalarDirection_contDiff hΟ a).smul contDiff_const).sub | |
| ((scalarDirection_contDiff hΟ b).smul contDiff_const) | |
| theorem curlTest_tsupport (Ο : Euc n β β) (a b : Euc n) : | |
| tsupport (curlTest Ο a b) β tsupport Ο := by | |
| apply closure_minimal _ (isClosed_tsupport _) | |
| intro x hx | |
| by_contra hh | |
| exact hx (by simp [curlTest,scalarDirection,fderiv_of_notMem_tsupport β hh]) | |
| theorem curlTest_divergence {Ο : Euc n β β} (hΟ : ContDiff β β Ο) (a b : Euc n) : | |
| divergence (curlTest Ο a b)=0 := by | |
| have ha := (scalarDirection_contDiff hΟ a).differentiable (by simp) | |
| have hb := (scalarDirection_contDiff hΟ b).differentiable (by simp) | |
| rw [show curlTest Ο a b=(fun x β¦ scalarDirection Ο a x β’ b)-(fun x β¦ scalarDirection Ο b x β’ a) from rfl, | |
| divergence_sub (ha.smul_const b) (hb.smul_const a),divergence_scalar_direction ha, | |
| divergence_scalar_direction hb] | |
| funext x | |
| simp only [Pi.sub_apply,Pi.zero_apply,scalarDirection_fderiv hΟ] | |
| exact sub_eq_zero.mpr ((hΟ.contDiffAt.isSymmSndFDerivAt (by simp only [minSmoothness_of_isRCLikeNormedField]; exact WithTop.coe_le_coe.mpr le_top)) b a) | |
| def curlTestLp {U : Set (Euc n)} (Ο : SmoothLocalTest U) (a b : Euc n) : VectorL2 n := | |
| ((curlTest_contDiff Ο.property.1 a b).continuous.memLp_of_hasCompactSupport | |
| (Ο.property.2.1.of_isClosed_subset (isClosed_tsupport _) (curlTest_tsupport _ _ _))).toLp | |
| (curlTest Ο.val a b) | |
| theorem curlTestLp_ae {U : Set (Euc n)} (Ο : SmoothLocalTest U) (a b : Euc n) : | |
| (curlTestLp Ο a b : Euc n β Euc n)=α΅[volume] curlTest Ο.val a b := MemLp.coeFn_toLp _ | |
| def CurlFreeLpOn (u : VectorL2 n) (U : Set (Euc n)) : Prop := | |
| β (Ο : SmoothLocalTest U) (a b : Euc n), inner β u (curlTestLp Ο a b)=0 | |
| theorem testGradient_curlTest_inner {U V : Set (Euc n)} (Ο : SmoothLocalTest V) | |
| (Ο : SmoothLocalTest U) (a b : Euc n) : | |
| inner β (testGradientLp Ο) (curlTestLp Ο a b)=0 := by | |
| rw [MeasureTheory.L2.inner_def] | |
| have he : (β« x, inner β (testGradientLp Ο x) (curlTestLp Ο a b x))= | |
| β« x, inner β (gradient Ο.val x) (curlTest Ο.val a b x) := by | |
| apply integral_congr_ae | |
| filter_upwards [testGradientLp_ae Ο,curlTestLp_ae Ο a b] with x hx hy | |
| rw [hx,hy] | |
| rw [he] | |
| have hi := integral_mul_divergence_eq_neg_inner_gradient_local Ο.property.1 | |
| (curlTest_contDiff Ο.property.1 a b) | |
| (Ο.property.2.1.of_isClosed_subset (isClosed_tsupport _) (curlTest_tsupport _ _ _)) | |
| rw [curlTest_divergence Ο.property.1] at hi | |
| simpa only [Pi.zero_apply,mul_zero,integral_zero,eq_neg_iff_add_eq_zero,zero_add] using hi | |
| theorem testGradientSpace_curlFree {U V : Set (Euc n)} {u : VectorL2 n} | |
| (hu : uβtestGradientSpace V) : CurlFreeLpOn u U := by | |
| intro Ο a b | |
| have hz := inner_zero_on_closed_span (Set.range (testGradientLp (U := V))) | |
| (u := curlTestLp Ο a b) (by | |
| rintro _ β¨Ο,rflβ© | |
| rw [real_inner_comm] | |
| exact testGradient_curlTest_inner Ο Ο a b) u hu | |
| rwa [real_inner_comm] at hz | |
| theorem CurlFreeLpOn.sub {U : Set (Euc n)} {u v : VectorL2 n} | |
| (hu : CurlFreeLpOn u U) (hv : CurlFreeLpOn v U) : CurlFreeLpOn (u-v) U := by | |
| intro Ο a b | |
| rw [inner_sub_left,hu Ο a b,hv Ο a b,sub_self] | |
| theorem weak_curl_harmonic_comparison {U : Set (Euc n)} {u e : VectorL2 n} | |
| (hu : CurlFreeLpOn u U) | |
| (h : β Ο : SmoothLocalTest U, (β« x, inner β (u x) (gradient Ο.val x))= | |
| β« x, inner β (e x) (gradient Ο.val x)) : | |
| β g : VectorL2 n, DivFreeLpOn g U β§ CurlFreeLpOn g U β§ βu-gββ€βeβ := by | |
| obtain β¨g,hg,hug,heβ© := weak_harmonic_gradient_comparison h | |
| have hcf := hu.sub (testGradientSpace_curlFree hug) | |
| rw [sub_sub_cancel] at hcf | |
| exact β¨g,hg,hcf,heβ© | |
| end RPISingularHarnack | |
| end | |
| end OAI | |