math / data /lean /OAI /Probability /SKFluctuations /ClockSampledRate.lean
introvoyz045's picture
Migrated from GitHub
4a56cd6 verified
Raw History Blame Contribute Delete
34.1 kB
import Mathlib
import OAI.Probability.SKFluctuations.ClockPathPairMeasurable
namespace OAI
/-! Clock Sampled Rate. -/
noncomputable section
namespace SKFluctuations.Hierarchy
open MeasureTheory ProbabilityTheory Filter Set
open scoped Topology NNReal BigOperators
attribute [local instance] Classical.propDecidable
variable {S ΞΉ : Type*} [Fintype S] [Nonempty S] [Fintype ΞΉ] [Nonempty ΞΉ]
omit [Nonempty S] in
theorem sampledPairMoment_eq (w : S β†’ ℝ) (Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ)
(q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0) (hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(as : List PositiveMass) (ha : MassOrdered 0 as) (P : S β†’ S β†’ ℝ) (u : ℝ) :
stepPairMoment w Ο† (q 0) (sampleClockSteps q 0 as) (sampleClockSteps_ordered q as ha).mem_pos P u=
massStepFunction as (fun j => cumulativePair w Ο† as
(fun j i => (q (partitionPoint 0 as j) i:ℝ)) j P) u := by
unfold stepPairMoment
rw [sampleClockSteps_masses]
congr 2
funext j
congr 2
funext k i
rw [sampleClockSteps_values q hq as ha,partitionValues_point]
theorem massStepFunction_sub (as : List PositiveMass) (f g : β„• β†’ ℝ) (u : ℝ) :
massStepFunction as (fun j => f j-g j) u=massStepFunction as f u-massStepFunction as g u := by
induction as generalizing f g with
| nil => rfl
| cons a as ih => simp only [massStepFunction]; split_ifs <;> simp_all
theorem sampledPressureRate_integral {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(K : ℝ β†’ ΞΉ β†’ ℝ) (as : List PositiveMass) (ha : MassOrdered 0 as) :
pressureRate w Ο† as (fun j i => (q (partitionPoint 0 as j) i:ℝ))
(fun j i => K (partitionPoint 0 as j) i)=
-(1/2:ℝ)*βˆ‘ i, ∫ u in (0:ℝ)..1,
partitionSample (fun v => K v i) 0 as u *
stepPairMoment w Ο† (q 0) (sampleClockSteps q 0 as)
(sampleClockSteps_ordered q as ha).mem_pos (coordinatePairTest Ο† i) u := by
rw [pressureRate_integral hw Ο† as ha]
congr 1
apply Finset.sum_congr rfl
intro i _
apply intervalIntegral.integral_congr
intro u _
dsimp only
rw [sampledPairMoment_eq w Ο† q hq as ha]
congr 1
unfold partitionSample
congr 1
funext j
exact (partitionValues_point (fun v => K v i) 0 as j).symm
omit [Fintype S] [Nonempty S] [Fintype ΞΉ] [Nonempty ΞΉ] in
theorem coordinatePairTest_bound (Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (D : ΞΉ β†’ ℝ)
(hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i) (i : ΞΉ) (Οƒ Ο„ : S) :
|coordinatePairTest Ο† i Οƒ Ο„|≀(D i)^2 := by
unfold coordinatePairTest
rw [abs_mul,pow_two]
exact mul_le_mul (hφ σ i) (hφ τ i) (abs_nonneg _) ((abs_nonneg _).trans (hφ σ i))
omit [Fintype ΞΉ] [Nonempty ΞΉ] in
theorem clockDirection_bound (q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
{u : ℝ} (hu : u ∈ Icc (0:ℝ) 1) (i : ΞΉ) :
|(r u i:ℝ)-(q u i:ℝ)|≀(r 1 i:ℝ)+(q 1 i:ℝ) := by
apply (abs_sub _ _).trans
simp only [abs_of_nonneg (NNReal.coe_nonneg _)]
exact add_le_add (by exact_mod_cast hr i hu (by constructor <;> norm_num) hu.2)
(by exact_mod_cast hq i hu (by constructor <;> norm_num) hu.2)
theorem partitionSample_sub (q r : ℝ β†’ ℝ) (a : ℝ) (as : List PositiveMass) (u : ℝ) :
partitionSample (fun v => r v-q v) a as u=partitionSample r a as u-partitionSample q a as u := by
rw [partitionSample_comp (fun v => r v-q v),partitionSample_comp r,partitionSample_comp q]
omit [Fintype ΞΉ] [Nonempty ΞΉ] in
theorem clockDirection_intervalIntegrable (q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1)) (i : ΞΉ) :
IntervalIntegrable (fun u => (r u i:ℝ)-(q u i:ℝ)) volume 0 1 := by
have hi (p : ℝ β†’ ΞΉ β†’ ℝβ‰₯0) (hp : βˆ€ i, MonotoneOn (fun u => p u i) (Icc (0:ℝ) 1)) :
IntervalIntegrable (fun u => (p u i:ℝ)) volume 0 1 := by
apply MonotoneOn.intervalIntegrable
rw [uIcc_of_le (by norm_num)]
exact fun u hu v hv huv => by exact_mod_cast hp i hu hv huv
exact (hi r hr).sub (hi q hq)
omit [Fintype ΞΉ] [Nonempty ΞΉ] in
theorem sampledClockDirection_l1_bound (q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
(as : List PositiveMass) (ha : MassOrdered 0 as) {h : ℝ} (hm : PartitionMesh h 0 as) (i : ΞΉ) :
(∫ u in (0:ℝ)..1, |partitionSample (fun v => (r v i:ℝ)-(q v i:ℝ)) 0 as u-
((r u i:ℝ)-(q u i:ℝ))|) ≀ h*((r 1 i:ℝ)-(r 0 i:ℝ)+((q 1 i:ℝ)-(q 0 i:ℝ))) := by
have hi (p : ℝ β†’ ΞΉ β†’ ℝβ‰₯0) (hp : βˆ€ i, MonotoneOn (fun u => p u i) (Icc (0:ℝ) 1)) :
IntervalIntegrable (fun u => (p u i:ℝ)) volume 0 1 := by
apply MonotoneOn.intervalIntegrable
rw [uIcc_of_le (by norm_num)]
exact fun u hu v hv huv => by exact_mod_cast hp i hu hv huv
have hiq := ((partitionSample_intervalIntegrable (fun u => (q u i:ℝ)) 0 as 0 1).sub (hi q hq)).abs
have hir := ((partitionSample_intervalIntegrable (fun u => (r u i:ℝ)) 0 as 0 1).sub (hi r hr)).abs
calc
_ ≀ ∫ u in (0:ℝ)..1, |partitionSample (fun v => (r v i:ℝ)) 0 as u-(r u i:ℝ)|+
|partitionSample (fun v => (q v i:ℝ)) 0 as u-(q u i:ℝ)| := by
apply intervalIntegral.integral_mono_on_of_le_Ioo (by norm_num)
((partitionSample_intervalIntegrable _ _ _ _ _).sub (clockDirection_intervalIntegrable q r hq hr i)).abs (hir.add hiq)
intro u _
rw [partitionSample_sub]
convert abs_sub (partitionSample (fun v => (r v i:ℝ)) 0 as u-(r u i:ℝ))
(partitionSample (fun v => (q v i:ℝ)) 0 as u-(q u i:ℝ)) using 1; congr 1; ring
_ = (∫ u in (0:ℝ)..1, |partitionSample (fun v => (r v i:ℝ)) 0 as u-(r u i:ℝ)|)+
(∫ u in (0:ℝ)..1, |partitionSample (fun v => (q v i:ℝ)) 0 as u-(q u i:ℝ)|) :=
intervalIntegral.integral_add hir hiq
_ ≀ _ := by
have hbq := partitionSample_l1_error (fun u hu v hv huv => show (q u i:ℝ)≀(q v i:ℝ) by exact_mod_cast hq i hu hv huv) as ha hm
have hbr := partitionSample_l1_error (fun u hu v hv huv => show (r u i:ℝ)≀(r v i:ℝ) by exact_mod_cast hr i hu hv huv) as ha hm
simpa only [abs_sub_comm,mul_add] using add_le_add hbr hbq
end SKFluctuations.Hierarchy
namespace SKFluctuations.Hierarchy
open MeasureTheory ProbabilityTheory Filter Set
open scoped Topology NNReal BigOperators
theorem intervalIntegrable_mul_bounded {f g : ℝ β†’ ℝ}
(hf : IntervalIntegrable f volume 0 1) (hg : IntervalIntegrable g volume 0 1)
{K : ℝ} (hK : βˆ€ u ∈ Ioc (0:ℝ) 1, |g u|≀K) :
IntervalIntegrable (fun u => f u*g u) volume 0 1 := by
rw [intervalIntegrable_iff_integrableOn_Ioc_of_le (by norm_num)] at hf hg ⊒
apply hf.mul_bdd hg.aestronglyMeasurable
filter_upwards [ae_restrict_mem measurableSet_Ioc] with u hu
simpa only [Real.norm_eq_abs] using hK u hu
theorem integral_product_error_le {f g fn gn : ℝ β†’ ℝ}
(hf : IntervalIntegrable f volume 0 1) (hg : IntervalIntegrable g volume 0 1)
(hfn : IntervalIntegrable fn volume 0 1) (hgn : IntervalIntegrable gn volume 0 1)
{M K : ℝ} (hM : βˆ€ u ∈ Ioc (0:ℝ) 1, |f u|≀M)
(hK : βˆ€ u ∈ Ioc (0:ℝ) 1, |gn u|≀K) :
|(∫ u in (0:ℝ)..1, fn u*gn u)-(∫ u in (0:ℝ)..1, f u*g u)| ≀
M*(∫ u in (0:ℝ)..1, |gn u-g u|)+K*(∫ u in (0:ℝ)..1, |fn u-f u|) := by
have hin := intervalIntegrable_mul_bounded hfn hgn hK
have hi : IntervalIntegrable (fun u => f u*g u) volume 0 1 := by
simpa only [mul_comm] using intervalIntegrable_mul_bounded hg hf hM
rw [←intervalIntegral.integral_sub hin hi]
apply (show |∫ u in (0:ℝ)..1, fn u*gn u-f u*g u| ≀
∫ u in (0:ℝ)..1, |fn u*gn u-f u*g u| from by
simpa only [Real.norm_eq_abs] using intervalIntegral.norm_integral_le_integral_norm (f := fun u => fn u*gn u-f u*g u) (by norm_num : (0:ℝ)≀1)).trans
calc
_ ≀ ∫ u in (0:ℝ)..1, M*|gn u-g u|+K*|fn u-f u| := by
apply intervalIntegral.integral_mono_on_of_le_Ioo (by norm_num) (hin.sub hi).abs
(((hgn.sub hg).abs.const_mul M).add ((hfn.sub hf).abs.const_mul K))
intro u hu
have hu' : u ∈ Ioc (0:ℝ) 1 := ⟨hu.1,hu.2.le⟩
calc
_ = |f u*(gn u-g u)+(fn u-f u)*gn u| := by congr 1; ring
_ ≀ |f u*(gn u-g u)|+|(fn u-f u)*gn u| := abs_add_le _ _
_ = |f u| *|gn u-g u|+|gn u| *|fn u-f u| := by rw [abs_mul,abs_mul]; ring
_ ≀ _ := add_le_add (mul_le_mul_of_nonneg_right (hM u hu') (abs_nonneg _))
(mul_le_mul_of_nonneg_right (hK u hu') (abs_nonneg _))
_ = _ := by
rw [intervalIntegral.integral_add ((hgn.sub hg).abs.const_mul M) ((hfn.sub hf).abs.const_mul K),
intervalIntegral.integral_const_mul,intervalIntegral.integral_const_mul]
attribute [local instance] Classical.propDecidable
variable {S ΞΉ : Type*} [Fintype S] [Nonempty S] [Fintype ΞΉ] [Nonempty ΞΉ]
theorem sampledRateCoordinate_error {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (D : ΞΉ β†’ ℝ) (hD : βˆ€ i, 0≀D i)
(hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i)
(p q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hp : βˆ€ i, MonotoneOn (fun u => p u i) (Icc (0:ℝ) 1))
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
(as : List PositiveMass) (ha : MassOrdered 0 as) (he : partitionEnd 0 as=1)
{h : ℝ} (hm : PartitionMesh h 0 as) (i : ΞΉ) :
|(∫ u in (0:ℝ)..1, partitionSample (fun v => (r v i:ℝ)-(q v i:ℝ)) 0 as u *
stepPairMoment w Ο† (p 0) (sampleClockSteps p 0 as)
(sampleClockSteps_ordered p as ha).mem_pos (coordinatePairTest Ο† i) u)-
(∫ u in (0:ℝ)..1, ((r u i:ℝ)-(q u i:ℝ))*pathPairMoment w Ο† p (coordinatePairTest Ο† i) u)| ≀
((r 1 i:ℝ)+(q 1 i:ℝ))*(ClockTree.errorJetVariation 2 0 0*(D i)^2*(4*h*clockVariationBound D p))+
(D i)^2*(h*((r 1 i:ℝ)-(r 0 i:ℝ)+((q 1 i:ℝ)-(q 0 i:ℝ)))) := by
have htest := coordinatePairTest_bound φ D hφ i
have hi := integral_product_error_le (clockDirection_intervalIntegrable q r hq hr i)
(pathPairMoment_intervalIntegrable hw φ D hD hφ p hp _ (sq_nonneg _) htest)
(partitionSample_intervalIntegrable (fun v => (r v i:ℝ)-(q v i:ℝ)) 0 as 0 1)
(stepPairMoment_intervalIntegrable w Ο† (p 0) (sampleClockSteps p 0 as)
(sampleClockSteps_ordered p as ha).mem_pos (coordinatePairTest Ο† i) 0 1)
(fun u hu => clockDirection_bound q r hq hr ⟨hu.1.le,hu.2⟩ i)
(fun u _ => stepPairMoment_bound hw Ο† (p 0) _ (sampleClockSteps_ordered p as ha) _ htest u)
apply hi.trans
exact add_le_add
(mul_le_mul_of_nonneg_left (sampledPairMoment_l1_bound hw φ D hD hφ p hp as ha he hm _ (sq_nonneg _) htest)
(add_nonneg (NNReal.coe_nonneg _) (NNReal.coe_nonneg _)))
(mul_le_mul_of_nonneg_left (sampledClockDirection_l1_bound q r hq hr as ha hm i) (sq_nonneg _))
end SKFluctuations.Hierarchy
namespace SKFluctuations.Hierarchy
open MeasureTheory ProbabilityTheory Filter Set
open scoped Topology NNReal BigOperators
attribute [local instance] Classical.propDecidable
variable {S ΞΉ : Type*} [Fintype S] [Nonempty S] [Fintype ΞΉ] [Nonempty ΞΉ]
def pathPressureRate (w : S β†’ ℝ) (Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ)
(p : ℝ β†’ ΞΉ β†’ ℝβ‰₯0) (K : ℝ β†’ ΞΉ β†’ ℝ) : ℝ :=
-(1/2:ℝ)*βˆ‘ i, ∫ u in (0:ℝ)..1, K u i*pathPairMoment w Ο† p (coordinatePairTest Ο† i) u
def pathRateApproxConstant (D : ΞΉ β†’ ℝ) (q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0) : ℝ :=
(1/2:ℝ)*(βˆ‘ i, (((r 1 i:ℝ)+(q 1 i:ℝ))*ClockTree.errorJetVariation 2 0 0*(D i)^2*4*
(clockVariationBound D q+clockVariationBound D r)+
(D i)^2*((r 1 i:ℝ)-(r 0 i:ℝ)+((q 1 i:ℝ)-(q 0 i:ℝ)))))
theorem sampledAffineRate_error {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (D : ΞΉ β†’ ℝ) (hD : βˆ€ i, 0≀D i)
(hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i)
(q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
(as : List PositiveMass) (ha : MassOrdered 0 as) (he : partitionEnd 0 as=1)
{h : ℝ} (hh : 0≀h) (hm : PartitionMesh h 0 as)
{t : ℝ} (ht : t ∈ Icc (0:ℝ) 1) :
|pressureRate w Ο† as (fun j i => (affineClockPath q r t (partitionPoint 0 as j) i:ℝ))
(fun j i => (r (partitionPoint 0 as j) i:ℝ)-(q (partitionPoint 0 as j) i:ℝ))-
pathPressureRate w Ο† (affineClockPath q r t) (fun u i => (r u i:ℝ)-(q u i:ℝ))| ≀
h*pathRateApproxConstant D q r := by
let p := affineClockPath q r t
have hp := affineClockPath_monotone q r hq hr t
rw [sampledPressureRate_integral hw Ο† _ hp (fun u i => (r u i:ℝ)-(q u i:ℝ)) as ha]
unfold pathPressureRate
rw [←mul_sub,abs_mul,←Finset.sum_sub_distrib]
norm_num only [abs_neg,abs_div,abs_one,abs_of_nonneg (by norm_num : (0:ℝ)≀2)]
apply (mul_le_mul_of_nonneg_left (Finset.abs_sum_le_sum_abs _ _) (by norm_num : (0:ℝ)≀1/2)).trans
calc
_ ≀ (1/2:ℝ)*βˆ‘ i, h*(((r 1 i:ℝ)+(q 1 i:ℝ))*ClockTree.errorJetVariation 2 0 0*(D i)^2*4*
(clockVariationBound D q+clockVariationBound D r)+
(D i)^2*((r 1 i:ℝ)-(r 0 i:ℝ)+((q 1 i:ℝ)-(q 0 i:ℝ)))) := by
apply mul_le_mul_of_nonneg_left _ (by norm_num)
apply Finset.sum_le_sum
intro i _
apply (sampledRateCoordinate_error hw φ D hD hφ p q r hp hq hr as ha he hm i).trans
have hv := mul_le_mul_of_nonneg_left (affineClockPath_variation_le D q r hq hr ht)
(show 0≀((r 1 i:ℝ)+(q 1 i:ℝ))*ClockTree.errorJetVariation 2 0 0*(D i)^2*(4*h) from by
apply mul_nonneg
Β· exact mul_nonneg (mul_nonneg (add_nonneg (NNReal.coe_nonneg _) (NNReal.coe_nonneg _))
(ClockTree.errorJetVariation_nonneg _ _ _)) (sq_nonneg _)
Β· positivity)
dsimp [p]
nlinarith only [hv]
_ = _ := by rw [←Finset.mul_sum]; unfold pathRateApproxConstant; ring
theorem pathDisorderPressure_hasDerivAt_bounded {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (C D : ΞΉ β†’ ℝ)
(hself : βˆ€ Οƒ i, (Ο† Οƒ (Pi.single i 1))^2=C i)
(hD : βˆ€ i, 0≀D i) (hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i)
(q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
{t : ℝ} (ht : t ∈ Ioo (0:ℝ) 1) :
HasDerivAt (fun s => pathDisorderPressure w Ο† C (affineClockPath q r s) 0)
(pathPressureRate w Ο† (affineClockPath q r t) (fun u i => (r u i:ℝ)-(q u i:ℝ))) t := by
have hlim : Tendsto (fun n : β„• => ((n+1:β„•):ℝ)⁻¹*pathRateApproxConstant D q r) atTop (𝓝 0) := by
simpa using uniformMasses_mesh_tendsto.mul_const (pathRateApproxConstant D q r)
have huni : TendstoUniformlyOn
(fun n s => pressureRate w Ο† (uniformMasses n)
(fun j i => (affineClockPath q r s (partitionPoint 0 (uniformMasses n) j) i:ℝ))
(fun j i => (r (partitionPoint 0 (uniformMasses n) j) i:ℝ)-(q (partitionPoint 0 (uniformMasses n) j) i:ℝ)))
(fun s => pathPressureRate w Ο† (affineClockPath q r s) (fun u i => (r u i:ℝ)-(q u i:ℝ))) atTop (Ioo (0:ℝ) 1) := by
apply Metric.tendstoUniformlyOn_iff.mpr
intro Ξ΅ hΞ΅
filter_upwards [hlim.eventually (gt_mem_nhds hΞ΅)] with n hn s hs
rw [Real.dist_eq,abs_sub_comm]
exact (sampledAffineRate_error hw φ D hD hφ q r hq hr (uniformMasses n)
(uniformMasses_ordered n) (uniformMasses_end n) (by positivity) (uniformMasses_mesh n) ⟨hs.1.le,hs.2.le⟩).trans_lt hn
apply hasDerivAt_of_tendstoUniformlyOn isOpen_Ioo huni
(Eventually.of_forall fun n s hs => sampledAffinePressure_hasDerivAt hw Ο† C hself q r hq hr
(uniformMasses n) (uniformMasses_ordered n) hs) _ ht
intro s hs
exact sampledDisorderPressure_tendsto hw φ C D hself (fun i σ => hφ σ i)
(affineClockPath q r s) (affineClockPath_monotone q r hq hr s) 0
theorem pathDisorderPressure_hasDerivAt {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (C : ΞΉ β†’ ℝ)
(hself : βˆ€ Οƒ i, (Ο† Οƒ (Pi.single i 1))^2=C i)
(q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
{t : ℝ} (ht : t ∈ Ioo (0:ℝ) 1) :
HasDerivAt (fun s => pathDisorderPressure w Ο† C (affineClockPath q r s) 0)
(pathPressureRate w Ο† (affineClockPath q r t) (fun u i => (r u i:ℝ)-(q u i:ℝ))) t := by
let D : ΞΉ β†’ ℝ := fun i => βˆ‘ Οƒ, |Ο† Οƒ (Pi.single i 1)|
have hD : βˆ€ i, 0≀D i := by intro i; exact Finset.sum_nonneg fun Οƒ _ => abs_nonneg _
have hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i := by
intro Οƒ i
exact Finset.single_le_sum (fun Ο„ _ => abs_nonneg (Ο† Ο„ (Pi.single i 1))) (Finset.mem_univ Οƒ)
exact pathDisorderPressure_hasDerivAt_bounded hw φ C D hself hD hφ q r hq hr ht
end SKFluctuations.Hierarchy
namespace SKFluctuations.Hierarchy
open MeasureTheory ProbabilityTheory Filter Set
open scoped Topology NNReal BigOperators
attribute [local instance] Classical.propDecidable
variable {S ΞΉ : Type*} [Fintype S] [Nonempty S] [Fintype ΞΉ] [Nonempty ΞΉ]
omit [Nonempty ΞΉ] in
theorem stepPairDisorder_finsetSum {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (v : ΞΉ β†’ ℝβ‰₯0)
(A B : List (GaussianStep ΞΉ)) (ho : OrderedSteps 0 (A++B))
{ΞΊ : Type*} (s : Finset ΞΊ) (P : ΞΊ β†’ S β†’ S β†’ ℝ) (x : ΞΉ β†’ ℝ) :
stepPairDisorder w Ο† v A B (fun Οƒ Ο„ => βˆ‘ i ∈ s, P i Οƒ Ο„) x=
βˆ‘ i ∈ s, stepPairDisorder w Ο† v A B (P i) x := by
have hA : βˆ€ t ∈ A, 0<t.1 := fun t ht => ho.mem_pos t (List.mem_append_left _ ht)
have hB : βˆ€ t ∈ B, 0<t.1 := fun t ht => ho.mem_pos t (List.mem_append_right _ ht)
have ha : MassOrdered 0 (positiveStepMasses A hA++positiveStepMasses B hB) := by
rw [←positiveStepMasses_append]
exact positiveStepMasses_ordered ho _
have he (P : S β†’ S β†’ ℝ) := congr_fun (ClockTree.pairDisorder_coordinates hw Ο† A B hA hB ho v P) x
simp_rw [←he]
exact ClockTree.disorderExpect_finsetSum hw Ο† _ ha _ _ s _ x
omit [Nonempty ΞΉ] in
theorem stepPairDisorder_const_mul {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (v : ΞΉ β†’ ℝβ‰₯0)
(A B : List (GaussianStep ΞΉ)) (ho : OrderedSteps 0 (A++B))
(P : S β†’ S β†’ ℝ) (c : ℝ) (x : ΞΉ β†’ ℝ) :
stepPairDisorder w Ο† v A B (fun Οƒ Ο„ => c*P Οƒ Ο„) x=
c*stepPairDisorder w Ο† v A B P x := by
have hA : βˆ€ t ∈ A, 0<t.1 := fun t ht => ho.mem_pos t (List.mem_append_left _ ht)
have hB : βˆ€ t ∈ B, 0<t.1 := fun t ht => ho.mem_pos t (List.mem_append_right _ ht)
have ha : MassOrdered 0 (positiveStepMasses A hA++positiveStepMasses B hB) := by
rw [←positiveStepMasses_append]
exact positiveStepMasses_ordered ho _
have he (P : S β†’ S β†’ ℝ) := congr_fun (ClockTree.pairDisorder_coordinates hw Ο† A B hA hB ho v P) x
simp_rw [←he]
exact ClockTree.disorderExpect_const_mul hw Ο† _ ha _ _ _ c x
omit [Fintype ΞΉ] [Nonempty ΞΉ] in
theorem retainedPairSample_ordered (q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0) (u : PositiveMass) (hu : u.val≀1)
(as : List PositiveMass) (ha : MassOrdered 0 as) :
OrderedSteps 0 ((sampleClockSteps q 0 (retainedBefore u as))++
sampleClockSteps q u.val (retainedAfter u as)) := by
have ho := retainedMasses_ordered u hu as ha
exact (sampleClockSteps_ordered q _ ho.1).append_bound u.property.le
(sampleClockSteps_mass_le q _ _ (retainedBefore_bounds u _)) (sampleClockSteps_ordered q _ ho.2)
theorem retainedPairSample_tendsto_all {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(u : PositiveMass) (hu : u.val≀1) (P : S β†’ S β†’ ℝ) (x : ΞΉ β†’ ℝ) :
Tendsto (fun k => retainedPairSample w Ο† q u (uniformMasses k) P x) atTop
(𝓝 (pathPairDisorder w Ο† q u P x)) := by
let D : ΞΉ β†’ ℝ := fun i => βˆ‘ Οƒ, |Ο† Οƒ (Pi.single i 1)|
have hD : βˆ€ i, 0≀D i := by intro i; exact Finset.sum_nonneg fun Οƒ _ => abs_nonneg _
have hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i := by
intro Οƒ i
exact Finset.single_le_sum (fun Ο„ _ => abs_nonneg (Ο† Ο„ (Pi.single i 1))) (Finset.mem_univ Οƒ)
let K : ℝ := βˆ‘ Οƒ, βˆ‘ Ο„, |P Οƒ Ο„|
have hK : 0≀K := by dsimp [K]; positivity
have hP (Οƒ Ο„ : S) : |P Οƒ Ο„|≀K := by
exact (Finset.single_le_sum (fun ρ _ => abs_nonneg (P Οƒ ρ)) (Finset.mem_univ Ο„)).trans
(Finset.single_le_sum (fun ρ _ => Finset.sum_nonneg fun Ξ· _ => abs_nonneg (P ρ Ξ·)) (Finset.mem_univ Οƒ))
exact retainedPairSample_tendsto hw φ D hD hφ q hq u hu P hK hP x
theorem pathPairMoment_finsetSum {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
{ΞΊ : Type*} (s : Finset ΞΊ) (P : ΞΊ β†’ S β†’ S β†’ ℝ)
{u : ℝ} (hu : u ∈ Ioc (0:ℝ) 1) :
pathPairMoment w Ο† q (fun Οƒ Ο„ => βˆ‘ i ∈ s, P i Οƒ Ο„) u=
βˆ‘ i ∈ s, pathPairMoment w Ο† q (P i) u := by
simp only [pathPairMoment,dite_eq_left hu.1]
have he (n : β„•) : retainedPairSample w Ο† q ⟨u,hu.1⟩ (uniformMasses n) (fun Οƒ Ο„ => βˆ‘ i ∈ s, P i Οƒ Ο„) 0=
βˆ‘ i ∈ s, retainedPairSample w Ο† q ⟨u,hu.1⟩ (uniformMasses n) (P i) 0 :=
stepPairDisorder_finsetSum hw Ο† _ _ _ (retainedPairSample_ordered q ⟨u,hu.1⟩ hu.2 _ (uniformMasses_ordered n)) s P 0
apply tendsto_nhds_unique (retainedPairSample_tendsto_all hw Ο† q hq ⟨u,hu.1⟩ hu.2 _ 0)
simp_rw [he]
exact tendsto_finsetSum s (fun i _ => retainedPairSample_tendsto_all hw Ο† q hq ⟨u,hu.1⟩ hu.2 (P i) 0)
theorem pathPairMoment_const_mul {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(P : S β†’ S β†’ ℝ) (c : ℝ) {u : ℝ} (hu : u ∈ Ioc (0:ℝ) 1) :
pathPairMoment w Ο† q (fun Οƒ Ο„ => c*P Οƒ Ο„) u=c*pathPairMoment w Ο† q P u := by
simp only [pathPairMoment,dite_eq_left hu.1]
have he (n : β„•) : retainedPairSample w Ο† q ⟨u,hu.1⟩ (uniformMasses n) (fun Οƒ Ο„ => c*P Οƒ Ο„) 0=
c*retainedPairSample w Ο† q ⟨u,hu.1⟩ (uniformMasses n) P 0 :=
stepPairDisorder_const_mul hw Ο† _ _ _ (retainedPairSample_ordered q ⟨u,hu.1⟩ hu.2 _ (uniformMasses_ordered n)) P c 0
apply tendsto_nhds_unique (retainedPairSample_tendsto_all hw Ο† q hq ⟨u,hu.1⟩ hu.2 _ 0)
simp_rw [he]
exact (retainedPairSample_tendsto_all hw Ο† q hq ⟨u,hu.1⟩ hu.2 P 0).const_mul c
end SKFluctuations.Hierarchy
namespace SKFluctuations.Hierarchy
open MeasureTheory ProbabilityTheory Filter Set
open scoped Topology NNReal BigOperators
attribute [local instance] Classical.propDecidable
variable {S ΞΉ : Type*} [Fintype S] [Nonempty S] [Fintype ΞΉ] [Nonempty ΞΉ]
theorem pathPairMoment_add {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(P Q : S β†’ S β†’ ℝ) {u : ℝ} (hu : u ∈ Ioc (0:ℝ) 1) :
pathPairMoment w Ο† q (fun Οƒ Ο„ => P Οƒ Ο„+Q Οƒ Ο„) u=
pathPairMoment w Ο† q P u+pathPairMoment w Ο† q Q u := by
have he := pathPairMoment_finsetSum hw Ο† q hq Finset.univ
(fun b : Bool => if b then P else Q) hu
simpa using he
theorem pathPairMoment_intervalIntegrable_all {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1)) (P : S β†’ S β†’ ℝ) :
IntervalIntegrable (pathPairMoment w Ο† q P) volume 0 1 := by
let D : ΞΉ β†’ ℝ := fun i => βˆ‘ Οƒ, |Ο† Οƒ (Pi.single i 1)|
have hD : βˆ€ i, 0≀D i := by intro i; exact Finset.sum_nonneg fun Οƒ _ => abs_nonneg _
have hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i := by
intro Οƒ i
exact Finset.single_le_sum (fun Ο„ _ => abs_nonneg (Ο† Ο„ (Pi.single i 1))) (Finset.mem_univ Οƒ)
let K : ℝ := βˆ‘ Οƒ, βˆ‘ Ο„, |P Οƒ Ο„|
have hK : 0≀K := by dsimp [K]; positivity
have hP (Οƒ Ο„ : S) : |P Οƒ Ο„|≀K := by
exact (Finset.single_le_sum (fun ρ _ => abs_nonneg (P Οƒ ρ)) (Finset.mem_univ Ο„)).trans
(Finset.single_le_sum (fun ρ _ => Finset.sum_nonneg fun Ξ· _ => abs_nonneg (P ρ Ξ·)) (Finset.mem_univ Οƒ))
exact pathPairMoment_intervalIntegrable hw φ D hD hφ q hq P hK hP
theorem pathPairMoment_featureKernel {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (q : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(K : ΞΉ β†’ ℝ) {u : ℝ} (hu : u ∈ Ioc (0:ℝ) 1) :
pathPairMoment w Ο† q (featureKernel Ο† K) u=
βˆ‘ i, K i*pathPairMoment w Ο† q (coordinatePairTest Ο† i) u := by
have he : featureKernel Ο† K = fun Οƒ Ο„ => βˆ‘ i, K i*coordinatePairTest Ο† i Οƒ Ο„ := by
funext Οƒ Ο„; simp only [featureKernel,coordinatePairTest]; congr 1; funext i; ring
rw [he,pathPairMoment_finsetSum hw Ο† q hq Finset.univ _ hu]
apply Finset.sum_congr rfl
intro i _
exact pathPairMoment_const_mul hw Ο† q hq _ (K i) hu
theorem pathPressureRate_integral {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (p q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hp : βˆ€ i, MonotoneOn (fun u => p u i) (Icc (0:ℝ) 1))
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1)) :
pathPressureRate w Ο† p (fun u i => (r u i:ℝ)-(q u i:ℝ))=
-(1/2:ℝ)*∫ u in (0:ℝ)..1,
pathPairMoment w Ο† p (featureKernel Ο† (fun i => (r u i:ℝ)-(q u i:ℝ))) u := by
have hi (i : ΞΉ) : IntervalIntegrable
(fun u => ((r u i:ℝ)-(q u i:ℝ))*pathPairMoment w Ο† p (coordinatePairTest Ο† i) u) volume 0 1 := by
simpa only [mul_comm] using intervalIntegrable_mul_bounded
(pathPairMoment_intervalIntegrable_all hw Ο† p hp _) (clockDirection_intervalIntegrable q r hq hr i)
(fun u hu => clockDirection_bound q r hq hr ⟨hu.1.le,hu.2⟩ i)
unfold pathPressureRate
rw [←intervalIntegral.integral_finsetSum (fun i _ => hi i)]
congr 1
apply intervalIntegral.integral_congr_ae
filter_upwards [] with u hu
rw [uIoc_of_le (by norm_num : (0:ℝ)≀1)] at hu
exact (pathPairMoment_featureKernel hw Ο† p hp _ hu).symm
end SKFluctuations.Hierarchy
namespace SKFluctuations.Hierarchy
open MeasureTheory ProbabilityTheory Filter Set
open scoped Topology NNReal BigOperators
attribute [local instance] Classical.propDecidable
variable {S ΞΉ : Type*} [Fintype S] [Nonempty S] [Fintype ΞΉ] [Nonempty ΞΉ]
omit [Nonempty ΞΉ] in
theorem clockCoordinateDistance_le (D C : ΞΉ β†’ ℝ) (q r : ΞΉ β†’ ℝ)
(h : βˆ€ i, |q i-r i|≀C i) :
clockCoordinateDistance D q rβ‰€βˆ‘ i, C i*(D i)^2 := by
apply Finset.sum_le_sum
intro i _
exact mul_le_mul_of_nonneg_right (h i) (sq_nonneg _)
theorem sampledPairDisorder_sup_comparison {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (D C : ΞΉ β†’ ℝ) (hD : βˆ€ i, 0≀D i)
(hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i)
(q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
(hC : βˆ€ u ∈ Icc (0:ℝ) 1, βˆ€ i, |(q u i:ℝ)-(r u i:ℝ)|≀C i)
(u : PositiveMass) (hu : u.val≀1) (as bs : List PositiveMass)
(ha : MassOrdered 0 as) (hb : MassOrdered u.val bs) (hau : βˆ€ a ∈ as, a.val≀u.val)
(heA : partitionEnd 0 as=u.val) (heB : partitionEnd u.val bs=1)
{m : ℝ} (hm : PartitionMesh m 0 (as++bs))
(P : S β†’ S β†’ ℝ) {K : ℝ} (hK : 0≀K) (hP : βˆ€ Οƒ Ο„, |P Οƒ Ο„|≀K) (x : ΞΉ β†’ ℝ) :
|sampledPairDisorder w Ο† q u.val as bs P x-sampledPairDisorder w Ο† r u.val as bs P x| ≀
ClockTree.errorJetVariation 2 0 0*K*(3*βˆ‘ i, C i*(D i)^2) := by
have hoa : MassOrdered 0 (as++bs) := ha.append_end (heA.symm β–Έ hb)
have he : partitionEnd 0 (as++bs)=1 := by rw [partitionEnd_append,heA,heB]
have hAB (p : ℝ β†’ ΞΉ β†’ ℝβ‰₯0) : sampleClockSteps p 0 as++sampleClockSteps p u.val bs=
sampleClockSteps p 0 (as++bs) := by rw [sampleClockSteps_append,heA]
have hh := stepPairDisorder_l1_comparison hw φ D hD hφ (q 0) (r 0)
(sampleClockSteps q 0 as) (sampleClockSteps q u.val bs)
(sampleClockSteps r 0 as) (sampleClockSteps r u.val bs) u.property.le
(sampleClockSteps_ordered q as ha) (sampleClockSteps_ordered q bs hb)
(sampleClockSteps_ordered r as ha) (sampleClockSteps_ordered r bs hb)
(sampleClockSteps_mass_le q 0 as hau) (sampleClockSteps_mass_le r 0 as hau) P hK hP x
rw [sampleClockSteps_terminal q hq 0 as ha,sampleClockSteps_terminal r hr 0 as ha,heA,
hAB q,hAB r,sampleClockSteps_terminal q hq 0 (as++bs) hoa,
sampleClockSteps_terminal r hr 0 (as++bs) hoa,he] at hh
have hi := clockCoordinateDistance_intervalIntegrable D
(stepClockFunction (fun i => (q 0 i:ℝ)) (sampleClockSteps q 0 (as++bs)))
(stepClockFunction (fun i => (r 0 i:ℝ)) (sampleClockSteps r 0 (as++bs)))
(fun i => stepClockFunction_intervalIntegrable _ (sampleClockSteps_ordered q _ hoa) i 0 1)
(fun i => stepClockFunction_intervalIntegrable _ (sampleClockSteps_ordered r _ hoa) i 0 1)
have hiB : (∫ v in (0:ℝ)..1, clockCoordinateDistance D
(stepClockFunction (fun i => (q 0 i:ℝ)) (sampleClockSteps q 0 (as++bs)) v)
(stepClockFunction (fun i => (r 0 i:ℝ)) (sampleClockSteps r 0 (as++bs)) v))β‰€βˆ‘ i, C i*(D i)^2 := by
calc
_ ≀ ∫ v in (0:ℝ)..1, βˆ‘ i, C i*(D i)^2 := by
apply intervalIntegral.integral_mono_on_of_le_Ioo (by norm_num) hi intervalIntegrable_const
intro v hv
apply clockCoordinateDistance_le
intro i
rw [sampleClockSteps_function q hq _ hoa v i,sampleClockSteps_function r hr _ hoa v i,
partitionSample_comp (fun v => (q v i:ℝ)),partitionSample_comp (fun v => (r v i:ℝ))]
have hB := partitionSample_id_bounds (as++bs) hoa hm ⟨hv.1.le,hv.2.le⟩
exact hC _ ⟨hB.1,hB.2.1.trans hv.2.le⟩ i
_ = _ := by simp
apply hh.trans
apply mul_le_mul_of_nonneg_left _ (mul_nonneg (ClockTree.errorJetVariation_nonneg _ _ _) hK)
have hf := clockCoordinateDistance_le D C _ _ (hC u.val ⟨u.property.le,hu⟩)
have ht := clockCoordinateDistance_le D C _ _ (hC 1 (by constructor <;> norm_num))
linarith
theorem retainedPairSample_sup_comparison {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (D C : ΞΉ β†’ ℝ) (hD : βˆ€ i, 0≀D i)
(hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i)
(q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
(hC : βˆ€ u ∈ Icc (0:ℝ) 1, βˆ€ i, |(q u i:ℝ)-(r u i:ℝ)|≀C i)
(u : PositiveMass) (hu : u.val≀1) (k : β„•)
(P : S β†’ S β†’ ℝ) {K : ℝ} (hK : 0≀K) (hP : βˆ€ Οƒ Ο„, |P Οƒ Ο„|≀K) (x : ΞΉ β†’ ℝ) :
|retainedPairSample w Ο† q u (uniformMasses k) P x-retainedPairSample w Ο† r u (uniformMasses k) P x| ≀
ClockTree.errorJetVariation 2 0 0*K*(3*βˆ‘ i, C i*(D i)^2) := by
have ho := retainedMasses_ordered u hu (uniformMasses k) (uniformMasses_ordered k)
exact sampledPairDisorder_sup_comparison hw φ D C hD hφ q r hq hr hC u hu _ _ ho.1 ho.2
(retainedBefore_bounds u _) (retainedBefore_end u _) (retainedAfter_end u _)
(retainedMasses_mesh u hu _ (uniformMasses_ordered k) (by positivity) (uniformMasses_mesh k)) P hK hP x
theorem pathPairDisorder_sup_comparison {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (D C : ΞΉ β†’ ℝ) (hD : βˆ€ i, 0≀D i)
(hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i)
(q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
(hC : βˆ€ u ∈ Icc (0:ℝ) 1, βˆ€ i, |(q u i:ℝ)-(r u i:ℝ)|≀C i)
(u : PositiveMass) (hu : u.val≀1)
(P : S β†’ S β†’ ℝ) {K : ℝ} (hK : 0≀K) (hP : βˆ€ Οƒ Ο„, |P Οƒ Ο„|≀K) (x : ΞΉ β†’ ℝ) :
|pathPairDisorder w Ο† q u P x-pathPairDisorder w Ο† r u P x| ≀
ClockTree.errorJetVariation 2 0 0*K*(3*βˆ‘ i, C i*(D i)^2) := by
apply le_of_tendsto ((retainedPairSample_tendsto_all hw Ο† q hq u hu P x).sub
(retainedPairSample_tendsto_all hw Ο† r hr u hu P x)).abs
exact Eventually.of_forall fun k => retainedPairSample_sup_comparison hw φ D C hD hφ q r hq hr hC u hu k P hK hP x
theorem pathPairMoment_sup_comparison {w : S β†’ ℝ} (hw : βˆ€ Οƒ, 0<w Οƒ)
(Ο† : S β†’ (ΞΉ β†’ ℝ) β†’L[ℝ] ℝ) (D C : ΞΉ β†’ ℝ) (hD : βˆ€ i, 0≀D i)
(hΟ† : βˆ€ Οƒ i, |Ο† Οƒ (Pi.single i 1)|≀D i)
(q r : ℝ β†’ ΞΉ β†’ ℝβ‰₯0)
(hq : βˆ€ i, MonotoneOn (fun u => q u i) (Icc (0:ℝ) 1))
(hr : βˆ€ i, MonotoneOn (fun u => r u i) (Icc (0:ℝ) 1))
(hC : βˆ€ u ∈ Icc (0:ℝ) 1, βˆ€ i, |(q u i:ℝ)-(r u i:ℝ)|≀C i)
{u : ℝ} (hu : u ∈ Ioc (0:ℝ) 1)
(P : S β†’ S β†’ ℝ) {K : ℝ} (hK : 0≀K) (hP : βˆ€ Οƒ Ο„, |P Οƒ Ο„|≀K) :
|pathPairMoment w Ο† q P u-pathPairMoment w Ο† r P u| ≀
ClockTree.errorJetVariation 2 0 0*K*(3*βˆ‘ i, C i*(D i)^2) := by
simp only [pathPairMoment,dite_eq_left hu.1]
exact pathPairDisorder_sup_comparison hw Ο† D C hD hΟ† q r hq hr hC ⟨u,hu.1⟩ hu.2 P hK hP 0
end SKFluctuations.Hierarchy
end
end OAI