@@ -46,6 +46,26 @@ def normed_group.of_add_dist' [has_norm α] [add_comm_group α] [metric_space α
46
46
{ rw [sub_eq_add_neg, ← add_right_neg y], apply H2 }
47
47
end }
48
48
49
+ /-- A normed group can be built from a norm that satisfies algebraic properties. This is
50
+ formalised in this structure. -/
51
+ structure normed_group.core (α : Type *) [add_comm_group α] [has_norm α] :=
52
+ (norm_eq_zero_iff : ∀ x : α, ∥x∥ = 0 ↔ x = 0 )
53
+ (triangle : ∀ x y : α, ∥x + y∥ ≤ ∥x∥ + ∥y∥)
54
+ (norm_neg : ∀ x : α, ∥-x∥ = ∥x∥)
55
+
56
+ noncomputable def normed_group.of_core (α : Type *) [add_comm_group α] [has_norm α]
57
+ (C : normed_group.core α) : normed_group α :=
58
+ { dist := λ x y, ∥x - y∥,
59
+ dist_eq := assume x y, by refl,
60
+ dist_self := assume x, (C.norm_eq_zero_iff (x - x)).mpr (show x - x = 0 , by simp),
61
+ eq_of_dist_eq_zero := assume x y h, show (x = y), from sub_eq_zero.mp $ (C.norm_eq_zero_iff (x - y)).mp h,
62
+ dist_triangle := assume x y z,
63
+ calc ∥x - z∥ = ∥x - y + (y - z)∥ : by simp
64
+ ... ≤ ∥x - y∥ + ∥y - z∥ : C.triangle _ _,
65
+ dist_comm := assume x y,
66
+ calc ∥x - y∥ = ∥ -(y - x)∥ : by simp
67
+ ... = ∥y - x∥ : by { rw [C.norm_neg] } }
68
+
49
69
section normed_group
50
70
variables [normed_group α] [normed_group β]
51
71
@@ -120,7 +140,7 @@ by rw ←norm_neg; simp
120
140
lemma ball_0_eq (ε : ℝ) : ball (0 :α) ε = {x | ∥x∥ < ε} :=
121
141
set.ext $ assume a, by simp
122
142
123
- theorem normed_space .tendsto_nhds_zero {f : γ → α} {l : filter γ} :
143
+ theorem normed_group .tendsto_nhds_zero {f : γ → α} {l : filter γ} :
124
144
tendsto f l (nhds 0 ) ↔ ∀ ε > 0 , { x | ∥ f x ∥ < ε } ∈ l :=
125
145
begin
126
146
rw [metric.tendsto_nhds], simp only [normed_group.dist_eq, sub_zero],
@@ -158,7 +178,7 @@ nnreal.coe_le.2 $ dist_norm_norm_le g h
158
178
159
179
end nnnorm
160
180
161
- instance prod.normed_group [normed_group β] : normed_group (α × β) :=
181
+ instance prod.normed_group : normed_group (α × β) :=
162
182
{ norm := λx, max ∥x.1 ∥ ∥x.2 ∥,
163
183
dist_eq := assume (x y : α × β),
164
184
show max (dist x.1 y.1 ) (dist x.2 y.2 ) = (max ∥(x - y).1 ∥ ∥(x - y).2 ∥), by simp [dist_eq_norm] }
@@ -169,7 +189,7 @@ begin have : ∥x∥ = max (∥x.fst∥) (∥x.snd∥) := rfl, rw this, simp[le_
169
189
lemma norm_snd_le (x : α × β) : ∥x.2 ∥ ≤ ∥x∥ :=
170
190
begin have : ∥x∥ = max (∥x.fst∥) (∥x.snd∥) := rfl, rw this , simp[le_max_right] end
171
191
172
- instance fintype.normed_group {π : α → Type *} [fintype α ] [∀i, normed_group (π i)] :
192
+ instance fintype.normed_group {π : ι → Type *} [fintype ι ] [∀i, normed_group (π i)] :
173
193
normed_group (Πb, π b) :=
174
194
{ norm := λf, ((finset.sup finset.univ (λ b, nnnorm (f b)) : nnreal) : ℝ),
175
195
dist_eq := assume x y,
@@ -364,15 +384,14 @@ by rw [real.norm_eq_abs, abs_of_nonneg (norm_nonneg _)]
364
384
365
385
section normed_space
366
386
367
- class normed_space (α : Type *) (β : Type *) [normed_field α]
368
- extends normed_group β, vector_space α β :=
369
- (norm_smul : ∀ (a:α) b , norm (a • b) = has_norm.norm a * norm b)
387
+ class normed_space (α : Type *) (β : Type *) [normed_field α] [normed_group β]
388
+ extends vector_space α β :=
389
+ (norm_smul : ∀ (a:α) (b:β) , norm (a • b) = has_norm.norm a * norm b)
370
390
371
- variables [normed_field α]
391
+ variables [normed_field α] [normed_group β]
372
392
373
393
instance normed_field.to_normed_space : normed_space α α :=
374
- { dist_eq := normed_field.dist_eq,
375
- norm_smul := normed_field.norm_mul }
394
+ { norm_smul := normed_field.norm_mul }
376
395
377
396
set_option class.instance_max_depth 43
378
397
@@ -382,7 +401,8 @@ normed_space.norm_smul s x
382
401
lemma nnnorm_smul [normed_space α β] (s : α) (x : β) : nnnorm (s • x) = nnnorm s * nnnorm x :=
383
402
nnreal.eq $ norm_smul s x
384
403
385
- variables {E : Type *} {F : Type *} [normed_space α E] [normed_space α F]
404
+ variables {E : Type *} {F : Type *}
405
+ [normed_group E] [normed_space α E] [normed_group F] [normed_space α F]
386
406
387
407
lemma tendsto_smul {f : γ → α} { g : γ → F} {e : filter γ} {s : α} {b : F} :
388
408
(tendsto f e (nhds s)) → (tendsto g e (nhds b)) → tendsto (λ x, (f x) • (g x)) e (nhds (s • b)) :=
@@ -462,41 +482,12 @@ instance : normed_space α (E × F) :=
462
482
..prod.normed_group,
463
483
..prod.vector_space }
464
484
465
- instance fintype.normed_space {ι : Type *} {E : ι → Type *} [fintype ι] [∀i, normed_space α (E i)] :
466
- normed_space α (Πi, E i) :=
467
- { norm := λf, ((finset.univ.sup (λb, nnnorm (f b)) : nnreal) : ℝ),
468
- dist_eq :=
469
- assume f g, congr_arg coe $ congr_arg (finset.sup finset.univ) $
470
- by funext i; exact nndist_eq_nnnorm _ _,
471
- norm_smul := λ a f,
485
+ instance fintype.normed_space {E : ι → Type *} [fintype ι] [∀i, normed_group (E i)]
486
+ [∀i, normed_space α (E i)] : normed_space α (Πi, E i) :=
487
+ { norm_smul := λ a f,
472
488
show (↑(finset.sup finset.univ (λ (b : ι), nnnorm (a • f b))) : ℝ) =
473
489
nnnorm a * ↑(finset.sup finset.univ (λ (b : ι), nnnorm (f b))),
474
- by simp only [(nnreal.coe_mul _ _).symm, nnreal.mul_finset_sup, nnnorm_smul],
475
- ..metric_space_pi,
476
- ..pi.vector_space α }
477
-
478
- /-- A normed space can be built from a norm that satisfies algebraic properties. This is
479
- formalised in this structure. -/
480
- structure normed_space.core (α : Type *) (β : Type *)
481
- [normed_field α] [add_comm_group β] [has_scalar α β] [has_norm β] :=
482
- (norm_eq_zero_iff : ∀ x : β, ∥x∥ = 0 ↔ x = 0 )
483
- (norm_smul : ∀ c : α, ∀ x : β, ∥c • x∥ = ∥c∥ * ∥x∥)
484
- (triangle : ∀ x y : β, ∥x + y∥ ≤ ∥x∥ + ∥y∥)
485
-
486
- noncomputable def normed_space.of_core (α : Type *) (β : Type *)
487
- [normed_field α] [add_comm_group β] [vector_space α β] [has_norm β]
488
- (C : normed_space.core α β) : normed_space α β :=
489
- { dist := λ x y, ∥x - y∥,
490
- dist_eq := assume x y, by refl,
491
- dist_self := assume x, (C.norm_eq_zero_iff (x - x)).mpr (show x - x = 0 , by simp),
492
- eq_of_dist_eq_zero := assume x y h, show (x = y), from sub_eq_zero.mp $ (C.norm_eq_zero_iff (x - y)).mp h,
493
- dist_triangle := assume x y z,
494
- calc ∥x - z∥ = ∥x - y + (y - z)∥ : by simp
495
- ... ≤ ∥x - y∥ + ∥y - z∥ : C.triangle _ _,
496
- dist_comm := assume x y,
497
- calc ∥x - y∥ = ∥ -(1 : α) • (y - x)∥ : by simp
498
- ... = ∥y - x∥ : begin rw[C.norm_smul], simp end ,
499
- norm_smul := C.norm_smul }
490
+ by simp only [(nnreal.coe_mul _ _).symm, nnreal.mul_finset_sup, nnnorm_smul] }
500
491
501
492
end normed_space
502
493
0 commit comments