Metric Space Notes
Metric Space Notes
Metric Space Notes
620-311
Metric Spaces
Lecture Notes
Semester 1, 2007
Notes by:
Revised by:
Kris Wysocki
Hyam Rubinstein
This compilation has been made in accordance with the provisions of Part
VB of the copyright act for the teaching purposes of the University for the
use of students of the University of Melbourne enrolled in the subject
620-311.
Contents
1 Introduction
Metric Spaces
3 Continuity
17
4 Complete Spaces
22
35
6 Topological Spaces
40
44
8 Connected Spaces
46
9 Product Spaces
51
57
11 Appendix
60
Introduction
Metric Spaces
Basic Concepts
Consider a non-empty set X, whose elements will be refered to as points. A
distance function or a metric on a set X is a function d : X X R which
assigns to each pair of points x and y in X a real number d(x, y) having the
following properties:
M1. d(x, y) 0 and d(x, y) = 0 if and only if x = y;
M2. d(x, y) = d(y, x) for all x, y X;
M3. d(x, z) 6 d(x, y) + d(y, z) for all x, y and z X.
Definition 2.1. A metric space is a pair (X, d) where d is a metric defined
on the set X.
The axiom M2 says that a metric is symmetric, and the axiom M3 is called
the triangle inequality since it reflects the geometrical fact that the length
of one side of a triangle is less than or equal to the sum of the lengths of the
other two sides.
Examples.
(1) Let X be any nonempty set. The discrete metric on X is defined by
(
0 x = y,
d(x, y) =
1 x 6= y.
(2) If (X, d) is a metric space and Y is a non-empty subset of X, then
for all x, y Y
dY (x, y) = d(x, y)
z, w C.
The set of real numbers R inherits the metric from C, namely d(x, y) =
|x y|, x, y R. Identifying C = {x1 + ix2 | x1 , x2 R} with R2 =
{(x1 , x2 )| x1 , x2 R}, the standard metric takes the form
p
d((x1 , x2 ), (y1 , y2 )) = (x1 y1 )2 + (x2 y2 )2 .
5
(4) Cartesian product of a finite number of metric spaces. Consider a finite collection of metric spaces (Xi , di ) , 1 6 i 6 n, and let X =
Q
n
i=1 Xi = X1 . . . Xn . For x = (x1 , . . . , xn ) and y = (y1 , . . . , yn ) X,
set
n
X
di (xi , yi ).
d(x, y) =
i=1
We next define the class of metric spaces which are the most interesting in
analysis. Let X be a vector space over R (or C).
Definition 2.2. A norm is a function
: X R having the following
properties:
N1.
x
0 and
x
= 0 if and only if x = 0.
N2.
x
= ||
x
for all x X and R (or C).
N3.
x + y
6
x
+
y
for all x, y X.
The pair (X,
) is called a normed vector space.
Proposition 2.3. Let X be a normed space. Then
d(x, y) =
x y
, x, y X,
defines a metric on X.
Clearly, N1 and N2 are satisfied. To see that N3 holds we need the following
lemma.
Lemma 2.4. Cauchy inequality. If x, y Rn , then
X
X
1/2
1/2 X
n
n
n
2
2
|yi |
.
|xi |
xi y i 6
i=1
i=1
i=1
Proof.
06
=
=
=
n
X
(xi yj xj yi ) =
n
X
i,j=1
n
n X
n
n
X
XX
xi xj yi yj
x2j yi2 2
x2i yj2 +
i=1 j=1
i=1 j=1
i=1 j=1
X
2
n
n
n
X
2 2 X
2 2
y
x +
x
y 2
xi yi
i
j
i=1
i=1
j=1
2
X
n
2
2
xi yi .
2 x y 2
i=1
i,j=1
n
n X
X
As a corollary we have
Corollary 2.5.
x + y
6
x
+
y
for all x, y Rn .
2
=
x
+ 2
i=1
i=1
i=1
n
X
i=1
2
2
2
xi yi +
y
6
x
+ 2
x
y
+
y
i=1
= (
x
+
y
)2 .
Consequently,
#1/2
" n
X
(xi yi )2
d(x, y) =
x y
=
i=1
b
a
|f (x) g(x)|dx,
f, g X.
d(xn , x) <
In this case we write
lim xn = x
or
xn x.
for n k.
n
X
di (xi , yi )
i=1
x, y X.
(1)
dj (xm
j , xj ) <
for m k and j = 1, . . . , n.
m
So xm
j xj as required. Conversely, assume that xj xj for j = 1, . . . , n.
Hence for a given > 0, there exists k(j) N such that
dj (xm
j , xj ) < /n
for m k(j).
if and only if
d (xn , x0 ) 0.
d(x, y)
,
1 + d(x, y)
x, y X.
(2)
d (x, y)
. So if d (xn , x0 ) 0, then d(xn , x0 ) 0. Note that with
1 d (x, y)
respect to this equivalent metric, the space X is bounded since d (x, y) < 1
for all x, y X.
(2) Consider the product (X, d) of metric spaces (Xi , di ). Recall that
d(x, y) =
n
X
i=1
Set
di (xi , yi ),
x = (x1 , . . . , xn ), y = (y1 , . . . , yn ) X.
11
2
<x+r
x<x+
n
R := r d(x, y)
x
r
Proof.
(a) We prove the result for the product of two metric spaces X1 and X2 .
Let a = (a1 , a2 ) A X. Since Ai is open in Xi , there exists ri such that
an open ball B(ai , ri ) in Xi is contained in Ai . Let r = min{r1 , r2 }. We
15
claim that B(a, r) A. Indeed, if x = (x1 , x2 ) B(a, r), then d(a, x) < r
where x = (x1 , x2 ), and since di (ai , xi ) < d(a, x) < r 6 ri we conclude that
xi B(ai , ri ). Hence xi Ai , i = 1, 2, so that x A.
(b) The proof follows from Proposition 2.8.
Definition 2.20. The boundary of A in X, denoted by A, is the set
A X \ A.
Hence x A if for every r > 0 the open ball B(x, r) intersects A and X \ A
as well. Clearly, the boundary is a closed set as it is an intersection of closed
sets.
Example 2.21. Consider R with the usual metric. Then
([0, 1]) = ((0, 1)) = {0, 1}
(Q) = (R \ Q) = R.
1
2
x 6= x + Q and x 6= x +
Qc , for n N.
n
n
Since
16
Example 2.28. [Cantor set] The Cantor set is a subset of [0, 1] constructed
as follows:
Consider the interval C0 = [0, 1].
Step 1. We divide C0 into three equal intervals [0, 1/3], [1/3, 2/3] and [2/3, 1]
and remove the middle open interval (1/3, 2/3). Denote the remaining intervals by C1 = [0, 1/3] [2/3, 1]. The length of intervals which constitute
C1 is equal to 2/3.
Step 2. We perform the same operations as in the first step on each of the
intervals of C1 . We remove intervals (1/9, 2/9) and (7/9, 8/9). Denote the
four remaining intervals by C2 .
Having finished the step (n 1), we perform the nth step and obtain the
set Cn consisting of 2n intervals.
Each of the sets Cn is closed and bounded, and Cn+1 Cn . The Cantor set
is defined as
\
Cn
C=
n=1
Continuity
Definition 3.1. Let (X, d) and (Y, ) be metric spaces and let f : X Y be
a function. The function f is said to be continuous at the point x0 X
if the following holds: for every > 0, there exists > 0 such that for all
x X if d(x, x0 ) < , then (f (x), f (x0 )) < . The function f is said to be
continuous if it is continuous at each point of X.
The following proposition rephrases the definition in terms of open balls.
Proposition 3.2. Let f : X Y be a function from a metric space X to
another metric space Y and let x0 X. Then f is continuous at x0 if and
only if for every > 0 there exists > 0 such that
f (B(x0 , )) B(f (x0 ), ).
Theorem 3.3. Let f : X Y be a function from a metric space (X, d)
to another metric space (Y, ) and let x0 X. Then f is continuous at x0
if and only if for every sequence {xn } such that xn x0 , f (xn ) f (x0 ).
Also, f is continuous if and only if for every convergent sequence {xn } in
X,
lim f (xn ) = f (lim xn ).
n
(3)
(4)
for all n k.
(5)
Global continuity has a simple formulation in terms of open and closed sets.
Theorem 3.4. Let f be a function from a metric space (X, d) to (Y, ).
Then
(a) f is continuous if and only if for every open set U Y , the preimage
f 1 (U ) of U is open in X. (Recall that the preimage f 1 (U ) is defined
as f 1 (U ) = {x X | f (x) U }).
(b) f is continuous if and only if for every closed set F Y , f 1 (F ) is
closed in X.
Proof. (a) Suppose first that f is continuous and U is open in Y . If
x f 1 (U ), then f (x) U . Since U is open in Y and f (x) U , there
exists a positive number such that B(f (x), ) U . In view of Proposition
3.2, there exists > 0 such that f (B(x, )) B(f (x), ). Hence B(x, )
f 1 (f (B(x, ))) f 1 (U ), so f 1 (U ) is open in X. Conversely, suppose
that f 1 (U ) is open in X for every open set U in Y . Let x X and let
> 0 be given. Since B(f (x), ) is open in Y , the set f 1 (B(f (x), ))
is open in X. Since x f 1 (B(f (x), )), there exists > 0 such that
B(x, ) f 1 (B(f (x), )). This implies that f (B(x, )) B(f (x), ), and
in view of Proposition 3.2, f is continuous.
(b) The proof is left as an exercise
Theorem 3.5. Let X, Y and Z be three metric spaces.
(a) If f : X Y and g : Y Z are continuous, then the composition
g f is continuous.
(b) If f : X Y is continuous, and A is a subspace of X, then the
restriction of f to A, f |A : A Y , is continuous.
Proof. (a) Let xn x0 . Since f is continuous at x0 , f (xn ) f (x0 ). Since
g is continuous at f (x0 ), g(f (xn )) g(f (x0 )). Hence g f (xn ) g f (x0 ).
The second statement follows from the first. Here is another proof of (a).
Let U be an open subset of Z. Since g is continuous, g1 (U ) is open in Y ,
and since f is continuous, f 1 (g1 (U )) is open in X. But f 1 (g1 (U )) =
(g f )1 (U ) and so, (g f )1 (U ) is open in X. Hence g f is continuous.
(b) Note that f |A = f j, where j : A X is the inclusion, i.e., defined by
j(x) = x for x A. Since for any open set U in X, j 1 (U ) = U A which
is open in A, it follows that j is continuous. So (b) follows from (a).
19
Theorem 3.6. Let (X, d), (Y1 , 1 ) and (Y2 , 2 ) be metric spaces. Let f be
a function from X to Y1 and g a function from X to Y2 .
Define the function h from X to the product Y1 Y2 by
h(x) = (f (x), g(x)),
for x X.
|x y| 6 |x y|.
|f (x) f (y)| = |f (t)| |x y| =
(1 + t2 )2
since |f (t)| 6 1. Hence for given , choose = . Then for any x, y such
that d(x, y) = |x y| < , we have
d(f (x), f (y)) = |f (x) f (y)| 6 |x y| = d(x, y) < = .
So f is uniformly continuous.
(2) The function f (x) = x2 for x R is not uniformly continuous. Indeed,
choose > 0 and set
x = 1/ + /2
and
y = 1/.
(6)
(7)
Complete Spaces
Definition 4.1. Let (X, d) be a given metric space and let {xn } be a sequence of points of X. We say that {xn } is Cauchy (or satisfies the
Cauchy condition) if for every > 0 there exists k N such that
d(xn , xm ) <
for all n, m k.
Proof. Take = 1. Since {xn } is Cauchy, there exists an index k such that
d(xn , xk ) < 1 for all n k. Let R > 1 be such that than d(xi , xk ) < R for
1 6 i 6 k 1. Then xn B(xk , R) for all n, so {xn } is bounded.
Proposition 4.3. If {xn } is convergent, then {xn } is a Cauchy sequence.
Proof. Assume that xn x. Then for a given > 0 there exists k N such
that d(xn , x) < /2 for all n k. Hence taking any n, m k,
d(xn , xm ) 6 d(xn , x) + d(x, xm ) < /2 + /2 = .
So {xn } is Cauchy.
Proposition 4.4. If {xn } is Cauchy and it contains a convergent subsequence, then {xn } converges.
Proof. Assume that {xn } is Cauchy and xkn x. We will show that xn
x. Let > 0. Since {xn } is Cauchy, there exists k such that d(xn , xkn ) < /2
for all n k . Also since xkn x, there exists k such that d(xkn , x) < /2
for all n k . Set k = max{k , k }. Then for n k,
d(xn , x) 6 d(xn , xkn ) + d(xkn , x) < /2 + /2 =
showing that xn x.
A Cauchy sequence need not converge. For example, consider {1/n} in the
metric space ((0, 1), | |). Clearly, the sequence is Cauchy in (0, 1) but does
not converge to any point of the interval.
Definition 4.5. A metric space (X, d) is called complete if every Cauchy
sequence {xn } in X converges to some point of X. A subset A of X is called
complete if A as a metric subspace of (X, d) is complete, that is, if every
Cauchy sequence {xn } in A converges to a point in A.
By the above example, not every metric space is complete; (0, 1) with the
usual metric is not complete. Also Q is not complete.
Theorem 4.6. The space R with the usual metric is complete.
Proof. Let {xn } be a Cauchy sequence in R. Then it is bounded, say |xn | 6
M . Set Sn = {xk | k n} and yn = inf Sn . Then Sn+1 Sn and so {yn }
is increasing and yn 6 M for all n. Hence {yn } converges, say to x (see
23
for all k N .
xN /2 6 yn 6 xN + /2
for all n N .
Hence
Let n . Then
xN /2 6 x 6 xN + /2,
Theorem 4.10. The space (Cb (X, Y ), ) is a complete metric space if (Y, d )
is complete.
Proof. The verification that is a metric is left as an exercise. Suppose that
Y is complete, and suppose that {fn } is a Cauchy sequence in Cb (X, Y ).
Then for every x X,
d (fn (x), fm (x)) 6 (fn , fm )
so that {fn (x)} is a Cauchy sequence on Y . Hence there exists a point,
denoted by f (x) Y , such that d (fn (x), f (x)) 0. In this way we obtain
a function f : X Y which associates with a point x X a point which is
the limit of {fn (x)}. We must check that f is continuous and bounded, and
that (fn , f ) 0. Let x X, and > 0. Then there exists N such that
d (f (x), fN (x)) < /3, and an open ball B(x, ) such that d (fN (x), fN (y)) <
/3 for every y B(x, ). It follows that for every y B(x, ),
d (f (x), f (y)) 6 d (f (x), fN (x)) + d (fN (x), fN (y)) + d (fN (y), f (y)) < .
Hence f is continuous. Now given > 0, chose n0 such that (fn , fm ) <
for all n, m n0 . Then for every x X,
d (fn (x), f (x)) = lim d (fn (x), fm (x)) 6
m
Proof. It suffices
to show that every open ball B(x, r) contains a point beT
longing to n1 Un . Since U1 is open and dense, B(x, r) U1 is non-empty
and open. So, there exists an open ball B(x1 , R) with R < 1 such that
B(x1 , R) B(x, r) and B(x1 , R) U1 . Taking r1 < R, we get that
B(x1 , r1 ) B(x, r) and B(x1 , r1 ) U1 . Similarly, since U2 is open and
dense, there exists x2 and r2 < 1/2 such that B(x2 , r2 ) B(x1 , r1 ) U2 .
Continuing in this way we find a sequence of balls B(xn , rn ) with rn < 1/n
and B(xn+1 , rn+1 ) B(xn , rn ) Un+1 . We claim that {xn } is Cauchy. By
26
Applications
Theorem 4.15. Let (X, d) be a complete metric space, and let {fn } be a
sequence of continuous functions fn : X R. Assume that the sequence
{fn (x)} is bounded for every x X. Then there exists a non-empty open set
U X on which the sequence {fn } is bounded, that is, there is a constant
M such that |fn (x)| 6 M for all x U and all n N.
27
Proof. Since the function fn is continuous, the set fn1 ([m, m]) = {x X |
|fn (x)| 6 m} is closed for any pair of positive integers n and m. Thus,
\
Em = {x X | |fn (x)| 6 m for all n N} =
fn1 ([m, m])
n
h0+
h0+
we have
f (x + h) f (x)
= f+ (x),
h
f (x + h) f (x)
= |f+ (x)|.
lim
h
h0+
28
(1)
Take an integer k 2 such that |f+ (x)| < k and x [0, 1 1/k]. In view of
(1), there exists 0 < < 1/k such that
|f (x + h) f (x)| 6 k h for all 0 6 h 6 .
Since f is continuous on a closed and bounded interval, there is C > 0 such
that |f (x)| 6 C for all x [0, 1] (this will be proved later on in the section on
compactness). Let k be any integer so that 2C/ < k . Then, for 6 h 6 1
such that x + h 6 1,
|f (x + h) f (x)| 6 |f (x + h)| + |f (x)| 6 2C =
2C
2C
6
h 6 k h.
(2)
for all h [0, 1/m]. Since {xk } [0, 1 1/m] we may assume that there
exists a subsequence, again denoted by {xk }, such that xk x [0, 11/m].
Hence, by the triangle inequality and by (2),
|f (x + h) f (x)| 6 |f (x + h) f (xk + h)| + |f (xk + h) fk (xk + h)|
g
f
Figure 2: The black curve is the graph of f and the grey curve is the graph
of g.
= .
at f and radius ). So Mm
S
In
view
of
the
Baires
theorem,
C([0,
1],
R)
=
6
m2 Mm since otherwise
S
M
has
non-empty
interior.
Hence
there
exists
f C([0, 1], R) so
m
m2
S
S
that f 6 m2 Mm . Since M m2 Mm , f 6 M . Since M contains
all functions which are differentiable at least at one point in [0, 1), f is not
differentiable at any x [0, 1).
Proof. We start with the uniqueness of the fixed point of f . Assume that
p 6= q and that f (p) = p and f (q) = q. Then
d(p, q) = d(f (p), f (q)) 6 d(p, q)
so that d(p, q) = 0 since (0, 1). So p = q, contradicting our assumption.
Hence f has at most one fixed point. Fix any point x X, and let x0 = x
and xn+1 = f (xn ) for n 0. Then for any n,
d(xn+1 , xn ) = d(f (xn ), f (xn1 )) 6 d(xn , xn1 )
and,
d(xn+1 , xn ) 6 d(xn , xn1 ) 6 2 d(xn1 , xn2 ) 6 6 n d(x1 , x0 ).
For m > n,
d(xm , xn ) 6 d(xn , xn+1 ) + d(xn+1 , xn+2 ) + + d(xm1 , xm )
X
i d(x1 , x0 )
6 n + n+1 + + m1 d(x1 , x0 ) 6
i=n
= n
X
i=0
n d(x1 , x0 )
i d(x1 , x0 ) =
.
1
n d(x1 , x0 )
.
1
(10)
Thus,
d(f (p), p) 6 d(f (p), xn+1 ) + d(xn+1 , p) = d(f (p), f (xn )) + d(xn+1 , p)
6 d(p, xn ) + d(xn+1 , p) 6
= n
(1 + )d(x1 , x0 )
0 as n ,
1
and therefore p = f (p). The inequality (9) follows from (10) by taking
n = 0.
Here is an application of the Banach fixed point theorem to the local existence of solutions of ordinary differential equations.
31
Fix (x0 , y0 ) U . Then we find > 0 and b > 0 such that if I = [x0 , x0 +]
and J = [y0 b, y0 + b], then I J U . Since f is continuous and I J is
closed and bounded, f is bounded on I J. That is, |f (x, y)| 6 M for some
M and all (x, y) I J. Replacing by a smaller number we may assume
that < 1 and M < b. Denote by X the set of all continuous functions
g : I J. The set X with the metric d(g, h) = sup{|g(x) h(x)|, x I} is
a complete metric space. For g X, let
Z x
(T g)(x) = y0 +
f (t, g(t))dt.
x0
x1
For x0 6 x 6 x0 + ,
Z x
Z
|(T g)(x) y0 | =
f (t, g(t))dt 6
x0
x0
32
Z x
|(T g)(x) (T h)(x)| =
[f (t, g(t)) f (t, h(t))] dt
Z xx0
6
|f (t, g(t)) f (t, h(t))|dt
x0
Completions
The space (0, 1) with the usual metric is not complete but is a subspace
of the complete metric space [0, 1] with the usual metric. This example
illustrates the general situation: every metric space X may be regarded as
e
e in such a way that X = X.
a subspace of a complete metric space X
We will need the following concept.
Definition 4.19. A map f from (X, d) to (Y, ) is called an isometry if
(f (x), f (y)) = d(x, y)
for all x, y X.
Theorem 4.21. Let (X, d) be a metric space. Then (X, d) has a completion. The completion is unique in the following sense: If ((X1 , d1 ), 1 ) and
((X2 , d2 ), 2 ) are completions of (X, d), then (X1 , d1 ) and (X2 , d2 ) are isometric. That is, there exists a surjective isometry f : X1 X2 such that
f 1 = 2 .
33
Proof.
Existence: Let B(X) be the space of bounded real valued functions defined
on X equipped with the uniform norm (f, g) = supyX |f (y) g(y)|. Fix a
point a X. With every x X we associate a function fx : X R defined
by
fx (y) = d(y, x) d(y, a),
y X.
We have
|fx (y)| = |d(y, x) d(y, a)| 6 d(x, a)
so that fx is bounded. Since
|fx1 (y) fx2 (y)| 6 d(x1 , x2 )
for all y X,
(fx1 , fx2 ) = supyX {|fx1 (y) fx2 (y)|} 6 d(x1 , x2 ). On the other hand,
(fx1 , fx2 ) |fx1 (x2 ) fx2 (x2 )| = d(x1 , x2 ).
Hence
(fx1 , fx2 ) = d(x1 , x2 ),
and the map f : X B(X) defined by f (x) = fx is an isometry onto f (X),
(f (x1 ), f (x2 )) = d(x1 , x2 ).
Denote by X the closure of f (X) in B(X) and let d be the metric on X
induced by . Since (B(X), ) is complete and X is closed in B(X), the
space (X , d ) is complete.
Uniqueness:
The isometry 1 : X 1 (X) has an inverse 1
1 : 1 (X) X. Then
is
an
isometry
from
(X)
onto
(X
).
Since 1 (X) is dense in
2 1
1
2
2
1
1
(X1 , d1 ), 2 1 extends to a map : X1 X2 satisfying
d2 ((x), (y)) = d1 (x, y),
for all
x, y X1 .
34
Proof. Let {yn } be any sequence in f (K), and let {xn } be a sequence in K
of points such that f (xn ) = yn . Since K is compact, {xn } has a converging
subsequence to a point in K; say xnk x with x K. Since f is continuous,
f (xnk ) f (x). That is, ynk f (x) and since f (x) f (K), f (K) is
compact.
As a corollary we get
Corollary 5.8. Let f : X R be a continuous function on a compact
metric space. Then f attains a maximum and a minimum value, that is,
there exist a and b X such that f (a) = inf{f (x) | x X} and f (b) =
sup{f (x) | x X}.
Proof. By Theorem 5.7, f (X) is compact, so it is bounded and sup{f (x) |
x X} is finite. Set C = sup{f (x) | x X}. By definition of supremum,
for every n N, there exists xn such that C 1/n 6 f (xn ) 6 C. The
sequence {xn } has a converging subsequence, xnk b because X is compact.
In view of the continuity of f , f (xnk ) f (b), and since C1/n 6 f (xn ) 6 C
for all n, f (b) = C. Similarly, there exists a X such that f (a) = inf{f (x) |
x X}.
Theorem 5.9. Suppose f : (X, d) (Y, d ) is a continuous mapping defined
on a compact metric space X. Then f is uniformly continuous.
Proof. Suppose not. Then there is some > 0 such that for all > 0 there
exist points x, y with d(x, y) < but d (f (x), f (y)) > 0. Take = 1/n
and let xn , yn be points such that d(xn , yn ) < 1/n but d (f (xn ), f (yn )) .
Compactness of X implies that there is a subsequence {xnk } converging to
some point x X. Since d(xnk , ynk ) < 1/nk 0 as k , the sequence
{ynk } converges to the same point x. Continuity of f implies that the
sequences {f (xnk )}, {f (ynk )} converge to f (x). Then d (f (xnk ), f (x)) < /2
and d (f (ynk ), f (x)) < /2 for k large, and so,
d (f (xnk , f (ynk )) 6 d (f (xnk ), f (x)) + d (f (x), f (ynk )) <
for k large, a contradiction to the fact that d (f (xn ), f (yn )) for all n.
Definition 5.11. Let (X, d) be a metric space and let A X. Then A has
the Heine-Borel property if S
for every open cover {Ui }iI of A, there is a
finite set F I such that A iS Ui .
Example 5.12. Consider a set X with a discrete metric. Then every onepoint set is open and the collection of all one-point sets is an open cover of
X. Clearly, this cover does not have any proper subcover. Hence, a discrete
metric space X has the Heine-Borel property if and only if X consists of a
finite number of points.
Theorem 5.15. Let A be a subset of a metric space (X, d). Then the
following conditions are equivalent:
(a) A is compact.
(b) A is complete and totally bounded.
(c) A has the Heine-Borel property.
Proof. We will show that (a) implies (b), (b) implies (c), (c) implies (a).
(a) implies (b). Let {xn } be a Cauchy sequence in A. We have to show
that it converges to a point in A. By compactness of A, some subsequence,
38
(c) implies (a). Suppose that A is not compact. Then there exists a
sequence {xn } in A with no convergent subsequence in A. Then for every
x A, there exists a ball B(x, x ) which contains xn for at most finitely many
n. Otherwise, there exists x such that for every r > 0, B(x, r) contains xn
for infinitely many n. Then, in particular, for every k, B(x, 1/k) contains
xn for infinitely many n. Choose n1 so that xn1 B(x, 1). Since B(x, 1/2)
contains xn for infinitely many n, there is n2 > n1 such that xn2 B(x, 1/2).
In this way we construct a subsequence {xnk } such that xnk B(x, 1/k).
This implies xnk x contradicting our assumption on {xn }. Now the family
{B(x, x )}xA is an open cover of A from which it is impossible to choose
a finite number of balls which will cover A since any finite cover by these
balls contains xn for finitely many n and since A contains xn for all positive
integers. Consequently, A is compact.
Topological Spaces
Our next aim is to push the process of abstraction a little further and define
spaces without distances in which continuous functions still make sense.
The motivation behind the definition is the criterion of continuity in terms
of open sets. This criterion tells us that a function between metric spaces
is continuous provided that the preimage of an open set is open. We make
the following definition.
Definition 6.1. Let X be a set. A topology on X is a collection T of
subsets of X satisfying the following properties:
O1 and X T .
Ui T .
T
O3 If U1 , U2 , . . . , Un T , then ni=1 T .
iI
40
Example 6.3. Let X be any set. The collection of all subsets of X, P(X),
is a topology on X. This topology is called the discrete topology. Every
subset U of X is an open set. On the other extreme, consider X and the
collection {, X}. It is also a topology on X, and is called the indiscrete
topology or the trivial topology.
T
C2 If Fi is a closed set for every i I, then iI Fi is closed.
S
C3 If F1 , . . . Fn are closed, then ni=1 Fi is closed.
41
Basis
If X is a topological space with topology T , then a basis for T is a collection
B T such that every member of T , i.e., every open set, is a union of
elements of B. (We allow the empty union giving the empty set.)
Example 6.7. The collection of all open balls forms a basis for the topology
of any metric space.
B1
x
B3
B2
Proof. Any basis satisfies (1) since the whole space X is open, and (2) since
the intersection of two open sets B1 B2 is open. Conversely, assume that
B is a collection of subsets of X with properties (1) and (2). Define T to be
the collection of all subsets of X that are unions of sets in B. We shall show
that T is a topology. The condition (1) guarantees that X T . Clearly,
an arbitrary union of sets in T belongs to T in view of the definition of T .
Assume that U, V T . We have to show that U V is the union of sets
in B. Take any x U V . Since U and V are unions of sets in B, there
exist B1 , B2 B such that x B1 U and x B2 V . So x B1 B2 ,
42
V
y
Continuity
Continuous functions in metric spaces were characterized in terms of open
and closed sets. This suggests the definition of continuity in topological
spaces.
Definition 6.11. Let X and Y be topological spaces and let f : X Y .
The map f is continuous at a point x0 if for every neighbourhood U of
f (x0 ) in Y there exists a neighbourhood V of x0 in X such that f (V ) U .
Global continuity of f is defined in terms of open sets: f is continuous if
f 1 (U ) is open in X for every open set U in Y .
43
Theorem 7.2. A topological space X has is compact if and only if for every
family
{Fi }iI of closed subsets of X having the finite intersection property,
T
F
6= .
i
iI
Proof. Assume that X is compact. Let {Fi }iI be a collection of closed sets
having the finite intersection property. Arguing by contradiction assume
44
T
S
S
that T iFi = . Writing Ui = X \ Fi we have iI Ui = iI [X \ Fi ] =
X \ iI Fi = X. So {Ui }iI is an open cover of X. Hence there are
Ui1 , . . . , Uik such that X = Ui1 Uik . But then = X \ X = X \
Sk
Tn
l=1 Uil =
l=1 Fil , contradicting the assumption that {Fi } has the finite
intersection property. Conversely, suppose that T
for every collection {Fi }iI
having the finite intersection property we have iI Fi 6= . Take any open
cover {Ui }T
iI of X, and define
T
SFi = X \ Ui . Then the Fi s are closed and
iI Fi =
iI [X \ Ui ] = X \ iI
T Ui = . So {Fi } does not have the finite
intersection
property
(otherwise
iI F
T
Si 6= ). So thereSis a finite set J I
such that iJ Fi = . But then X = iJ [X \ Fi ] = iJ Ui showing that
X is compact.
Theorem 7.3. A closed subspace of a compact topological space is compact.
Proof. Let K be a closed subset of a topological space X, and let {U }iJ be
an open cover of K. Then the collection {U }iJ {K c } is a family of open
subsets of X that covers X. Since X is compact, there is a finite subfamily
of this family that covers X. The corresponding subfamily of {U }iJ covers
K.
Theorem 7.4. If X is a Hausdorff space, then every compact subset of X
is closed.
Proof. Let K be a compact subset of X. Since X is Hausdorff, for every
x K c and every y K, there are disjoint open sets Uxy and Vxy such that
x Uxy and y Vxy . Then for every x K c , {Vxy }yK is anS
open cover of
n
K. Since
Tn K is compact, there exist y1 , . . . , yn K such K i=1 Vxyi . Setc
U = i=1 Uxyi . Then U is open, U K = , and x U . Thus x U K
showing that K c is open, and consequently, that K is closed.
Theorem 7.5. A compact Hausdorff space is normal.
Proof. Let A and B be disjoint closed subsets of a compact Hausdorff space.
In view of Theorem 7.3, the sets A and B are compact. Proceeding like we
did in the proof of the previous theorem, we find for every x B disjoint
open sets Vx and Ux such that x Vx and A Ux . Then the open sets
{Vx }xB cover B. Consequently, there exist x1 , . . . , xn B such that B
Vx1 Vxn := V . Then U := Ux1 Uxn is open, U V = , and
A U, B V .
45
Connected Spaces
46
Example 8.1. The set X containing at least two points and considered
with the discrete topology is disconnected. However, X with the indiscrete
topology is connected.
Theorem
8.7. If {Ai }S
iI is a family of connected subsets of X such that
T
A
=
6
,
then
A
=
iI i
iI Ai is connected.
Product Spaces
(11)
Observe that the intersection of two such sets is again a set of this form.
Indeed,
(U1 Un ) (V1 Vn ) = (U1 V1 ) (Un Vn ).
(U1 V1 ) (U2 V2 )
X2
U2
V2
U1
V1
X1
Consequently, the family (11) forms a basis. Let j : X Xj be the
projection of X onto the jth factor, defined by
j (x1 , . . . , xn ) = xj ,
51
(x1 , . . . , xn ) X.
t [0, 1].
Lemma 9.7. Let Y be a topological space and let B be a basis for the topology
of Y . If every open cover of Y by sets in B has a finite subcover, then Y is
compact.
Proof. Let {Ui }iI be an open cover of Y . For each y Y , choose Vy B
and an index j so that y Vy Uj . The family {Vy }yY forms an open
cover of Y by sets belonging to B. In view of the assumption, there exists a
finite number of the Vy s that cover Y . Since each of these Vy s is contained
in at least one of the Uj s, we obtain a finite number of Uj s that cover Y .
Hence Y is compact.
Theorem 9.8 (Tychonoff s Theorem for the finite product). Let X
be the product of compact spaces X1 , . . . , Xn . Then X is compact.
Proof. We consider only the product of two compact spaces X1 and X2 . let
R be a cover of X1 X2 by basic open sets of the form U V , U open in X1
and V open in X2 . In view of Lemma 9.7, it is enough to show that R has a
finite subcover. Fix z X2 . The slice X1 {z} is compact. Hence there are
finitely many sets U1 V1 , . . . , Un Vn in R covering the slice X {z}. We
may assume that z Vj for all 1 6 j 6 n, by throwing out products where
the second factor does not contain z. The set V (z) = V1 Vn is an open
set containing z, and the set 21 (V (z)) is covered by sets Uj Vj , 1 6 j 6 n.
The collection {V (z)}zX2 is an open cover of X2 , and since X2 is compact,
X2 = V (z1 ) V (zl ) for some finite number of points zj X2 . Then
X = 21 (V (z1 )) 21 (V (zl )). Each 21 (V (zj )) is covered by finitely
many sets in R. Consequently, X can be covered by finitely many sets in
R, and, in view of Lemma 9.7, X is compact.
54
Theorem 9.11 (Ascoli-Arzela Theorem). Let X be a compact topological space and let (M, ) be a complete metric space. Let F C(X, M ).
Then the closure F is compact in C(X, M ) if and only if the two following
conditions hold:
(1) F is equicontinuous.
(2) For every x X, the set F(x) = {f (x) | f F} has a compact closure
in M .
Proof. Since C(X, M ) is a complete metric space, F is compact if and only
if F is totally bounded. Assume first that the conditions (1) and (2) are
satisfied. In view of the above remark we have to show that F is totally
bounded. Given > 0, for each x X there exists an open neighbourhood
V (x) such that if y V (x), then (f (x), f (y)) < for all f F. Since
{V (x)}xX is an open cover of X and X is compact by assumption, there
exist a finite number of points x1 , . . . , xn such that V (x1 ), . . . , V (xn ) cover
X. The sets F(xj ) are totally bounded in M , hence so is the union S =
F(x1 ) F(xn ). Let {a1 , . . . , am } be an -net for S. For every map
: {1, . . . , n} {1, . . . , m} denote by
B = {f F | (f (xj ), a(j) ) < for all j = 1, . . . , n}.
55
10
Applying Lemma 10.1 again to the open set U1/2 containing A and to the
open set V containing U 1/2 , we obtain open sets U1/4 and U3/4 such that
A U1/4 U 1/4 U1/2 U 1/2 U3/4 U 3/4 V.
Continuing in this way, we associate to every such dyadic rational number
p (0, 1) an open subset Up X having the following properties
Up Uq ,
A Up ,
Up V,
(12)
0 < p < 1,
(13)
0 < p < 1.
(14)
Next we shall construct a function f which is continuous and such that the
sets Up are level sets of f on which f assumes the value p. Define f (x) = 0
if x Up for all p > 0 and f (x) = sup{p| x 6 Up } otherwise. Clearly,
0 6 f 6 1, f (x) = 0 for all x A and f (x) = 1 for all x B. It remains
to show that f is continuous. Take x X. We only consider the case
that 0 < f (x) < 1. (The remaining cases f (x) = 0 and f (x) = 1 are left
as an exercise.) Let > 0 and choose dyadic rationals p and q such that
0 < p, q < 1 and
f (x) < p < f (x) < q < f (x) + .
Then x 6 Ur for dyadic rationals r between p and f (x) so that, in view of
(12), x 6 U p . On the other hand, x Uq . So W = Uq \ U p is an open
neighbourhood of x. Then p 6 f (y) 6 q for any y W which shows that
|f (x) f (y)| < for all y W . Hence f is continuous and the proof is
completed.
Theorem 10.3 (Tietzes extension theorem). Let A be a closed subset of a
normal space X and let f be a bounded continuous real valued function on
A. Then there exists a bounded continuous function h : X R such that
f = h on A.
Proof. Set a0 = sup{|f (a)|| a A}. Since f is bounded, the number a0 is
finite. Define sets
B0 = {a A| f (a) 6 a0 /3}
C0 = {a A| f (a) a0 /3}.
Since f is continuous and A is closed, the sets B0 and C0 are closed and
disjoint subsets of X. Taking a linear combination of the function from
Urysohns lemma and a suitable constant function we find a continuous
58
function g0 : X R satisfying a0 /3 6 g0 6 a0 /3 on X, g0 = a0 /3 on B0
and g0 = a0 /3 on C0 . Thus,
|g0 | 6 a0 /3
on X
|f g0 | 6 2a0 /3
on A.
on X
(15)
|fn | = |f g0 g1 gn | 6 2 a0 /3
on A.
(16)
|f g0 g1 gn | 6 2an1 /3
on A.
n 1.
If n > m, then
n
m+1
2
a0
2
+ +
|hn hm | = |gm+1 + + gn | 6
3
3
3
m+1
2
a0 .
6
3
Consequently, {hn } is Cauchy in C(X, R). Hence there exists a continuous
function h : X R such that hn h. In addition,
n
X
a0 X 2 n
= a0 ,
|gk | 6
|h| = |lim hn | = lim|hn | 6 lim
3
3
k=0
k=1
59
11
Appendix
Sets
A set is considered to be a collection of objects. The objects of a set A are
called elements (or members) of A. If x is an element of a set A we write
x A, and if x is not an element of A we write x 6 A. Two sets A and B
are called equal, A = B, if A and B have the same elements. A set A is a
subset of a set B, written A B, if every element of A is also an element
of B. The empty set has no elements; it has the property that it is a
subset of any set, that is, A for any set A. Given two sets A and B we
define:
(a) the union A B of A and B as the set
A B = {x | x A or x B};
(b) the intersection A B of A and B as the set
A B = {x | x A and x B};
(c) the set difference A \ B (or A B) of A and B as the set
A \ B = {x | x A and x 6 B}.
Sets A and B are called disjoint if A B = . The concept of union
and intersection of two sets extends to unions and intersections of arbitrary
families of sets. By a family of sets we mean a nonempty set F whose
elements are sets themselves. If F is a family of sets, then
[
A = {x | x A for some A F}
AF
AF
A = {x | x A for all A F }.
iI
iI
iI
iI
The set of all subsets of a given set X is called the power set and is denoted
by P(X).
If X and Y are sets, their cartesian product X Y is the set consisting
of all ordered pairs (x, y) with x X and y YQ. Similarly, given n sets
X1 , . . . , Xn we can define their cartesian product ni=1 Xi = X1 . . . Xn .
Given two sets X and Y , a relation from X to Y is a subset R of X Y . We
say that R is a relation on X if R is a subset of X X, that is, R X X.
Quite often we write xRy instead of (x, y) R.
The most important example of a relation is a function. A relation f from
X to Y is called a function if for each x X there exists exactly one y Y
such that xf y. If xf y, we write y = f (x); y is called the value of f at x.
We also will write f : X Y to mean that f is a function from X to Y .
Here X is called the domain of f , Y is called the codomain of f , and the
set {f (x) | x X} is called the range of f . If f : X Y is a function,
A X and B Y , then the image of A and the preimage (or inverse
image) of B under f are sets defined by
f 1 (B) = {x | f (x) B}.
f 1
f
iI
(A ) = f
iI
c
Ai
f 1 (Ai ).
iI
c
(A) .
Example 11.2. Consider the interval I = [0, 1]. We shall show that I is
uncountable. Seeking a contradiction, suppose that I is countable. Hence all
elements of I can be listed as an infinite sequence {x1 , x2 , . . .} with decimal
expansions:
x1 = 0.a11 a12 a13
Define
(
1
bn =
2
if ann 6= 1,
if ann = 1
Proposition 11.3. Let A be a non-empty set. Then the following are equivalent:
(a) A is countable.
(b) There exists a surjection f : N A.
(c) There exists an injection g : A N.
Proof. Assume that A is countable. If A is countably infinite, then there
exists a bijection f : N A. If A is finite, then there is a bijection h :
{1, . . . , n} A for some n. Define f : N A by
(
h(i)
if 1 6 i 6 n,
f (i) =
h(n)
if i > n.
Check that f is a surjection. So the implication (a) = (b) is proved. Next
we prove the implication (b) = (c). Let f : N A be a surjection. Define
g : A N by the equation g(a) = smallest number in f 1 (a). Since f is
a surjection, f 1 (a) is non-empty for any a A, so that g is well-defined.
Next check that if a 6= a , then f 1 (a) and f 1 (a ) are disjoint, so they have
different smallest elements. The injectivity of g follows. Now the implication
(c) (a). Assume that g : A N is injective. We want to show that A is
countable. Note that g from A to g(A) is a bijection. So it suffices to show
that any subset B of N is countable. This is obvious when B is finite. Hence
assume that B is an infinite subset of N. We define a bijection h : N B.
Let h(1) be the smallest element of B. Since B is infinite, it is non-empty
and so h(1) is well-defined. Having already defined h(n 1), let h(n) be
the smallest element of the set {k B | k > h(n 1)}. Again this set
is non-empty, so h(n) is well-defined. Now check that the function h is a
bijection from N to B.
63
The ordering properties start with the fact that there is a subset R+ of R, the
set of positive real numbers. The set R+ is characterized by the property:
if a, b R+ , then a + b and ab R+ . The fact that a R+ is denoted by
0 < a or a > 0. The set of negative real numbers R = R+ is the set of
negatives of elements in R+ . For every a R, we have a R+ or a = 0 or
a R . The notation a < b (or b > a) means that b a R+ . We also
write a 6 b to mean a < b or a = b. The order properties of real numbers
are as follows:
(a) a < b and b < c, then a < c.
(b) a < b and c > 0, then ac < bc.
(c) a < b and c R, then a + c < b + c.
(d) a < b and a, b > 0, then 1/b < 1/a.
If A R, a number M is called an upper bound for A if a 6 M for all
a A. Similarly, m is a lower bound for A if m 6 a for all a A. A
subset A of R is called bounded above if it has an upper bound, and is
called bounded below if it has a lower bound. If A has an upper and lower
bound, then it is called bounded. A given subset of R may have several
upper bounds. If A has an upper bound M such that M 6 b for any upper
bound b of A, then we call M a least upper bound of A or supremum
of A, and denote it by M = sup A. Similarly, a real number m is called a
greatest lower bound of A or an infimum of A if m is a lower bound of
A and b 6 m for all lower bounds b of A. If m is the greatest lower bound
of A, we write m = inf A.
The completeness property of R asserts that every non-empty subset
A R that is bounded above has a least upper bound, and that every nonempty subset S R which is bounded below has a greatest lower bound.
Useful characterisations of a least upper bound and a greatest lower bound
are contained in the following propositions:
Proposition 11.8. Let A R be bounded above. Then a = sup A if and
only if x 6 a for any x A, and for any > 0 there exists x A such that
a < x + .
Proof. Assume first that a = sup A. Clearly, x 6 a for any x A. Take
> 0. If for all x A, x + 6 a, then x 6 a for all x. Hence a
is an upper bound of A contradicting the definition of a as the least upper
bound of A. Conversely, from x 6 a for any x A follows that a is an upper
65
bound of A. Assume that there is an upper bound b such that b < a. Then
we get a contradiction with the fact that for any > 0 there exists x A
such that a < x + . Let := (a b)/2 and choose such an x A. Then
x + 6 b + = (a + b)/2 < a.
There is also a similar characterisation of inf A provided that A is bounded
from below.
Proposition 11.9. Let A R be bounded from below. Then a = inf A if
and only if a 6 x for any x A, and for any > 0 there exists x A such
that x < a.
The proof of the proposition follows from the previous one by observing
two facts: if A is bounded from below then the set A = {x | x A} is
bounded from above and that sup(A) = inf A.
It is useful to introduce the extended real number system, R = R
{, } by adjoining symbols and subject to the ordering rule
< a < for all a R. If A is not bounded above, then we write
sup A = , and if A is not bounded below we write inf A = . For
example, we have inf R = and sup R = . We also have sup =
and inf = , and for all non-empty sets A, inf A 6 sup A. With this
terminology, the completeness property asserts that every subset of R has a
least upper bound and a greatest lower bound.
The arithmetic operations on R can be partially extended to R. In particular
we have:
+ r = r + = for r R
() + () = ,
and () + () = .
() + ()
()() = .
68
n kn
n kn
69
(d) lim inf an 6 lim sup an , with equality if and only if {an } converges (in
this case lim sup an = lim an );
(f ) If {ank } is a subsequence of {an }, then lim inf an 6 lim inf ank 6
lim sup ank 6 lim sup an .
The proof is left as an exercise.
Theorem 11.15 (Bolzano-Weierstrass Theorem).
Let {an } be a bounded sequence in R. Then it has a subsequence that converges.
Proof. Set a = lim sup an . We will construct inductively a subsequence
{ank } of {an } which converges to a. In view of Proposition 11.13, there
exists n1 such that an1 > a 1. Having obtained n1 < n2 < < nk such
that anj > a 1/j for 1 6 j 6 k, we find, again by applying Proposition
11.13, nk+1 > nk such that ank+1 > a 1/(k + 1). Hence a 6 lim inf ank 6
lim sup ank 6 lim sup an = a. So lim ank = a and the proof is finished.
References
[Me] B. Mendelson, Introduction to Topology.
[M] J. R. Munkres, Topology: A First Course.
[P] C. W. Patty, Foundations of topology.
[S] W. A. Sutherland. Introduction to metric and topological spaces.
70