Module mathcomp.analysis.real_measure.lebesgue_stieltjes_measure
From HB Require Import structures.From mathcomp Require Import boot order finmap ssralg ssrnum ssrint interval.
From mathcomp Require Import interval_inference archimedean.
#[warning="-warn-library-file-internal-analysis"]
From mathcomp Require Import unstable.
From mathcomp Require Import boolp classical_sets fsbigop cardinality.
From mathcomp Require Import reals ereal topology normedtype sequences esum
measure realfun.
Set Implicit Arguments.
Unset Strict Implicit.
Unset Printing Implicit Defensive.
Import Order.TTheory GRing.Theory Num.Def Num.Theory.
Import numFieldTopology.Exports.
Local Open Scope classical_set_scope.
Local Open Scope ring_scope.
Reserved Notation "R .-ocitv" (at level 5, format "R .-ocitv").
Reserved Notation "R .-ocitv.-measurable"
(at level 6, format "R .-ocitv.-measurable").
Reserved Notation "R .-open" (at level 5, format "R .-open").
Reserved Notation "R .-open.-measurable"
(at level 6, format "R .-open.-measurable").
Notation right_continuousUsed by
- mathcomp.analysis.probability_theory.random_variable
Source code f :=
(forall xSource code, f%function @ at_right x --> f%function x).
Lemma right_continuousWSource code (RSource code : numFieldType) {tdSource code odSource code} (USource code : orderNbhsType td od)
(fSource code : R -> U) : continuous f -> right_continuous f.
Proof.
HBSource code.mixinSource code RecordSource code isCumulativeSource code (RSource code :Source code numFieldTypeSource code) {td od}
(U : orderNbhsType td od) (f : R -> U) := {
cumulative_is_nondecreasing : nondecreasing f ;
cumulative_is_right_continuous : right_continuous f }.
#[shortSource code(type=cumulativeSource code)]Source code
HBSource code.structureSource code DefinitionSource code CumulativeSource code
(RSource code :Source code numFieldTypeSource code) {td od} (U : orderNbhsType td od) :=
{ fSource code of isCumulative R td od U f }.
Arguments cumulative_is_nondecreasing {R td od U} _.
Arguments cumulative_is_right_continuous {R td od U} _.
Lemma nondecreasing_right_continuousPSource code (RSource code : realFieldType) (aSource code : R) (eSource code : R)
(fSource code : cumulative R R) :
e > 0 -> exists dSource code : {posnum R}, f (a + d%:num) <= f a + e.
Proof.
move=> /(_ a) /(@cvgr_dist_lt _ _ R^o) /(_ _ e0)[] _ /posnumP[d] => h.
exists (PosNum [gt0 of (d%:num / 2)]) => //=.
move: h => /(_ (a + d%:num / 2)) /=.
rewrite opprD addNKr normrN ger0_norm// ltr_pdivrMr// ltr_pMr// 2!ltrDl.
rewrite ltr01 divr_gt0// => /(_ erefl erefl).
rewrite ler0_norm.
by rewrite subr_le0 (cumulative_is_nondecreasing f)// lerDl.
by rewrite opprB ltrBlDl; exact: ltW.
Qed.
Context {RSource code : realFieldType}.
Let id_ndSource code : {homo @idfun R : xSource code ySource code / x <= y}.
Proof.
Let id_rcSource code : right_continuous (@idfun R).
Proof.
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code isCumulativeSource code.Build R _ _ R idfun id_nd id_rc.
End id_is_cumulative.
HBSource code.mixinSource code RecordSource code isCumulativeBoundedSource code (RSource code :Source code numFieldTypeSource code) (l r : R) (f : R -> R) := {
cumulativeNy : f @ -oo --> l ;
cumulativey : f @ +oo --> r }.
#[shortSource code(type=cumulativeBoundedSource code)]Source code
HBSource code.structureSource code DefinitionSource code CumulativeBoundedSource code (RSource code :Source code realFieldTypeSource code) (l r : R) :=
{ fSource code of isCumulativeBounded R l r f & Cumulative R f}.
Arguments cumulativeNy {R l r} s.
Arguments cumulativey {R l r} s.
Context (RSource code : realType).
Implicit Types (I J K : set R).
Definition ocitv_type
Used by
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integral_nonneg
- mathcomp.analysis.real_measure.lebesgue_measure
Source code : Type := R.
Definition ocitv
Used by
- mathcomp.analysis.real_measure.lebesgue_measure
- mathcomp.analysis.real_measure.measurable_realfun
Source code := [set `]x.1, x.2]%classic | xSource code in [set: R * R]].
Lemma is_ocitvUsed by
- mathcomp.analysis.probability_theory.random_variable
- mathcomp.analysis.real_measure.lebesgue_measure
Source code aSource code bSource code : ocitv `]a, b]%classic.
Hint Extern 0 (ocitv _) => solve [apply: is_ocitv] : core.
Lemma ocitv0Source code : ocitv set0.
Proof.
Lemma ocitvPUsed by
- mathcomp.analysis.real_measure.lebesgue_measure
- mathcomp.analysis.real_measure.measurable_realfun
Source code XSource code : ocitv X <-> X = set0 \/ exists2 xSource code, x.1 < x.2 & X = `]x.1, x.2]%classic.
Proof.
case: (boolP (x.1 < x.2)) => x12; first by right; exists x.
by left; rewrite set_itv_ge.
Qed.
Lemma ocitvDSource code : semi_setD_closed ocitv.
Proof.
rewrite setD0; exists [set `]a.1, a.2]%classic].
by split=> [//|? ->//||? ? -> ->//]; rewrite bigcup_set1.
rewrite setDE setCitv/= setIUr -!set_itvI.
rewrite /Order.meet/= /Order.meet/= /Order.join/=
?(andbF, orbF)/= ?(meetEtotal, joinEtotal).
rewrite -negb_or le_total/=; set c := minr _ _; set d := maxr _ _.
have inside : a.1 < c -> d < a.2 -> `]a.1, c] `&` `]d, a.2] = set0.
rewrite -subset0 lt_min gt_max => /andP[a12 ab1] /andP[_ ba2] x /= [].
have b1a2 : b.1 <= a.2 by rewrite ltW// (lt_trans ltb).
have a1b2 : a.1 <= b.2 by rewrite ltW// (lt_trans _ ltb).
rewrite /c /d (min_idPr _)// (max_idPr _)// !in_itv /=.
move=> /andP[a1x xb1] /andP[b2x xa2].
by have := lt_le_trans b2x xb1; case: ltgtP ltb.
exists ((if a.1 < c then [set `]a.1, c]%classic] else set0) `|`
(if d < a.2 then [set `]d, a.2]%classic] else set0)); split.
- by rewrite finite_setU; do! case: ifP.
- by move=> ? []; case: ifP => ? // ->//=.
- by rewrite bigcup_setU; congr (_ `|` _);
case: ifPn => ?; rewrite ?bigcup_set1 ?bigcup_set0// set_itv_ge.
- move=> I J/=; case: ifP => //= ac; case: ifP => //= da [] // -> []// ->.
by rewrite inside// => -[].
by rewrite setIC inside// => -[].
Qed.
Lemma ocitvISource code : setI_closed ocitv.
Proof.
Definition ocitv_display
Source code : Type -> measure_display
Proof.
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code PointedSource code.on ocitv_type.
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code
@isSemiRingOfSetsSource code.Build (ocitv_display R)
ocitv_type ocitv ocitv0 ocitvI ocitvD.
End itv_semiRingOfSets.
Notation "R .-ocitv"Used by
- mathcomp.analysis.real_measure.lebesgue_measure
Source code := (ocitv_display R) : measure_display_scope.
Notation "R .-ocitv.-measurable"Used by
- mathcomp.analysis.real_measure.measurable_realfun
Source code := (measurable : set_system (ocitv_type R)) :
classical_set_scope.
Context {RSource code : realType}.
Definition measurableTypeR
Source code := g_sigma_algebraType (@ocitv R).
Definition lebesgue_display
Source code : measure_display := (@ocitv R).-sigma.
Definition measurableR
Source code : set_system R := (@ocitv R).-sigma.-measurable.
HBSource code.instanceSource code DefinitionSource code _Source code :Source code MeasurableSource code lebesgue_display measurableTypeR :=
Measurable.on measurableTypeR.
#[non_forgetful_inheritance]Source code
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code MeasurableSource code.copy R measurableTypeR.
Lemma measurable_set1Source code (rSource code : R) : measurable [set r].
Proof.
by apply: sub_sigma_algebra; exact/is_ocitv.
Qed.
Lemma measurable_itvSource code (iSource code : interval R) : measurable [set` i].
Proof.
by apply: sub_sigma_algebra; apply: is_ocitv.
have mopoo (xSource code : R) : measurable `]x, +oo[.
by rewrite itv_bndy_bigcup_BRight; exact: bigcup_measurable.
have mnooc (xSource code : R) : measurable `]-oo, x].
by rewrite -setCitvr; exact/measurableC.
have ooE (aSource code bSource code : R) : `]a, b[%classic = `]a, b] `\ b.
by rewrite setDitv1r.
have moo (aSource code bSource code : R) : measurable `]a, b[ by rewrite ooE; exact: measurableD.
have mcc (aSource code bSource code : R) : measurable `[a, b].
case: (boolP (a <= b)) => ab; last by rewrite set_itv_ge.
by rewrite -setU_1itvob//; apply/measurableU.
have mco (aSource code bSource code : R) : measurable `[a, b[.
case: (boolP (a < b)) => ab; last by rewrite set_itv_ge.
by rewrite -setU_1itvob//; apply/measurableU.
have oooE (bSource code : R) : `]-oo, b[%classic = `]-oo, b] `\ b.
by rewrite setDitv1r.
case: i => [[[] a|[]] [[] b|[]]] => //; do ?by rewrite set_itv_ge.
- by rewrite -setU_1itvob//; exact/measurableU.
- by rewrite oooE; exact/measurableD.
- by rewrite set_itvNyy.
Qed.
End measurableRocitv.
#[global]
Hint Extern 0 (measurable (_ @^-1` [set _])) =>
solve [apply: measurable_funPTI; exact: measurable_set1] : core.
#[global]
Hint Extern 0 (measurable [set _]) => solve [apply: measurable_set1] : core.
#[global]
Hint Extern 0 (measurable [set` _] ) => exact: measurable_itv : core.
End MeasurableRocitv.
Context (RSource code : realType).
Implicit Types x y z : R.
Definition G
Source code := [set ASource code | exists xSource code, A = `]x, +oo[%classic].
Lemma measurable_itv_bnd_inftyUsed by
- mathcomp.analysis.real_measure.measurable_realfun
Source code bSource code xSource code :
G.-sigma.-measurable [set` Interval (BSide b x) +oo%O].
Proof.
rewrite itvcyEbigcap; apply: bigcapT_measurable => k.
by apply: sub_sigma_algebra; eexists; reflexivity.
Qed.
Lemma measurable_itv_boundedSource code aSource code bSource code xSource code : a != +oo%O ->
G.-sigma.-measurable [set` Interval a (BSide b x)].
Proof.
by rewrite set_itv_splitD; apply: measurableD => //;
exact: measurable_itv_bnd_infty.
by rewrite -setCitvr; apply: measurableC; exact: measurable_itv_bnd_infty.
Qed.
Lemma measurableEUsed by
- mathcomp.analysis.real_measure.measurable_realfun
Source code : (@ocitv R).-sigma.-measurable = G.-sigma.-measurable.
Proof.
apply: smallest_sub; first exact: smallest_sigma_algebra.
by move=> I [x _ <-]; exact: measurable_itv_bounded.
by apply: smallest_sub; [exact: smallest_sigma_algebra|move=> A' /= [x ->]].
Qed.
End rgenoinfty.
Context (RSource code : realType).
Implicit Types x y z : R.
Definition G
Source code := [set ASource code | exists xSource code, A = `]-oo, x[%classic].
Lemma measurable_itv_bnd_inftySource code bSource code xSource code :
G.-sigma.-measurable [set` Interval -oo%O (BSide b x)].
Proof.
rewrite -setCitvr itvoyEbigcup; apply/measurableC/bigcupT_measurable => n.
rewrite -setCitvl; apply: measurableC.
by apply: sub_sigma_algebra; eexists; reflexivity.
Qed.
Lemma measurable_itv_boundedSource code aSource code bSource code xSource code : a != -oo%O ->
G.-sigma.-measurable [set` Interval (BSide b x) a].
Proof.
by rewrite set_itv_splitD; apply/measurableD => //;
rewrite -setCitvl; apply: measurableC; exact: measurable_itv_bnd_infty.
by rewrite -setCitvl; apply: measurableC; exact: measurable_itv_bnd_infty.
Qed.
Lemma measurableEUsed by
- mathcomp.analysis.real_measure.measurable_realfun
Source code : (@ocitv R).-sigma.-measurable = G.-sigma.-measurable.
Proof.
apply: smallest_sub; first exact: smallest_sigma_algebra.
by move=> I [x _ <-]; exact: measurable_itv_bounded.
by apply: smallest_sub; [exact: smallest_sigma_algebra|move=> A' /= [x ->]].
Qed.
End rgeninftyo.
Context (RSource code : realType).
Implicit Types x y z : R.
Definition G
mk_sequence : forall [R : Type], R ^nat -> R ^nat mk_sequence is not universe polymorphic Arguments mk_sequence [R]%_type_scope f / _ The reduction tactics unfold mk_sequence when applied to 2 arguments mk_sequence is transparent Expands to: Constant mathcomp.analysis.sequences.mk_sequence Declared in library mathcomp.analysis.sequences, line 156, characters 11-22
Source code : set_system R := [set ASource code | exists xSource code, A = `[x, +oo[%classic].
Lemma measurable_itv_bnd_inftySource code bSource code xSource code :
G.-sigma.-measurable [set` Interval (BSide b x) +oo%O].
Proof.
rewrite itvoyEbigcup; apply: bigcupT_measurable => k.
by apply: sub_sigma_algebra; eexists; reflexivity.
Qed.
Lemma measurable_itv_boundedSource code aSource code bSource code ySource code : a != +oo%O ->
G.-sigma.-measurable [set` Interval a (BSide b y)].
Proof.
rewrite set_itv_splitD.
by apply: measurableD; exact: measurable_itv_bnd_infty.
by rewrite -setCitvr; apply: measurableC; exact: measurable_itv_bnd_infty.
Qed.
Lemma measurableEUsed by
- mathcomp.analysis.real_measure.measurable_realfun
Source code : (@ocitv R).-sigma.-measurable = G.-sigma.-measurable.
Proof.
apply: smallest_sub; first exact: smallest_sigma_algebra.
by move=> I [x _ <-]; exact: measurable_itv_bounded.
by apply: smallest_sub; [exact: smallest_sigma_algebra|move=> A' /= [x ->]].
Qed.
End rgencinfty.
Context (RSource code : realType).
Implicit Types x y z : R.
Definition G
series : forall {V : GRing.Zmodule.Exports.zmodType}, V ^nat -> V ^nat series is not universe polymorphic Arguments series {V} u_ n : simpl never (where some original arguments have been renamed) The reduction tactics never unfold series series is transparent Expands to: Constant mathcomp.analysis.sequences.series Declared in library mathcomp.analysis.sequences, line 455, characters 11-17
Source code := [set ASource code | exists xSource code ySource code, A = `]x, y[%classic].
Local Lemma measurable_itvooSource code xSource code ySource code : G.-sigma.-measurable `]x, y[%classic.
Proof.
Local Lemma measurable_itv_o_inftySource code xSource code : G.-sigma.-measurable `]x, +oo[%classic.
Proof.
Lemma measurable_itv_bnd_inftySource code bSource code xSource code :
G.-sigma.-measurable [set` Interval (BSide b x) +oo%O].
Proof.
rewrite itvcyEbigcap; apply: bigcapT_measurable => k.
exact: measurable_itv_o_infty.
Qed.
Lemma measurable_itv_infty_bndSource code bSource code xSource code :
G.-sigma.-measurable [set` Interval -oo%O (BSide b x)].
Proof.
Lemma measurable_itv_boundedSource code aSource code xSource code bSource code ySource code :
G.-sigma.-measurable [set` Interval (BSide a x) (BSide b y)].
Proof.
apply: measurableC; apply: measurableU; try solve[
exact: measurable_itv_infty_bnd|exact: measurable_itv_bnd_infty].
Qed.
Lemma measurableEUsed by
- mathcomp.analysis.real_measure.measurable_realfun
Source code : (@ocitv R).-sigma.-measurable = G.-sigma.-measurable.
Proof.
apply: smallest_sub; first exact: smallest_sigma_algebra.
by move=> I [x _ <-]; exact: measurable_itv_bounded.
by apply: smallest_sub; [exact: smallest_sigma_algebra|move=> A' /= [x [y ->]]].
Qed.
End rgenopens.
Context (RSource code : realType).
Implicit Types a b : R.
Import MeasurableRocitv.
Lemma measurableEUsed by
- mathcomp.analysis.real_measure.lebesgue_measure
- mathcomp.analysis.real_measure.measurable_realfun
Source code : (@ocitv R).-sigma.-measurable = open.-sigma.-measurable.
Proof.
apply: sigma_algebra_subl=> U.
- by rewrite /RGenOpens.G/= => -[a [b ->]]; exact: sub_sigma_algebra.
- move=> oU; rewrite (open_disjoint_itv_bigcup oU).
apply: sigma_algebra_bigcup => k.
have /is_intervalP -> := @open_disjoint_itv_is_interval _ U oU k.
exact: measurable_itv.
Qed.
End rgenopensets.
Context {RSource code : realType}.
Definition open_type
harmonic : forall {R : fieldType}, R ^nat harmonic is not universe polymorphic Arguments harmonic {R} n / (where some original arguments have been renamed) The reduction tactics unfold harmonic when applied to 2 arguments harmonic is transparent Expands to: Constant mathcomp.analysis.sequences.harmonic Declared in library mathcomp.analysis.sequences, line 676, characters 11-19
Source code : Type := R.
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code PointedSource code.on open_type.
Let measurableSource code : set_system R :=
@measurable _ (g_sigma_algebraType (@open _ R)).
Let measurable0Source code : measurable set0
Proof.
Let measurableCSource code ASource code : measurable A -> measurable (~` A).
Proof.
Let measurable_bigcupSource code (FSource code : (set R)^nat) : (forall iSource code, measurable (F i)) ->
measurable (\bigcup_iSource code (F i)).
Proof.
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code
@isMeasurableSource code.Build (sigma_display (@open _ R))
open_type measurable measurable0 measurableC measurable_bigcup.
End open.
Notation "R .-open"Source code := (sigma_display (@open _ R)) : measure_display_scope.
Notation "R .-open.-measurable"Used by
- mathcomp.analysis.real_measure.lebesgue_measure
Source code := (measurable : set_system (@open_type R)) :
classical_set_scope.
Context {RSource code : realType}.
Definition measurableTypeR
arithmetic_mean : forall [R : numDomainType], R ^nat -> R ^nat arithmetic_mean is not universe polymorphic Arguments arithmetic_mean [R] u_ _ arithmetic_mean is transparent Expands to: Constant mathcomp.analysis.sequences.arithmetic_mean Declared in library mathcomp.analysis.sequences, line 716, characters 11-26
Used by
- mathcomp.analysis.lebesgue_integral_theory.measurable_fun_approximation
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integral_differentiation
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integral_nonneg
- mathcomp.analysis.probability_theory.random_variable
Source code := g_sigma_algebraType (@open _ R).
Definition lebesgue_display
harmonic_mean : forall [R : numDomainType], R ^nat -> R ^nat harmonic_mean is not universe polymorphic Arguments harmonic_mean [R] u_ _ harmonic_mean is transparent Expands to: Constant mathcomp.analysis.sequences.harmonic_mean Declared in library mathcomp.analysis.sequences, line 719, characters 11-24
Used by
- mathcomp.analysis.real_measure.measurable_realfun
Source code : measure_display := R.-open.
Definition measurableR
root_mean_square : forall [R : realType], R ^nat -> R ^nat root_mean_square is not universe polymorphic Arguments root_mean_square [R] u_ _ root_mean_square is transparent Expands to: Constant mathcomp.analysis.sequences.root_mean_square Declared in library mathcomp.analysis.sequences, line 723, characters 11-27
Source code : set_system R := R.-open.-measurable.
HBSource code.instanceSource code DefinitionSource code _Source code :Source code MeasurableSource code lebesgue_display measurableTypeR :=
Measurable.on measurableTypeR.
#[non_forgetful_inheritance]Source code
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code MeasurableSource code.copy R measurableTypeR.
Lemma measurable_set1Used by
- mathcomp.analysis.probability_theory.independence
- mathcomp.analysis.probability_theory.subpmf
- mathcomp.analysis.probability_theory.random_variable
Source code (rSource code : R) : measurable [set r].
Proof.
Lemma measurable_itvUsed by
- mathcomp.analysis.ftc
- mathcomp.analysis.probability_theory.normal_distribution
Source code (iSource code : interval R) : measurable [set` i].
Proof.
rewrite /MeasurableRocitv.lebesgue_display.
by rewrite RGenOpenSets.measurableE.
Qed.
End measurableRopen.
#[global]
Hint Extern 0 (measurable (_ @^-1` [set _])) =>
solve [apply: measurable_funPTI; exact: measurable_set1] : core.
#[global]
Hint Extern 0 (measurable [set _]) => solve [apply: measurable_set1] : core.
#[global]
Hint Extern 0 (measurable [set` _] ) => exact: measurable_itv : core.
Lemma measurable_funP1Source code {dSource code} {aTSource code : measurableType d} {rTSource code : realType}
(fSource code : {mfun aT >-> rT}) DSource code (ySource code : rT) :
measurable D -> measurable (D `&` f @^-1` [set y]).
Proof.
solve [apply: measurable_funP1; assumption] : core.
Context {RSource code : realType} (muSource code : measure (measurableTypeR R) R).
Definition ocitv_measure
arithmetic : forall {R : GRing.Zmodule.Exports.zmodType}, R -> R -> R ^nat arithmetic is not universe polymorphic Arguments arithmetic {R} (a z)%_ring_scope n / (where some original arguments have been renamed) The reduction tactics unfold arithmetic when applied to 4 arguments arithmetic is transparent Expands to: Constant mathcomp.analysis.sequences.arithmetic Declared in library mathcomp.analysis.sequences, line 882, characters 11-21
Source code : set (MeasurableRocitv.measurableTypeR R) -> \bar R :=
mu.
Let measure0Source code : ocitv_measure set0 = 0.
Proof.
Let measure_ge0Source code xSource code : (0 <= ocitv_measure x)%E.
Proof.
Let measure_semi_sigma_additiveSource code : semi_sigma_additive ocitv_measure.
Proof.
- move=> i; apply: H1; split => //=; first exact: sigma_algebra_measurable.
by rewrite -RGenOpenSets.measurableE; exact: sub_sigma_algebra.
- by rewrite -RGenOpenSets.measurableE.
Qed.
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code isMeasureSource code.Build _ _ _ ocitv_measure
measure0 measure_ge0 measure_semi_sigma_additive.
Lemma ocitv_measure_extSource code ASource code : ocitv_measure A = mu A
Proof.
End ocitv_measure.
End MeasurableRopen.
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integrable
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_Rintegral
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integral_definition
- mathcomp.analysis.lebesgue_integral_theory.giry
- mathcomp.analysis.lebesgue_integral_theory.simple_functions
- mathcomp.analysis.lebesgue_integral_theory.radon_nikodym
- mathcomp.analysis.lebesgue_integral_theory.measurable_fun_approximation
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integral_dominated_convergence
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integral_differentiation
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integral_fubini
- mathcomp.analysis.lebesgue_integral_theory.lebesgue_integral_nonneg
- mathcomp.analysis.ftc
- mathcomp.analysis.probability_theory.independence
- mathcomp.analysis.probability_theory.exponential_distribution
- mathcomp.analysis.probability_theory.subpmf
- mathcomp.analysis.probability_theory.beta_distribution
- mathcomp.analysis.probability_theory.bernoulli_distribution
- mathcomp.analysis.probability_theory.poisson_distribution
- mathcomp.analysis.probability_theory.uniform_distribution
- mathcomp.analysis.probability_theory.normal_distribution
- mathcomp.analysis.probability_theory.binomial_distribution
- mathcomp.analysis.probability_theory.random_variable
- mathcomp.analysis.gauss_integral
- mathcomp.analysis.real_measure.lebesgue_measure
- mathcomp.analysis.real_measure.measurable_realfun
- mathcomp.analysis.kernel
- mathcomp.analysis.borel_hierarchy
- mathcomp.analysis.elementary_functions.trigonometry_integral
- mathcomp.analysis.hoelder
Source code.
Export MeasurableRopen.
End MeasurableR.
Context {RSource code : realType} (fSource code : R -> R).
Import MeasurableR.
Local Open Scope ereal_scope.
Implicit Types i j : interval R.
Let gSource code : \bar R -> \bar R := er_map f.
Definition wlength
exp_coeff : forall {R : realType}, R -> R ^nat exp_coeff is not universe polymorphic Arguments exp_coeff {R} x%_ring_scope _ exp_coeff is transparent Expands to: Constant mathcomp.analysis.sequences.exp_coeff Declared in library mathcomp.analysis.sequences, line 1094, characters 11-20
Used by
- mathcomp.analysis.real_measure.lebesgue_measure
- mathcomp.analysis.real_measure.measurable_realfun
Source code (ASource code : set (ocitv_type R)) : \bar R :=
let iSource code := Rhull A in g i.2 - g i.1.
Lemma wlength0Used by
- mathcomp.analysis.probability_theory.random_variable
- mathcomp.analysis.real_measure.lebesgue_measure
- mathcomp.analysis.real_measure.measurable_realfun
Source code : wlength (set0 : set R) = 0.
Lemma wlength_singletonSource code (rSource code : R) : wlength `[r, r] = 0.
Proof.
Lemma wlength_setTSource code : wlength setT = +oo%E :> \bar R.
Lemma wlength_itvUsed by
- mathcomp.analysis.real_measure.lebesgue_measure
- mathcomp.analysis.real_measure.measurable_realfun
Source code iSource code : wlength [set` i] = if i.2 > i.1 then g i.2 - g i.1 else 0.
Proof.
rewrite le_eqVlt => /orP[|/lt_ereal_bnd i12]; last first.
rewrite -wlength0; congr (wlength _).
by apply/eqP/negPn; rewrite -/(neitv _) neitvE -leNgt (ltW i12).
case: i => -[ba a|[|]] [bb b|[|]] //=.
- rewrite /= => /eqP[->{b}]; move: ba bb => -[] []; try
by rewrite set_itvE wlength0.
by rewrite wlength_singleton.
- by move=> _; rewrite set_itvE wlength0.
- by move=> _; rewrite set_itvE wlength0.
Qed.
Lemma wlength_finite_fin_numSource code iSource code : neitv i -> wlength [set` i] < +oo ->
((i.1 : \bar R) \is a fin_num) /\ ((i.2 : \bar R) \is a fin_num).
Proof.
by move=> _; rewrite wlength_itv /= ltry.
by move=> _; rewrite wlength_itv /= ltNye.
by move=> _; rewrite wlength_itv.
Qed.
Lemma finite_wlength_itvSource code iSource code : neitv i -> wlength [set` i] < +oo ->
wlength [set` i] = (fine (g i.2))%:E - (fine (g i.1))%:E.
Proof.
rewrite fineK.
by rewrite /g; move: i2f; case: (ereal_of_itv_bound i.2).
rewrite fineK.
by rewrite /g; move: i1f; case: (ereal_of_itv_bound i.1).
rewrite wlength_itv; case: ifPn => //; rewrite -leNgt le_eqVlt => /predU1P[->|].
by rewrite subee// /g; move: i1f; case: (ereal_of_itv_bound i.1).
by move/lt_ereal_bnd/ltW; rewrite leNgt; move: i0 => /neitvP => ->.
Qed.
Lemma wlength_itv_bndUsed by
- mathcomp.analysis.probability_theory.random_variable
Source code (aSource code bSource code : R) (xSource code ySource code : bool) : (a <= b)%R ->
wlength [set` Interval (BSide x a) (BSide y b)] = (f b - f a)%:E.
Proof.
Lemma wlength_infty_bndSource code bSource code rSource code :
wlength [set` Interval -oo%O (BSide b r)] = +oo :> \bar R.
Proof.
Lemma wlength_bnd_inftySource code bSource code rSource code :
wlength [set` Interval (BSide b r) +oo%O] = +oo :> \bar R.
Proof.
Lemma pinfty_wlength_itvSource code iSource code : wlength [set` i] = +oo ->
(exists sSource code rSource code, i = Interval -oo%O (BSide s r) \/ i = Interval (BSide s r) +oo%O)
\/ i = `]-oo, +oo[.
Proof.
- by case: ifPn.
- by left; exists ba, a; right.
- by left; exists bb, b; left.
- by right.
Qed.
Lemma wlength_itv_ge0Source code (ndfSource code : {homo f : xSource code ySource code / (x <= y)%R}) iSource code :
0 <= wlength [set` i].
Proof.
Lemma wlength_RhullUsed by
- mathcomp.analysis.real_measure.lebesgue_measure
Source code (ASource code : set R) : wlength [set` Rhull A] = wlength A.
Proof.
Lemma le_wlength_itvSource code (ndfSource code : {homo f : xSource code ySource code / (x <= y)%R}) iSource code jSource code :
{subset i <= j} -> wlength [set` i] <= wlength [set` j].
Proof.
have [->|/set0P I0] := eqVneq I set0; first by rewrite wlength0 wlength_itv_ge0.
have [J0|/set0P J0] := eqVneq J set0.
by move/subset_itvP; rewrite -/J J0 subset0 -/I => ->.
move=> /subset_itvP ij; apply: leeB => /=.
have [ui|ui] := asboolP (has_ubound I).
have [uj /=|uj] := asboolP (has_ubound J); last by rewrite leey.
by rewrite lee_fin ndf// supS.
have [uj /=|//] := asboolP (has_ubound J).
by move: ui; have := subset_has_ubound ij uj.
have [lj /=|lj] := asboolP (has_lbound J); last by rewrite leNye.
have [li /=|li] := asboolP (has_lbound I); last first.
by move: li; have := subset_has_lbound ij lj.
by rewrite lee_fin; exact/ndf/infS.
Qed.
Lemma le_wlengthSource code (ndfSource code : {homo f : xSource code ySource code / (x <= y)%R}) :
{homo wlength : ASource code BSource code / A `<=` B >-> A <= B}.
Proof.
End wlength.
Context {RSource code : realType}.
Lemma wlength_semi_additiveSource code (fSource code : R -> R) :
measure_function.semi_additive (wlength f).
Proof.
move=> Itriv [[/= a1 a2] _] /esym /[dup] + ->.
rewrite wlength_itv ?lte_fin/= -EFinB.
case: ifPn => a12; last first.
pose I iSource code := `](b i).1, (b i).2]%classic.
rewrite set_itv_ge//= -(bigcup_mkord _ I) /I => /bigcup0P I0.
by under eq_bigr => i _ do rewrite I0//= wlength0; rewrite big1.
set A := `]a1, a2]%classic.
rewrite -bigcup_pred; set P := xpredT; rewrite (eq_bigl P)//.
move: P => P; have [p] := ubnP #|P|; elim: p => // p IHp in P a2 a12 A *.
rewrite ltnS => cP /esym AE.
have : A a2 by rewrite /A /= in_itv/= lexx andbT.
rewrite AE/= => -[i /= Pi] a2bi.
case: (boolP ((b i).1 < (b i).2)) => bi; last by rewrite itv_ge in a2bi.
have {}a2bi : a2 = (b i).2.
apply/eqP; rewrite eq_le (itvP a2bi)/=.
suff: A (b i).2 by move=> /itvP->.
by rewrite AE; exists i=> //=; rewrite in_itv/= lexx andbT.
rewrite {a2}a2bi in a12 A AE *.
rewrite (bigD1 i)//= wlength_itv ?lte_fin/= bi !EFinD -addeA.
congr (_ + _)%E; apply/eqP; rewrite addeC -sube_eq// 1?adde_defC//.
rewrite ?EFinN oppeK addeC; apply/eqP.
have [a1bi|a1bi] := eqVneq a1 (b i).1.
rewrite {a1}a1bi in a12 A AE {IHp} *; rewrite subee ?big1// => j.
move=> /andP[Pj Nji]; rewrite wlength_itv ?lte_fin/=; case: ifPn => bj//.
exfalso; have /trivIsetP/(_ j i I I Nji) := Itriv.
pose m := ((b j).1 + (b j).2) / 2%:R.
have mbj : `](b j).1, (b j).2]%classic m.
by rewrite /= !in_itv/= ?(midf_lt, midf_le)//= ltW.
rewrite -subset0 => /(_ m); apply; split=> //.
by suff: A m by []; rewrite AE; exists j.
have a1b2 j : P j -> (b j).1 < (b j).2 -> a1 <= (b j).2.
move=> Pj bj; suff /itvP-> : A (b j).2 by [].
by rewrite AE; exists j => //=; rewrite ?in_itv/= bj/=.
have a1b j : P j -> (b j).1 < (b j).2 -> a1 <= (b j).1.
move=> Pj bj; case: ltP=> // bj1a.
suff : A a1 by rewrite /A/= in_itv/= ltxx.
by rewrite AE; exists j; rewrite //= in_itv/= bj1a//= a1b2.
have bbi2 j : P j -> (b j).1 < (b j).2 -> (b j).2 <= (b i).2.
move=> Pj bj; suff /itvP-> : A (b j).2 by [].
by rewrite AE; exists j => //=; rewrite ?in_itv/= bj/=.
apply/IHp.
- by rewrite lt_neqAle a1bi/= a1b.
- rewrite (leq_trans _ cP)// -(cardID (pred1 i) P).
rewrite [X in (_ < X + _)%N](@eq_card _ _ (pred1 i)).
by move=> j; rewrite !inE andbC; case: eqVneq => // ->.
rewrite ?card1 ?ltnS// subset_leq_card//.
by apply/fintype.subsetP => j; rewrite -topredE/= !inE andbC.
apply/seteqP; split=> /= [x [j/= /andP[Pj Nji]]|x/= xabi].
case: (boolP ((b j).1 < (b j).2)) => bj; last by rewrite itv_ge.
apply: subitvP; rewrite subitvE ?bnd_simp a1b//= leNgt.
have /trivIsetP/(_ j i I I Nji) := Itriv.
rewrite -subset0 => /(_ (b j).2); apply: contra_notN => /= bi1j2.
by rewrite !in_itv/= bj !lexx bi1j2 bbi2.
have: A x.
rewrite /A/= in_itv/= (itvP xabi)/= ltW//.
by rewrite (le_lt_trans _ bi) ?(itvP xabi).
rewrite AE => -[j /= Pj xbj].
exists j => //=.
apply/andP; split=> //; apply: contraTneq xbj => ->.
by rewrite in_itv/= le_gtF// (itvP xabi).
Qed.
Lemma wlength_ge0Source code (fSource code : cumulative R R) (ISource code : set (ocitv_type R)) :
(0 <= wlength f I)%E.
Proof.
#[local] Hint Extern 0 (0%:E <= wlength _ _) => solve[apply: wlength_ge0] : core.
HBSource code.instanceSource code DefinitionSource code _Source code (fSource code :Source code cumulativeSource code R R) :=
isContent.Build _ _ R (wlength f)
(wlength_ge0 f)
(wlength_semi_additive f).
Hint Extern 0 (measurable _) => solve [apply: is_ocitv] : core.
Lemma cumulative_content_sub_fsumSource code (fSource code : cumulative R R) (DSource code : {fset nat}) a0Source code b0Source code
(aSource code bSource code : nat -> R) : (forall iSource code, i \in D -> a i <= b i) ->
`]a0, b0] `<=` \big[setU/set0]_(iSource code <- D) `]a i, b i]%classic ->
f b0 - f a0 <= \sum_(iSource code <- D) (f (b i) - f (a i)).
Proof.
apply (@le_trans _ _ 0).
by rewrite subr_le0 cumulative_is_nondecreasing// ltW.
rewrite big_seq sumr_ge0// => i iD.
by rewrite subr_ge0 cumulative_is_nondecreasing// Dab.
have mab k : [set` D] k -> R.-ocitv.-measurable `]a k, b k]%classic by [].
move: h; rewrite -bigcup_fset.
move/(content_sub_fsum (wlength f) (finite_fset D) mab (is_ocitv a0 b0)) => /=.
rewrite wlength_itv_bnd// -lee_fin => /le_trans; apply.
rewrite -sumEFin fsbig_finite//= set_fsetK// big_seq [in leRHS]big_seq.
by apply: lee_sum => i iD; rewrite wlength_itv_bnd// Dab.
Qed.
Lemma wlength_sigma_subadditiveSource code (fSource code : cumulative R R) :
measurable_subset_sigma_subadditive (wlength f).
Proof.
rewrite /subset_sigma_subadditive wlength_itv ?lte_fin/= -EFinB => lebig.
case: ifPn => a12; last by rewrite nneseries_esum ?esum_ge0.
wlog wlogh : b A AE lebig / forall nSource code, (b n).1 <= (b n).2.
move=> /= h.
set A' := fun nSource code => if (b n).1 >= (b n).2 then set0 else A n.
set b' := fun nSource code => if (b n).1 >= (b n).2 then (0, 0) else b n.
rewrite [leRHS](_ : _ = \sum_(nSource code <oo) wlength f (A' n))%E.
apply: (@eq_eseriesr _ (wlength f \o A) (wlength f \o A')) => k.
rewrite /= /A' AE; case: ifPn => // bn.
by rewrite set_itv_ge//= bnd_simp -leNgt.
apply: (h b').
- move=> k; rewrite /A'; case: ifPn => // bk.
by rewrite set_itv_ge//= bnd_simp -leNgt /b' bk.
- by rewrite AE /b' (negbTE bk).
- apply: (subset_trans lebig); apply subset_bigcup => k _.
rewrite /A' AE; case: ifPn => bk //.
by rewrite subset0 set_itv_ge//= bnd_simp -leNgt.
- by move=> k; rewrite /b'; case: ifPn => //; rewrite -ltNge => /ltW.
apply/lee_addgt0Pr => _/posnumP[e].
rewrite [e%:num]splitr [in leRHS]EFinD addeA -leeBlDr//.
apply: le_trans (epsilon_trick _ _ _) => //=.
have [c ce] := nondecreasing_right_continuousP a.1 f [gt0 of e%:num / 2].
have [D De] : exists DSource code : nat -> {posnum R}, forall iSource code,
f ((b i).2 + (D i)%:num) <= f ((b i).2) + (e%:num / 2) / 2 ^ i.+1.
suff : forall iSource code, exists diSource code : {posnum R},
f ((b i).2 + di%:num) <= f ((b i).2) + (e%:num / 2) / 2 ^ i.+1.
by move/choice => -[g hg]; exists g.
by move=> k; apply nondecreasing_right_continuousP.
have acbd : `[ a.1 + c%:num / 2, a.2] `<=`
\bigcup_iSource code `](b i).1, (b i).2 + (D i)%:num[%classic.
apply: (@subset_trans _ `]a.1, a.2]).
move=> r; rewrite /= !in_itv/= => /andP [+ ->].
by rewrite andbT; apply: lt_le_trans; rewrite ltrDl.
apply: (subset_trans lebig) => r [n _ Anr]; exists n => //.
move: Anr; rewrite AE /= !in_itv/= => /andP [->]/= /le_lt_trans.
by apply; rewrite ltrDl.
have := @segment_compact _ (a.1 + c%:num / 2) a.2; rewrite compact_cover.
have obd k : [set: nat] k -> open `](b k).1, ((b k).2 + (D k)%:num)[%classic.
by move=> _; exact: interval_open.
move=> /(_ _ _ _ obd acbd){obd acbd}.
case=> X _ acXbd.
rewrite /cover in acXbd.
rewrite -EFinD.
apply: (@le_trans _ _ (\sum_(iSource code <- X) (wlength f `](b i).1, (b i).2]%classic) +
\sum_(iSource code <- X) (f ((b i).2 + (D i)%:num)%R - f (b i).2)%:E)%E).
apply: (@le_trans _ _ (f a.2 - f (a.1 + c%:num / 2))%:E).
rewrite lee_fin -addrA -opprD lerB// (le_trans _ ce)//.
rewrite cumulative_is_nondecreasing//.
by rewrite lerD2l ler_pdivrMr// ler_pMr// ler1n.
apply: (@le_trans _ _
(\sum_(iSource code <- X) (f ((b i).2 + (D i)%:num) - f (b i).1)%:E)%E).
rewrite sumEFin lee_fin cumulative_content_sub_fsum//.
by move=> k kX; rewrite (@le_trans _ _ (b k).2)// lerDl.
apply: subset_trans.
exact/(subset_trans _ acXbd)/subset_itv_oc_cc.
move=> x [k kX] kx; rewrite -bigcup_fset; exists k => //.
by move: x kx; exact: subset_itv_oo_oc.
rewrite addeC -big_split/=; apply: lee_sum => k _.
by rewrite !(EFinB, wlength_itv_bnd)// addeA subeK.
rewrite -big_split/= nneseries_esum//; first by move=> k _; rewrite adde_ge0.
rewrite esum_ge//=; first by [move=> n _; rewrite adde_ge0].
exists [set` X] => //; rewrite fsbig_finite//= set_fsetK.
rewrite big_seq [in X in (_ <= X)%E]big_seq; apply: lee_sum => k kX.
by rewrite AE leeD2l// lee_fin lerBlDl natrX De.
Qed.
HBSource code.instanceSource code DefinitionSource code _Source code (fSource code :Source code cumulativeSource code R R) :=
Content_SigmaSubAdditive_isMeasure.Build _ _ _
(wlength f) (wlength_sigma_subadditive f).
Lemma wlength_sigma_finiteUsed by
- mathcomp.analysis.real_measure.lebesgue_measure
Source code (fSource code : R -> R) :
sigma_finite [set: (ocitv_type R)] (wlength f).
Proof.
Definition ocitv_lebesgue_stieltjes_measure
expR : forall {R : realType}, R -> R expR is not universe polymorphic Arguments expR {R} x%_ring_scope expR is transparent Expands to: Constant mathcomp.analysis.sequences.expR Declared in library mathcomp.analysis.sequences, line 1199, characters 11-15 nseries : nat ^nat -> nat -> nat nseries is not universe polymorphic Arguments nseries u n%_nat_scope nseries is transparent Expands to: Constant mathcomp.analysis.sequences.nseries Declared in library mathcomp.analysis.sequences, line 1223, characters 11-18 eseries : forall {R : numDomainType}, (\bar R) ^nat -> (\bar R) ^nat eseries is not universe polymorphic Arguments eseries {R} u_ n : simpl never (where some original arguments have been renamed) The reduction tactics never unfold eseries eseries is transparent Expands to: Constant mathcomp.analysis.sequences.eseries Declared in library mathcomp.analysis.sequences, line 1325, characters 11-18 etelescope : forall {R : numDomainType}, (\bar R) ^nat -> (\bar R) ^nat etelescope is not universe polymorphic Arguments etelescope {R} u_ n : simpl never (where some original arguments have been renamed) The reduction tactics never unfold etelescope etelescope is transparent Expands to: Constant mathcomp.analysis.sequences.etelescope Declared in library mathcomp.analysis.sequences, line 1326, characters 11-21 sdrop : forall [T : Type], T ^nat -> nat -> set T sdrop is not universe polymorphic Arguments sdrop [T]%_type_scope u n%_nat_scope _ sdrop is transparent Expands to: Constant mathcomp.analysis.sequences.sdrop Declared in library mathcomp.analysis.sequences, line 2149, characters 11-16
Source code (fSource code : cumulative R R) :=
measure_extension (wlength f).
HBSource code.instanceSource code DefinitionSource code _Source code (fSource code :Source code cumulativeSource code R R) :=
Measure.on (ocitv_lebesgue_stieltjes_measure f).
Let ocitv_sigmaT_finite_lebesgue_stieltjes_measureSource code (fSource code : cumulative R R) :
sigma_finite setT (ocitv_lebesgue_stieltjes_measure f).
Proof.
by move=> [X bX fX]; exists X.
Qed.
HBSource code.instanceSource code DefinitionSource code _Source code (fSource code :Source code cumulativeSource code R R) :=
@Measure_isSigmaFinite.Build _ _ _ (ocitv_lebesgue_stieltjes_measure f)
(ocitv_sigmaT_finite_lebesgue_stieltjes_measure f).
Definition lebesgue_stieltjes_measure
sups : forall [R : realType], (R^o) ^nat -> R ^nat sups is not universe polymorphic Arguments sups [R] u _ sups is transparent Expands to: Constant mathcomp.analysis.sequences.sups Declared in library mathcomp.analysis.sequences, line 2182, characters 11-15
Used by
- mathcomp.analysis.probability_theory.random_variable
- mathcomp.analysis.real_measure.lebesgue_measure
Source code (fSource code : cumulative R R) :
set (g_sigma_algebraType (@open _ R)) -> \bar R :=
measure_extension (wlength f).
Let lsm0Source code (fSource code : cumulative R R) : lebesgue_stieltjes_measure f set0 = 0.
Proof.
Let lsm_ge0Source code (fSource code : cumulative R R) xSource code : (0 <= lebesgue_stieltjes_measure f x)%E.
Proof.
Let lsm_semi_sigma_additiveSource code (fSource code : cumulative R R) :
semi_sigma_additive (lebesgue_stieltjes_measure f).
Proof.
rewrite RGenOpenSets.measurableE//=.
Qed.
HBSource code.instanceSource code DefinitionSource code _Source code (fSource code :Source code cumulativeSource code R R) :=
isMeasure.Build _ _ _ (lebesgue_stieltjes_measure f)
(lsm0 f) (lsm_ge0 f) (@lsm_semi_sigma_additive f).
Let sigmaT_finite_lebesgue_stieltjes_measureSource code (fSource code : cumulative R R) :
sigma_finite setT (lebesgue_stieltjes_measure f).
Proof.
by move=> [X bX fX]; exists X=>// i; rewrite -RGenOpenSets.measurableE.
Qed.
HBSource code.instanceSource code DefinitionSource code _Source code (fSource code :Source code cumulativeSource code R R) :=
@Measure_isSigmaFinite.Build _ _ _ (lebesgue_stieltjes_measure f)
(sigmaT_finite_lebesgue_stieltjes_measure f).
End wlength_extension.
Context {RSource code : realType} (fSource code : cumulative R R).
Import MeasurableR.
Let ocitv_lebesgue_stieltjes_measure_uniqueSource code
(muSource code : {measure set (MeasurableRocitv.measurableTypeR R) -> \bar R}) :
(forall XSource code, ocitv X -> lebesgue_stieltjes_measure f X = mu X) ->
forall ASource code : set R, measurable A -> lebesgue_stieltjes_measure f A = mu A.
Proof.
apply: measure_extension_unique => //=.
- exact: wlength_sigma_finite.
- by move=> X mX; rewrite -muE// -measurable_mu_extE.
- by rewrite RGenOpenSets.measurableE.
Qed.
Lemma lebesgue_stieltjes_measure_uniqueUsed by
- mathcomp.analysis.probability_theory.random_variable
- mathcomp.analysis.real_measure.lebesgue_measure
Source code
(muSource code : {measure set (MeasurableRopen.measurableTypeR R) -> \bar R}) :
(forall XSource code, ocitv X -> lebesgue_stieltjes_measure f X = mu X) ->
forall ASource code : set R, measurable A -> lebesgue_stieltjes_measure f A = mu A.
Proof.
End lebesgue_stieltjes_measure_unique.
Context {RSource code : realType}.
Definition completed_lebesgue_stieltjes_measure
limn_sup : forall [R : realType], (R^o) ^nat -> join_order_topology_POrderedPointedTopological_between_Order_POrder_and_filter_PointedNbhs (numFieldTopology.Real_sort__canonical__order_topology_POrderedPointedTopological R) limn_sup is not universe polymorphic Arguments limn_sup [R] u limn_sup is transparent Expands to: Constant mathcomp.analysis.sequences.limn_sup Declared in library mathcomp.analysis.sequences, line 2319, characters 11-19
Used by
- mathcomp.analysis.real_measure.lebesgue_measure
Source code (fSource code : cumulative R R) :=
@completed_measure_extension _ _ _ (wlength f).
HBSource code.instanceSource code DefinitionSource code _Source code (fSource code :Source code cumulativeSource code R R) :=
Measure.on (@completed_lebesgue_stieltjes_measure f).
Let sigmaT_finite_completed_lebesgue_stieltjes_measureSource code (fSource code : cumulative R R) :
sigma_finite setT (@completed_lebesgue_stieltjes_measure f).
Proof.
HBSource code.instanceSource code DefinitionSource code _Source code (fSource code :Source code cumulativeSource code R R) :=
@Measure_isSigmaFinite.Build _ _ _
(@completed_lebesgue_stieltjes_measure f)
(sigmaT_finite_completed_lebesgue_stieltjes_measure f).
End completed_lebesgue_stieltjes_measure.
Context {RSource code : realType} (fSource code : cumulativeBounded (0:R) (1:R)).
Local Open Scope measure_display_scope.
Let lsfSource code := lebesgue_stieltjes_measure f.
Let lebesgue_stieltjes_setTSource code : lsf setT = 1%E.
Proof.
pose I nSource code : set R := `]- (n%:R), n%:R]%classic.
have : (lsf \o I) n @[nSource code --> \oo] --> 1%E.
have -> : lsf \o I = (fun nSource code => (f n%:R)%:E - (f (- n%:R))%:E)%E.
apply/funext=> n; rewrite /= /lsf/= /lebesgue_stieltjes_measure.
rewrite /measure_extension measurable_mu_extE/=; first exact: is_ocitv.
by rewrite wlength_itv_bnd// ge0_cp.
rewrite -(sube0 1); apply: cvgeB => //.
- by apply/cvg_EFin; [near=> F
|exact/(cvg_comp _ _ (@cvgr_idn R))/cumulativey].
- apply/cvg_EFin; [by near=> F|apply: (cvg_ninftyP _ _).1 => //].
exact: cumulativeNy.
by apply: (cvg_comp _ _ (@cvgr_idn R)); rewrite ninfty.
have : (lsf \o I) n @[nSource code --> \oo] --> lsf (\bigcup_nSource code I n).
apply: nondecreasing_cvg_measure; rewrite /I//; first exact: bigcup_measurable.
by move=> *; apply/subsetPset/subset_itv; rewrite leBSide/= ?lerN2 ler_nat.
exact: cvg_unique.
Unshelve. all: end_near. Qed.
HBSource code.instanceSource code DefinitionSource code _Source code :=Source code @Measure_isProbabilitySource code.Build _ _ _
(lebesgue_stieltjes_measure f) lebesgue_stieltjes_setT.
End probability_measure_of_lebesgue_stieltjes_measure.