Skip to content

Commit b0cf09f

Browse files
committed
wip and tried making factory from uniform to normedModType
1 parent 431dc8b commit b0cf09f

File tree

2 files changed

+79
-2
lines changed

2 files changed

+79
-2
lines changed

theories/holomorphy.v

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,25 @@ I don't want the canonical lmodtype structure on C,
2323
Therefore this is based on a fork of real-closed *)
2424
HB.instance Definition _ (R : rcfType) := NormedModule.copy R[i] R[i]^o.
2525

26+
HB.instance Definition _ (R : rcfType) := Uniform.copy (Rcomplex R) R[i].
27+
HB.instance Definition _ (R : rcfType) := Pointed.copy (Rcomplex R) R[i].
28+
29+
Section Rcomplex_NormedModType.
30+
Variable (R : rcfType).
31+
HB.howto Rcomplex normedModType 11.
32+
33+
Definition ball : R -> Rcomplex R -> R -> Prop
34+
- ball_center_subproof : forall (x : M) (e : R), 0 < e -> ball x e x
35+
- ball_sym_subproof : forall (x y : M) (e : R), ball x e y -> ball y e x
36+
- ball_triangle_subproof :
37+
forall (x y z : M) (e1 e2 : R),
38+
ball x e1 y -> ball y e2 z -> ball x (e1 + e2)%E z
39+
- entourageE_subproof : entourage = entourage_ ball
40+
41+
HB.about Uniform_isPseudoMetric.Build.
42+
; NormedZmod_PseudoMetric_eq;
43+
PseudoMetricNormedZmod_Lmodule_isNormedModule
44+
2645
HB.factory Record Normed_And_Lmodule_isNormedModule (K : numFieldType) R of @Num.NormedZmodule K R & GRing.Lmodule K R := {
2746
normrZ : forall (l : K) (x : R), normr (l *: x) = normr l * normr x;
2847
}.
@@ -239,15 +258,15 @@ Lemma real_normc_ler (x y : R) :
239258
Proof.
240259
rewrite /normc /= -ler_sqr ?nnegrE ?normr_ge0 ?sqrtr_ge0 //.
241260
rewrite sqr_sqrtr ?addr_ge0 ?sqr_ge0 ?real_normK //=.
242-
by rewrite ler_addl ?sqr_ge0.
261+
by rewrite lerDl ?sqr_ge0.
243262
Qed.
244263

245264
Lemma im_normc_ler (x y : R) :
246265
`|y| <= normc (x +i* y).
247266
Proof.
248267
rewrite /normc /= -ler_sqr ?nnegrE ?normr_ge0 ?sqrtr_ge0 //.
249268
rewrite sqr_sqrtr ?addr_ge0 ?sqr_ge0 ?real_normK //=.
250-
by rewrite ler_addr ?sqr_ge0.
269+
by rewrite lerDr ?sqr_ge0.
251270
Qed.
252271

253272
End complex_extras.
@@ -403,6 +422,14 @@ have -> : (fun h : C => h^-1 *: ((f (c + h) - f c))) @ (realC @ (dnbhs 0)) =
403422
\o realC @ (dnbhs (0 : R)) by [].
404423
suff -> : ( (fun h : C => h^-1 *: (f (c + h) - f c)) \o realC)
405424
= (fun h : R => h^-1 *: ((f%:Rfun \o shift c) (h *: (1%:Rc)) - f c : Rcomplex _) ) :> (R -> C) .
425+
STOP.
426+
rewrite /=.
427+
f_equal => /=.
428+
Set Printing All.
429+
Search lim Logic.eq .
430+
Search (lim _ = lim _).
431+
Set Printing All.
432+
apply: lim_eq.
406433
admit.
407434
apply: funext => h /=.
408435
by rewrite Inv_realC /= -!scalecr realC_alg [X in f X]addrC.

theories/normedtype_theory/normed_module.v

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2061,3 +2061,53 @@ HB.instance Definition _ :=
20612061
Check M : normedModType R.
20622062

20632063
HB.end.
2064+
2065+
HB.factory Record Uniform_Lmodule_isNormed (R : numFieldType) M of Uniform M & GRing.Lmodule R M := {
2066+
norm : M -> R;
2067+
ler_normD : forall x y, norm (x + y) <= norm x + norm y ;
2068+
normrZ : forall (l : R) (x : M), norm (l *: x) = `|l| * norm x ;
2069+
normr0_eq0 : forall x : M, norm x = 0 -> x = 0 ;
2070+
entourage_norm : forall x : M, nbhs_ball_ (ball_ norm) x = filter.nbhs x;
2071+
}.
2072+
2073+
HB.builders Context R M of Uniform_Lmodule_isNormed R M.
2074+
2075+
Lemma normrMn (x : M) (n : nat) : norm (x *+ n) = norm x *+ n.
2076+
Proof.
2077+
admit.
2078+
Admitted.
2079+
2080+
2081+
Lemma normrN (x : M) : norm (- x) = norm x.
2082+
Proof. admit. Admitted.
2083+
2084+
HB.instance Definition _ := Num.Zmodule_isNormed.Build R M ler_normD normr0_eq0 normrMn normrN.
2085+
HB.instance Definition _ := isPointed.Build M 0.
2086+
2087+
Definition ball := ball_ (fun x : M => `|x|).
2088+
2089+
Lemma ball_center_subproof (x : M) (e : R) : 0 < e -> ball x e x.
2090+
Proof. by rewrite /ball /ball_/= subrr normr0. Qed.
2091+
2092+
Lemma ball_sym_subproof (x y : M) (e : R) : ball x e y -> ball y e x.
2093+
Proof. by rewrite /ball /ball_/= distrC. Qed.
2094+
2095+
Lemma ball_triangle_subproof (x y z : M) (e1 e2 : R) :
2096+
ball x e1 y ->
2097+
ball y e2 z ->
2098+
ball x (e1 + e2)%E z.
2099+
Proof.
2100+
rewrite /ball /ball_/= => ? ?.
2101+
rewrite -[x](subrK y) -(addrA (x + _)).
2102+
by rewrite (le_lt_trans (ler_normD _ _))// ltrD.
2103+
Qed.
2104+
2105+
Lemma entourageE_subproof : entourage = entourage_ ball.
2106+
Proof. admit. Admitted.
2107+
2108+
HB.instance Definition _ := Uniform_isPseudoMetric.Build R M ball_center_subproof ball_sym_subproof ball_triangle_subproof entourageE_subproof.
2109+
2110+
HB.about NormedZmod_PseudoMetric_eq.Build.
2111+
; PseudoMetricNormedZmod_Lmodule_isNormedModule
2112+
2113+
HB.howto M normedModType.

0 commit comments

Comments
 (0)