@@ -10,6 +10,11 @@ Require Import ereal reals signed topology prodnormedzmodule.
1010(* *)
1111(* Note that balls in topology.v are not necessarily open, here they are. *)
1212(* *)
13+ (* * Limit superior and inferior: *)
14+ (* limf_esup f F, limf_einf f F == limit sup/inferior of f at "filter" F *)
15+ (* f has type X -> \bar R. *)
16+ (* F has type set (set X). *)
17+ (* *)
1318(* * Normed Topological Abelian groups: *)
1419(* pseudoMetricNormedZmodType R == interface type for a normed topological *)
1520(* Abelian group equipped with a norm *)
@@ -144,6 +149,35 @@ Import numFieldTopology.Exports.
144149Local Open Scope classical_set_scope.
145150Local Open Scope ring_scope.
146151
152+ Section limf_esup_einf.
153+ Variables (T : choiceType) (X : filteredType T) (R : realFieldType).
154+ Implicit Types (f : X -> \bar R) (F : set (set X)).
155+ Local Open Scope ereal_scope.
156+
157+ Definition limf_esup f F := ereal_inf [set ereal_sup (f @` V) | V in F].
158+
159+ Definition limf_einf f F := - limf_esup (\- f) F.
160+
161+ Lemma limf_esupE f F :
162+ limf_esup f F = ereal_inf [set ereal_sup (f @` V) | V in F].
163+ Proof . by []. Qed .
164+
165+ Lemma limf_einfE f F :
166+ limf_einf f F = ereal_sup [set ereal_inf (f @` V) | V in F].
167+ Proof .
168+ rewrite /limf_einf limf_esupE /ereal_inf oppeK -[in RHS]image_comp /=.
169+ congr (ereal_sup [set _ | _ in [set ereal_sup _ | _ in _]]).
170+ by under eq_fun do rewrite -image_comp.
171+ Qed .
172+
173+ Lemma limf_esupN f F : limf_esup (\- f) F = - limf_einf f F.
174+ Proof . by rewrite /limf_einf oppeK. Qed .
175+
176+ Lemma limf_einfN f F : limf_einf (\- f) F = - limf_esup f F.
177+ Proof . by rewrite /limf_einf; under eq_fun do rewrite oppeK. Qed .
178+
179+ End limf_esup_einf.
180+
147181Definition pointed_of_zmodule (R : zmodType) : pointedType := PointedType R 0.
148182
149183Definition filtered_of_normedZmod (K : numDomainType) (R : normedZmodType K)
@@ -214,6 +248,20 @@ move=> [y [[z Az oppzey] [t Bt opptey]]]; exists (- y).
214248by split; [rewrite -oppzey opprK|rewrite -opptey opprK].
215249Qed .
216250
251+ Lemma dnbhsN {R : numFieldType} (r : R) :
252+ (- r)%R^' = (fun A => -%R @` A) @` r^'.
253+ Proof .
254+ apply/seteqP; split=> [A [e/= e0 reA]|_/= [A [e/= e0 reA <-]]].
255+ exists (-%R @` A).
256+ exists e => // x/= rxe xr; exists (- x)%R; rewrite ?opprK//.
257+ by apply: reA; rewrite ?eqr_opp//= opprK addrC distrC.
258+ rewrite image_comp (_ : _ \o _ = idfun) ?image_id// funeqE => x/=.
259+ by rewrite opprK.
260+ exists e => //= x/=; rewrite -opprD normrN => axe xa.
261+ exists (- x)%R; rewrite ?opprK//; apply: reA; rewrite ?eqr_oppLR//=.
262+ by rewrite opprK.
263+ Qed .
264+
217265Module PseudoMetricNormedZmodule.
218266Section ClassDef.
219267Variable R : numDomainType.
@@ -1629,6 +1677,15 @@ End Exports.
16291677End numFieldNormedType.
16301678Import numFieldNormedType.Exports.
16311679
1680+ Lemma limf_esup_dnbhsN {R : realType} (f : R -> \bar R) (a : R) :
1681+ limf_esup f a^' = limf_esup (fun x => f (- x)%R) (- a)%R^'.
1682+ Proof .
1683+ rewrite /limf_esup dnbhsN image_comp/=.
1684+ congr (ereal_inf [set _ | _ in _]); apply/funext => A /=.
1685+ rewrite image_comp/= -compA (_ : _ \o _ = idfun)// funeqE => x/=.
1686+ by rewrite opprK.
1687+ Qed .
1688+
16321689Section NormedModule_numDomainType.
16331690Variables (R : numDomainType) (V : normedModType R).
16341691
@@ -2077,6 +2134,47 @@ Lemma nbhs_left_ge x z : z < x -> \forall y \near x^'-, z <= y.
20772134Proof . by move=> xz; near do apply/ltW; apply: nbhs_left_gt.
20782135Unshelve. all: by end_near. Qed .
20792136
2137+ Lemma not_near_at_rightP T (f : R -> T) (p : R) (P : pred T) :
2138+ ~ (\forall x \near p^'+, P (f x)) ->
2139+ forall e : {posnum R}, exists2 x, p < x < p + e%:num & ~ P (f x).
2140+ Proof .
2141+ move=> pPf e; apply: contrapT => /forallPNP pePf; apply: pPf; near=> t.
2142+ apply: contrapT; apply: pePf; apply/andP; split.
2143+ - by near: t; exact: nbhs_right_gt.
2144+ - by near: t; apply: nbhs_right_lt; rewrite ltr_addl.
2145+ Unshelve. all: by end_near. Qed .
2146+
2147+ Lemma withinN (A : set R) a :
2148+ within A (nbhs (- a)) = - x @[x --> within (-%R @` A) (nbhs a)].
2149+ Proof .
2150+ rewrite eqEsubset /=; split; move=> E /= [e e0 aeE]; exists e => //.
2151+ move=> r are ra; apply: aeE; last by rewrite memNE opprK.
2152+ by rewrite /= opprK addrC distrC.
2153+ move=> r aer ar; rewrite -(opprK r); apply: aeE; last by rewrite -memNE.
2154+ by rewrite /= opprK -normrN opprD.
2155+ Qed .
2156+
2157+ Let fun_predC (T : choiceType) (f : T -> T) (p : pred T) : involutive f ->
2158+ [set f x | x in p] = [set x | x in p \o f].
2159+ Proof .
2160+ by move=> fi; apply/seteqP; split => _/= [y hy <-];
2161+ exists (f y) => //; rewrite fi.
2162+ Qed .
2163+
2164+ Lemma at_rightN a : (- a)^'+ = -%R @ a^'-.
2165+ Proof .
2166+ rewrite /at_right withinN [X in within X _](_ : _ = [set u | u < a])//.
2167+ rewrite (@fun_predC _ -%R)/=; last exact: opprK.
2168+ by rewrite image_id; under eq_fun do rewrite ltr_oppl opprK.
2169+ Qed .
2170+
2171+ Lemma at_leftN a : (- a)^'- = -%R @ a^'+.
2172+ Proof .
2173+ rewrite /at_left withinN [X in within X _](_ : _ = [set u | a < u])//.
2174+ rewrite (@fun_predC _ -%R)/=; last exact: opprK.
2175+ by rewrite image_id; under eq_fun do rewrite ltr_oppl opprK.
2176+ Qed .
2177+
20802178End at_left_right.
20812179#[global] Typeclasses Opaque at_left at_right.
20822180Notation "x ^'-" := (at_left x) : classical_set_scope.
@@ -2088,6 +2186,20 @@ Notation "x ^'+" := (at_right x) : classical_set_scope.
20882186#[global] Hint Extern 0 (Filter (nbhs _^'-)) =>
20892187 (apply: at_left_proper_filter) : typeclass_instances.
20902188
2189+ Lemma cvg_at_leftNP {T : topologicalType} {R : numFieldType}
2190+ (f : R -> T) a (l : T) :
2191+ f @ a^'- --> l <-> f \o -%R @ (- a)^'+ --> l.
2192+ Proof .
2193+ by rewrite at_rightN -?fmap_comp; under [_ \o _]eq_fun => ? do rewrite /= opprK.
2194+ Qed .
2195+
2196+ Lemma cvg_at_rightNP {T : topologicalType} {R : numFieldType}
2197+ (f : R -> T) a (l : T) :
2198+ f @ a^'+ --> l <-> f \o -%R @ (- a)^'- --> l.
2199+ Proof .
2200+ by rewrite at_leftN -?fmap_comp; under [_ \o _]eq_fun => ? do rewrite /= opprK.
2201+ Qed .
2202+
20912203Section open_itv_subset.
20922204Context {R : realType}.
20932205Variables (A : set R) (x : R).
0 commit comments