Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions _CoqProject
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ theories/measure_theory/measurable_function.v
theories/measure_theory/signed_measure.v
theories/measure_theory/measure.v

theories/real_measure/normedtype_measure.v
theories/real_measure/lebesgue_stieltjes_measure.v
theories/real_measure/lebesgue_measure.v
theories/real_measure/measurable_realfun.v
Expand Down
1 change: 1 addition & 0 deletions theories/Make
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ measure_theory/measurable_function.v
measure_theory/signed_measure.v
measure_theory/measure.v

real_measure/normedtype_measure.v
real_measure/lebesgue_stieltjes_measure.v
real_measure/lebesgue_measure.v
real_measure/measurable_realfun.v
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ Section continuous_compact_integrable.
Context {rT : realType}.
Let mu : measure _ _ := @lebesgue_measure rT.
Import MeasurableR.
Let R : measurableType _ := measurableTypeR rT.
Let R : measurableType _ := (*measurableTypeR*) rT.
Local Open Scope ereal_scope.

Lemma continuous_compact_integrable (f : R -> R^o) (A : set R^o) :
Expand All @@ -78,7 +78,7 @@ Section continuous_density_L1.
Context (rT : realType).
Let mu : measure _ _ := @lebesgue_measure rT.
Import MeasurableR.
Let R : measurableType _ := measurableTypeR rT.
Let R : measurableType _ := (*measurableTypeR*) rT.
Local Open Scope ereal_scope.

Import HBSimple.
Expand Down Expand Up @@ -180,7 +180,7 @@ Section lebesgue_differentiation_continuous.
Context {rT : realType}.
Let mu : measure _ _ := @lebesgue_measure rT.
Import MeasurableR.
Let R : measurableType _ := measurableTypeR rT.
Let R : measurableType _ := (*measurableTypeR*) rT.

Let ballE (x : R) (r : {posnum rT}) :
ball x r%:num = `](x - r%:num), (x + r%:num)[%classic :> set rT.
Expand Down
6 changes: 3 additions & 3 deletions theories/lebesgue_integral_theory/lebesgue_integral_nonneg.v
Original file line number Diff line number Diff line change
Expand Up @@ -557,7 +557,7 @@ Local Notation mu := lebesgue_measure.
Import MeasurableR.

Lemma lebesgue_measureN (A : set R) : measurable A ->
pushforward mu (-%R : _ -> measurableTypeR R) A = mu A.
pushforward mu (-%R : _ -> (*measurableTypeR*) R) A = mu A.
Proof.
move=> mA; apply/esym/lebesgue_measure_unique => //= _ [[a b]] _ <-.
rewrite /pushforward opp_preimage_itvbndbnd/= !lebesgue_measure_itv/=.
Expand All @@ -569,7 +569,7 @@ Lemma ge0_integration_by_substitution0 (f : R -> \bar R) :
\int[mu]_(r in `[0%R, +oo[) f r = \int[mu]_(r in `]-oo, 0%R]) f (- r)%R.
Proof.
move=> mf f0; rewrite (_ : `]-oo, 0%R]%classic =
(-%R : _ -> measurableTypeR R) @^-1` `[0%R, +oo[).
(-%R : _ -> (*measurableTypeR*) R) @^-1` `[0%R, +oo[).
by rewrite opp_preimage_itvbndy oppr0.
rewrite -ge0_integral_pushforward//=; first exact: measurable_funS mf.
by apply: eq_measure_integral => //= A mA AS; exact/esym/lebesgue_measureN.
Expand Down Expand Up @@ -1068,7 +1068,7 @@ End integral_patch.
Section ge0_cvgn_integral.
Local Open Scope ereal_scope.
Import MeasurableR.
Context {R : realType} (mu : {measure set (@measurableTypeR R) -> \bar R})
Context {R : realType} (mu : {measure set ((*@measurableTypeR*) R) -> \bar R})
(f : R -> R).
Hypothesis f0 : (forall x, 0 <= f x)%R.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -703,7 +703,7 @@ Hint Extern 0 (hausdorff_space _) => (exact: Rhausdorff) : core.
Local Open Scope ereal_scope.
Context (rT : realType) (A : set rT).
Let mu : measure _ _ := @lebesgue_measure rT.
Let R : measurableType _ := measurableTypeR rT.
Let R : measurableType _ := rT(*measurableTypeR rT*).
Hypothesis mA : measurable A.
Hypothesis finA : mu A < +oo.

Expand Down
8 changes: 4 additions & 4 deletions theories/probability_theory/random_variable.v
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@ Context {R : realType} (f : cumulativeBounded (0:R) (1:R)).
Local Open Scope measure_display_scope.
Import MeasurableR.

Let idTR : measurableTypeR R -> R := idfun.
Let idTR : (*measurableTypeR*) R -> R := idfun.

#[local] HB.instance Definition _ :=
@isMeasurableFun.Build _ _ _ _ idTR (@measurable_id _ _ setT).
Expand Down Expand Up @@ -410,10 +410,10 @@ End cdf_of_lebesgue_stieltjes_measure.

Section lebesgue_stieltjes_measure_of_cdf.
Import MeasurableR.
Context {R : realType} (P : probability (measurableTypeR R) R).
Context {R : realType} (P : probability ((*measurableTypeR*) R) R).
Local Open Scope measure_display_scope.

Let idTR : measurableTypeR R -> R := idfun.
Let idTR : (*measurableTypeR*) R -> R := idfun.

#[local] HB.instance Definition _ :=
@isMeasurableFun.Build _ _ _ _ idTR (@measurable_id _ _ setT).
Expand Down Expand Up @@ -626,7 +626,7 @@ Let mu : {measure set _ -> \bar R} := @lebesgue_measure R.
Lemma ge0_expectation_ccdf (X : {RV P >-> R}) : (forall x, 0 <= X x)%R ->
'E_P[X] = \int[mu]_(r in `[0%R, +oo[) ccdf X r.
Proof.
pose GR := measurableTypeR R.
pose GR := (*measurableTypeR*) R.
pose distrX := distribution P X.
pose D : set R := `[0%R, +oo[%classic.
move=> X_ge0.
Expand Down
17 changes: 7 additions & 10 deletions theories/real_measure/lebesgue_measure.v
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ From mathcomp Require Import boolp classical_sets functions cardinality fsbigop
reals.
From mathcomp Require Import topology ereal numfun normedtype sequences
esum measure.
From mathcomp Require Export lebesgue_stieltjes_measure measurable_realfun.
From mathcomp Require Export normedtype_measure lebesgue_stieltjes_measure measurable_realfun.

(**md**************************************************************************)
(* # Lebesgue Measure *)
Expand Down Expand Up @@ -572,9 +572,7 @@ apply: (@measure_semi_sigma_additive _ _ _ (@lebesgue_measure R)
move=> [X mX [X' mX']] XX'Fn.
apply: measurable_image_fine.
rewrite -XX'Fn.
apply: measurableU.
apply: measurable_image_EFin.
by rewrite RGenOpenSets.measurableE/= in mX.
apply: measurableU; first exact: measurable_image_EFin.
by case: mX' => //; exact: measurableU.
- move=> i j _ _ [x [[a [Fia aoo ax] [b [Fjb boo] bx]]]].
move: tF => /(_ i j Logic.I Logic.I); apply.
Expand All @@ -591,32 +589,31 @@ apply: (@measure_semi_sigma_additive _ _ _ (@lebesgue_measure R)
+ by rewrite not_orP => -[]/(_ erefl).
+ by rewrite not_orP => -[]/(_ erefl).
- move: mUF.
rewrite {1}/measurable /emeasurable /= => -[X mX [Y []]] {Y};
have moX : measurable X by rewrite -RGenOpenSets.measurableE.
rewrite {1}/measurable /emeasurable /= => -[X mX [Y []]] {Y}.
+ rewrite setU0 => h.
rewrite [X in measurable X](_ : _ = X) // predeqE => r; split => [|Xr].
rewrite [X in measurable X](_ : _ = X)// predeqE => r; split => [|Xr].
move=> -[n _ [x [Fnx xoo <-{r}]]].
have : (\bigcup_n F n) x by exists n.
by rewrite -h => -[x' Xx' <-].
have [n _ Fnr] : (\bigcup_n F n) r%:E by rewrite -h; exists r.
by exists n => //; exists r%:E => //; split => // -[].
+ move=> h.
rewrite [X in measurable X](_ : _ = X) // predeqE => r; split => [|Xr].
rewrite [X in measurable X](_ : _ = X)// predeqE => r; split => [|Xr].
move=> -[n _ [x [Fnx xoo <-]]].
have : (\bigcup_n F n) x by exists n.
by rewrite -h => -[[x' Xx' <-//]|xoo']; move/not_orP : xoo => -[].
have [n _ Fnr] : (\bigcup_n F n) r%:E by rewrite -h; left; exists r.
by exists n => //; exists r%:E => //; split => // -[].
+ (* NB: almost the same as the previous one, factorize?*)
move=> h.
rewrite [X in measurable X](_ : _ = X) // predeqE => r; split => [|Xr].
rewrite [X in measurable X](_ : _ = X)// predeqE => r; split => [|Xr].
move=> -[n _ [x [Fnx xoo <-]]].
have : (\bigcup_n F n) x by exists n.
by rewrite -h => -[[x' Xx' <-//]|xoo']; move/not_orP : xoo => -[].
have [n _ Fnr] : (\bigcup_n F n) r%:E by rewrite -h; left; exists r.
by exists n => //; exists r%:E => //; split => // -[].
+ move=> h.
rewrite [X in measurable X](_ : _ = X) // predeqE => r; split => [|Xr].
rewrite [X in measurable X](_ : _ = X)// predeqE => r; split => [|Xr].
move=> -[n _ [x [Fnx xoo <-]]].
have : (\bigcup_n F n) x by exists n.
by rewrite -h => -[[x' Xx' <-//]|].
Expand Down
Loading
Loading