File size: 2,206 Bytes
4a56cd6
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
import Mathlib
import OAI.Probability.SKBarriers.Gaussian.BoundedPrimitive
import OAI.Probability.SKBarriers.Hierarchy.TimeChainRepresentation

namespace OAI

section

noncomputable section
open scoped NNReal Topology
open MeasureTheory ProbabilityTheory Filter Set
namespace SK.Analytic

def scalarTimeChainAverage (Ξ² : ℝ) (l : List (ℝ Γ— ℝβ‰₯0)) (f g : ℝ β†’ ℝ) (x : ℝ) : ℝ :=
  scalarHierarchyAverage l.length (fun i => (l.get i).1)
    (fun i => Ξ²*Real.sqrt ((l.get i).2:ℝ)) f g x

theorem scalarCDFAverage_eq_chainAverage {f g dg : ℝ β†’ ℝ}
    (hf : BoundedDerivs f) (hg : βˆ€ y, HasDerivAt g (dg y) y) (hdg : Continuous dg)
    {K B C : ℝβ‰₯0} (hfK : LipschitzWith K f)
    (hB : βˆ€ y, |g y| ≀ B) (hC : βˆ€ y, |dg y| ≀ C)
    (Ξ² : ℝ) {Ξ± : ℝ β†’ ℝ} (hΞ± : βˆ€ z, Ξ± z∈Icc (0:ℝ) 1) (hmono : Monotone Ξ±)
    (l : List (ℝ Γ— ℝβ‰₯0)) (hm : βˆ€ p∈l, p.1∈Icc (0:ℝ) 1)
    (s : ℝ) (t : ℝβ‰₯0) (ht : t≀1) (hdur : chainDuration l=t)
    (hmodel : TimeChainModels Ξ± s l) (x : ℝ) :
    scalarCDFAverage Ξ² Ξ± s t f g x=scalarTimeChainAverage Ξ² l f g x := by
  let G := boundedPrimitive g
  have hc : Continuous g := continuous_iff_continuousAt.mpr (fun y => (hg y).continuousAt)
  have hG : BoundedDerivs G := boundedPrimitive_regular hg hdg hB hC
  have hGd : βˆ€ y, HasDerivAt G (g y) y := boundedPrimitive_hasDerivAt hc
  have hGB : LipschitzWith B G := boundedPrimitive_lipschitz hc hB
  have he : (fun a => scalarCDFOperator Ξ² Ξ± s t (primitivePerturbation f G a) x)=
      fun a => scalarTimeChain Ξ² l (primitivePerturbation f G a) x := by
    funext a
    exact scalarCDFOperator_eq_chain (primitivePerturbation_regular hf hG a)
      (primitivePerturbation_lipschitz hfK hGB a) Ξ² hΞ± hmono l hm s t ht hdur hmodel x
  rw [scalarCDFAverage_eq_terminalDerivative Ξ² Ξ± s t hf hG hGd]
  have hd := (scalarCDFOperator_terminal_hasDerivAt Ξ² hΞ± hmono hf hG hGd hg hfK hGB hB hC s t ht x 0).deriv
  rw [he] at hd
  rw [← hd]
  simp only [scalarTimeChain_eq_hierarchy]
  rw [scalarHierarchy_primitive_derivative _ _ _ hf hG hGd,
    primitivePerturbation_zero]
  simp only [add_zero,scalarTimeChainAverage]

end SK.Analytic

end
end

end OAI