Module mathcomp.analysis.ess_sup_inf
From HB Require Import structures.From mathcomp Require Import boot order algebra.
From mathcomp Require Import boolp classical_sets functions cardinality.
From mathcomp Require Import reals ereal topology normedtype sequences.
From mathcomp Require Import measure lebesgue_measure measurable_realfun.
# Essential infimum and essential supremum
```
ess_sup f == essential supremum of the function f : T -> R where T is a
semiRingOfSetsType and R is a realType
ess_inf f == essential infimum
```
Unset SsrOldRewriteGoalsOrder.
Set Implicit Arguments.
Unset Strict Implicit.
Unset Printing Implicit Defensive.
Import Order.TTheory GRing.Theory Num.Def Num.Theory.
Import numFieldNormedType.Exports.
Local Open Scope classical_set_scope.
Local Open Scope ring_scope.
Local Open Scope ereal_scope.
Section essential_supremum.
Context { : semiRingOfSetsType d} { : realType}.
Variable : {measure set T -> \bar R}.
Implicit Type f : T -> \bar R.
Definition
ess_sup
Source code
:= ereal_inf [set | \forall \ae mu, f x <= y].Source code
Lemma
ess_supEae
Source code
: ess_sup f = ereal_inf [set | \forall \ae mu, f x <= y].Source code
Proof.
by []. Qed.
End essential_supremum.
Section essential_supremum_lemmas.
Context { : measurableType d} { : realType}.
Variable : {measure set T -> \bar R}.
Implicit Types (f g : T -> \bar R) (h k : T -> R) (x y : \bar R) (r : R).
Lemma
ae_le_measureP
Source code
: measurable_fun [set: T] f ->Source code
(\forall \ae mu, f x <= y) <-> mu (f @^-1` `]y, +oo[) = 0.
Proof.
move=> f_meas; have fVroo_meas : d.-measurable (f @^-1` `]y, +oo[).
by rewrite -[_ @^-1` _]setTI; apply/f_meas=> //; exact/emeasurable_itv.
have setCfVroo : f @^-1` `]y, +oo[ = ~` [set | f x <= y].
by apply: setC_inj; rewrite preimage_setC setCitv/= set_itvxx setU0 setCK.
split.
move=> [N [dN muN0 inN]]; rewrite (subset_measure0 _ dN)// => x.
by rewrite setCfVroo; apply: inN.
set N := (X in mu X) => muN0; exists N; rewrite -setCfVroo.
by split => //; exact: fVroo_meas.
Qed.
by rewrite -[_ @^-1` _]setTI; apply/f_meas=> //; exact/emeasurable_itv.
have setCfVroo : f @^-1` `]y, +oo[ = ~` [set | f x <= y].
by apply: setC_inj; rewrite preimage_setC setCitv/= set_itvxx setU0 setCK.
split.
move=> [N [dN muN0 inN]]; rewrite (subset_measure0 _ dN)// => x.
by rewrite setCfVroo; apply: inN.
set N := (X in mu X) => muN0; exists N; rewrite -setCfVroo.
by split => //; exact: fVroo_meas.
Qed.
Local Notation
ess_sup
Source code
:= (ess_sup mu).Source code
Lemma
ess_supEmu0
Source code
: measurable_fun [set: T] f ->Source code
ess_sup f = ereal_inf [set | mu (f @^-1` `]y, +oo[) = 0].
Proof.
Lemma
ess_sup_ge
Source code
: \forall \ae mu, f x <= ess_sup f.Source code
Proof.
rewrite ess_supEae//; set I := (X in ereal_inf X).
have [->|IN0] := eqVneq I set0.
by rewrite ereal_inf0; apply: nearW => ?; rewrite leey.
have [u uI uinf] := ereal_inf_seq IN0.
rewrite -(cvg_lim _ uinf)//; near=> x.
rewrite lime_ge//; first by apply/cvgP: uinf.
by apply: nearW; near: x; apply/ae_foralln => n; apply: uI.
Unshelve. all: by end_near. Qed.
have [->|IN0] := eqVneq I set0.
by rewrite ereal_inf0; apply: nearW => ?; rewrite leey.
have [u uI uinf] := ereal_inf_seq IN0.
rewrite -(cvg_lim _ uinf)//; near=> x.
rewrite lime_ge//; first by apply/cvgP: uinf.
by apply: nearW; near: x; apply/ae_foralln => n; apply: uI.
Unshelve. all: by end_near. Qed.
Lemma
ess_supP
Source code
: reflect (\forall \ae mu, f x <= y) (ess_sup f <= y).Source code
Proof.
apply: (iffP (ereal_inf_leP _)) => /=; last 2 first.
- by move=> [z fz zy]; near do apply: le_trans zy.
- by move=> fy; exists y.
by rewrite -ess_supEae//; exact: ess_sup_ge.
Unshelve. all: by end_near. Qed.
- by move=> [z fz zy]; near do apply: le_trans zy.
- by move=> fy; exists y.
by rewrite -ess_supEae//; exact: ess_sup_ge.
Unshelve. all: by end_near. Qed.
Lemma
le_ess_sup
Source code
: (\forall \ae mu, f x <= g x) -> ess_sup f <= ess_sup g.Source code
Proof.
move=> fg; apply/ess_supP => //.
near do rewrite (le_trans (near fg _ _))//=.
exact: ess_sup_ge.
Unshelve. all: by end_near. Qed.
near do rewrite (le_trans (near fg _ _))//=.
exact: ess_sup_ge.
Unshelve. all: by end_near. Qed.
Lemma
eq_ess_sup
Source code
: (\forall \ae mu, f x = g x) -> ess_sup f = ess_sup g.Source code
Proof.
Lemma
ess_sup_cst
Source code
: 0 < mu [set: T] -> ess_sup (cst x) = x.Source code
Proof.
move=> muT_gt0; apply/eqP; rewrite eq_le; apply/andP; split.
by apply/ess_supP => //; apply: nearW.
have ae_proper := ae_properfilter_algebraOfSetsType muT_gt0.
by near (almost_everywhere mu) => y; near: y; apply: ess_sup_ge.
Unshelve. all: by end_near. Qed.
by apply/ess_supP => //; apply: nearW.
have ae_proper := ae_properfilter_algebraOfSetsType muT_gt0.
by near (almost_everywhere mu) => y; near: y; apply: ess_sup_ge.
Unshelve. all: by end_near. Qed.
Lemma
ess_sup_ae_cst
Source code
: 0 < mu [set: T] ->Source code
(\forall \ae mu, f x = y) -> ess_sup f = y.
Proof.
Lemma
ess_sup_gee
Source code
: 0 < mu [set: T] ->Source code
(\forall \ae mu, a <= f x) -> a <= ess_sup f.
Proof.
Lemma
abs_sup_eq0_ae_eq
Source code
: ess_sup (abse \o f) = 0 -> f = \0 %[ae mu].Source code
Proof.
Lemma
abs_ess_sup_eq0
Source code
: mu [set: T] > 0 ->Source code
f = \0 %[ae mu] -> ess_sup (abse \o f) = 0.
Proof.
move=> muT_gt0 f0; apply/eqP; rewrite eq_le; apply/andP; split.
by apply/ess_supP => /=; near do rewrite (near f0 _ _)//= normr0//.
by rewrite -[0]ess_sup_cst// le_ess_sup//=; near=> x; rewrite abse_ge0.
Unshelve. all: by end_near. Qed.
by apply/ess_supP => /=; near do rewrite (near f0 _ _)//= normr0//.
by rewrite -[0]ess_sup_cst// le_ess_sup//=; near=> x; rewrite abse_ge0.
Unshelve. all: by end_near. Qed.
Lemma
ess_sup_pZl
Source code
: (0 < r)%R ->Source code
ess_sup (cst r%:E \* f) = r%:E * ess_sup f.
Proof.
move=> /[dup] /ltW r_ge0 r_gt0.
gen have esc_le : r f r_ge0 r_gt0 /
ess_sup (cst r%:E \* f) <= r%:E * ess_sup f.
by apply/ess_supP; near do rewrite /cst/= lee_pmul2l//; apply/ess_supP.
apply/eqP; rewrite eq_le esc_le// -lee_pdivlMl//=.
apply: le_trans (esc_le _ _ _ _); rewrite ?invr_gt0 ?invr_ge0//.
by under eq_fun do rewrite muleA -EFinM mulVf ?mul1e ?gt_eqF//.
Unshelve. all: by end_near. Qed.
gen have esc_le : r f r_ge0 r_gt0 /
ess_sup (cst r%:E \* f) <= r%:E * ess_sup f.
by apply/ess_supP; near do rewrite /cst/= lee_pmul2l//; apply/ess_supP.
apply/eqP; rewrite eq_le esc_le// -lee_pdivlMl//=.
apply: le_trans (esc_le _ _ _ _); rewrite ?invr_gt0 ?invr_ge0//.
by under eq_fun do rewrite muleA -EFinM mulVf ?mul1e ?gt_eqF//.
Unshelve. all: by end_near. Qed.
Lemma
ess_supZl
Source code
: mu [set: T] > 0 -> (0 <= r)%R ->Source code
ess_sup (cst r%:E \* f) = r%:E * ess_sup f.
Proof.
move=> muTN0; case: ltgtP => // [r_gt0|<-] _; first exact: ess_sup_pZl.
by under eq_fun do rewrite mul0e; rewrite mul0e ess_sup_cst.
Qed.
by under eq_fun do rewrite mul0e; rewrite mul0e ess_sup_cst.
Qed.
Lemma
ess_sup_eqNyP
Source code
: ess_sup f = -oo <-> \forall \ae mu, f x = -oo.Source code
Proof.
Lemma
ess_supD
Source code
: ess_sup (f \+ g) <= ess_sup f + ess_sup g.Source code
Lemma
ess_sup_absD
Source code
:Source code
ess_sup (abse \o (f \+ g)) <= ess_sup (abse \o f) + ess_sup (abse \o g).
Proof.
End essential_supremum_lemmas.
Arguments ess_sup_ae_cst {d T R mu f}.
Arguments ess_supP {d T R mu f y}.
Section real_essential_supremum.
Context { : semiRingOfSetsType d} { : realType}.
Variable : {measure set T -> \bar R}.
Implicit Types f : T -> R.
Notation
ess_supr
Source code
f := (ess_sup mu (EFin \o f)).Source code
End real_essential_supremum.
Section real_essential_supremum_lemmas.
Context { : measurableType d} { : realType}.
Variable : {measure set T -> \bar R}.
Implicit Types (f : T -> R) (r : R).
Notation
ess_supr
Source code
f := (ess_sup mu (EFin \o f)).Source code
Lemma
ess_supr_bounded
Source code
: ess_supr f < +oo ->Source code
exists , \forall \ae mu, (f x <= M)%R.
Proof.
set g := EFin \o f => ltfy; have [|supfNy] := eqVneq (ess_sup mu g) -oo.
by move=> /ess_sup_eqNyP fNy; exists 0%:R; apply: filterS fNy.
have supf_fin : ess_supr f \is a fin_num by case: ess_sup ltfy supfNy.
by exists (fine (ess_supr f)); near do rewrite -lee_fin fineK//; apply/ess_supP.
Unshelve. all: by end_near. Qed.
by move=> /ess_sup_eqNyP fNy; exists 0%:R; apply: filterS fNy.
have supf_fin : ess_supr f \is a fin_num by case: ess_sup ltfy supfNy.
by exists (fine (ess_supr f)); near do rewrite -lee_fin fineK//; apply/ess_supP.
Unshelve. all: by end_near. Qed.
Lemma
ess_sup_eqr0_ae_eq
Source code
: ess_supr (normr \o f) = 0 -> f = 0%R %[ae mu].Source code
Proof.
Lemma
ess_suprZl
Source code
: mu [set: T] > 0 -> (0 <= r)%R ->Source code
ess_supr (cst r \* f)%R = r%:E * ess_supr f.
Proof.
Lemma
ess_sup_ger
Source code
: 0 < mu [set: T] -> (forall , x <= (f t)%:E) ->Source code
x <= ess_supr f.
Proof.
Lemma
ess_sup_ler
Source code
: (forall , (f t)%:E <= y) -> ess_supr f <= y.Source code
Lemma
ess_sup_cstr
Source code
: 0 < mu [set: T] -> ess_supr (cst y) = y%:E.Source code
Proof.
Lemma
ess_suprD
Source code
: ess_supr (f \+ g)%R <= ess_supr f + ess_supr g.Source code
Lemma
ess_sup_normD
Source code
:Source code
ess_supr (normr \o (f \+ g)%R) <= ess_supr (normr \o f) + ess_supr (normr \o g).
Proof.
End real_essential_supremum_lemmas.
Notation
ess_supr
Source code
mu f := (ess_sup mu (EFin \o f)).Source code
Section essential_infimum.
Context { : semiRingOfSetsType d} { : realType}.
Variable : {measure set T -> \bar R}.
Implicit Types f : T -> \bar R.
Definition
ess_inf
Source code
:= ereal_sup [set | \forall \ae mu, y <= f x].Source code
Lemma
ess_infEae
Source code
: ess_inf f = ereal_sup [set | \forall \ae mu, y <= f x].Source code
Proof.
by []. Qed.
End essential_infimum.
Section essential_infimum_lemmas.
Context { : measurableType d} { : realType}.
Variable : {measure set T -> \bar R}.
Implicit Types (f : T -> \bar R) (x y : \bar R) (r : R).
Local Notation
ess_inf
Source code
:= (ess_inf mu).Source code
Local Notation
ess_sup
Source code
:= (ess_sup mu).Source code
Lemma
ess_infEN
Source code
: ess_inf f = - ess_sup (\- f).Source code
Proof.
rewrite ess_supEae ess_infEae ereal_infEN oppeK; congr (ereal_sup _).
apply/seteqP; split=> [y /= y_le|_ [/= y y_ge <-]].
by exists (- y); rewrite ?oppeK//=; apply: filterS y_le => x; rewrite leeN2.
by apply: filterS y_ge => x; rewrite leeNl.
Qed.
apply/seteqP; split=> [y /= y_le|_ [/= y y_ge <-]].
by exists (- y); rewrite ?oppeK//=; apply: filterS y_le => x; rewrite leeN2.
by apply: filterS y_ge => x; rewrite leeNl.
Qed.
Lemma
ess_supEN
Source code
: ess_sup f = - ess_inf (\- f).Source code
Proof.
Lemma
ess_infN
Source code
: ess_inf (\- f) = - ess_sup f.Source code
Lemma
ess_supN
Source code
: ess_sup (\- f) = - ess_inf f.Source code
Lemma
ess_infP
Source code
: reflect (\forall \ae mu, y <= f x) (y <= ess_inf f).Source code
Lemma
ess_inf_le
Source code
: \forall \ae mu, ess_inf f <= f x.Source code
Proof.
exact/ess_infP. Qed.
Lemma
le_ess_inf
Source code
: (\forall \ae mu, f x <= g x) -> ess_inf f <= ess_inf g.Source code
Proof.
move=> fg; apply/ess_infP => //.
near do rewrite (le_trans _ (near fg _ _))//=.
exact: ess_inf_le.
Unshelve. all: by end_near. Qed.
near do rewrite (le_trans _ (near fg _ _))//=.
exact: ess_inf_le.
Unshelve. all: by end_near. Qed.
Lemma
eq_ess_inf
Source code
: (\forall \ae mu, f x = g x) -> ess_inf f = ess_inf g.Source code
Proof.
Lemma
ess_inf_cst
Source code
: 0 < mu [set: T] -> ess_inf (cst x) = x.Source code
Proof.
Lemma
ess_inf_ae_cst
Source code
: 0 < mu [set: T] ->Source code
(\forall \ae mu, f x = y) -> ess_inf f = y.
Proof.
Lemma
ess_inf_gee
Source code
: 0 < mu [set: T] ->Source code
(\forall \ae mu, y <= f x) -> y <= ess_inf f.
Proof.
Lemma
ess_inf_pZl
Source code
: (0 < r)%R -> ess_inf (cst r%:E \* f) = r%:E * ess_inf f.Source code
Proof.
Lemma
ess_infZl
Source code
: mu [set: T] > 0 -> (0 <= r)%R ->Source code
ess_inf (cst r%:E \* f) = r%:E * ess_inf f.
Proof.
move=> muTN0; case: ltgtP => // [a_gt0|<-] _; first exact: ess_inf_pZl.
by under eq_fun do rewrite mul0e; rewrite mul0e ess_inf_cst.
Qed.
by under eq_fun do rewrite mul0e; rewrite mul0e ess_inf_cst.
Qed.
Lemma
ess_inf_eqyP
Source code
: ess_inf f = +oo <-> \forall \ae mu, f x = +oo.Source code
Proof.
Lemma
ess_infD
Source code
: ess_inf (f \+ g) >= ess_inf f + ess_inf g.Source code
End essential_infimum_lemmas.
Arguments ess_inf_ae_cst {d T R mu f}.
Arguments ess_infP {d T R mu f y}.
Section real_essential_infimum.
Context { : measurableType d} { : realType}.
Variable : {measure set T -> \bar R}.
Implicit Types (f : T -> R) (x : \bar R) (r : R).
Notation
ess_infr
Source code
f := (ess_inf mu (EFin \o f)).Source code
Lemma
ess_infr_bounded
Source code
: ess_infr f > -oo ->Source code
exists , \forall \ae mu, (f x >= M)%R.
Proof.
set g := EFin \o f => ltfy; have [|inffNy] := eqVneq (ess_inf mu g) +oo.
by move=> /ess_inf_eqyP fNy; exists 0%:R; apply: filterS fNy.
have inff_fin : ess_infr f \is a fin_num by case: ess_inf ltfy inffNy.
by exists (fine (ess_infr f)); near do rewrite -lee_fin fineK//; apply/ess_infP.
Unshelve. all: by end_near. Qed.
by move=> /ess_inf_eqyP fNy; exists 0%:R; apply: filterS fNy.
have inff_fin : ess_infr f \is a fin_num by case: ess_inf ltfy inffNy.
by exists (fine (ess_infr f)); near do rewrite -lee_fin fineK//; apply/ess_infP.
Unshelve. all: by end_near. Qed.
Lemma
ess_infrZl
Source code
: mu [set: T] > 0 -> (0 <= r)%R ->Source code
ess_infr (cst r \* f)%R = r%:E * ess_infr f.
Proof.
Lemma
ess_inf_ger
Source code
: 0 < mu [set: T] -> (forall , x <= (f t)%:E) ->Source code
x <= ess_infr f.
Proof.
Lemma
ess_inf_ler
Source code
: (forall , x <= (f t)%:E) -> x <= ess_infr f.Source code
Lemma
ess_inf_cstr
Source code
: 0 < mu [set: T] -> ess_infr (cst r) = r%:E.Source code
Proof.
End real_essential_infimum.
Notation
ess_infr
Source code
mu f := (ess_inf mu (EFin \o f)).Source code