Nothing Special   »   [go: up one dir, main page]

Metric Spaces and Topology, Notes

Download as pdf or txt
Download as pdf or txt
You are on page 1of 51

5CCM226A/6CCM226B Metric Spaces and Topology

Lecturer: Dr Jeremiah Buckley


Spring 2021

There are two types of exercises in these notes: those in the body of the text and those at
the ends of sections. Exercises of the first type form an essential part of the exposition; they
fill gaps in the text. Exercises of the second type are aimed at improving your understanding
of the concepts involved. Attempting (and successfully solving!) exercises of both types is a
crucial part of the course - mathematics is not a spectator sport. Difficult exercises
are marked with a star.

Contents
1 Metric Spaces 3
1.1 Convergence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.2 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

2 Open and Closed Sets (in a Metric Space) 8


2.1 Balls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2.2 Open sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
2.3 Closed Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11
2.4 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14

3 Topological Spaces 15
3.1 Sequences and Hausdorff spaces . . . . . . . . . . . . . . . . . . . . . . . . . 16
3.2 Closed Sets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
3.3 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18

4 Continuity 21
4.1 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24

5 Completeness 26
5.1 Cauchy Sequences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
5.2 Complete Metric Spaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
5.3 Cantor’s Intersection Theorem . . . . . . . . . . . . . . . . . . . . . . . . . . 29
5.4 Contractions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

1
5.5 Picard’s Existence Theorem for First Order Differential Equations . . . . . . 30
5.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32

6 Connectedness 33
6.1 Connected topological spaces . . . . . . . . . . . . . . . . . . . . . . . . . . 33
6.2 Path-connectedness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
6.3 Connectedness as a topological invariant . . . . . . . . . . . . . . . . . . . . 35
6.4 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36

7 Compactness 37
7.1 Sequential compactness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
7.2 Compactness in a topological space . . . . . . . . . . . . . . . . . . . . . . . 37
7.3 Totally bounded sets in a metric space . . . . . . . . . . . . . . . . . . . . . 39
7.4 Compactness and continuous functions . . . . . . . . . . . . . . . . . . . . . 40
7.5 Uniform continuity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
7.6 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42

8 Products and quotients of topological spaces 44


8.1 The product topology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
8.2 Quotient spaces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47

A Supplementary Material for Level 6 49

B Non-examinable bonus material 50


B.1 The completion of a metric space . . . . . . . . . . . . . . . . . . . . . . . . 50

2
1 Metric Spaces
Definition 1.1. Let X be a non-empty set. A function d : X × X → R is called a metric
on X if it satisfies

ˆ d(x, y) > 0 if x 6= y and d(x, x) = 0,

ˆ d(x, y) = d(y, x), and

ˆ d(x, z) ≤ d(x, y) + d(y, z) (the triangle inequality),

where x, y and z are arbitrary elements of X. We say that (X, d) is a metric space.

Example 1.2. R or C with the usual (Euclidean) metric d(x, y) = |x − y|.


Example 1.3. Rn or Cn with the Euclidean metric
n
!1/2
X
d(x, y) = |xi − yi |2
i=1

where xi and yi are coordinates of the points x and y respectively.


Exercise 1.4. (i) Prove the Cauchy-Schwarz inequality: If ai , bi ≥ 0 then
v v
Xn u n u n
uX uX
2
ai b i ≤ t ai t b2i .
i=1 i=1 i=1

pP pP
Hint: Let A = a2i , B = b2i and apply the inequality xy ≤ 21 (x2 + y 2 ) to aAi and bBi
(ii) Prove that the function defined in Example 1.3 satisfies the triangle inequality, and is
therefore a metric.
Example 1.5. Rn or Cn with the metric

d(x, y) = |x1 − y1 | + |x2 − y2 | + · · · + |xn − yn |.

Example 1.6. Rn or Cn with the metric

d(x, y) = max{|xi − yi | : 1 ≤ i ≤ n}.

Example 1.7. C[a, b], the set of all continuous (real or complex-valued) functions on [a, b],
with the metric
d(f, g) = sup |f (x) − g(x)|. (1.1)
x∈[a,b]

Example 1.8. Let B(S) (or sometimes `∞ (S)) denote the set of all bounded (real or
complex-valued) functions on a set S with the metric

d(f, g) = sup |f (x) − g(x)|. (1.2)


x∈S

3
Note that (1.2) turns into (1.1) if S = [a, b]. In other words, if S = [a, b] then (1.2)
and (1.1) define the same metric. However the space C[a, b] is strictly smaller than B[a, b]
(every continuous function on [a, b] is bounded but there are bounded functions that are
not continuous).
Example 1.9. Let (X, d) be a metric space and suppose that A is a non-empty subset of
X. Then (A, d) is a metric space, which we call a metric subspace of (X, d).
Example 1.10. Given any non-empty set X, define the metric d by
(
1, if x 6= y
d(x, y) =
0, if x = y.

We call this metric the discrete metric.


We can also define the distance between a point and a set in a metric space; by an abuse
of notation we use the same letter d.
Definition 1.11. If (X, d) is a metric space and A ⊂ X then we define

d(x, A) = inf d(x, a)


a∈A

1.1 Convergence
Definition 1.12. A sequence xn of elements of a metric space (X, d) is said to converge to
x ∈ X if for any ε > 0 there exists an integer Nε such that d(xn , x) ≤ ε for all n > Nε . We
write xn → x as n → ∞.
Lemma 1.13 (another definition of convergence). The sequence xn converges to x in (X, d)
if and only if d(xn , x) → 0 in R.
Proof. By definition, the sequence of non-negative numbers d(xn , x) converges to zero if
and only if for any ε > 0 there exists an integer Nε such that d(xn , x) ≤ ε for all n > Nε .
Lemma 1.14. If rn are non-negative numbers such that rn → 0 in R and d(xn , x) ≤ rn for
all (sufficiently large) n then xn converges to x in (X, d).
Proof. By definition, the sequence of real numbers rn converges to zero if and only if for any
ε > 0 there exists an integer Nε such that rn ≤ ε for all n > Nε . Then d(xn , x) ≤ rn ≤ ε
for all n > Nε which means that d(xn , x) → 0.
Lemma 1.15 (uniqueness of limits). Let xn be a sequence in (X, d) and suppose that xn → x
and xn → y as n → ∞. Then x = y.
Proof. We have, by the triangle inequality, for any n

0 ≤ d(x, y) ≤ d(x, xn ) + d(xn , y) → 0

as n → ∞. By the Squeeze Lemma d(x, y) = 0, i.e., x = y.

4
Remark 1.16. This allows us to write x = limn→∞ xn .

Definition 1.17. We say that metrics d1 and d2 defined on the same set X are equivalent
if
xn → x in (X, d1 ) if and only if xn → x in (X, d2 ).

Exercise 1.18. Check that the metrics introduced in Examples 1.5 and 1.6 are equivalent
to the Euclidean metric (Example 1.3), whereas the discrete metric (Example 1.10) on
X = Rn is not.

Definition 1.19. We say that a sequence of functions fn ∈ B(S) (or in any subspace
of B(S)) converges uniformly on S if it converges with respect to the metric defined in
Example 1.8

From now on, unless specifically stated otherwise, we will always assume that the space
B(S) is equipped with this metric, in particular we will assume that C[a, b] always carries
this metric.

Lemma 1.20 (another definition of uniform convergence). Let fn be a sequence in B(S)


and f ∈ B(S). Then fn → f in B(S) if and only if for any ε > 0 there exists an integer
Nε such that |f (x) − fn (x)| ≤ ε for all n > Nε and all x ∈ S.

Proof. fn → f in B(S) if and only if d(f, fn ) = supx∈S |f (x) − fn (x)| → 0 (Lemma 1.13).
By definition, the sequence of real numbers supx∈S |f (x) − fn (x)| converges to zero if and
only if for any ε > 0 there exists an integer Nε such that

sup |f (x) − fn (x)| ≤ ε , for all n > Nε .


x∈S

Therefore we only have to prove that supx∈S |f (x)−fn (x)| ≤ ε if and only if |f (x)−fn (x)| ≤
ε for all x ∈ S.
If supx∈S |f (x) − fn (x)| ≤ ε then, obviously,

|f (x) − fn (x)| ≤ sup |f (x) − fn (x)| ≤ ε, for all x ∈ S.


x∈S

Assume now that |f (x) − fn (x)| ≤ ε for all x ∈ S. By definition, the supremum coincides
with the least upper bound. Therefore for any δ > 0 there exists a point xδ ∈ S such that

sup |f (x) − fn (x)| ≤ δ + |f (xδ ) − fn (xδ )| ≤ δ + ε.


x∈S

Since δ can be chosen arbitrarily small, this implies that supx∈S |f (x) − fn (x)| ≤ ε.
Remark 1.21. A sequence of functions fn ∈ B(S) converges to f ∈ B(S) pointwise if
for any x ∈ S and ε > 0 there exists an integer Nε,x such that |f (x) − fn (x)| ≤ ε for all
n > Nε,x . In this definition the integer Nε,x may depend on x. If for any ε the set {Nε,x }x∈S
is bounded from above, that is Nε,x ≤ Nε for all x ∈ S, then fn → f uniformly.

5
1.2 Exercises
Exercise 1.22. (i) For x, y ∈ (0, ∞) let

1 1
d(x, y) = − .
x y

Is d a metric on (0, ∞)?


(ii) For x, y ∈ R let

x y
d(x, y) = √ − p .
1 + 1 + x2 1 + 1 + y 2

Is d a metric on R?
[Hint : Consider a more general problem - what properties does a function f need to
satisfy so that d(x, y) = |f (x) − f (y)| is a metric?]
Exercise 1.23. Let (X, ρ) be a metric space. Show that

ρ(x, y)
d(x, y) =
1 + ρ(x, y)
is a metric on X.
Exercise 1.24. Let C[a, b] denote the set of all continuous (real or complex-valued) func-
tions on [a, b] and define
Z b
d(f, g) = |f (x) − g(x)|dx.
a
Show that d is a metric.
Exercise 1.25. Let (X1 , d1 ) and (X2 , d2 ) be metric spaces. Set X = X1 × X2 and for
x = (x1 , x2 ) ∈ X and y = (y1 , y2 ) ∈ X define
ˆ d(x, y) = d1 (x1 , y1 ) + d2 (x2 , y2 ),

ˆ ρ(x, y) = d1 (x1 , y1 )2 + d2 (x2 , y2 )2 and


p

ˆ σ(x, y) = max{d1 (x1 , y1 ), d2 (x2 , y2 )}.

Show that d, ρ and σ are all metrics on X.


Exercise 1.26. (i) Let d be the metric on (0, ∞) defined in Exercise 1.22 (i). Show that d
is equivalent to the usual metric on (0, ∞).
(ii) Let X be non-empty and suppose that ρ and d are metrics on X. Show that if there
exist positive constants L and M such that for all x, y ∈ X,

Lρ(x, y) ≤ d(x, y) ≤ M ρ(x, y),

then ρ and d are equivalent. Show further that the converse is false. [Hint : Use (i).]

6
Exercise 1.27. In each of the following cases determine whether the sequence of functions
fn (a) converges pointwise on [0, 1] and (b) converges uniformly on [0, 1].
x
(i) fn (x) = ,
x+n
nx
(ii) fn (x) = .
1 + n 2 x2

7
2 Open and Closed Sets (in a Metric Space)
2.1 Balls
Let (X, d) be a metric space and r be a strictly positive number.

Definition 2.1. If α ∈ X then the set

Br (α) = {x ∈ X : d(x, α) < r}

is called the open ball of centre α and radius r and the set

Br [α] = {x ∈ X : d(x, α) ≤ r}

is called the closed ball of centre α and radius r.

If there is a need to emphasize the metric, we write Brd (α) and Brd [α].
Example 2.2. In R with the usual metric we have Br (α) = (α − r, α + r) and Br [α] =
[α − r, α + r].
Example 2.3. In R2 with the usual metric Br (α) and Br [α] are the open and closed discs
centred at α of radius r
Example 2.4. If X is any non-empty set and d is the discrete metric then
(
{α}, if r ≤ 1
Br (α) =
X, if r > 1,

while (
{α}, if r < 1
Br [α] =
X, if r ≥ 1,
Exercise 2.5. Plot the ball B1 ((0, 0)) in R2 for the metrics defined in Examples 1.5 and
1.6
Clearly,
α ∈ Br−ε (α) ⊆ Br (α) ⊆ Br [α] ⊆ Br+ε (α) (2.1)
for every r > ε > 0.

Definition 2.6. A set A ⊆ X is said to be a neighbourhood of α ∈ X if A contains an open


ball Br (α) for some r > 0.

Example 2.7. Consider (0, 1] in R with the usual metric. Then (0, 1] is a neighbourhood
of 12 but is not a neighbourhood of 1.
In view of (2.1), the balls Br (α) and Br [α] are neighbourhoods of the point α. Now we
can rephrase Definition 1.12 as follows.

8
Lemma 2.8. (i) A sequence xn in a metric space converges to x if and only if for any ball
Bε (x) there exists an integer Nε such that for all n > Nε we have xn ∈ Bε (x).
(ii) A sequence xn in a metric space converges to x if and only if for any neighbourhood
A of x there exists an integer NA such that for all n > NA we have xn ∈ A.
Theorem 2.9. Two metrics ρ and d on the same set X are equivalent if and only if every
open ball Brρ (x) contains an open ball Bsd (x) and every open ball Bsd (x) contains an open
ball Btρ (x).
d
Proof. If every open ball Brρ (x) contains an open ball Bsd (x) and xn → x then for any r > 0
we can choose s > 0 and ns such that

xn ∈ Bsd (x) ⊆ Brρ (x) , ∀n > ns .


ρ
This implies that xn → x. Similarly, if every open ball Bsd (x) contains an open ball Btρ (x),
ρ d
then xn → x implies xn → x. Hence, the metrics are equivalent.
Assume now that the metrics are equivalent but there exists an open ball Brρ (x) which
contains no open Bsd (x), s > 0. Let us choose a sequence sn → 0 and let xn ∈ Bsdn (x) and
d
xn 6∈ Brρ (x). Then xn → x. However, the sequence xn does not converge to x in the metric
ρ because xn 6∈ Brρ (x) for all n. Therefore the metrics ρ and d are not equivalent, and we
obtain a contradiction.
The theorem implies that if A is a neighbourhood of x in (X, d) then it is a neighbour-
hood of x with respect to every metric which is equivalent to d.

2.2 Open sets


Definition 2.10. Let (X, d) be a metric space. A set is open in (X, d) if it contains a ball
about each of its points. Equivalently, a set is open in (X, d) if it is a neighbourhood of
each of its points.
Lemma 2.11. An open ball in a metric space (X, d) is open in (X, d).
Proof. If x ∈ Br (α) then d(x, α) = r − ε for some ε > 0. If y ∈ Bε (x) then d(y, x) < ε and,
by the triangle inequality,

d(y, α) ≤ d(y, x) + d(x, α) < ε + r − ε = r.

This implies that y ∈ Br (α) for all y ∈ Bε (x), that is, Bε (x) ⊆ Br (α).
Theorem 2.12. If (X, d) is a metric space then
1. the whole space X and the empty set ∅ are both open in (X, d),

2. the union of any collection of open subsets of X is open in (X, d),

3. the intersection of any finite collection of open subsets of X is open in (X, d).

9
Proof. 1. The whole space is open because it contains all open balls and the empty set is
open because it does not contain any points.
2. If x belongs to the union of open sets An , then x belongs to at least one of the sets
An . Since this set is open, it also contains an open ball about x. This ball lies in the union
of An , so the union is an open set.
3. If A1 , A2 , . . . , Ak are open sets and x ∈ ∩kn=1 An , then x ∈ An for every n =
1, . . . , k. Since An are open, for each n there exists rn such that Brn (x) ⊆ An . Let
r = min{r1 , r2 , . .. , rk }. Then r > 0 and Br (x) ⊆ Brn (x) ⊆ An for all n = 1, . . . , k, so
Br (x) ⊆ ∩kn=1 An .
Example 2.13. Consider R with the usual metric. Then {0} is not open in R, since
(−ε, ε) = Bε (0) * {0} for any ε > 0.
Example 2.14. Consider R with the usual metric. Let An be the open intervals
(−1/n, 1/n) in R. Then An are open sets but the intersection ∩∞ n=1 An = {0} is not open.
Thus, an infinite intersection of open sets is not necessarily open.
Example 2.15. Consider R with the usual metric. Then A = {x ∈ R : 0 < x ≤ 1} is not
open in R, since (1 − ε, 1 + ε) = Bε (1) * A for any ε > 0.
Example 2.16. Consider again A = {x ∈ R : 0 < x ≤ 1}, as a metric subspace of R. Then
A is open in A!
Example 2.17. Consider again {0} ⊆ R but now equipped with the discrete metric d.
Then {0} = B1 (0) is open in (R, d)!!

Lemma 2.18. A set is open if and only if it coincides with the union of a collection of
open balls.

Proof. According to Lemma 2.11 and Theorem 2.12 2, the union of any collection of open
balls is open.
On the other hand, if A is open, then for every point x ∈ A there exists a ball B(x)
about x lying in A. We have A = ∪x∈A B(x). Indeed, the union ∪x∈A B(x) is a subset of A
because every ball B(x) is a subset of A, and the union contains every point x ∈ A because
x ∈ B(x).
Exercise 2.19. Let X be an arbitrary non-empty set and let d be the discrete metric on
X. Let A be an arbitrary subset of X. Show that A is open.

Theorem 2.20. Let (X, d) be a metric space and (A, d) a subspace. A set U is open in A
if and only if U = A ∩ O for some O open in X.

Proof. First notice that if α ∈ A and r > 0 then

BrA (α) = {x ∈ A : d(x, α) < r} = A ∩ {x ∈ X : d(x, α) < r} = A ∩ BrX (α). (2.2)

Let U be open in A. Then, by Lemma 2.18, we can write U = i BiA for some collection
S
of open balls BiA in A. By (2.2) we can write each BiA = A ∩ BiX for some open ball in

10
X and so U = A ∩ ( i BiX ). Since O = i BiX is open in X by Lemma 2.18, we have
S S
U = A ∩ O for some O open in X.
Conversely, if O is open in X and α ∈ A ∩ O then BrX (α) ⊆ O for some r > 0. Using
(2.2) again we see that BrA (α) = A ∩ BrX (α) ⊆ A ∩ O and so A ∩ O is open in A.

Definition 2.21. A point x ∈ A is said to be an interior point of the set A if there exists
an open ball Br (x) lying in A. The interior of a set A is the union of all open sets contained
in A, that is, the maximal open set (with respect to set inclusion) contained in A. The
interior of A is denoted by int(X,d) (A), or if the context is clear, simply int(A).

Exercise 2.22. Show that x is an interior point of the set A if and only if x ∈ int(A).

2.3 Closed Sets


Definition 2.23. A point x ∈ X is called a limit point of a set A if every ball about x
contains a point of A distinct from x. Other terms for “limit point” are “accumulation
point” or “cluster point”. The set of limit points of A is denoted A0 .

Remark 2.24. The notation A0 is not very satisfactory, since the set of limit points of a
set A depends on the metric space (X, d). We will only use this notation when the context
is clear.
Exercise 2.25. Show that if A ⊆ B then A0 ⊆ B 0 .

Lemma 2.26. A point x is a limit point of a set A if and only if there is a sequence xn of
elements of A distinct from x which converges to x.

Proof. If xn → x then every ball about x contains a point xn (see Lemma 2.8). Conversely,
if every ball about x contains a point of A distinct from x, then there exists a sequence
of points xn ∈ A distinct from x and lying in the balls B1/n (x). Obviously, this sequence
converges to x.

Definition 2.27. A set is closed in (X, d) if it contains all of its limit points.

Lemma 2.28 (another definition of closed sets). A set A is closed if and only if the limit
of any convergent sequence of elements of A lies in A.

Proof. If a sequence of elements of A has a limit then either this limit coincides with one
of the elements of the sequence (and then it lies in A) or it is a limit point of A. Therefore
a closed set A contains the limits of all convergent sequences {xn } ⊆ A.
Conversely, every limit point is a limit of some sequence {xn } ⊆ A. Therefore A contains
all its limit points, provided that the limit of any convergent sequence of elements of A lies
in A.

Lemma 2.29. A closed ball in a metric space (X, d) is closed.

11
Proof. Let xn be a convergent subsequence lying in the closed ball Br [α] and let x be its
limit. Then, by the triangle inequality,

d(x, α) ≤ d(x, xn ) + d(xn , α) ≤ d(x, xn ) + r, for all n ∈ N.

Since xn → x, we can make d(x, xn ) arbitrarily small by choosing n large. This implies
that d(x, α) ≤ r, that is, x ∈ Br [α].
Theorem 2.30. If A is open in (X, d) then X \ A is closed in (X, d). If A is closed in
(X, d) then X \ A is open in (X, d).
Proof. If A is open, then for every point of A there exists a ball about this point lying in
A. Clearly, such a ball does not contain any points from X \ A. This means that no point
of A is a limit point of X \ A, that is, X \ A contains all of its limit points.
If A is closed, then it contains all its limit points, so no point x ∈ X \ A is a limit point
of A. This means that for any x ∈ X \ A there exists a ball Br (x) which lies in X \ A, that
is, X \ A is open.
Exercise 2.31. Let X be an arbitrary non-empty set and let d be the discrete metric on
X. Let A be an arbitrary subset of X. Use Exercise 2.19 to show that A is closed.
Theorem 2.32. In a metric space (X, d)
ˆ the whole space X and the empty set ∅ are both closed,

ˆ the intersection of any collection of closed sets is closed, and

ˆ the union of any finite collection of closed sets is closed.


Proof. The theorem follows from Theorem 2.12, Theorem 2.30 and the following elementary
results.
1. X \ X = ∅ and X \ ∅ = X (obvious).
2. The complement of the intersection of the sets Aν coincides with the union of the
complements X \ Aν . Indeed,
!
\ \
x∈X\ Aν ⇔ x 6∈ Aν ⇔ x 6∈ Aν for some ν
ν ν
[
⇔ x ∈ X \ Aν for some ν ⇔ x ∈ (X \ Aν ).
ν

3. The complement of the union of sets Aν coincides with the intersection of the comple-
ments X \ Aν . Indeed,
!
[ [
x∈X\ Aν ⇔ x 6∈ Aν ⇔ x 6∈ Aν for all ν
ν ν
\
⇔ x ∈ X \ Aν for all ν ⇔ x ∈ X \ (Aν ).
ν

12
Remark 2.33. There are sets that are neither open nor closed, e.g., [0, 1) in R with the
usual metric (prove this!).
Definition 2.34. The closure of a set A is the intersection of all closed sets containing A,
that is, the minimal (with respect to set inclusion) closed set containing A. The closure is
denoted by Clos(X,d) (A) or, if there is no potential for confusion, Clos(A) or Ā.
Theorem 2.35. Ā = A ∪ A0 .
Proof. The set A ∪ A0 is closed. Indeed, let x ∈ X \ (A ∪ A0 ) be an arbitrary point. Then
x 6∈ A0 . Therefore there exists a ball Br (x) which does not contain elements of A distinct
from x (Definition 2.23). Since x 6∈ A, this implies that Br (x) ⊆ X \ A. For every point
y ∈ Br (x) there exists a ball Bε (y) ⊆ Br (x) ⊆ X \ A by Lemma 2.11, that is, a point
y ∈ Br (x) cannot be a limit point of A. Therefore Br (x) ⊆ X \ (A ∪ A0 ). Thus, for every
point x ∈ X \ (A ∪ A0 ) we can find a ball Br (x) ⊆ X \ (A ∪ A0 ). This means that the set
X \ (A ∪ A0 ) is open. By Theorem 2.30 the set A ∪ A0 is closed.
It remains to prove that A ∪ A0 is the minimal closed set which contains A. Let A ⊆
K ⊆ A ∪ A0 and K 6= A ∪ A0 . Then K does not contain at least one point of A0 . Since
A0 ⊆ K 0 by Exercise 2.25, the set K does not contain at least one of its limit points, and
so is not closed.
Corollary 2.36. x ∈ Ā if and only if there exists a sequence {xn } ⊆ A which converges to
x.
Proof. If x ∈ Ā, then x ∈ A or x ∈ A0 (by the theorem). In the first case, the se-
quence {x, x, . . .} ⊆ A converges to x, in the second case a sequence {xn } → x exists by
Lemma 2.26.
Conversely, assume that there exists a sequence {xn } ⊆ A which converges to x. If
xn = x for some n then x ∈ A. If xn are distinct from x then, by Lemma 2.26, x ∈ A0 .
Therefore x ∈ Ā = A ∪ A0 .
Corollary 2.37. x ∈ Ā if and only if U ∩ A 6= ∅ for every neighbourhood U of x.
Proof. If U ∩ A 6= ∅ for every neighbourhood U of x then either x ∈ A or U ∩ A contains
a point different to x for every U and x is therefore a limit point of A.
Corollary 2.38. Ā = {x ∈ X : d(x, A) = 0}.
Proof. We have d(x, A) = inf y∈A d(x, y) = 0 if and only if there exists a sequence {xn } ⊆ A
with d(x, xn ) → 0.
Since Br (a) ⊆ Br [a], it follows from Lemma 2.29 that

Br (a) ⊆ Br [a]

(see Definition 2.34). On the other hand, the closure of the open ball Br (a) does not
necessarily coincide with the closed ball Br [a]. In particular, in Example 2.4, B1 (a) =
B1 (a) = {a} (since B1 (a) is closed by Exercise 2.31) but B1 [a] = X.

13
2.4 Exercises
Exercise 2.39. Show that a singleton set in a metric space is closed.
Exercise 2.40. Write down the interior and the closure of the following subsets of R
(equipped with the usual metric):
(0, 1), [0, 1), (0, 1) ∪ (1, 2), [0, 1] ∪ {2}.
For which of these sets is its closure equal to the closure of its interior?
For which of these sets is its interior equal to the interior of its closure?
Exercise 2.41. Let A and B be subsets of a metric space. Show that
(i) int(A) ∩ int(B) = int(A ∩ B), (ii) A ∪ B = A ∪ B,
(iii) int(A) ∪ int(B) ⊆ int(A ∪ B), (iv) A ∩ B ⊆ A∩ B,
(v)A = X \ int(X \ A), (vi) int(A) = X \ X \ A .
By finding suitable counterexamples, show that equality in (iii) and (iv) does not hold in
general.
Exercise 2.42. Consider R with the usual metric and let rn be an enumeration of Q. Put
An = {rn }. Compute

Clos ∪∞ ∪∞

n=1 An and n=1 Clos(An ).

Exercise 2.43. Consider R with the usual metric and let An = [−1, n1 ]. Compute

int ∩∞ ∩∞

n=1 An and n=1 int(An ).

Exercise 2.44. Find a metric space (X, d) and a subset A ⊆ X such that int(A) = ∅ and
A = X.
Exercise 2.45. Find the set of limit points in C of the set n1 + mi : n, m ∈ N .


Exercise 2.46. Find the closures and the interiors of the following sets :
(i) {(x,
 y) : xy = 1} as a subset of R2 , (ii) {z : |z| ≤ 1} as a subset of C,
(iii) x : sin x1 = 0 as a subset of R, (iv) (x, sin x1 ) : 0 < x ≤ π1 as a subset of R2 .
Do not try to write out elaborate proofs, particularly for (iv).
Exercise 2.47. Show that a set U is open if and only if U = int(U ).
Exercise 2.48. Show that a set A is closed if and only if A = A.
Exercise 2.49. Let ρ and d be two metrics on the same set X. Prove that ρ and d are
equivalent if and only if every ρ-open set is d-open and every d-open set is ρ-open. [In many
treatments this is the definition of equivalence for metrics.]
*Exercise 2.50. Show that any open subset of R with the usual metric can be written as
a countable union of disjoint open intervals.

14
3 Topological Spaces
Definition 3.1. Let X be a non-empty set. A collection τ of subsets of X is called a
topology on X if it satisfies
ˆ ∅, X ∈ τ ,

ˆ Ui ∈ τ for every i ∈ I implies that ∪i∈I Ui ∈ τ , and

ˆ U1 , U2 , . . . , Un ∈ τ implies that ∩ni=1 Ui ∈ τ .


We say that (X, τ ) is a topological space.
Example 3.2. Let (X, d) be a metric space, and let τ be the collection of open sets in X.
Then Theorem 2.12 implies that τ is a topology on X. We call τ the topology induced by
the metric d.
Example 3.3. Let X be a non-empty set and let τ = 2X = P(X) be the collection of all
subsets of X. Then τ is a topology on X. We call this topology the discrete topology.
Exercise 3.4. Show that the discrete topology is induced by the discrete metric.
Hint: Exercise 2.19.
Example 3.5. Let X be a non-empty set and let τ = {∅, X}. Then τ is a topology on X.
We call this topology the trivial topology.
Exercise 3.6. Show that if X contains at least two elements then there is no metric on X
that induces the trivial topology.
Hint: Let x and y be distinct elements, put r = d(x, y) and consider Br (x).
Example 3.7. Let X = {0, 1} and let τ = {∅, {0}, X}. Then τ is a topology on X. There
is no metric on X that induces this topology.
Definition 3.8. Let (X, τ ) be a topological space. We call the elements of τ the open sets
of the space (X, τ ). If x ∈ X and A ⊆ X then we say that A is a neighbourhood of x if
x ∈ U ⊆ A for some open set U of X.
Remark 3.9. It is easy to see that a set U is a neighbourhood of a point x in a metric
space (Definition 2.6) if and only if it is a neighbourhood of x with respect to the induced
topology as just defined. This is a principle that we will follow throughout the course, we
will define the same concept in a metric space and in a topological space. You should verify,
when it is not immediately obvious, that we are doing this in a consistent manner, that is,
that the topological definition corresponds to the metric definition in a metric space.
Exercise 3.10. Show that in a topological space a set is open if and only if it is a neigh-
bourhood of all of its points.
Definition 3.11. Let (X, τ ) be a topological space, and let A ⊆ X. We define the subspace
topology (or the relative topology, or the induced topology) on A by

τA = {U ∩ A : U ∈ τ }.

15
Exercise 3.12. Show that the subspace topology is indeed a topology.

Definition 3.13. The interior of a set A is the union of all open sets contained in A, that
is, the maximal open set (with respect to set inclusion) contained in A. The interior of A
is denoted by int(X,τ ) (A), or if the context is clear, simply int(A).

Exercise 3.14. Show that a set U is open if and only if U = int(U )

3.1 Sequences and Hausdorff spaces


We now define convergence in a topological space, guided by Lemma 2.8.

Definition 3.15. We say that a sequence (xn )∞


n=1 converges to a point x in a topological
space and write xn → x as n → ∞ if for every neighbourhood U of x there exists NU such
that xn ∈ U for n ≥ N .

Example 3.16. Consider R with the trivial topology, let xn = n1 and x = π. If U is a


neighbourhood of x then x ∈ V ⊆ U , where V is open. This means that V = R and so
U = R. Take N = 1. For n ≥ N we have xn ∈ U . Therefore xn → x, i.e., n1 → π, as
n → ∞.
Example 3.17. In fact, if (X, τ ) is any set with the trivial topology, if (xn )n∈N is an
arbitrary sequence and if x is an arbitrary point, then xn → x as n → ∞.
It is thus not possible to write limn→∞ xn for a convergent sequence in an arbitrary
topological space. We address this issue by making the following definition.

Definition 3.18. We say that a topological space (X, τ ) is a Hausdorff space if given
distinct x, y ∈ X we can find disjoint open sets U, V ⊂ X such that x ∈ U and y ∈ V .

Remark 3.19. This is just one of many “separation axioms” that can be imposed on a
topological space. It is however, the most frequently used and discussed and is therefore
the only one that we will concern ourselves with in this course.

Proposition 3.20. Every metric space is a Hausdorff space.

Proof. If X is a singleton then there is nothing to prove. Otherwise let x, y ∈ X with x 6= y,


put r = d(x, y) > 0 and consider U = B r2 (x) and V = B r2 (y). We need to show that U and
V are disjoint. But if z ∈ U ∩ V then
r r
r = d(x, y) ≤ d(x, z) + d(z, y) < 2
+ 2
= r,

which is a contradiction.

Lemma 3.21. Let xn be a sequence in a Hausdorff space and suppose that xn → x and
xn → y as n → ∞. Then x = y.

16
Proof. Suppose that x 6= y. Then there exist disjoint open sets U, V such that x ∈ U and
y ∈ V . Since xn → x there exists N1 such that xn ∈ U for n > N1 . Since xn → y there
exists N2 such that xn ∈ V for n > N2 . Choose n > max{N1 , N2 }. Then xn ∈ U ∩ V = ∅,
a contradiction.
Remark 3.22. This lemma allows one to develop a theory of Hausdorff spaces based on
the behaviour of sequences. In a general topological space, this theory breaks down and one
approach is to generalise the notion of sequences. There are two alternative approaches,
based on either nets or filters. You already met an example of a net when you defined the
Riemann integral, there you did not take a limit of a sequence as n → ∞ but took a limit
over “partitions of an interval” as the mesh size tended to 0. We will not proceed in this
direction in this course and accordingly make no further comment on nets and filters.

3.2 Closed Sets


Definition 3.23. A point x ∈ X is called a limit point of a set A if every open neighbour-
hood of x contains a point of A distinct from x. The set of limit points of A is denoted
A0 .

Exercise 3.24. Show that if A ⊆ B then A0 ⊆ B 0 .

Definition 3.25. A set is closed in (X, τ ) if it contains all of its limit points.

Theorem 3.26. A is open in (X, τ ) if and only if X \ A is closed in (X, τ ).

Proof. If A is open then A is an open neighbourhood of every point in A. This means that
no point of A is a limit point of X \ A, that is, X \ A contains all of its limit points.
If A is closed, then it contains all its limit points, so no point x ∈ X \A is a limit point of
A. This means that for any x ∈ X \ A there exists an open set U such that x ∈ U ⊆ X \ A,
that is, X \ A is a neighbourhood of x. Since x ∈ X \ A was arbitrary, this means that
X \ A is open.
Exercise 3.27. Prove that in a topological space (X, τ )

ˆ the whole space X and the empty set ∅ are both closed,

ˆ the intersection of any collection of closed sets is closed, and

ˆ the union of any finite collection of closed sets is closed.

Lemma 3.28. Let A be a closed set in a topological space X. Let xn → x as n → ∞ and


suppose that xn ∈ A for every n. Then x ∈ A.

Proof. Suppose that x ∈


/ A and put U = X \ A. Then U is open in X and x ∈ U . Since
xn → x there must exist N such that xn ∈ U = X \ A for all n > N . But this contradicts
our assumption that xn ∈ A for every n.

17
Definition 3.29. The closure of a set A is the intersection of all closed sets containing A,
that is, the minimal (with respect to set inclusion) closed set containing A. The closure is
denoted by Clos(X,τ ) (A) or, if there is no potential for confusion, Clos(A) or Ā.
Exercise 3.30. Show that in a topological space Ā = A ∪ A0 .
Exercise 3.31. Show that in a topological space x ∈ Ā if and only if U ∩ A 6= ∅ for every
neighbourhood U of x.
These results all highlight the similarity between topological and metric spaces. How-
ever, some of the results we proved about metric spaces do not hold in a general topological
space. For example, the converse to Lemma 3.28 is not true (compare with Lemma 2.28)
and neither is the analogue of Corollary 2.36. A counter example is given in Exercise 3.40
below.

3.3 Exercises
Exercise 3.32. Suppose that xn → x in a topological space. Show that any subsequence
of (xn ) also converges to x.
Exercise 3.33. Show that two metrics on the same set are equivalent if and only if they
induce the same topology.
Exercise 3.34. Let (X, τ ) be a topological space and let A ⊆ X. Show that a set C is
closed in A if and only if C = B ∩ A where B is closed in X.
Exercise 3.35. Repeat Exercise 2.41 in a topological space.
Exercise 3.36. Let X be an arbitrary non-empty set equipped with the trivial topology
and let A ⊆ X be arbitrary. What are int(A) and A?
Exercise 3.37. Let X be an arbitrary non-empty set equipped with the discrete topology
and let A ⊆ X be arbitrary. What are int(A) and A?
Exercise 3.38. Let X be an arbitrary non-empty set and define τ = {U ⊆ X : X \
U is a finite set} ∪ {∅}.
(i) Prove that τ is a topology. It is called the co-finite toplogy.

(ii) Prove that singletons are closed in this topology.

(iii) If X is finite show that the co-finite topology is the same as the discrete topology.

(iv) If X is infinite show that the co-finite topology is not Hausdorff.


Exercise 3.39. Let X be an arbitrary non-empty set and define τ = {U ⊆ X : X \
U is at most countable} ∪ {∅}.
(i) Prove that τ is a topology. It is called the co-countable toplogy.

(ii) If X is countable, show that the co-countable topology is the same as the discrete
topology.

18
*Exercise 3.40. Equip R with the co-countable topology as defined in Exercise 3.39.

(i) Prove that if xn → x then there exists N such that xn = x for all n ≥ N .

(ii) Let A = [0, ∞). By (i), if xn ∈ A for all n and xn → x as n → ∞ then x ∈ A. Is A


closed?

(iii) Let B ⊆ R be arbitrary. Prove that B = B if B is countable and that B = R


otherwise. Can you give a similar characterisation of int(B)?

*Exercise 3.41. Consider again R with the co-countable topology. Use Exercise 3.40 (i)
to show that xn → x with respect to the co-countable topology if and only if xn → x with
respect to the discrete topology. Is the co-countable topology induced by a metric?
*Exercise 3.42 (Furstenberg’s proof of the infinitude of primes). Let a, b ∈ Z and let
S(a, b) = {an+b : n ∈ Z} denote the corresponding arithmetic sequence. Define a collection
of subsets τ of Z to consist of the empty set together with unions of arithmetic sequences,
that is, U ∈ τ if and only if for every x ∈ U there exists ax ∈ Z such that S(ax , x) ⊆ U .

ˆ Show that τ defines a topology on Z.

ˆ Show that a non-empty finite set cannot be open.

ˆ Show that S(a, b) is both open and closed for every a, b ∈ Z.


[
ˆ Notice that Z \ {1, −1} = S(p, 0). Prove that there are infinitely many primes.
p prime

In the text we chose to axiomatize open sets when we defined topological spaces. This is
the standard approach, although the choice is in some sense arbitrary. The exercises below
indicate two of the other possibilities, although there are others. They are intended merely
as a curiosity for the interested reader, and are in no way important for the rest of the
course.
Exercise 3.43 (define topology via closed sets). Let C be a collection of subsets of a
non-empty set X that satisfy

ˆ the whole space X and the empty set ∅ are both in C,

ˆ the intersection of any collection of sets in C is an element of C, and

ˆ the union of any finite collection of sets in C is an element of C.

Let τ = {U ⊂ X : U = X \ C for some C ∈ C}. Show that τ is a topology.


*Exercise 3.44 (Kuratowski closure axioms). Let X be a non-empty set

(i) Suppose that c : P(X) → P(X) is a map (a “closure operator”) that satisfies:

– c(∅) = ∅.

19
– A ⊆ c(A) for every A ⊆ X.
– c(A ∪ B) = c(A) ∪ c(B) for every A, B ⊆ X.

Define C = {A ∈ P(X) : A = c(A)} (the “closed sets”). Show that C satisfies the
axioms from Exercise 3.43 and so may be used to define a topology.

(ii) Suppose further that c(c(A)) ⊆ c(A) for every A. Prove that if τ is the topology
generated by c then Closτ (A) = c(A).

20
4 Continuity
Definition 4.1. Let (X, ρ) and (Y, d) be metric spaces. A map f : X → Y is said to
be continuous at α ∈ X if for any ε > 0 there exists δ > 0 such that d(f (x), f (α)) < ε
whenever ρ(x, α) < δ. The map f is said to be continuous if it is continuous at every point
α ∈ X.
If f is a function on Rn , that is, a map from Rn to R or to C, then the above definition
coincides with the usual definition of continuity.
Theorem 4.2 (sequential characterisation of continuity). A map f : (X, ρ) → (Y, d) is
continuous at α ∈ X if and only if for every sequence xn converging to α in (X, ρ), the
sequence f (xn ) converges to f (α) in (Y, d).
Proof. Assume that f is continuous at α and that xn → α in (X, ρ). In order to prove that
f (xn ) → f (α) in (Y, d) we have to show that for every ε > 0 there exists Nε such that
d(f (xn ), f (α)) ≤ ε, for all n > Nε . (4.1)
Since f is continuous at α, given ε > 0 we can find δ > 0 such that ρ(xn , α) < δ implies
d(f (xn ), f (α)) < ε. Since the sequence xn converges to α in (X, ρ), for this δ there exists
Nδ such that ρ(xn , α) < δ for all n > Nδ . Obviously, (4.1) holds true for Nε = Nδ .
Now assume that for every sequence xn converging to α in (X, ρ), the sequence f (xn )
converges to f (α) in (Y, d). If f is not continuous then there exists ε0 > 0 such that for
any δ > 0 we can find x ∈ X for which ρ(x, α) < δ and d(f (x), f (α)) ≥ ε0 . Let xn ∈ X be
such that ρ(xn , α) < 1/n and d(f (xn ), f (α)) ≥ ε0 . Then xn → α in (X, ρ) but f (xn ) does
not converge to f (α) in (Y, d), and we obtain a contradiction.
Theorem 4.3. If a map f : (X, ρ) → (Y, d) is continuous at α and a map g : (Y, d) → (Z, σ)
is continuous at f (α), then g ◦ f : (X, ρ) → (Z, σ) is continuous at α.
Proof. Let xn be an arbitrary sequence converging to α in (X, ρ). Then, since f is continu-
ous at α, f (xn ) → f (α) in (Y, d) and, since g is continuous at g(α), g ◦ f (xn ) = g (f (xn )) →
g (f (α)) in (Z, σ). In view of Theorem 4.2 this means that g ◦ f is continuous at α.
Lemma 4.4. If (X, d) is a metric space and x0 ∈ X is a fixed element, then f : x 7→ d(x, x0 )
is a continuous map from (X, d) to R.
This lemma is a special case (A = {x0 }) of the following lemma.
Lemma 4.5. If (X, d) is a metric space and A ⊂ X is a fixed subset, then f : x 7→ d(x, A)
is a continuous map from (X, d) to R.
Proof. By the triangle inequality, if x, y ∈ X then d(x, A) − d(y, A) ≤ d(x, y) (explain
why!). Interchanging the role of x and y we have
|d(x, A) − d(y, A)| ≤ d(x, y).
In particular
|f (xn ) − f (α)| = |d(xn , A) − d(α, A)| ≤ d(xn , α)
so that f (xn ) → f (α) whenever xn → α.

21
Recall from Exercise 1.25 that if (X1 , d1 ) and (X2 , d2 ) are metric spaces we can define
a metric on X = X1 × X2 by
p
ρ(x, y) = d1 (x1 , y1 )2 + d2 (x2 , y2 )2
where x = (x1 , x2 ) ∈ X and y = (y1 , y2 ) ∈ X. This is often called the direct product of the
spaces (X1 , d1 ) and (X2 , d2 ). Using this above definition for X = Y = R makes R × R the
same as R2 with the Euclidean metric; however there are many other metrics that may be
defined on X × Y as we saw also in Exercise 1.25.
Note that continuity of a function of two variables with this metric is not the the same
as continuity in each variable separately.
Example 4.6. The real-valued function
(
xy
2 2, if x2 + y 2 6= 0,
f (x, y) = x +y
0, if x = y = 0,
defined on R2 is continuous at the origin in each variable separately but is not continuous
as a function of two variables (prove this!).
Definition 4.7. Given a map f : X → Y and a subset A ⊂ Y , the set {x ∈ X : f (x) ∈ A}
is denoted f −1 (A) and called the pre-image of A under f .
Note that f −1 (A) is a well-defined set irrespective of whether f has any inverse. Now
Definition 4.1 can be rephrased as follows:
Let (X, ρ) and (Y, d) be metric spaces. A map f : X → Y is said to be continuous at
α ∈ X if for any open ball Bεd (f (α)) about f (α) there exists a ball Bδρ (α) about α such
that Bδρ (α) ⊂ f −1 Bεd (f (α)) .
Theorem 4.8 (inverse image characterization of continuity). Let (X, ρ) and (Y, d) be metric
spaces and f : X → Y be a map from X to Y . Then the following statements are equivalent:
(1) f is continuous,
(2) the pre-image of every open subset of Y under f is an open subset of X,
(3) the pre-image of every closed subset of Y under f is a closed subset of X.
Proof. The pre-image of the complement of a set A coincides with the complement of the
pre-image f −1 (A). Therefore Theorem 2.30 implies that (2) is equivalent to (3). Let us
prove that (2) is equivalent to (1).
Assume first that f is continuous. Let A be an open subset of Y and x ∈ f −1 (A) ⊂ X.
Since A is open, there exists a ball Bε (f (x)) about the point f (x) such that Bε (f (x)) ⊂ A.
Since f is continuous there exists a ball Bδ (x) about x such that Bδ (x) ⊂ f −1 (Bε (f (x))) ⊂
f −1 (A) (by our re-statement of Definition 4.1). Therefore for every point x ∈ f −1 (A) there
exists a ball Bδ (x) lying in f −1 (A), which means that f −1 (A) is open.
Assume now that the pre-image of any open set is open. Let x ∈ X and Bε (f (x)) be
a ball about f (x) ∈ Y . The inverse image f −1 (Bε (f (x))) is an open set which contains
the point x. Therefore there exists a ball Bδ (x) about x such that Bδ (x) ⊂ f −1 (Bε (f (x))).
This implies that f is continuous (again by our re-statement of Definition 4.1).

22
We now use this characterisation of continuity to prove an important property of metric
spaces.

Theorem 4.9. Let (X, d) be a metric space and let A and B be disjoint closed sets. There
exist disjoint open sets U and V with A ⊂ U and B ⊂ V .

Proof. Let A and B be disjoint closed sets; we claim that

U = {x ∈ X : d(x, A) < d(x, B)}

and
V = {x ∈ X : d(x, A) > d(x, B)}
satisfy the desired properties. It is clear that U and V are disjoint.
To see that A ⊂ U consider an arbitrary x ∈ A. Then x ∈ / B and, since B is closed,
Corollary 2.38 implies that d(x, B) > 0 = d(x, A) and so x ∈ U . Similarly B ⊂ V .
It remains to show that U and V are open. Define f : X → R by x 7→ d(x, A) − d(x, B).
Then, by Lemma 4.4 (explain why!), f is continuous and, since (−∞, 0) is open and U =
f −1 ((−∞, 0)), U is open. Similarly V is open.

Definition 4.10. Let X and Y be topological spaces. We say that a map f : X → Y is


continuous if the pre-image of every open subset of Y under f is an open subset of X.

Exercise 4.11. Let X and Y be topological spaces. Show that a map f : X → Y is


continuous if and only if the pre-image of every closed subset of Y under f is a closed
subset of X.

Definition 4.12. Let X and Y be topological spaces. We say that a map f : X → Y is


a homeomorphism if it is a continuous bijection, and the inverse map f −1 : Y → X is also
continuous. We say that the spaces X and Y are homeomorphic and write X ≡ Y .

Exercise 4.13. Show that:

ˆ X ≡ X for any topological space X.

ˆ If X ≡ Y then Y ≡ X.

ˆ If X ≡ Y and Y ≡ Z then X ≡ Z.

Definition 4.14. Let (X, d) and (Y, ρ) be metric spaces. We say that a map f : X → Y is
an isometry if d(x, y) = ρ(f (x), f (y)) for all x, y ∈ X. We say that a bijective isometry is
an isometric isomorphism and say that the spaces X and Y are isometrically isomorphic.

Exercise 4.15. Show that an isometry is continuous and injective.


Exercise 4.16. Show that if two metric spaces are isometrically isomorphic then the in-
duced topological spaces are homeomorphic.

23
4.1 Exercises
Exercise 4.17. Let X and Y be sets and f : X → Y be a mapping. Suppose {Ai }i∈I is a
family of subsets of Y indexed by a set I. Prove that
! !
[ [ \ \
f −1 Ai = f −1 (Ai ), f −1 Ai = f −1 (Ai ).
i∈I i∈I i∈I i∈I

Exercise 4.18. Show that the function



2 1, |(x, y)| > 1,
f : R → R, f (x, y) =
0, |(x, y)| < 1,

is not continuous (here R and R2 have their usual Euclidean metrics).


Exercise 4.19. Let X, Y be topological spaces and choose a point c ∈ Y . Let f : X → Y
be the constant map defined by f (x) = c for all x ∈ X. Show that f is continuous.
Exercise 4.20. Prove that if (X, ρ) is a metric space and R has its usual usual metric
(d(x, y) = |x − y|), then f : X → R is a continuous mapping if and only if for each a ∈ R,
the sets
{x ∈ X | f (x) < a} , {x ∈ X | f (x) > a}
are open in (X, ρ). Does the same result hold if X is a topological space?
Exercise 4.21. Let (X, ρ) be a metric space and let f, g : X → R be continuous mappings.
(i) Show that the functions f + g, f · g are continuous mappings, where for x ∈ X,

(f + g)(x) = f (x) + g(x), (f · g)(x) = f (x) · g(x).

(ii) Show that if for all x ∈ X, g(x) 6= 0, then f /g : X → R is continuous, where


f (x)
f /g(x) = .
g(x)
Exercise 4.22. Let ρ and d be metrics on the same set X. Define the identity function by

id : (X, ρ) → (X, d)
x 7→ x.

[The domain and the range are the same set but have different metrics.] Prove that ρ and d
are equivalent if and only if both the identity function from (X, ρ) to (X, d) and the identity
function from (X, d) to (X, ρ) are continuous.
Exercise 4.23. Let X be a topological space. Show that the identity map

id : X → X
x 7→ x

is continuous.

24
Exercise 4.24. Let X, Y and Z be topological spaces. Show that if a map f : X → Y is
continuous and a map g : Y → Z is continuous then the composition map g ◦ f : X → Z
is continuous.
Exercise 4.25. Let X and Y be topological spaces. Show that a map f : X → Y is
continuous if and only if the map f : X → f (X) is continuous. (The topology on f (X) is
the subspace topology induced by the topology on Y .)
Exercise 4.26. Show that for any a < b we have (in the standard topology):

ˆ (a, b) ≡ (0, 1).

ˆ [a, b) ≡ [0, 1).

ˆ (a, b] ≡ (0, 1].

ˆ [a, b] ≡ [0, 1].

Can you give conditions on a and b that allow one to say that the spaces are isometrically
isomorphic?
Exercise 4.27. Show that

f :(−1, 1) → R
x
x 7→ √
1 − x2
is a homeomorphism.
Exercise 4.28. Let S 1 = {(x, y) ∈ R2 : x2 + y 2 = 1} be the unit circle in R2 with the usual
topology. Consider the map

f :[0, 2π) → S 1
θ 7→ (cos θ, sin θ).

(i) Show that f is continuous and bijective (here [0, 2π) is a subspace of the usual Eu-
clidean space R).

(ii) Does f define a homeomorphism between [0, 2π) and S 1 as topological spaces?

(iii) Is f an isometry between [0, 2π) and S 1 as metric spaces (here S 1 is endowed with
the arc-length metric)?

25
5 Completeness
5.1 Cauchy Sequences
Definition 5.1. A sequence xn of elements of a metric space (X, d) is called a Cauchy
sequence if, given any ε > 0, there exists Nε such that d(xn , xm ) < ε for all n, m > Nε .

Lemma 5.2. Every convergent sequence is a Cauchy sequence.

Proof. If xn → x then for any ε > 0 there exists Nε such that d(xn , x) < ε/2 for all n > Nε .
Applying the triangle inequality we obtain

d(xn , xm ) ≤ d(xn , x) + d(xm , x) < ε/2 + ε/2 = ε

for all n, m > Nε . This implies that xn is a Cauchy sequence.

Lemma 5.3. If a Cauchy sequence has a convergent subsequence, then it is convergent to


the same limit.

Proof. Let xn be a Cauchy sequence and xnk → x be a convergent subsequence. Then for
any ε > 0 there exists Nε such that d(xn , xnk ) < ε/2 and d(xnk , x) < ε/2 for all n, nk > Nε .
Applying the triangle inequality we obtain

d(xn , x) ≤ d(xnk , x) + d(xn , xnk ) < ε/2 + ε/2 = ε

for all n > Nε . Since ε is an arbitrary positive number, this implies that xn → x.

5.2 Complete Metric Spaces


Definition 5.4. A metric space (X, d) is said to be complete if every Cauchy sequence
{xn } ⊂ X converges to a limit x ∈ X.

Example 5.5. R is complete under the usual metric (this is usually considered an axiom).
1
Example 5.6. (0, 1) with the usual metric is incomplete. Indeed n
is a Cauchy sequence
that has no limit in (0, 1).
Example 5.7. Q with the usual metric is incomplete. This is because any sequence xn
which converges to an irrational number is a Cauchy sequence but does not have a limit in
X.
Example 5.8. C with the standard metric is complete. Indeed, if {cn } is a sequence of
complex numbers and cn = an + ibn , where an = Re cn and bn = Im cn , then

ˆ {cn } is a Cauchy sequence if and only if {an } and {bn } are Cauchy sequences of real
numbers, and

ˆ the sequence {cn } converges if and only if the sequences {an } and {bn } converge.

26
Exercise 5.9. Prove that Rn and Cn are complete for n = 2, 3, . . . .
Proposition 5.10. Let (X, d) be a complete metric space and suppose that A is a closed
subset of X. Then the subspace (A, d) is complete.
Proof. Let (xn ) be a Cauchy sequence in A. Then (xn ) is also a Cauchy sequence in X and
so xn → x ∈ X by the completeness of X. But since xn ∈ A for every n and A is closed we
must have x ∈ A by 2.28. So A is complete.
Proposition 5.11. Let (A, d) be a subspace of a metric space (X, d) and suppose that (A, d)
is complete. Then A is a closed subset of X.
Proof. Let (xn ) be a sequence in A such that xn → x ∈ X. By 2.28 we only need to show
that x ∈ A. Now since the sequence (xn ) is convergent in X it must be a Cauchy sequence
in X by Lemma 5.2 and therefore a Cauchy sequence in A also. The completeness of (A, d)
forces x ∈ A.
If a metric space (X, d) is not complete then it has Cauchy sequences which do not
converge. This means, in a sense, that there are gaps (or missing elements) in X. Every
incomplete metric space can be made complete by adding new elements, which can be
thought of as the missing limits of non-convergent Cauchy sequences. More precisely, we
have the following theorem.
Theorem 5.12. Let (X, d) be an arbitrary metric space. Then there exists a complete
˜ such that
metric space (X̃, d)
˜ y) = d(x, y) whenever x, y ∈ X;
(i) X ⊂ X̃ and d(x,

(ii) for every x̃ ∈ X̃ there exists a sequence of elements xn ∈ X such that xn → x̃ as


˜
n → ∞ in the space (X̃, d).
˜ is said to be the completion
The proof of this theorem is omitted. The metric space (X̃, d)
of (X, d). If (X, d) is already complete then necessarily X = X̃ and d = d. ˜
Example 5.13. The completion of the space Q with the usual metric can be taken as
the definition of R. Any irrational number can be written as an infinite decimal fraction
0.a1 a2 a3 . . . or, in other words, can be identified with the Cauchy sequence 0, 0.a1 , 0.a1 a2 ,
0.a1 a2 a3 , ... of rational numbers which does not converge to a rational limit.
*Exercise 5.14. Justify why we may speak of the completion: Prove that if (X1 , d˜1 ) and
(X2 , d˜2 ) are complete metric spaces that satisfy Properties (i) and (ii) in Theorem 5.12 then
(X1 , d˜1 ) and (X2 , d˜2 ) are isometrically isomorphic.
Theorem 5.15. Let (A, d) be a subspace of a complete metric space (X, d) and let Ā be
the closure of A in (X, d). Then (Ā, d) is the completion of (A, d).
Exercise 5.16. Prove Theorem 5.15.
Theorem 5.17. B(S) is complete.

27
Proof. Let f1 , f2 , . . . be a Cauchy sequence in B(S). Then for any ε > 0 there exists Nε
such that
sup |fn (x) − fm (x)| < ε/2, for all n, m > Nε .
x∈S

This implies that for each fixed x ∈ S the numbers fn (x) form a Cauchy sequence of real (or
complex, if fn are complex-valued functions) numbers. Since the space of real (or complex)
numbers is complete, this sequence has a limit. Let us denote this limit by f (x). Then
fn (x) → f (x) for each fixed x ∈ S, that is, for any ε > 0 there exists an integer Nε,x (which
may depend on x) such that

|fn (x) − f (x)| < ε/2, for all n > Nε,x .

For any integers n and m we have

|fn (x) − f (x)| ≤ |fn (x) − fm (x)| + |fm (x) − f (x)|.

Let n > Nε and choose m such that m > Nε and m > Nε,x . Then the right hand side is at
most ε. Therefore the left hand side is at most ε for all x ∈ S provided that n > Nε . This
implies that supx∈S |fn (x) − f (x)| ≤ ε for all n > Nε , which means that fn → f uniformly.
It remains to prove that f is bounded. Choosing n > Nε we obtain

sup |f (x)| ≤ sup |fn (x) − fn (x) + f (x)|


x∈S x∈S
≤ sup (|fn (x)| + |fn (x) − f (x)|)
x∈S
≤ sup |fn (x)| + sup |fn (x) − f (x)| ≤ sup |fn (x)| + ε.
x∈S x∈S x∈S

Since fn is bounded, this estimate implies that f is also bounded.


Corollary 5.18. C[a, b] is complete.
Proof. Since continuous functions on [a, b] are bounded the theorem implies that any Cauchy
sequence of continuous functions fk uniformly converges to a bounded function f on [a, b]
and we only need to prove that the function f is continuous.
In order to prove that we have to show that for any ε > 0 there exists δ > 0 such that
|f (x) − f (y)| < ε whenever |x − y| < δ. We have

|f (x) − f (y)| = |f (x) − fn (x) + fn (x) − fn (y) + fn (y) − f (y)|


≤ |f (x) − fn (x)| + |fn (x) − fn (y)| + |fn (y) − f (y)|.

Since fn → f in B(S), we can choose n such that |f (x) − fn (x)| < ε/3 and |f (y) − fn (y)| <
ε/3. Since the function fn is continuous, there exists δ > 0 such that |fn (x) − fn (y)| < ε/3
whenever |x − y| < δ. Therefore

|f (x) − f (y)| < ε/3 + ε/3 + ε/3 = ε

whenever |x − y| < δ.

28
5.3 Cantor’s Intersection Theorem
Definition 5.19. Let (X, d) be a metric space and let A ⊆ X be non-empty. We define
the diameter of A by
diam(A) = sup{d(a, b) : a, b ∈ A}.

Theorem 5.20. Let X be a complete metric space and let (An )∞


n=1 be a sequence of non-
empty bounded closed subsets of X such that

A1 ⊇ A2 ⊇ A3 ⊇ · · · ⊇ An ⊇ An+1 ⊇ . . . .

Suppose further that diam(An ) → 0 as n → ∞. Then ∩∞


n=1 An is a singleton set.

Proof. See Appendix A.

5.4 Contractions
Definition 5.21. A map T from a metric space (X, d) to itself is called a contraction if
d(T x, T y) ≤ cd(x, y) for some 0 ≤ c < 1 and all x, y ∈ X.

Exercise 5.22. Suppose that T is a contraction from a metric space (X, d) to itself. Show
that

(i) T is continuous, and

(ii) T has at most one fixed point in X.

The next result is known as either the Contraction Mapping Theorem or the Banach
Fixed Point Theorem.

Theorem 5.23. If T is a contraction on a complete metric space, then the equation T x = x


has a unique solution x and, for any x0 ∈ X, the sequence xn = T n x0 converges to x.

Proof. Let n > m. Then, since d(T x, T y) ≤ cd(x, y), we have

d(xm , xn ) = d(T m x0 , T n x0 ) ≤ cd(T m−1 x0 , T n−1 x0 )


≤ c2 d(T m−2 x0 , T n−2 x0 ) . . . ≤ cm d(x0 , T n−m x0 ).

By the triangle inequality

d(x0 , T n−m x0 ) ≤ d(x0 , T x0 ) + d(T x0 , T 2 x0 ) + d(T 2 x0 , T 3 x0 ) + · · · + d(T n−m−1 x0 , T n−m x0 )


≤ d(x0 , T x0 ) + cd(x0 , T x0 ) + c2 d(x0 , T x0 ) + · · · + cn−m−1 d(x0 , T x0 )
≤ (1 − c)−1 d(x0 , T x0 ).

These two inequalities imply that

d(xm , xn ) ≤ cm (1 − c)−1 d(x0 , T x0 ), for all x0 ∈ X, and for all n > m. (5.1)

29
Since c < 1, the expression on the right hand side can be made arbitrarily small by
choosing large m. This implies that {xn } is a Cauchy sequence. Since our metric space is
complete, {xn } converges to a limit x. In view of Lemma 4.4, we have

d(x, T x) = lim d(xn , T x) = lim d(T n x0 , T x)


n→∞ n→∞
≤ c lim d(T n−1 x0 , x) = c lim d(xn−1 , x) = 0.
n→∞ n→∞

Therefore d(x, T x) = 0, that is T x = x. Uniqueness follows from Exercise 5.22.


Theorem 5.23 allows one to construct an approximate solution to an equation of the
form T x = x by choosing an arbitrary element x0 ∈ X and evaluating xm = T m x for
sufficiently large m. This is called the method of successive approximations.

Corollary 5.24 (error estimate). Under the conditions of Theorem 5.23 we have

d(xm , x) ≤ cm (1 − c)−1 d(x0 , T x0 ), for all x0 ∈ X, m = 0, 1, 2, . . . (5.2)

Proof. (5.2) is obtained from (5.1) by passing to the limit as n → ∞ and applying
Lemma 4.4.
Example 5.25. Let f be a real-valued function defined on an interval [a, b] such that
f (x) ∈ [a, b] and
|f (x) − f (y)| ≤ c|x − y| (5.3)
for all x, y ∈ [a, b] and some constant c < 1. Then, for any x0 ∈ [a, b], the sequence
x1 = f (x0 ), x2 = f (x1 ), x3 = f (x2 ), . . . converges to the only solution of the equation
f (x) = x.
Remark 5.26. The inequality (5.3) (with some c > 0) is called the Lipschitz condition. If
f is continuously differentiable on [a, b] then, by the mean value theorem, f satisfies the
Lipschitz condition with c = supx∈[a,b] |f 0 (x)|.

5.5 Picard’s Existence Theorem for First Order Differential


Equations
Let f be a real-valued function defined on an open domain Ω ⊆ R2 . Consider the ordinary
(non-linear) differential equation


= f (x, ϕ(x)) (5.4)
dx
with the initial condition ϕ(x0 ) = ϕ0 , where x is a one dimensional variable, ϕ is a function
of x and ϕ0 is some constant.

30
Theorem 5.27 (Picard’s theorem). Let (x0 , ϕ0 ) ∈ Ω and let f be a continuous function
satisfying the Lipschitz condition

|f (x, y1 ) − f (x, y2 )| ≤ L|y1 − y2 | (5.5)

for all (x, y1 ) and (x, y2 ) in Ω where L is some constant. Then the equation (5.4) with the
initial condition ϕ(x0 ) = ϕ0 has a unique solution on some interval [x0 − δ, x0 + δ].

Proof. Since f is continuous, we have |f (x, y)| ≤ R whenever (x, y) lie in a sufficiently small
ball B about the point (x0 , ϕ0 ). Let us choose a small positive constant δ such that

ˆ (x, y) ∈ B whenever |x − x0 | ≤ δ and |y − ϕ0 | ≤ Rδ;

ˆ Lδ < 1 .

Denote by C ∗ the closed ball of radius Rδ centre ϕ0 in the space C[x0 −δ, x0 +δ]; in other
words, C ∗ is the set of all continuous functions ψ on the interval [x0 − δ, x0 + δ] satisfying
the estimate
sup |ψ(x) − ϕ0 | ≤ Rδ.
x∈[x0 −δ,x0 +δ]

By Theorem 5.15 the space C ∗ provided with the metric (1.1) is complete.
By the fundamental theorem of calculus, the equation (5.4) with the initial condition
ϕ(x0 ) = ϕ0 is equivalent to the integral equation
Z x
ϕ(x) = ϕ0 + f (t, ϕ(t))dt. (5.6)
x0

Consider the map T : C ∗ → C[x0 − δ, x0 + δ] defined by


Z x
T ψ(x) = ϕ0 + f (t, ψ(t))dt, wherex ∈ [x0 − δ, x0 + δ].
x0

Then (5.6) is equivalent to the identity T ϕ = ϕ .


If ψ ∈ C ∗ then we have
Z x
|T ψ(x) − ϕ0 | ≤ f (t, ψ(t))dt ≤ Rδ
x0

for every x ∈ [x0 − δ, x0 + δ], which implies that T : C ∗ → C ∗ . (5.5) implies that
Z x
|T ψ1 (x) − T ψ2 (x)| ≤ |f (t, ψ1 (t)) − f (t, ψ2 (t))|dt ≤ Lδ sup |ψ1 (t) − ψ2 (t)|.
x0 t∈[x0 −δ,x0 +δ]

Since Lδ < 1, the above inequality means that the map T : C ∗ → C ∗ is a contraction. Now
Picard’s theorem follows from the Contraction Mapping Theorem.

31
5.6 Exercises
Exercise 5.28. Let (xn ) be a Cauchy sequence in a metric space. Prove that there exists
x ∈ X and M > 0 such that xn ∈ BM (x) for every n.
Exercise 5.29. Let d be the metric on (0, +∞) defined in Exercise 1.22 (i). Define the
sequence (an )∞
1 by an = n. Show that the sequence {an } is a Cauchy sequence. In light of
Exercise 1.26, could we extend the notion of completeness to topological spaces?
Exercise 5.30. Let X be the set of numbers {1, 2−1 , 3−1 , 4−1 , . . .} and d(x, y) = |x − y| for
x, y ∈ X. Is the metric space (X, d) complete? If not, what is its completion?
Exercise 5.31. Let (X, d) be a complete metric space and let T : X → X be such that T n
is a contraction for some n ∈ N. Prove that the equation T x = x has a unique solution.
1
Exercise 5.32. Show that x 7→ 21 (x7 − 3x4 + x + 4) is a contraction mapping on the
interval [0, 1] equipped with the standard metric. Use this to show that the equation
x7 − 3x4 − 20x + 4 = 0 has exactly one real root between 0 and 1.
Exercise 5.33. Let X be the interval (0, 1/3) be equipped with the standard metric
d(x, y) = |x − y|, and let T be defined by T x = x2 . Show that T maps X into X and is a
contraction, but the equation T x = x has no solutions. Why does this not contradict the
contraction mapping theorem?
Exercise 5.34. Consider the complete metric space (X, d) with X = [1, ∞) and d(x, y) =
|x − y|. Let T be defined by T x = x + 1/x. Show that T maps X into X and that
d(T x, T y) < d(x, y), for all x, y ∈ X with x 6= y, but the equation T x = x has no solutions.
Exercise 5.35. A function f : R → R is said to be increasing at the point x if there exists
δ(x) > 0 such that f (y) ≤ f (x) ≤ f (z) whenever x − δ(x) < y < x < z < x + δ(x). If f
(not necessarily continuous) is increasing at every point of a closed bounded interval [a, b],
prove that it is increasing on [a, b] (that is, f (y) ≤ f (x) whenever a ≤ y ≤ x ≤ b).
Let g : Q → Q be defined by
( √
q if q ≤ 2,
g(q) = √
q − 1 if q > 2.

Note that g is increasing at every point of Q. Check that your argument for the first part
of this question does not prove that g is increasing on Q ∩ [0, 2].

32
6 Connectedness
There are two commonly used notions of connectedness in topological spaces.

6.1 Connected topological spaces


Definition 6.1. A set A in a topological space is clopen if it is both open and closed.
It is clear that in the space (X, τ ) the sets X and ∅ are always clopen; we call them
the trivial clopen sets.
Exercise 6.2. Show that the following are equivalent:
ˆ There is a non-trivial clopen set.
ˆ We can write X = A ∪ B where A and B are disjoint non-empty open sets.
ˆ We can write X = A ∪ B where A and B are disjoint non-empty closed sets.
Definition 6.3. Let X be a topological space. We say that S ⊂ X is connected if the
subspace S has no non-trivial clopen sets. We say that the subspace S is a connected space
Example 6.4. Consider S = (0, 1) ∪ (2, 3) in R with the usual topology. Then S is
disconnected.
Exercise 6.5. If X is a set with the discrete topology, show that S is connected if and
only if it is a singleton.
Definition 6.6. We say that I ⊆ R is an interval if x, z ∈ I and x < y < z implies that
y ∈ I.
Remark 6.7. Notice that singletons are intervals according to this definition, as are sets
like (−∞, 0] or (0, +∞) or R.
Theorem 6.8. Let I ⊆ R, equipped with the usual topology. Then I is connected if and
only if it is an interval.
Proof. First suppose that I is not an interval. Then there exist x, z ∈ I and x < y < z such
that y ∈/ I. Define A = I ∩ (−∞, y) and B = I ∩ (y, ∞). Then A and B are non-empty
since x ∈ A and y ∈ B; A and B are open in I by Theorem 2.20; and A and B are clearly
disjoint. So I is not connected.
Conversely suppose that I is an interval but I is not connected. Then there exist non-
empty clopen (in I) disjoint sets A, B with I = A ∪ B. We choose x ∈ A and z ∈ B; we
may assume that x < z. We define y = sup A ∩ [x, z], which exists since x ∈ A ∩ [x, z] and
A ∩ [x, z] is bounded above by z; moreover x ≤ y ≤ z which implies that y ∈ I.
Now A is clopen and therefore closed in I, and so A ∩ [x, z] is a closed subset of I, which
implies that y ∈ A ∩ [x, z] ⊆ A. Therefore y 6= z. So x ≤ y < z which means that we can
choose εn > 0 such that εn → 0 as n → ∞ and y + εn < z. We then have y + εn ∈ [x, z] ⊆ I
and y + εn > sup A ∩ [x, z] whence y + εn ∈ B. But B is also closed in I which means that
y = limn→∞ y + εn ∈ B.
We have shown that y ∈ A ∩ B = ∅, and this contradiction completes the proof.

33
Definition 6.9. Let X be a topological space and define χE : X → R by
(
0, if x ∈
/E
χE (x) =
1, if x ∈ E.

We call χE the characteristic function of E.

Remark 6.10. Sometimes, particularly in probability theory, χE is denoted 1E and called


the indicator function of E.

Lemma 6.11. E is clopen in X if and only if χE is continuous.

Proof. Suppose that E is clopen in X and U is open in R. Then




 ∅, if 0, 1 ∈
/U

E, if 0 ∈ / U, 1 ∈ U
χ−1
E (U ) =


 X \ E, if 0 ∈ U, 1 ∈/U
X, if 0, 1 ∈ U,

is open in R.
Conversely, if χE is continuous then E = χ−1 −1
E ({1}) and X \ E = χE ({0}) are closed in
X.

Proposition 6.12. Let X be a topological space. The following are equivalent:

1. X is connected.

2. Whenever f : X → R is continuous and f (X) ⊆ {0, 1} we have that f is constant.

Proof. Suppose that 2. holds, let E be clopen in X and choose f = χE . Since E is clopen,
f is continuous and therefore constant. So either f = 0 or f = 1. Equivalently, either
E = ∅ or E = X, so E is trivial.
Conversely, suppose that X is connected and f : X → R is continuous with f (X) ⊆
{0, 1}. Define
E = {x ∈ X : f (x) = 0} = f −1 ({0})
which is closed. Further

X \ E = {x ∈ X : f (x) = 1} = f −1 ({1})

which is also closed. So E is clopen, which means that E = ∅ or E = X. Equivalently


f = 0 or f = 1.

34
6.2 Path-connectedness
Definition 6.13. Given two points x1 , x2 of a topological space X, a continuous function
γ : [0, 1] → X with γ(0) = x1 and γ(1) = x2 is called a path from x1 to x2 . We say that
S ⊆ X is path-connected if there exists a path taking values in S between any two points
of S. We say that the subspace S is a path-connected space.

Remark 6.14. Note that if there is a path γ12 from x1 to x2 and a path γ23 from x2 to x3
then (
γ12 (2t), if 0 ≤ t ≤ 21 ,
γ13 (t) =
γ23 (2t − 1), if 12 ≤ t ≤ 1,
is a path from x1 to x3 .
Example 6.15. A connected set is not necessarily path-connected. The “topologist’s sine
curve”   
1
x, sin : x ∈ (0, 1] ∪ {(0, 0)} ⊂ R2 (6.1)
x
is connected, but not path-connected. The latter is because the point (0, 0) cannot be
reached by a non-constant path lying in this set.

Theorem 6.16. A path-connected set is connected.

Proof. Suppose that S is path-connected but not connected and let A, B be disjoint non-
empty open (in S) sets such that S = A ∪ B. Choose x ∈ A and y ∈ B and let γ be a
path from x to y in S. Since γ is continuous, the pre-images γ −1 (A) and γ −1 (B) are open
subsets of [0, 1]. Clearly these subsets are not empty and moreover

γ −1 (A) ∩ γ −1 (B) = ∅, γ −1 (A) ∪ γ −1 (B) = [0, 1],

that is, the pair γ −1 (A), γ −1 (B) are disjoint non-empty open sets whose union is all of [0, 1].
But no such pair can exist, since [0, 1] is connected.

6.3 Connectedness as a topological invariant


Theorem 6.17. Let X and Y be topological spaces and let f : X → Y be continuous. If
X is connected then f (X) is connected.

Proof. We may assume, by Exercise 4.25, that f is surjective. Let A be clopen in Y . Since
f is continuous, f −1 (A) is clopen in X. So we must have f −1 (A) = ∅ or f −1 (A) = X. Now
f (f −1 (A)) = A so either A = f (∅) = ∅ or A = f (X) = Y . That is, A is trivial.
Note that in view of Theorem 6.11 the above theorem includes the Intermediate Value
Theorem of elementary analysis.
Example 6.18. Let a > 0 and n ∈ N. There exists b > 0 such that bn = a.

35
Proof. Let X = (0, ∞) and define

f :X → X
x 7→ xn .

Clearly f is continuous and X is connected. Hence f (X) is connected and so it is an


interval. For large enough k we have k1n < a < k n , i.e., f ( k1 ) < a < f (k). Therefore there
exists b ∈ X such that f (b) = a.
Example 6.19. R 6≡ (0, 1) ∪ (1, 2), since (0, 1) ∪ (1, 2) is not connected.
Example 6.20. R2 \ {(0, 0)} with the usual topology is path-connected.
Proof. If x and y are distinct elements of R2 \ {(0, 0)} and the origin is not a point on the
line segment joining x to y then we can choose this line as a path. Otherwise we choose z
not on the line and then form the path that goes from x to z to y, as in Remark 6.14.
Example 6.21. R 6≡ R2 .
Proof. Suppose that there exists a homeomorphism f : R2 → R. Let t = f ((0, 0)) and
consider the restricted map f : R2 \ {(0, 0)} → R \ {t}. This map is continuous, and
R2 \ {(0, 0)} is connected, which implies that R \ {t} is connected, which is absurd.

6.4 Exercises
Exercise 6.22. Prove that the closure of a connected set is connected.
[Hint : Prove (easily) that, if A is an open set with C ∩ A = ∅ then C ∩ A = ∅.]
Exercise 6.23. Let P and Q be connected sets such that P ∩ Q 6= ∅. Prove that P ∪ Q
is connected.
Exercise 6.24. Let A be path-connected and let f be a real-valued function on A with
the property that for each a ∈ A there is a neighbourhood N of a such that f is constant
on N . (This property could be described as “f is locally constant on A”.) Prove that f is
constant on A.
Exercise 6.25. Let f : R → R be continuous and define F : R2 → R by F (x, y) =
f (x) − f (y). Prove that F is continuous. Let T = {(x, y) : x > y}. Show that if F does
not vanish on T then F has constant sign on T . [Hint: connectedness.] Deduce that every
real-valued continuous injective function on R is monotonic.

36
7 Compactness
7.1 Sequential compactness
Intervals which are closed and bounded figure prominently in analysis on the real line. An
appropriate generalization of their essential properties that are relevant to analysis in more
general spaces is compactness. We begin by recalling the Bolzano-Weierstrass theorem.

Theorem 7.1. Let a, b ∈ R with a < b. Every sequence in [a, b] has a convergent subse-
quence.

This inspires our first definition.

Definition 7.2. A subset K of a metric space (X, d) is said to be sequentially compact if


any sequence in K has a subsequence which converges in X to a limit in K. We say that
the subspace (K, d) is a sequentially compact space.

It is clear from the definition that if K is sequentially compact in the space (X, d) and
the metric ρ is equivalent to d then K is sequentially compact in the space (X, ρ).
Example 7.3. [a, b] , for any a < b ∈ R.
Example 7.4. (0, 1) is not sequentially compact in R with the usual metric. Indeed the
sequence xn = n1 has no subsequence that converges to a limit in (0, 1).

Proposition 7.5. Every sequentially compact space is complete.

Proof. Let (xn ) be a Cauchy sequence in a sequentially compact space X. Since some
subsequence converges to a limit in X, by Lemma 5.3, (xn ) converges in X.

7.2 Compactness in a topological space


Definition 7.6. Let X be a topological space and K ⊆ X. We call a family (Ui )i∈I of
subsets of X an open cover of K if

ˆ Each Ui is open in X, and

ˆ K ⊆ ∪i∈I Ui .

We say that K is a compact subset of X if every open cover of K permits a finite subcover,
that is, if (Ui )i∈I is an open cover of K then there exist i1 , . . . , in ∈ I such that K ⊆
Ui1 ∪ · · · ∪ Uin . We say that the subspace K is a compact space.

Exercise 7.7. Let X be a topological space and suppose that K ⊆ Y ⊆ X. Prove that
K is a compact subset of X if and only if K is a compact subset of the subspace Y . This
shows why we may call a subspace a compact space, without referencing the “bigger space”.
Exercise 7.8. Show that any finite subset of a topological space is compact.

37
Definition 7.9. We say that a family of sets (Ci )i∈I has the finite intersection property
(FIP) if Ci1 ∩ · · · ∩ Cin 6= ∅ for every i1 , . . . , in ∈ I.

Example 7.10. Consider Cn = [n, +∞) ⊂ R for n ∈ Z. If n1 < · · · < nk then Cn1 ∩ · · · ∩
Cnk = Cnk 6= ∅ so (Cn )n∈Z has the FIP.

Theorem 7.11. Let X be a topological space. The following are equivalent:

1. X is compact.

2. If (Ci )i∈I is an arbitrary family of closed sets with the FIP then ∩i∈I Ci 6= ∅.

Proof. Assume that X is compact and let (Ci )i∈I be an arbitrary family of closed sets with
the FIP. Suppose that ∩i∈I Ci = ∅ and define Ui = X \ Ci . Then each Ui is open and
moreover ∪i∈I Ui = X \ (∩i∈I Ci ) = X. That is, the Ui are an open cover of X and so there
exists a finite subcover Ui1 , . . . , Uin . But then

Ci1 ∩ · · · ∩ Cin = X \ (Ui1 ∪ · · · ∪ Uin ) = ∅

which contradicts the FIP.


Conversely, assume that 2. holds but X is not compact. Then there exists an open
cover Ui of X that does not permit a finite subcover. Put Ci = X \ Ui and note that each
Ci is closed. Further for any finite collection Ci1 , . . . , Cin we have

Ci1 ∩ · · · ∩ Cin = X \ (Ui1 ∪ · · · ∪ Uin ) 6= ∅

since Ui1 , . . . , Uin does not form a cover of X. The sets Ci therefore satisfy the FIP and so
∩i∈I Ci 6= ∅, or equivalently, ∪i∈I Ui 6= X, which is absurd.

Corollary 7.12. R is not compact.

Proof. This is immediate from the theorem in light of Example 7.10.

Theorem 7.13. If X is a compact space and C is a closed subset of X then C is compact.

Proof. Let (Ci )i∈I be an arbitrary family of closed sets in C with the FIP. By Exercise 3.34
the sets (Ci )i∈I are closed in X. By the compactness of X we have ∩i∈I Ci 6= ∅. Therefore
C is compact.

Theorem 7.14. If X is a Hausdorff space and C is a compact subset of X then C is closed


in X.

Proof. We may assume that C 6= ∅, X since the result is trivial in these cases. We will
prove that U = X \ C is open in X. Fix y ∈ U . Given x ∈ C we have x 6= y and since X
is Hausdorff we may find open (in X) sets Vx 3 x and Wx 3 y such that Vx ∩ Wx = ∅.
We have
C ⊆ ∪x∈C Vx

38
and we set Vex = C ∩ Vx . Then each Vex is open in C and moreover C = ∪x∈C Vex . Since C is
compact we have
C = Vex1 ∪ · · · ∪ Vexn
for some x1 , . . . , xn ∈ C, and so

C ⊆ Vx1 ∪ · · · ∪ Vxn

We define W = Wx1 ∩ · · · ∩ Wxn and notice that y ∈ W and W is open in X. Further since
W ∩ Vxj ⊆ Wxj ∩ Vxj = ∅ we must have

W ∩ (Vx1 ∪ · · · ∪ Vxn ) = ∅

and therefore W ∩ C = ∅.
We have shown that W ⊆ U and so U is a neighbourhood of y. Since y was arbitrary
we see that U is open in X.

7.3 Totally bounded sets in a metric space


Definition 7.15. A subset K of a metric space (X, d) is bounded if for some x ∈ X and
r > 0 we have K ⊂ Br (x).
Remark 7.16. It is easy to see that a subset is bounded if and only if its diameter is finite.
Theorem 7.17. If K is a compact subset of a metric space (X, d) then K is bounded.
Proof. If K is not bounded then, for every x ∈ K, the family of balls Bn (x), n = 1, 2, . . .,
is an open cover of K, which does not have a finite subcover.
Combining this theorem with Theorem 7.14 we see that compact sets in a metric space
are closed and bounded. The converse to this statement is false, see Exercise 7.31. For this
reason we define a stronger criteria than bounded.
Definition 7.18. A metric space (X, d) is said to be totally bounded if for every ε > 0
there exists a finite collection of open balls Bε (xi ) that cover X.
Exercise 7.19. Show that if (X, d) is a totally bounded space then the set X is bounded.
Exercise 7.20. (i) Show that if a < b ∈ R then [a, b] with the usual metric is totally
bounded.

(ii) Show that if (X, d) is a totally bounded space and S ⊆ X then the subspace (S, d) is
totally bounded.

(iii) Show that any bounded subset of R with the usual metric is totally bounded.
Theorem 7.21. Let (X, d) be a metric space. The following are equivalent:
1. X is compact.

39
2. X is sequentially compact.
3. X is complete and totally bounded.
Proof. The proof that 1. implies 2. is contained in Appendix A.
We now show that 2. implies 3. Suppose that X is sequentially compact. We have
already seen in Proposition 7.5 that X is complete. Suppose now that X is not totally
bounded. Then there exists ε > 0 such that given any finite collection {x1 , . . . , xn } ⊂ X
we can find a point x ∈ X such that d(x, xi ) ≥ ε for i = 1, . . . , n. This means that we can
construct a sequence {xn } ⊆ X such that d(xn , xm ) ≥ ε for every n, m. Such a sequence
has no convergent subsequence, which contradicts the fact that X is sequentially compact.
Thus X is totally bounded.
The proof that 3. implies 1. is omitted.
Lemma 7.22. If K and L are compact subsets of metric spaces (X, d) and (Y, ρ) respec-
tively, then K × L as a subset of X × Y with the metric
p
σ ((x1 , y1 ), (x2 , y2 )) = d(x1 , x2 )2 + ρ(y1 , y2 )2

is compact.
Proof. Let (xn , yn ) be an arbitrary sequence in K × L. Since K is compact, there is a
subsequence xnk which converges to a limit x ∈ K as k → ∞. Since L is compact, the
sequence ynk has a subsequence ynk i which converges to a limit y ∈ L as i → ∞. Since
xnk → x as k → ∞, we also have xnk i → x as i → ∞. By definition of convergence, 
d(xnk i , x) → 0 and ρ(ynk i , y) → 0 as i → ∞. This implies that σ (xnk i , ynk i ), (x, y) → 0 as
i → ∞, that is, (xnk i , ynk i ) → (x, y) ∈ K × L. Therefore any sequence (xn , yn ) of elements
of K × L has a subsequence which converges to a limit in K × L.
Remark 7.23. In fact, Tychonoff’s theorem states that the arbitrary product of compact
spaces is compact, if one defines the topology on an infinite product correctly. This theorem
turns out to be equivalent to the axiom of choice.
Theorem 7.24 (The Heine-Borel Theorem). A closed and bounded subset of Rn is compact.
Proof. Since any bounded subset lies in a closed cube Qn , in view of Theorem 7.13 it is
sufficient to prove that the closed cube is compact. The closed cube Qn is a direct product
of a one dimensional closed cube Q1 (a closed interval) and a closed cube Qn−1 ⊂ Rn−1 .
If Q1 and Qn−1 are compact then, by Lemma 7.22, Qn is also compact. Therefore it is
sufficient to prove that a closed interval is compact (and the required result is obtained by
induction in n). But this is immediate from the Bolzano-Weierstrass theorem.

7.4 Compactness and continuous functions


Theorem 7.25. The image of a compact set by a continuous map is compact. In other
words, if X and Y are topological spaces, f : X → Y is continuous and X is compact then
f (X) is compact.

40
Proof. Let (Ui )i be an open cover of f (X) and set Vi = f −1 (Ui ). Since each Ui is open in
Y and f is continuous we see that each Vi is open in X. Moreover f (X) ⊆ ∪i Ui implies
that X ⊆ ∪i Vi which means that the Vi are an open cover of X. Since X is compact we
have X ⊆ Vi1 ∪ · · · ∪ Vik for some i1 , . . . , ik . But then f (X) ⊆ Ui1 ∪ · · · ∪ Uik , which means
that the open cover (Ui )i permits a finite subcover. Therefore f (X) is compact.

Corollary 7.26. R 6≡ [0, 1].

Proof. [0, 1] is compact, R is not.

Theorem 7.27. Let X be a compact topological space and Y be a Hausdorff space. Suppose
that f : X → Y is a continuous bijection. Then the inverse mapping f −1 is continuous.

Proof. We see from Exercise 4.11 that it is sufficient to prove that the pre-image
(f −1 )−1 (B) = f (B) ⊂ Y is closed whenever the set B ⊂ X is closed.
If B is closed in X then, by Theorem 7.13, it is compact. By Theorem 7.25 f (B) is also
compact and therefore is closed in Y (Theorem 7.14).
Example 7.28. Let X be the space of continuously differentiable functions on a closed
interval [a, b] and ρ, d be the metrics on X defined as follows:

ρ(f, g) = sup |f (x) − g(x)| + sup |f 0 (x) − g 0 (x)|,


x∈[a,b] x∈[a,b]

d(f, g) = sup |f (x) − g(x)|.


x∈[a,b]

ρ
The identity map (X, ρ) → (X, d) is a bijection and is continuous because fn → f implies
d
that fn → f . However, the inverse mapping is not continuous. Indeed, the sequence
2
fn (x) = sin(nn x) converges to the zero function with respect to the metric d but does not
converge with respect to the metric ρ.

7.5 Uniform continuity


Definition 7.29. We say that a (real or complex-valued) function f defined on a metric
space (X, d) is uniformly continuous if for any ε > 0 there exists δ > 0 such that |f (x) −
f (y)| < ε whenever d(x, y) < δ.

Obviously, a uniformly continuous function is continuous.

Theorem 7.30. If (X, d) is a compact metric space then any continuous function f on
(X, ρ) is uniformly continuous.

Proof. Let ε > 0. Since f is continuous, for every point x ∈ X there exists δx > 0 such that
ε
|f (y) − f (x)| < whenever d(y, x) < δx (7.1)
2

41
Let Bx = Bδx /2 (x). Since x ∈ Bx , the collection of open balls {Bx }x∈X is an open cover
of X. Since X is compact, it has a finite subcover, that is, there exists a finite collection
of points x1 , x2 , . . . , xk such that X = ∪kn=1 Bxn . Denote δ = 21 min{δx1 , . . . , δxk }. Since the
number of points xn is finite, we have δ > 0.
Let x, y ∈ X and d(x, y) < δ. Since X = ∪kn=1 Bxn there exists n such that x ∈ Bxn ,
that is, d(x, xn ) < δxn /2. By the triangle inequality,

d(y, xn ) ≤ d(x, xn ) + d(x, y) < δxn /2 + δ ≤ δxn

and, in view of (7.1), we have

|f (y) − f (x)| ≤ |f (y) − f (xn )| + |f (xn ) − f (x)| < ε/2 + ε/2 = ε.

Thus we have proved that for any ε > 0 there exists δ > 0 such that |f (x) − f (y)| < ε
whenever d(x, y) < δ.

7.6 Exercises
Exercise 7.31. Show that a discrete topological space is compact if and only if it is finite.
Exercise 7.32. Give an example of a compact subset of a topological space that is not
closed.
Exercise 7.33. Show that a finite union of bounded sets is bounded.
Exercise 7.34. Give an example of a bounded metric space that is not totally bounded.
Exercise 7.35. Let X be a compact space and suppose that f : X → R is continuous
(with respect to the usual metric on R). Show that there exist x1 , x2 ∈ X such that

f (x1 ) ≤ f (x) ≤ f (x2 )

for all x ∈ X.
Exercise 7.36. Let (X, ρ) be a metric space and suppose that ∅ 6= A, B ⊆ X. Let

d(A, B) = inf{ρ(a, b) : a ∈ A, b ∈ B}.

(i) Give an example of two sets A, B ⊆ R such that d(A, B) = 0, but A ∩ B = ∅.


(ii) Prove that if A and B are compact, then there exist a0 ∈ A and b0 ∈ B such that
ρ(a0 , b0 ) = d(A, B).
(iii) Prove that if (X, ρ) is Rn equipped with the usual metric, A is compact and B is
closed, then there exist a0 ∈ A and b0 ∈ B such that ρ(a0 , b0 ) = d(A, B).
(iv) Give an example of two closed sets A, B ⊆ R such that d(A, B) = 0, but A∩B = ∅.
(v) Let (X, ρ) be C([0, 1]) equipped with the usual sup metric. Give an example of two
closed bounded sets A, B ⊆ X such that d(A, B) = 0, but A ∩ B = ∅.

42
Exercise 7.37. Let (X, d) be a compact metric space and suppose that T : X → X satisfies
the condition d(T x, T y) < d(x, y) for all x 6= y in X. Prove that the equation T x = x has
a unique solution in X. Compare this result to Exercise 5.34.
Hint: consider the mapping X 3 x 7→ d(x, T x) ∈ R and prove that it attains its
minimum on X.
Exercise 7.38. Let (X, d) be a compact metric space and suppose that T : X → X is
continuous and satisfies the condition d(T x, T y) ≥ d(x, y) for all x and y in X. Prove that
T (X) = X.
Hint: suppose the contrary – there exists x0 ∈ X \ T (X). Show that the sequence
xn = T n x0 , n ∈ N does not have convergent subsequences.)
Exercise 7.39. In each of the following cases, determine whether
(a) fn converges to the zero function pointwise on [0, 1],
(b) fn converges
R 1 to the zero function uniformly on [0, 1],
(c) limn→∞ 0 fn (x)dx = 0.

(i)
fn (x) = xn (1 − x).
(ii)
fn (x) = nxn (1 − x).
(iii)
fn (x) = n2 xn (1 − x).
(iv)
fn (x) = 2nx exp(−nx2 ).
(v) (
1 1
n
if 2n ≤ x ≤ n1 ,
fn (x) =
0 otherwise.

(vi) (
1
1 if 2n ≤ x ≤ n1 ,
fn (x) =
0 otherwise.

(vii) (
1
n if 2n ≤ x ≤ n1 ,
fn (x) =
0 otherwise.

Exercise 7.40. Let f : R → R be continuous and define fn (x) = f x + n1 . Prove that




{fn } converges uniformly to f on any compact subset of R. [Hint : uniform continuity.]


Find an example which shows that, in general, {fn } does not converge uniformly on R.
*Exercise 7.41. We say that a topological space X is separable if there exists a countable
subset A ⊆ X such that A = X. Prove that a compact metric space is separable.

43
8 Products and quotients of topological spaces
8.1 The product topology
Let X and Y be topological spaces and denote by Z = X × Y the Cartesian product of X
and Y (as sets).
Definition 8.1. We say that U is open in Z if whenever (x, y) ∈ U there exist V open in
X and W open in Y such that

(x, y) ∈ V × W ⊆ U.

We call the collection of all such sets the product topology on Z.


Remark 8.2. Sometimes the product topology is called the box topology. The product and
the box topology may be defined on arbitrary products of topological spaces; they agree on
finite products but in general are different.
Proposition 8.3. The product topology is a topology on Z.
Proof. Let τ denote the product topology. By a tautological argument, ∅ ∈ τ . Since
Z = X × Y , X is open in X and Y is open in Y , we see that Z ∈ τ .
Suppose that Ui ∈ τ for i ∈ I and (x, y) ∈ ∪i∈I Ui . Then (x, y) ∈ Ui for some i ∈ I and
so we can find V open in X and W open in Y such that

(x, y) ∈ V × W ⊆ Ui ⊆ ∪i∈I Ui .

We conclude that ∪i∈I Ui ∈ τ .


Finally suppose that U1 , U2 ∈ τ and (x, y) ∈ U1 ∩ U2 . Since (x, y) ∈ U1 we can find V1
open in X and W1 open in Y such that (x, y) ∈ V1 × W1 ⊆ U1 . Similarly we can find V2
open in X and W2 open in Y such that (x, y) ∈ V2 × W2 ⊆ U2 . Let V = V1 ∩ V2 , which is
open in X, and W = W1 ∩ W2 , which is open in Y . Further (x, y) ∈ V × W ⊆ U1 ∩ U2 and
so U1 ∩ U2 ∈ τ .
Remark 8.4. It is not true in general that every open set in X × Y is of the form V × W
where V is open in X and W is open in Y . However, we do have the following.
Exercise 8.5. U is open in the product topology if and only if U is a union of sets of the
form V × W where V is open in X and W is open in Y .
Definition 8.6. We define the projection maps

πX : Z → X
(x, y) 7→ x

and

πY : Z → Y
(x, y) 7→ y.

44
Theorem 8.7. Let X and Y be topological spaces and Z = X × Y .

1. If we endow Z with the product topology then πX and πY are continuous.

2. The product topology is the smallest topology on Z making πX and πY continuous.

Proof. 1. Let U be open in X. Then


−1
πX (U ) = {(x, y) ∈ Z : πX (x, y) ∈ U } = {(x, y) ∈ Z : x ∈ U } = U × Y

which is clearly open in the product topology. Hence πX is continuous. Similarly πY is


continuous.
2. Let τ be the product topology and let τ̃ be any topology on Z for which πX and πY
−1
are continuous. Let U be open in X. Then πX (U ) = U ×Y ∈ τ̃ since πX is continuous for τ̃ .
−1
Likewise, if V is open in X then πY (V ) = X ×V ∈ τ̃ . Hence U ×V = (U ×Y )∩(X ×V ) ∈ τ̃ .
The result follows from Exercise 8.5.

Theorem 8.8. If X and Y are Hausdorff spaces then X × Y is a Hausdorff space.

Proof. Let (x1 , y1 ) and (x2 , y2 ) be distinct points in X × Y . Suppose that x1 6= x2 . Then,
since X is Hausdorff, there exist disjoint open (in X) sets V1 and V2 such that x1 ∈ V1
and x2 ∈ V2 . We set U1 = V1 × Y and U2 = V2 × Y which are obviously open in the
product topology, and disjoint. Further we have (x1 , y1 ) ∈ U1 and (x2 , y2 ) ∈ U2 and so
we’ve separated the points by disjoint open sets in this case.
If x1 = x2 then necessarily y1 6= y2 and we may proceed similarly. It follows that X × Y
is Hausdorff.

Theorem 8.9. Let (X, dX ) and (Y, dY ) be metric spaces and define the metric

σ((x1 , y1 ), (x2 , y2 )) = max{dX (x1 , x2 ), dY (y1 , y2 )}

on Z = X × Y . Then the topology τσ induced by σ is equal to the product topology τ on Z.

Remark 8.10. In light of Exercise 1.25, there are other metrics on Z that induce the
product topology.
Proof. Let U ∈ τσ and suppose that (x, y) ∈ U . Then there exists ε > 0 such that
BεZ ((x, y)) ⊆ U . It is clear that BεZ ((x, y)) = BεX (x) × BεY (y) and since BεX (x) is open in
X and BεY (y) is open in Y we see that U ∈ τ .
Conversely if U ∈ τ and (x, y) ∈ U then (x, y) ∈ V × W ⊆ U for some V open in X
and Y open in Y . Now there exist ε1 , ε2 > 0 such that BεX1 (x) ⊆ V and BεY2 (y) ⊆ W and
we define ε = min{ε1 , ε2 }. Then

BεZ ((x, y)) = BεX (x) × BεY (y) ⊆ BεX1 (x) × BεY2 (y) ⊆ V × W ⊆ U

whence U ∈ τσ .

45
Corollary 8.11. Let (X, dX ) and (Y, dY ) be metric spaces, define Z = X × Y and suppose
that (xn , yn ) is a sequence in Z and (x, y) ∈ Z. Then (xn , yn ) → (x, y) in Z if and only if
xn → x in X and yn → y in Y .

Proof.

max{dX (xn , x), dY (yn , y)} → 0 ⇔ dX (xn , x) → 0 and dY (yn , y) → 0.

Exercise 8.12. Show that this result continues to hold if X and Y are topological spaces.

Theorem 8.13. Suppose that X and Y are connected topological spaces. Then X × Y is
connected.

Proof. Let f : Z → R be continuous and suppose that f (Z) ⊆ {0, 1}. By Proposition 6.12
it suffices to show that f is constant. Let (x1 , y1 ), (x2 , y2 ) ∈ Z; it suffices to show that
f (x1 , y1 ) = f (x2 , y2 ).
Define

F :X→R
x 7→ f (x, y1 )

and note that F = f ◦ ι where

ι:X→Z
x 7→ (x, y1 ).

Now let U be open in Z and x0 ∈ ι−1 (U ). Then (x0 , y1 ) = ι(x0 ) ∈ U and so there exist V, W
open in X, Y respectively such that (x0 , y1 ) ∈ V ×W ⊆ U . It follows that ι(x) = (x, y1 ) ∈ U
for all x ∈ V , or equivalently, V ⊆ ι−1 (U ). Since x0 ∈ V ⊆ ι−1 (U ) is arbitrary we see that
ι−1 (U ) is open in X.
We conclude that ι is continuous and therefore F = f ◦ ι is continuous. Since F (X) ⊆
{0, 1} and X is connected we see that F is constant which implies that f (x1 , y1 ) = f (x2 , y1 ).
We next define

Φ:Y →R
y 7→ f (x2 , y)

and note that F = f ◦ j where

j:Y →Z
y 7→ (x2 , y).

Arguing similarly we see that f (x2 , y1 ) = f (x2 , y2 ). We conclude that f (x1 , y1 ) = f (x2 , y2 )
as desired.

46
Exercise 8.14. Suppose that X and Y are topological spaces and X × Y is connected.
Prove that X and Y are connected.
[Hint: πX (Z) = X, πY (Z) = Y .]
Theorem 8.15. Let X, Y and T be topological spaces and set Z = X × Y . Let g : T → Z.
Then g is continuous if and only if πX ◦ g : T → X and πY ◦ g : T → Y are continuous.
Proof. It is clear that if g is continuous then πX ◦ g and πY ◦ g are continuous, since they
are the composition of continuous maps. Conversely suppose that πX ◦ g and πY ◦ g are
continuous and suppose that U is open in Z and t ∈ g −1 (U ). Then there exist V, W open
in X, Y respectively such that g(t) ∈ V × W ⊆ U . This implies that πX ◦ g(t) ∈ V , and so
t ∈ (πX ◦ g)−1 (V ) which is open in T . Similarly t ∈ (πY ◦ g)−1 (W ) which is open in T .
We define U 0 = (πX ◦ g)−1 (V ) ∩ (πY ◦ g)−1 (W ) which is also open in T and contains t.
Now if s ∈ U 0 then πX ◦ g(s) ∈ V and πY ◦ g(s) ∈ W whence g(s) ∈ V × W ⊆ U . We have
shown that t ∈ U 0 ⊆ g −1 (U ) where U 0 is open in T . Since t is arbitrary we see that g −1 (U )
is open in T and so g is continuous.

8.2 Quotient spaces


Definition 8.16. Let X be a topological space and f : X → Y be a map, where Y is a
non-empty set. Define the topology on Y induced by f by

τ = {U ⊆ Y : f −1 (U ) is open in X}.

Exercise 8.17. Show that τ is indeed a topology on Y .


Exercise 8.18. (i) Show that f : X → Y is now a continuous map.
(ii) Show further that τ is the biggest topology on Y for which f is continuous.
Proposition 8.19. Let X be a topological space, f : X → Y and endow Y with the topology
induced by f . Suppose that Z is another topological space. Then g : Y → Z is continuous
if and only if g ◦ f : X → Z is continuous.
Proof. Obviously g continuous implies that g ◦ f is continuous. Conversely,  suppose that
g ◦ f is continuous and U is open in Z. Then (g ◦ f )−1 (U ) = f −1 g −1 (U ) is open in X,
which implies that g −1 (U ) is open in Y . So g is continuous.
Definition 8.20. Suppose that X is a non-empty set and ∼ is an equivalence relation
on X. We denote by [x] = {y ∈ X : y ∼ x} the equivalence classes of X. We define
(X/∼) = {[x] : x ∈ X}, the quotient of X by ∼. We define the quotient map

π : X → X/∼
x 7→ [x].

Definition 8.21. Suppose that X is a topological space and ∼ is an equivalence relation


on X. We define the quotient topology on X/∼ to be the topology induced by the quotient
map π. We call the resulting space the quotient space.

47
Proposition 8.22. (i) If X is connected then X/∼ is connected.
(ii) If X is compact then X/∼ is compact.

Proof. This follows immediately from the fact that π is continuous and surjective.
Example 8.23. R/Z ≡ T.
We define an equivalence relation on R by x ∼ y if x − y ∈ Z. We write R/Z for the
quotient R/∼ and π for the quotient map. We also denote by T = {z ∈ C : |z| = 1} the
unit circle in the complex plane. We now define

f :R→T
x 7→ e2πix ,

which is clearly continuous and surjective. Moreover f (x) = f (y) ⇔ x − y ∈ Z and so the
map

F : R/Z → T
[x] 7→ e2πix

is well-defined. Now f = F ◦ π is continuous, so Proposition 8.19 implies that F is contin-


uous. Since f is surjective, so is F . Furthermore

F ([x]) = F ([y]) ⇔ f (x) = f (y) ⇔ x − y ∈ Z ⇔ x ∼ y ⇔ [x] = [y]

so F is injective. Finally note that T is Hausdorff and R/Z = π([0, 1]) is compact, since
[0, 1] is compact. It follows from Theorem 7.27 that F is a homeomorphism.
Example 8.24. The topology on R/Q is the trivial topology.
Suppose that U is a non-empty open subset in the quotient topology on R/Q. Then
π −1 (U ) = O for some non-empty open O ⊆ R, where π is the quotient map. Now O must
contain an interval of the form (a, b) where 0 < b − a < +∞. Let q be a rational number
satisfying 0 < q < b − a and notice that {x + nq : x ∈ (a, b), n ∈ Z} = R. It follows that
U = π(O) = π(R) = R/Q.

48
A Supplementary Material for Level 6
Proof of Theorem 5.20. Let x, y ∈ ∩∞ n=1 An . Then x, y ∈ An for any n and so d(x, y) ≤
diam(An ) → 0 as n → ∞. Thus d(x, y) = 0, i.e., x = y, so ∩∞ n=1 An contains at most one
point.
Since each An is non-empty we can choose xn ∈ An for each n. Now for n, m ≥ N we
have xn , xm ∈ AN and so d(xn , xm ) ≤ diam(AN ) → 0 as N → ∞. The sequence (xn ) is
therefore Cauchy, and so it converges to a limit in x ∈ X.
Finally note that for m ≥ n we have xm ∈ An , and since An is closed, we must have
x ∈ An . This is true for all n and so x ∈ ∩∞
n=1 An .

The proof that 1. implies 2. in Theorem 7.21. Let X be compact, suppose that xn is a se-
quence of elements in X and set Cn = Clos({xn , xn+1 , xn+2 , . . . }). Then

C1 ⊇ C2 ⊇ · · · ⊇ Cn ⊇ Cn+1 ⊇ . . .

and so
Cn1 ∩ Cn2 ∩ · · · ∩ Cnk = Cnk 6= ∅
if n1 < n2 < · · · < nk . So (Cn )n has the FIP and each Cn is closed. Since X is compact
∩∞n=1 Cn 6= ∅.
Let x ∈ ∩∞ n=1 Cn . Then x ∈ Clos({x1 , x2 , x3 , . . . }) and so B1 (x) 3 xN1 for some N1 ,
that is d(xN1 , x) < 1. Suppose now that we have constructed N1 < N2 < · · · < Nk such
that d(xNj , x) < 1j for j = 1, 2, . . . , k. Since x ∈ Clos({xNk +1 , xNk +2 , . . . }) we must have
B 1 (x) 3 xNk+1 for some Nk+1 > Nk .
k+1
By induction we construct a sequence N1 < N2 < . . . such that d(xNj , x) < 1j for
j = 1, 2, . . . . Clearly xNj → x as j → ∞ and (xNj )j is a subsequence of (xn )n . Hence X is
sequentially compact.

49
B Non-examinable bonus material
B.1 The completion of a metric space
The aim is to prove Theorem 5.12
Lemma B.1. If xn and yn , n ∈ N are Cauchy sequences in a metric space (X, d) then the
sequence of non-negative numbers an = d(xn , yn ) is convergent.
Proof. Let us prove that an forms a Cauchy sequence; since R is complete this will imply
that the sequence an is convergent.
Applying the triangle inequality we obtain

|an − am | = |d(xn , yn ) − d(xm , ym )| = |d(xn , yn ) − d(xm , yn ) + d(xm , yn ) − d(xm , ym )|


≤ |d(xn , yn ) − d(xm , yn )| + |d(xm , yn ) − d(xm , ym )|
≤ d(xn , xm ) + d(yn , ym ).

Given ε > 0, we can choose Nε such that d(xn , xm ) < ε/2 and d(yn , ym ) < ε/2 for all
n, m > Nε . Then |an − am | < ε which implies that an is a Cauchy sequence.
Corollary B.2. If xn , n ∈ N is a Cauchy sequence, then for any y ∈ X the sequence of
real numbers an = d(xn , y) is convergent.
Proof. Since {y, y, y, . . .} is a Cauchy sequence in X, this is a particular case of the lemma.

Let (X, d) be a metric space and let X̃ be the set which consists of all elements x ∈ X
and all Cauchy sequences α = {x1 , x2 , . . .} ⊂ X which do not converge to a limit in X. We
define a function d˜ on X̃ × X̃ as follows:
˜ y) = d(x, y);
ˆ If x, y ∈ X then d(x,
˜ α) = d(α,
ˆ if y ∈ X and α = {x1 , x2 , . . .} is a Cauchy sequence in X, then d(y, ˜ y) =
limn→∞ d(xn , y);
˜ β) =
ˆ if α = {x1 , x2 , . . .} and β = {y1 , y2 , . . .} are Cauchy sequences in X, then d(α,
limn→∞ d(xn , yn ).
Since d is a non-negative symmetric function the function d˜ is also non-negative and sym-
metric.
˜ v) ≤ d(u,
Lemma B.3. For all u, v, w ∈ X̃ we have d(u, ˜ w) + d(w,
˜ v) (the triangle inequal-
ity).
Proof. Assume that u = {x1 , x2 , . . .}, v = {y1 , y2 , . . .} and w = {z1 , z2 , . . .} are Cauchy
sequences, that is, u, v, w ∈ X̃ \ X. Since d is a metric, we have

d(xn , yn ) ≤ d(xn , zn ) + d(zn , yn )

50
for all n. Taking the limits as n → ∞, we obtain
˜ v) = lim d(xn , yn ) ≤ lim (d(xn , zn ) + d(zn , yn ))
d(u,
n→∞ n→∞
˜ w) + d(w,
= lim d(xn , zn ) + lim d(zn , yn ) = d(u, ˜ v).
n→∞ n→∞

If u ∈ X, v ∈ X or w ∈ X then the proof is obtained by substituting in the above


inequalities xn = u, yn = v or zn = w respectively.
We want to view the function d˜ as a metric on X̃. We have already seen that this
function is non-negative and symmetric and proved the triangle inequality. It is also clear
˜ u) = 0 for all u ∈ X̃. If x ∈ X then d(x,
that d(u, ˜ u) > 0 for all Cauchy sequences
˜ v) = 0 does
u ∈ X̃ \ X (otherwise the sequence u converges to the limit x). However, d(u,
not necessarily imply that u = v in the case where u and v are Cauchy sequences. In order
to overcome this difficulty we must admit that there are elements of X̃ which coincide with
each other. In other words, we must identify some elements of X̃.

Definition B.4. We shall say that the elements u, v ∈ X̃ coincide and write u = v if
˜ v) = 0.
d(u,

Clearly, for x, y ∈ X we have x = y only if x coincides with y in X. If x ∈ X and


˜ α) > 0 (otherwise the sequence
α = {x1 , x2 , . . .} ∈ X̃ is a Cauchy sequence then d(x,
α converges to the limit x). This implies that we do not identify the elements of X with
Cauchy sequences lying in X̃ \X. Finally, if α = {x1 , x2 , . . .} ∈ X̃ and β = {y1 , y2 , . . .} ∈ X̃
are Cauchy sequences, then α = β if and only if limn→∞ d(xn , yn ) = 0.
Remark B.5. Rigorously speaking, we should say that X̃ consists of elements of X and
the classes of equivalent Cauchy sequences introduced above.
˜ is said to be the completion of the metric space
Definition B.6. The metric space (X̃, d)
(X, d).

One can easily prove the following theorem, which implies Theorem 5.12.

Theorem B.7. The completion of a metric space (X, d) is a complete metric space.

51

You might also like