End RInt_comp.
(** * Parametric integrals *)

(* Specifications: *)
Lemma is_derive_RInt_param_aux : forall (f : R -> R -> R) (a b x : R),
locally x (fun x : R => forall t, Rmin a b <= t <= Rmax a b -> ex_derive (fun u : R => f u t) x) ->
(forall t, Rmin a b <= t <= Rmax a b -> continuity_2d_pt (fun u v => Derive (fun z => f z v) u) x t) ->
locally x (fun y : R => ex_RInt (fun t => f y t) a b) ->
ex_RInt (fun t => Derive (fun u => f u t) x) a b ->
is_derive (fun x : R => RInt (fun t => f x t) a b) x
(RInt (fun t => Derive (fun u => f u t) x) a b).
Lemma is_derive_RInt_param : forall f a b x,
locally x (fun x => forall t, Rmin a b <= t <= Rmax a b -> ex_derive (fun u => f u t) x) ->
(forall t, Rmin a b <= t <= Rmax a b -> continuity_2d_pt (fun u v => Derive (fun z => f z v) u) x t) ->
locally x (fun y => ex_RInt (fun t => f y t) a b) ->
is_derive (fun x => RInt (fun t => f x t) a b) x
(RInt (fun t => Derive (fun u => f u t) x) a b).
Lemma is_derive_RInt_param_bound_comp_aux1 :
forall (f : R -> R -> R) (a : R -> R) (x : R),
(exists eps:posreal, locally x (fun y : R => ex_RInt (fun t => f y t) (a x - eps) (a x + eps))) ->
(exists eps:posreal, locally x
(fun x0 : R =>
forall t : R,
a x-eps <= t <= a x+eps ->
ex_derive (fun u : R => f u t) x0)) ->
(locally_2d (fun x' t =>
continuity_2d_pt (fun u v : R => Derive (fun z : R => f z v) u) x' t) x (a x)) ->
continuity_2d_pt
(fun u v : R => Derive (fun z : R => RInt (fun t : R => f z t) v (a x)) u) x (a x).
Lemma is_derive_RInt_param_bound_comp_aux2 :
forall (f : R -> R -> R) (a : R -> R) (b x da : R),
(locally x (fun y : R => ex_RInt (fun t => f y t) (a x) b)) ->
(exists eps:posreal, locally x (fun y : R => ex_RInt (fun t => f y t) (a x - eps) (a x + eps))) ->
is_derive a x da ->
(exists eps:posreal, locally x
(fun x0 : R =>
forall t : R,
Rmin (a x-eps) b <= t <= Rmax (a x+eps) b ->
ex_derive (fun u : R => f u t) x0)) ->
(forall t : R,
Rmin (a x) b <= t <= Rmax (a x) b ->
continuity_2d_pt (fun u v : R => Derive (fun z : R => f z v) u) x t) ->
(locally_2d (fun x' t =>
continuity_2d_pt (fun u v : R => Derive (fun z : R => f z v) u) x' t) x (a x)) ->
continuity_pt (fun t => f x t) (a x) ->
is_derive (fun x : R => RInt (fun t => f x t) (a x) b) x
(RInt (fun t : R => Derive (fun u => f u t) x) (a x) b+(-f x (a x))*da).
Lemma is_derive_RInt_param_bound_comp_aux3 :
forall (f : R -> R -> R) a (b : R -> R) (x db : R),
(locally x (fun y : R => ex_RInt (fun t => f y t) a (b x))) ->
(exists eps:posreal, locally x (fun y : R => ex_RInt (fun t => f y t) (b x - eps) (b x + eps))) ->
is_derive b x db ->
(exists eps:posreal, locally x
(fun x0 : R =>
forall t : R,
Rmin a (b x-eps) <= t <= Rmax a (b x+eps) ->
ex_derive (fun u : R => f u t) x0)) ->
(forall t : R,
Rmin a (b x) <= t <= Rmax a (b x) ->
continuity_2d_pt (fun u v : R => Derive (fun z : R => f z v) u) x t) ->
(locally_2d (fun x' t =>
continuity_2d_pt (fun u v : R => Derive (fun z : R => f z v) u) x' t) x (b x)) ->
continuity_pt (fun t => f x t) (b x) ->
is_derive (fun x : R => RInt (fun t => f x t) a (b x)) x
(RInt (fun t : R => Derive (fun u => f u t) x) a (b x) +f x (b x)*db).
Lemma is_derive_RInt_param_bound_comp :
forall (f : R -> R -> R) (a b : R -> R) (x da db : R),
(locally x (fun y : R => ex_RInt (fun t => f y t) (a x) (b x))) ->
(exists eps:posreal, locally x (fun y : R => ex_RInt (fun t => f y t) (a x - eps) (a x + eps))) ->
(exists eps:posreal, locally x (fun y : R => ex_RInt (fun t => f y t) (b x - eps) (b x + eps))) ->
is_derive a x da ->
is_derive b x db ->
(exists eps:posreal, locally x
(fun x0 : R =>
forall t : R,
Rmin (a x-eps) (b x -eps) <= t <= Rmax (a x+eps) (b x+eps) ->
ex_derive (fun u : R => f u t) x0)) ->
(forall t : R,
Rmin (a x) (b x) <= t <= Rmax (a x) (b x) ->
continuity_2d_pt (fun u v : R => Derive (fun z : R => f z v) u) x t) ->
(locally_2d (fun x' t =>
continuity_2d_pt (fun u v : R => Derive (fun z : R => f z v) u) x' t) x (a x)) ->
(locally_2d (fun x' t =>
continuity_2d_pt (fun u v : R => Derive (fun z : R => f z v) u) x' t) x (b x)) ->
continuity_pt (fun t => f x t) (a x) ->
continuity_pt (fun t => f x t) (b x) ->
is_derive (fun x : R => RInt (fun t => f x t) (a x) (b x)) x
(RInt (fun t : R => Derive (fun u => f u t) x) (a x) (b x)+(-f x (a x))*da+(f x (b x))*db).