Open and Closed Balls in Metric Spaces
If
then the open ball centered at
with radius
is as the set of points
contained in:

Similarly, the closed ball centered at
with radius
is the set of points
contained in:

Now notice that
is simply the Euclidean distance function
for the metric space
. We can extend the concept of open and closed balls to any metric space with its own defined metric as defined below.
Definition: If
is a metric space,
, and
then the Open Ball centered at
with radius
is defined to be the set
.
For example, consider the metric space
where the metric
for all
by:

Then for each
, we can define the open ball centered at
and with radius
to be the set of all points
contained in:

We can likewise define the closed ball centered at
for some metric space
as follows.
Definition: If
is a metric space,
, and
then the Closed Ball centered at
with radius
is defined to be the set
.
Note the subtle but important difference between the definitions of open and closed balls centered at
with radius
.
From the example above, we can define the closed ball centered at
and with radius
to be the set of all points
contained in:

Open and Closed Sets in Metric Spaces
A set
is said to be open if
, that is, for every point
we have that there exists a positive real number
such that the ball centered at
with radius
is contained in
, i.e.,
.
Furthermore, we said that
is closed if
is open.
For any general metric space
, we define open and closeds subsets
of
in a similar manner.
Definition: If
is a metric space and
then
is said to be Open if
and
is said to be Closed if
is open. Moreover,
is said to be Clopen if it is both open and closed.
It is important to note that the definitions above are somewhat of a poor choice of words. A set
may just be open, just closed, open and closed (clopen), or even neither. Unfortunately these definitions are standard and we should note that saying a set is "not open" does not mean it is closed and likewise, saying a set is "not closed" does not mean it is open.
Now consider the whole set
. Is
open or closed? Well by definition, for every
there exists a positive real number
such that
since the ball centered at
with radius
is defined to be the set of all points IN
that are of a distance less than
of
. Therefore
is an open set.
So then the complement of
is
is a closed set. However, it is vacuously true that for all
there exists a ball centered at
fully contained in
since
contains no points to begin with. Therefore
is also an open set and so
is also a closed set.
This is the case for all metric spaces
. The whole set
and empty set
are trivially clopen sets!
Licensing
Content obtained and/or adapted from: