Download data/lean/OAI/Geometry/IsometricImmersion/Comparison/ActualComparisonGradient.lean from introvoyz045/math: direct link, hf CLI and curl.
- Browser
- Download file 6.95 kB
-
https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Geometry/IsometricImmersion/Comparison/ActualComparisonGradient.lean
- Command line
-
hf download hf://datasets/introvoyz045/math/data/lean/OAI/Geometry/IsometricImmersion/Comparison/ActualComparisonGradient.lean
-
curl -L -o ActualComparisonGradient.lean https://huggingface.co/datasets/introvoyz045/math/resolve/main/data/lean/OAI/Geometry/IsometricImmersion/Comparison/ActualComparisonGradient.lean
6.95 kB
| import OAI.Geometry.IsometricImmersion.Metrics.SmoothMetricRestriction | |
| import OAI.Geometry.IsometricImmersion.Comparison.ComparisonGradientSlice | |
| namespace OAI | |
| noncomputable section | |
| open Set Filter MeasureTheory | |
| open scoped ContDiff Topology | |
| namespace SmoothLocal.HighEquation | |
| open SmoothLocal.Geometry SmoothLocal.Weighted SmoothLocal.ODE | |
| open SmoothLocal.Hyperbolic SmoothLocal.Taylor | |
| theorem exists_actual_comparison_gradient | |
| {gRef : MetricField} {U S : Set Coord} | |
| (hgRef : SmoothPositiveOn gRef U) (hU : IsOpen U) | |
| (hS : IsCompact S) (hSU : S β U) | |
| (R Z0 Z : β) (hR : 0 β€ R) {c s0 : β} (hc : 0 < c) (hs0 : 0 < s0) : | |
| β C : β, 1 β€ C β§ β (g : MetricField) (P z : Coord β β) (V : Set Coord) | |
| (boxRadius width pulseRadius a b F : β), | |
| IsOpen V β V β U β SmoothPositiveOn g V β | |
| ContDiffOn β β P V β ContDiffOn β β z V β | |
| 0 < width β width < boxRadius β a β€ b β | |
| closedRectangle (-boxRadius) boxRadius a b β V β | |
| closedRectangle (-boxRadius) boxRadius a b β S β | |
| (β p β closedRectangle (-boxRadius) boxRadius a b, βpβ β€ R) β | |
| CoordinateBound P (closedRectangle (-boxRadius) boxRadius a b) 3 Z0 β | |
| CoordinateBound z (closedRectangle (-boxRadius) boxRadius a b) 3 Z β | |
| (β p β closedRectangle (-boxRadius) boxRadius a b, | |
| (covHessian g z p).det = gaussianCurvature g p*heightEnergy g z p) β | |
| (β p β closedRectangle (-boxRadius) boxRadius a b, covHessian g z p 0 0 β 0) β | |
| (β p β closedRectangle (-boxRadius) boxRadius a b, β sigma β Icc (0 : β) 1, | |
| c β€ |stateQDenominator gRef (qHeightJetSegment P z sigma p)| β§ | |
| s0 β€ qFirstCoefficient gRef 5 (qHeightJetSegment P z sigma p)) β | |
| (β x β Ioo (-boxRadius) boxRadius, P (boxPoint x a)=z (boxPoint x a)) β | |
| (β x β Ioo (-boxRadius) boxRadius, | |
| coordPartial 1 P (boxPoint x a)=coordPartial 1 z (boxPoint x a)) β | |
| 0 < pulseRadius β 0 β€ F β | |
| comparisonEnergySpeed C*(b-a) β€ width-pulseRadius β | |
| (β p β closedRectangle (-boxRadius) boxRadius a b, |metricComparisonSource g gRef P z p| β€ F) β | |
| β t β Icc a b, β i : Fin 2, | |
| Real.sqrt (β« x in Icc (-pulseRadius) pulseRadius, | |
| (coordPartial i (comparisonDifference P z) (boxPoint x t))^2) β€ | |
| Real.sqrt (2*(1+1/s0))* | |
| (Real.exp (comparisonEnergyRate C Z0 Z s0*(b-a))*F*Real.sqrt (2*width)*(b-a)) := by | |
| obtain β¨C,hC,henergyβ© := exists_actual_comparison_energy hgRef hU hS hSU R Z0 Z hR hc hs0 | |
| refine β¨C,hC,?_β© | |
| intro g P z V boxRadius width pulseRadius a b F hV hVU hg hP hz hw hwR hab | |
| hboxV hboxS hpB hPZ hzZ hD hxx hmargin hvalue hvelocity hpulse hF hwidth hsource | |
| let T := closedRectangle (-boxRadius) boxRadius a b | |
| let speed := comparisonEnergySpeed C | |
| let rate := comparisonEnergyRate C Z0 Z s0 | |
| have hs : 0 β€ speed := add_nonneg (zero_le_one.trans hC) (Real.sqrt_nonneg _) | |
| have hr : 0 β€ rate := by unfold rate comparisonEnergyRate; positivity | |
| have hlength : 2*speed*(b-a)<2*width := by linarith | |
| have hgRefV := hgRef.mono hVU | |
| have hseg : β p β T, β sigma β Icc (0 : β) 1, | |
| qHeightJetSegment P z sigma p β darbouxQStateDomain gRef V := by | |
| intro p hp sigma hsigma | |
| exact β¨by simpa only [statePoint_qHeightJetSegment] using hboxV hp, | |
| abs_pos.mp (hc.trans_le (hmargin p hp sigma hsigma).1)β© | |
| obtain β¨W,hW,hTW,hWV,_,hWsmoothβ© := exists_comparison_coefficient_neighborhood | |
| hgRefV hV hP hz (closedRectangle_compact _ _ _ _) hboxV hseg | |
| have hSlabT {t : β} (ht : t β Icc a b) : shrinkingSlab (-width) width a t speed β T := by | |
| intro p hp | |
| change p 1 β Icc a t β§ p 0 β Icc (-width+speed*(p 1-a)) (width-speed*(p 1-a)) at hp | |
| have hinc : 0 β€ speed*(p 1-a) := mul_nonneg hs (sub_nonneg.mpr hp.1.1) | |
| exact β¨β¨by linarith [hp.2.1], | |
| by linarith [hp.2.2]β©,β¨hp.1.1,hp.1.2.trans ht.2β©β© | |
| intro t ht i | |
| have hTT : closedRectangle (-boxRadius) boxRadius a t β T := | |
| fun p hp => β¨hp.1,β¨hp.2.1,hp.2.2.trans ht.2β©β© | |
| have hlengtht : 2*speed*(t-a)<2*width := by | |
| have hm := mul_le_mul_of_nonneg_left (sub_le_sub_right ht.2 a) (mul_nonneg (by norm_num : (0 : β) β€ 2) hs) | |
| exact hm.trans_lt hlength | |
| have hEt := henergy g P z V boxRadius width a t hV hVU hg hP hz hw hwR ht.1 | |
| (hTT.trans hboxV) (hTT.trans hboxS) (fun p hp => hpB p (hTT hp)) | |
| (fun ds hds p hp => hPZ ds hds p (hTT hp)) (fun ds hds p hp => hzZ ds hds p (hTT hp)) | |
| (fun p hp => hD p (hTT hp)) (fun p hp => hxx p (hTT hp)) | |
| (fun p hp sigma hsigma => hmargin p (hTT hp) sigma hsigma) hvalue hvelocity hlengtht | |
| have horder (s : β) (hsat : s β Icc a t) : | |
| inwardLeft (-width) a speed s β€ inwardRight width a speed s := by | |
| have hm := mul_le_mul_of_nonneg_left (sub_le_sub_right hsat.2 a) hs | |
| dsimp [inwardLeft,inwardRight] | |
| linarith | |
| have hI := integrated_movingSourceNorm_le_of_pointwise_bound ht.1 hs hF horder | |
| (fun p hp => hsource p (hSlabT ht hp)) | |
| have hE : Real.sqrt (movingEnergy (-width) width a speed (comparisonCoefficient gRef P z 5) | |
| (comparisonDifference P z) t) β€ Real.exp (rate*(b-a))*F*Real.sqrt (2*width)*(b-a) := by | |
| have hI' : (β« s in a..t, movingSourceNorm (-width) width a speed | |
| (metricComparisonSource g gRef P z) s) β€ F*Real.sqrt (2*width)*(t-a) := by | |
| simpa only [sub_neg_eq_add,βtwo_mul] using hI | |
| have h0 := hEt.trans (mul_le_mul_of_nonneg_left hI' (Real.exp_pos _).le) | |
| have hexp : Real.exp (rate*(t-a)) β€ Real.exp (rate*(b-a)) := | |
| Real.exp_le_exp.mpr (mul_le_mul_of_nonneg_left (sub_le_sub_right ht.2 a) hr) | |
| have htime : F*Real.sqrt (2*width)*(t-a) β€ F*Real.sqrt (2*width)*(b-a) := | |
| mul_le_mul_of_nonneg_left (sub_le_sub_right ht.2 a) (mul_nonneg hF (Real.sqrt_nonneg _)) | |
| have hprod := mul_le_mul hexp htime | |
| (mul_nonneg (mul_nonneg hF (Real.sqrt_nonneg _)) (sub_nonneg.mpr ht.1)) (Real.exp_pos _).le | |
| apply h0.trans | |
| convert hprod using 1 | |
| first | rfl | ring | |
| have hcover : inwardLeft (-width) a speed t β€ -pulseRadius β§ | |
| pulseRadius β€ inwardRight width a speed t := by | |
| have hm := mul_le_mul_of_nonneg_left (sub_le_sub_right ht.2 a) hs | |
| dsimp [inwardLeft,inwardRight] | |
| constructor <;> linarith | |
| have hgrad := fixed_slice_gradient_le_moving_energy hW (hWsmooth 5).continuousOn | |
| ((hz.mono hWV).sub (hP.mono hWV)) hs0 hpulse.le hcover.1 hcover.2 | |
| (fun x hx => hTW (hSlabT ht (point_mem_shrinkingSlab β¨ht.1,le_rflβ© hx))) | |
| (fun x hx => averagedQCoefficient_lower hgRefV hV | |
| (hseg _ (hSlabT ht (point_mem_shrinkingSlab β¨ht.1,le_rflβ© hx))) 5 | |
| (fun sigma hsigma => (hmargin _ (hSlabT ht (point_mem_shrinkingSlab β¨ht.1,le_rflβ© hx)) sigma hsigma).2)) i | |
| exact hgrad.trans (mul_le_mul_of_nonneg_left hE (Real.sqrt_nonneg _)) | |
| end SmoothLocal.HighEquation | |
| end | |
| end OAI | |