File size: 4,085 Bytes
4a56cd6 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | import Mathlib
namespace OAI
open Set Metric
noncomputable section
namespace CompactBanach
theorem normalized_embedding_of_finite
{X E : Type*} [MetricSpace X] [NormedAddCommGroup E] [ProperSpace E]
(o : X) {A : β} (hA : 0 β€ A)
(hfinite : β s : Finset X, β f : s β E, β x y : s,
dist x y β€ dist (f x) (f y) β§ dist (f x) (f y) β€ A * dist x y) :
β f : X β E, β x y : X,
dist x y β€ dist (f x) (f y) β§ dist (f x) (f y) β€ A * dist x y := by
classical
let Q : Set (X β E) := {f | β x, f x β closedBall 0 (A * dist o x)}
have hQ : IsCompact Q := isCompact_pi_infinite fun x => isCompact_closedBall _ _
let C : X Γ X β Set (X β E) := fun p => {f |
dist p.1 p.2 β€ dist (f p.1) (f p.2) β§
dist (f p.1) (f p.2) β€ A * dist p.1 p.2}
have hC (p : X Γ X) : IsClosed (C p) :=
(isClosed_le continuous_const ((continuous_apply p.1).dist (continuous_apply p.2))).inter
(isClosed_le ((continuous_apply p.1).dist (continuous_apply p.2)) continuous_const)
have hFIP (u : Finset (X Γ X)) : (Q β© β p β u, C p).Nonempty := by
let s : Finset X := insert o (u.image Prod.fst βͺ u.image Prod.snd)
have ho : o β s := by simp [s]
obtain β¨f, hfβ© := hfinite s
let g : X β E := fun x => if hx : x β s then f β¨x, hxβ© - f β¨o, hoβ© else 0
refine β¨g, ?_, ?_β©
Β· intro x
by_cases hx : x β s
Β· simp only [g, dite_eq_left hx, mem_closedBall, dist_zero_right]
simpa only [dist_eq_norm, Subtype.dist_eq, dist_comm o x] using (hf β¨x, hxβ© β¨o, hoβ©).2
Β· simp only [g, dite_eq_right hx, mem_closedBall, dist_self]
exact mul_nonneg hA dist_nonneg
Β· simp only [mem_iInter]
intro p hp
have hx : p.1 β s := by simp [s, Finset.mem_image_of_mem _ hp]
have hy : p.2 β s := by simp [s, Finset.mem_image_of_mem _ hp]
change dist p.1 p.2 β€ dist (g p.1) (g p.2) β§
dist (g p.1) (g p.2) β€ A * dist p.1 p.2
simpa only [g, dite_eq_left hx, dite_eq_left hy, dist_sub_right, Subtype.dist_eq] using
hf β¨p.1, hxβ© β¨p.2, hyβ©
obtain β¨f, _, hfβ© := hQ.inter_iInter_nonempty C hC hFIP
refine β¨f, fun x y => ?_β©
exact mem_iInter.mp hf (x, y)
theorem normalized_embedding_of_scaled
{X E : Type*} [MetricSpace X] [NormedAddCommGroup E] [NormedSpace β E]
{f : X β E} {a A : β} (ha : 0 < a)
(hf : β x y, a * dist x y β€ dist (f x) (f y) β§
dist (f x) (f y) β€ A * a * dist x y) :
β g : X β E, β x y,
dist x y β€ dist (g x) (g y) β§ dist (g x) (g y) β€ A * dist x y := by
let g : X β E := fun x => aβ»ΒΉ β’ f x
have hd (x y : X) : dist (g x) (g y) = aβ»ΒΉ * dist (f x) (f y) := by
simp only [g, dist_smulβ, Real.norm_eq_abs, abs_inv, abs_of_pos ha]
refine β¨g, fun x y => ?_β©
rw [hd]
constructor
Β· calc
dist x y = aβ»ΒΉ * (a * dist x y) := by field_simp
_ β€ _ := mul_le_mul_of_nonneg_left (hf x y).1 (inv_nonneg.mpr ha.le)
Β· calc
aβ»ΒΉ * dist (f x) (f y) β€ aβ»ΒΉ * (A * a * dist x y) :=
mul_le_mul_of_nonneg_left (hf x y).2 (inv_nonneg.mpr ha.le)
_ = A * dist x y := by field_simp
theorem finite_witness_of_no_embedding
{X E : Type*} [MetricSpace X] [NormedAddCommGroup E] [NormedSpace β E]
[ProperSpace E] (o : X) {A : β} (hA : 0 β€ A)
(hno : Β¬ β f : X β E, β x y,
dist x y β€ dist (f x) (f y) β§ dist (f x) (f y) β€ A * dist x y) :
β s : Finset X, Β¬ β f : s β E, β a : β, 0 < a β§
β x y : s, a * dist x y β€ dist (f x) (f y) β§
dist (f x) (f y) β€ A * a * dist x y := by
classical
by_contra! h
apply hno
apply normalized_embedding_of_finite o hA
intro s
obtain β¨f, a, ha, hfβ© := h s
exact normalized_embedding_of_scaled ha hf
end CompactBanach
end
end OAI
|