Skip to content

Commit 84ff007

Browse files
committed
deprecate approximation and make its interface accessible
1 parent 61b7572 commit 84ff007

File tree

5 files changed

+200
-129
lines changed

5 files changed

+200
-129
lines changed

CHANGELOG_UNRELEASED.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,38 @@
1010
- in `normedtype.v`:
1111
+ lemmas `continuous_within_itvcyP`, `continuous_within_itvNycP`
1212

13+
- in `lebesgue_measure.v`:
14+
+ lemma `measurable_indicP`
15+
16+
- in `lebesgue_integral.v`:
17+
+ definition `approx_A` (was `Let A`)
18+
+ definition `approx_B` (was `Let B`)
19+
+ lemma `measurable_fun_sum`
20+
+ lemma `integrable_indic`
21+
1322
### Changed
23+
24+
- in `lebesgue_integrale.v`
25+
+ change implicits of `measurable_funP`
1426

1527
### Renamed
1628

29+
- in `lebesgue_measure.v`:
30+
+ `measurable_fun_indic` -> `measurable_indic`
31+
1732
### Generalized
1833

1934
### Deprecated
2035

36+
- in file `lebesgue_integral.v`:
37+
+ lemma `approximation`
38+
2139
### Removed
2240

41+
- in `lebesgue_integral.v`:
42+
+ lemma `measurable_indic` (was uselessly specializing `measurable_fun_indic` (now `measurable_indic`) from `lebesgue_measure.v`)
43+
+ notation `measurable_fun_indic` (deprecation since 0.6.3)
44+
2345
### Infrastructure
2446

2547
### Misc

theories/charge.v

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1921,29 +1921,29 @@ Lemma change_of_variables f E : (forall x, 0 <= f x) ->
19211921
\int[mu]_(x in E) (f x * ('d nu '/d mu) x) = \int[nu]_(x in E) f x.
19221922
Proof.
19231923
move=> f0 mE mf; set g := 'd nu '/d mu.
1924-
have [h [ndh hf]] := approximation mE mf (fun x _ => f0 x).
1924+
pose h := nnsfun_approx mE mf.
19251925
have -> : \int[nu]_(x in E) f x =
19261926
lim (\int[nu]_(x in E) (EFin \o h n) x @[n --> \oo]).
19271927
have fE x : E x -> f x = lim ((EFin \o h n) x @[n --> \oo]).
1928-
by move=> Ex; apply/esym/cvg_lim => //; exact: hf.
1928+
by move=> Ex; apply/esym/cvg_lim => //; exact: cvg_nnsfun_approx.
19291929
under eq_integral => x /[!inE] /fE -> //.
19301930
apply: monotone_convergence => //.
19311931
- move=> n; apply/measurable_EFinP.
19321932
by apply: (measurable_funS measurableT) => //; exact/measurable_funP.
19331933
- by move=> n x Ex //=; rewrite lee_fin.
1934-
- by move=> x Ex a b /ndh /=; rewrite lee_fin => /lefP.
1934+
- by move=> x Ex a b ab; rewrite lee_fin; exact/lefP/nd_nnsfun_approx.
19351935
have -> : \int[mu]_(x in E) (f \* g) x =
19361936
lim (\int[mu]_(x in E) ((EFin \o h n) \* g) x @[n --> \oo]).
19371937
have fg x :E x -> f x * g x = lim (((EFin \o h n) \* g) x @[n --> \oo]).
19381938
by move=> Ex; apply/esym/cvg_lim => //; apply: cvgeMr;
1939-
[exact: f_fin_num|exact: hf].
1939+
[exact: f_fin_num|exact: cvg_nnsfun_approx].
19401940
under eq_integral => x /[!inE] /fg -> //.
19411941
apply: monotone_convergence => [//| | |].
19421942
- move=> n; apply/emeasurable_funM; apply/measurable_funTS.
19431943
exact/measurable_EFinP.
19441944
exact: measurable_int (f_integrable _).
19451945
- by move=> n x Ex //=; rewrite mule_ge0 ?lee_fin//=; exact: f_ge0.
1946-
- by move=> x Ex a b /ndh /= /lefP hahb; rewrite lee_wpmul2r ?lee_fin// f_ge0.
1946+
- by move=> x Ex a b ab/=; rewrite lee_wpmul2r ?lee_fin ?f_ge0//; exact/lefP/nd_nnsfun_approx.
19471947
suff suf n : \int[mu]_(x in E) ((EFin \o h n) x * g x) =
19481948
\int[nu]_(x in E) (EFin \o h n) x.
19491949
by under eq_fun do rewrite suf.
@@ -2008,7 +2008,7 @@ Proof.
20082008
move=> numu mula mE; have nula := measure_dominates_trans numu mula.
20092009
have mf : measurable_fun E ('d nu '/d mu).
20102010
exact/measurable_funTS/(measurable_int _ (f_integrable _)).
2011-
have [h [ndh hf]] := approximation mE mf (fun x _ => f_ge0 numu x).
2011+
pose h := approximation mE mf.
20122012
apply: integral_ae_eq => //.
20132013
- apply: (integrableS measurableT) => //.
20142014
apply: f_integrable.
@@ -2018,7 +2018,7 @@ apply: integral_ae_eq => //.
20182018
- move=> A AE mA; rewrite change_of_variables//.
20192019
+ by rewrite -!f_integral.
20202020
+ exact: f_ge0.
2021-
+ exact: measurable_funS mf.
2021+
+ by move: (mf); exact: measurable_funS.
20222022
Qed.
20232023

20242024
End chain_rule.

theories/kernel.v

Lines changed: 29 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -571,24 +571,30 @@ Lemma measurable_fun_integral_finite_kernel (l : R.-fker X ~> Y)
571571
(k0 : forall z, 0 <= k z) (mk : measurable_fun [set: X * Y] k) :
572572
measurable_fun [set: X] (fun x => \int[l x]_y k (x, y)).
573573
Proof.
574-
have [k_ [ndk_ k_k]] := approximation measurableT mk (fun x _ => k0 x).
575-
apply: (measurable_fun_xsection_integral ndk_ (k_k ^~ Logic.I)) => n r.
576-
have [l_ hl_] := measure_uub l.
577-
by apply: measurable_fun_xsection_finite_kernel => // /[!inE].
574+
pose k_ := nnsfun_approx measurableT mk.
575+
apply: (@measurable_fun_xsection_integral _ k_).
576+
- by move=> a b ab; exact/nd_nnsfun_approx.
577+
- by move=> z; exact/cvg_nnsfun_approx.
578+
- move => n r.
579+
have [l_ hl_] := measure_uub l.
580+
by apply: measurable_fun_xsection_finite_kernel => // /[!inE].
578581
Qed.
579582

580583
Lemma measurable_fun_integral_sfinite_kernel (l : R.-sfker X ~> Y)
581584
(k0 : forall t, 0 <= k t) (mk : measurable_fun [set: X * Y] k) :
582585
measurable_fun [set: X] (fun x => \int[l x]_y k (x, y)).
583586
Proof.
584-
have [k_ [ndk_ k_k]] := approximation measurableT mk (fun xy _ => k0 xy).
585-
apply: (measurable_fun_xsection_integral ndk_ (k_k ^~ Logic.I)) => n r.
586-
have [l_ hl_] := sfinite_kernel l.
587-
rewrite (_ : (fun x => _) = (fun x =>
588-
mseries (l_ ^~ x) 0 (xsection (k_ n @^-1` [set r]) x))); last first.
589-
by apply/funext => x; rewrite hl_//; exact/measurable_xsection.
590-
apply: ge0_emeasurable_fun_sum => // m _.
591-
by apply: measurable_fun_xsection_finite_kernel => // /[!inE].
587+
pose k_ := nnsfun_approx measurableT mk.
588+
apply: (@measurable_fun_xsection_integral _ k_).
589+
- by move=> a b ab; exact/nd_nnsfun_approx.
590+
- by move=> z; exact/cvg_nnsfun_approx.
591+
- move => n r.
592+
have [l_ hl_] := sfinite_kernel l.
593+
rewrite (_ : (fun x => _) = (fun x =>
594+
mseries (l_ ^~ x) 0 (xsection (k_ n @^-1` [set r]) x))); last first.
595+
by apply/funext => x; rewrite hl_//; exact/measurable_xsection.
596+
apply: ge0_emeasurable_fun_sum => // m _.
597+
by apply: measurable_fun_xsection_finite_kernel => // /[!inE].
592598
Qed.
593599

594600
End measurable_fun_integral_finite_sfinite.
@@ -1007,8 +1013,11 @@ Lemma measurable_fun_integral_kernel
10071013
(k : Y -> \bar R) (k0 : forall z, 0 <= k z) (mk : measurable_fun [set: Y] k) :
10081014
measurable_fun [set: X] (fun x => \int[l x]_y k y).
10091015
Proof.
1010-
have [k_ [ndk_ k_k]] := approximation measurableT mk (fun x _ => k0 x).
1011-
by apply: (measurable_fun_preimage_integral ndk_ k_k) => n r; exact/ml.
1016+
pose k_ := nnsfun_approx measurableT mk.
1017+
apply: (@measurable_fun_preimage_integral _ _ _ _ _ _ k_) => //.
1018+
- by move=> a b ab; exact/nd_nnsfun_approx.
1019+
- by move=> z _; exact/cvg_nnsfun_approx.
1020+
- by move=> n r; exact/ml.
10121021
Qed.
10131022

10141023
End measurable_fun_integral_kernel.
@@ -1077,13 +1086,13 @@ Lemma integral_kcomp x f : (forall z, 0 <= f z) -> measurable_fun [set: Z] f ->
10771086
\int[kcomp l k x]_z f z = \int[l x]_y (\int[k (x, y)]_z f z).
10781087
Proof.
10791088
move=> f0 mf.
1080-
have [f_ [ndf_ f_f]] := approximation measurableT mf (fun z _ => f0 z).
1089+
pose f_ := nnsfun_approx measurableT mf.
10811090
transitivity (\int[kcomp l k x]_z (lim ((f_ n z)%:E @[n --> \oo]))).
1082-
by apply/eq_integral => z _; apply/esym/cvg_lim => //=; exact: f_f.
1091+
by apply/eq_integral => z _; apply/esym/cvg_lim => //=; exact: cvg_nnsfun_approx.
10831092
rewrite monotone_convergence//; last 3 first.
10841093
by move=> n; exact/measurable_EFinP.
10851094
by move=> n z _; rewrite lee_fin.
1086-
by move=> z _ a b /ndf_ /lefP ab; rewrite lee_fin.
1095+
by move=> z _ a b ab; rewrite lee_fin; exact/lefP/nd_nnsfun_approx.
10871096
rewrite (_ : (fun _ => _) =
10881097
(fun n => \int[l x]_y (\int[k (x, y)]_z (f_ n z)%:E)))//; last first.
10891098
by apply/funext => n; rewrite integral_kcomp_nnsfun.
@@ -1099,12 +1108,12 @@ transitivity (\int[l x]_y lim ((\int[k (x, y)]_z (f_ n z)%:E) @[n --> \oo])).
10991108
+ exact/measurable_EFinP.
11001109
+ by move=> z _; rewrite lee_fin.
11011110
+ exact/measurable_EFinP.
1102-
+ by move: ab => /ndf_ /lefP ab z _; rewrite lee_fin.
1111+
+ by move=> z _; rewrite lee_fin; exact/lefP/nd_nnsfun_approx.
11031112
apply: eq_integral => y _; rewrite -monotone_convergence//; last 3 first.
11041113
- by move=> n; exact/measurable_EFinP.
11051114
- by move=> n z _; rewrite lee_fin.
1106-
- by move=> z _ a b /ndf_ /lefP; rewrite lee_fin.
1107-
by apply: eq_integral => z _; apply/cvg_lim => //; exact: f_f.
1115+
- by move=> z _ a b ab; rewrite lee_fin; exact/lefP/nd_nnsfun_approx.
1116+
by apply: eq_integral => z _; apply/cvg_lim => //; exact: cvg_nnsfun_approx.
11081117
Qed.
11091118

11101119
End integral_kcomp.

0 commit comments

Comments
 (0)