Open and Closed Sets in Metric Spaces

What does it mean for a set to have no sharp edges? Consider the plane with its usual distance. The disk {(x,y):x2+y2<1}\{(x,y): x^2+y^2 < 1\} feels fundamentally different from the disk {(x,y):x2+y2≤1}\{(x,y): x^2+y^2 \le 1\}. The first contains none of its "rim." The second contains all of it. This article makes that intuition precise. It uses only the notion of distance supplied by a metric space. The concepts of open and closed sets are the seed from which all of topology grows. Once we know which sets are "open" in a metric space, we can define continuity, convergence, compactness, and connectedness. We do this purely in terms of open sets. We never again need to mention ε\varepsilon's and δ\delta's explicitly. This is the bridge from analysis (built on distances) to topology (built on open sets alone). It is the reason a single abstract definition can unify convergence of sequences of real numbers, convergence of functions, and convergence of matrices under one roof. The strategy here is to build outward from the single most basic shape a metric space offers: the open ball. Open sets are unions of open balls. Closed sets are complements of open sets. From these two definitions we extract a small toolkit of equivalent characterizations. These come via limit points, via sequences, and via closure under complementation. This toolkit will be used constantly in every subsequent topological argument. By the end of this article you will have several things. You will have a rigorous definition of open and closed sets in a metric space. You will have a proof of their fundamental closure properties (the axioms that later define a topological space abstractly). You will have a sequential characterization of closedness. You will have worked examples in Rn\mathbb{R}^n and in function spaces. Finally, you will have a careful discussion of the traps that trip up every beginner exactly once. These traps include sets that are neither open nor closed, or both.

Key takeaways
  • An open ball B(x,r)={y∈X:d(x,y)<r}B(x,r) = \{y \in X : d(x,y) < r\} is the basic building block of a metric space.
  • A set UU is open if every point of UU has some open ball around it contained in UU.
  • A set FF is closed if its complement X∖FX \setminus F is open — equivalently, FF contains all its limit points.
  • Arbitrary unions and finite intersections of open sets are open; arbitrary intersections and finite unions of closed sets are closed.
  • Sets can be open, closed, both (clopen), or neither — all four cases occur even in R\mathbb{R}.
  • Key idea: openness is a local condition (wiggle room at every point), and closedness is its complement, equivalently "closed under taking limits."

Where this lives today

The open/closed dichotomy underlies essentially all of modern analysis: continuity of a function f:X→Yf: X \to Y between metric spaces is equivalent to the preimage of every open set being open, a purely topological reformulation of the ε\varepsilon-δ\delta definition. Compactness (every open cover has a finite subcover) and its practical consequences — the Extreme Value Theorem, existence of minimizers in optimization — are stated entirely in the language of open sets. In complex analysis, domains of holomorphy and the identity theorem rely on open connected sets; the maximum modulus principle is phrased via open sets on which a function attains no interior maximum. In differential geometry, manifolds are built by gluing open sets homeomorphic to Rn\mathbb{R}^n, making the open-set toolkit the literal scaffolding of the definition of a manifold. In numerical analysis and optimization, closed sets (such as closed convex feasible regions) guarantee that limits of feasible sequences remain feasible, which is exactly why convergence proofs for gradient descent and projection algorithms invoke closedness. In probability theory, the Borel σ\sigma-algebra generating measurable sets is built starting from the open sets of a metric space, so every measure-theoretic statement about "measurable events" ultimately traces back to this article's definitions. In cryptography and coding theory, metrics on finite spaces (e.g. Hamming distance) still support the same ball/open-set machinery, used to define error-correcting sphere-packing bounds. These threads all begin with the same open ball defined here, and all continue directly into Topological Spaces and Open Sets and Closure, Interior, and Boundary.

Ask the tutor: Can you show me why every finite subset of a metric space must be closed, using the limit-point characterization directly?

DefinitionOpen balls, open sets, and closed sets in a metric space

Let (X,d)(X,d) be a metric space.

Open ball. For x∈Xx \in X and r>0r > 0, the open ball of radius rr centered at xx is

B(x,r)={ y∈X:d(x,y)<r }.B(x,r) = \{\, y \in X : d(x,y) < r \,\}.

Open set. A subset U⊆XU \subseteq X is open (in XX, with respect to dd) if for every x∈Ux \in U there exists r>0r > 0 such that

B(x,r)⊆U.B(x,r) \subseteq U.

Equivalently, UU is a union of open balls.

Closed set. A subset F⊆XF \subseteq X is closed if its complement X∖FX \setminus F is open.

Limit point. A point x∈Xx \in X is a limit point (or accumulation point) of a set A⊆XA \subseteq X if every open ball B(x,r)B(x,r), r>0r>0, contains a point of AA different from xx; that is,

∀r>0,(B(x,r)∖{x})∩A≠∅.\forall r>0,\quad \big(B(x,r)\setminus\{x\}\big) \cap A \ne \varnothing.

By convention, ∅\varnothing and XX are declared open (vacuously and trivially, respectively); this is consistent with the ball definition above, since the "for every x∈∅x \in \varnothing" condition is vacuous, and XX obviously contains a ball around each of its points.

Intuition

Think of an open ball as "wiggle room": if y∈B(x,r)y \in B(x,r), you can nudge yy slightly in any direction (in a general metric space, "direction" just means "to any nearby point") and stay inside the ball, provided the nudge is small enough. Openness of a set UU says every point of UU has some amount of wiggle room, though the amount is allowed to shrink as you approach the "edge" of UU — as long as it never reaches zero for points actually inside UU. Closed sets are the mirror image: a set is closed exactly when it has no missing edge — whenever a sequence of points in FF homes in on some target point of XX, that target is already in FF. This is why intervals like [0,1][0,1] (which contain their endpoints) are closed, while (0,1)(0,1) (missing both endpoints) is open. The picture below shows the real line with these two intervals, highlighting the crucial difference: at the endpoints of [0,1][0,1], no ball of any positive radius fits inside (0,1)(0,1), but every ball around an endpoint of [0,1][0,1] pokes outside [0,1][0,1] into the complement, and that is precisely what makes [0,1][0,1]'s complement open.

:::svg[Open interval (0,1)(0,1) has wiggle room at every point; closed interval [0,1][0,1] contains its endpoints] 0 1 (0, 1) is open ball fits inside 0 1 [0, 1] is closed

::: The second picture worth carrying around is the ball itself in R2\mathbb{R}^2: not always literally round if you change the metric, but always defined the same way. In the taxicab metric d1((x1,y1),(x2,y2))=∣x1−x2∣+∣y1−y2∣d_1((x_1,y_1),(x_2,y_2)) = |x_1-x_2|+|y_1-y_2|, the "ball" B(0,1)B(0,1) is a diamond, not a disk — a reminder that "open ball" is a metric-dependent notion, even though the resulting open sets of R2\mathbb{R}^2 turn out to be the same collection for many common metrics (a fact revisited when comparing equivalent metrics).

Figure
Open ball of radius 1 in the Euclidean metric (circle) versus the taxicab metric (diamond)
Euclidean: $d_2$, disk Taxicab: $d_1$, diamond
TheoremFundamental properties of open and closed sets

Let (X,d)(X,d) be a metric space. 1. Every open ball is an open set. For any x∈Xx \in X and r>0r > 0, the set B(x,r)B(x,r) is open. 2. ∅\varnothing and XX are both open and both closed. 3. Arbitrary unions of open sets are open. If {Uα}α∈A\{U_\alpha\}_{\alpha \in A} is any family of open subsets of XX, then ⋃α∈AUα\bigcup_{\alpha \in A} U_\alpha is open. 4. Finite intersections of open sets are open. If U1,…,UnU_1, \dots, U_n are open subsets of XX, then ⋂i=1nUi\bigcap_{i=1}^n U_i is open. 5. (Dually, by De Morgan's laws) Arbitrary intersections of closed sets are closed, and finite unions of closed sets are closed. 6. Sequential characterization of closed sets. A set F⊆XF \subseteq X is closed if and only if for every sequence (xn)(x_n) in FF converging to some x∈Xx \in X, we have x∈Fx \in F. Equivalently, FF is closed iff FF contains all of its limit points.

Proof

We prove each part in order. Throughout, B(x,r)={y∈X:d(x,y)<r}B(x,r) = \{y \in X : d(x,y) < r\}.

(1) Every open ball is open. Let x0∈Xx_0 \in X, r>0r>0, and let B=B(x0,r)B = B(x_0,r). Take any y∈By \in B; we must find ρ>0\rho > 0 with B(y,ρ)⊆BB(y,\rho) \subseteq B. Since y∈By \in B, we have d(x0,y)<rd(x_0,y) < r, so

ρ:=r−d(x0,y)>0.\rho := r - d(x_0,y) > 0.

We claim B(y,ρ)⊆BB(y,\rho) \subseteq B. Let z∈B(y,ρ)z \in B(y,\rho), so d(y,z)<ρd(y,z) < \rho. By the triangle inequality for the metric dd,

d(x0,z)≤d(x0,y)+d(y,z)<d(x0,y)+ρ=d(x0,y)+(r−d(x0,y))=r.d(x_0,z) \le d(x_0,y) + d(y,z) < d(x_0,y) + \rho = d(x_0,y) + \big(r - d(x_0,y)\big) = r.

Hence z∈B(x0,r)=Bz \in B(x_0,r) = B. Since zz was arbitrary, B(y,ρ)⊆BB(y,\rho) \subseteq B, proving BB is open by definition.

(2) ∅\varnothing and XX are open and closed. ∅\varnothing is open vacuously: the defining condition "for every x∈∅x \in \varnothing, there is a ball around xx inside ∅\varnothing" has no xx to check, so it holds automatically. XX is open because for every x∈Xx \in X, B(x,1)⊆XB(x,1) \subseteq X trivially (every point of XX has distance defined and every ball is by definition a subset of XX). Since X∖∅=XX \setminus \varnothing = X is open, ∅\varnothing is closed; since X∖X=∅X \setminus X = \varnothing is open, XX is closed.

(3) Arbitrary unions of open sets are open. Let {Uα}α∈A\{U_\alpha\}_{\alpha \in A} be open sets and let U=⋃α∈AUαU = \bigcup_{\alpha \in A} U_\alpha. Let x∈Ux \in U. By definition of union, x∈Uα0x \in U_{\alpha_0} for some index α0\alpha_0. Since Uα0U_{\alpha_0} is open, there is r>0r>0 with B(x,r)⊆Uα0B(x,r) \subseteq U_{\alpha_0}. Since Uα0⊆UU_{\alpha_0} \subseteq U, we get B(x,r)⊆UB(x,r) \subseteq U. As x∈Ux \in U was arbitrary, UU is open. (Note this argument used no finiteness restriction on AA; it works even if AA is uncountable.)

(4) Finite intersections of open sets are open. Let U1,…,UnU_1,\dots,U_n be open and let V=⋂i=1nUiV = \bigcap_{i=1}^n U_i. If V=∅V = \varnothing we are done by (2). Otherwise let x∈Vx \in V. For each i=1,…,ni = 1,\dots,n, since x∈Uix \in U_i and UiU_i is open, there exists ri>0r_i > 0 with B(x,ri)⊆UiB(x,r_i) \subseteq U_i. Let

r:=min⁡{r1,…,rn}.r := \min\{r_1,\dots,r_n\}.

This minimum is over a finite nonempty set of positive numbers, hence r>0r > 0 (this step genuinely requires finiteness — see the counterexample below for what fails otherwise). For each ii, since r≤rir \le r_i, we have B(x,r)⊆B(x,ri)⊆UiB(x,r) \subseteq B(x,r_i) \subseteq U_i. Hence B(x,r)⊆⋂i=1nUi=VB(x,r) \subseteq \bigcap_{i=1}^n U_i = V. Since x∈Vx \in V was arbitrary, VV is open.

(5) Duals for closed sets. Let {Fα}α∈A\{F_\alpha\}_{\alpha \in A} be closed sets. By definition each X∖FαX \setminus F_\alpha is open. By De Morgan's law,

X∖⋂α∈AFα=⋃α∈A(X∖Fα),X \setminus \bigcap_{\alpha \in A} F_\alpha = \bigcup_{\alpha \in A} (X \setminus F_\alpha),

and the right side is open by part (3) (an arbitrary union of open sets). Hence ⋂αFα\bigcap_{\alpha} F_\alpha has open complement, i.e., is closed. Similarly, for finitely many closed sets F1,…,FnF_1,\dots,F_n, De Morgan gives

X∖⋃i=1nFi=⋂i=1n(X∖Fi),X \setminus \bigcup_{i=1}^n F_i = \bigcap_{i=1}^n (X \setminus F_i),

a finite intersection of open sets, open by part (4). Hence ⋃i=1nFi\bigcup_{i=1}^n F_i is closed.

(6) Sequential characterization of closed sets. Recall (xn)→x(x_n) \to x means: for every ε>0\varepsilon > 0, there exists NN such that n≥N  ⟹  d(xn,x)<εn \ge N \implies d(x_n,x) < \varepsilon, i.e. xn∈B(x,ε)x_n \in B(x,\varepsilon) for all n≥Nn \ge N. (⇒\Rightarrow) Suppose FF is closed. Let (xn)(x_n) be a sequence in FF with xn→xx_n \to x for some x∈Xx \in X. We must show x∈Fx \in F. Suppose, for contradiction, x∉Fx \notin F, i.e., x∈X∖Fx \in X \setminus F. Since FF is closed, X∖FX\setminus F is open, so there exists r>0r>0 with B(x,r)⊆X∖FB(x,r) \subseteq X \setminus F. But since xn→xx_n \to x, there exists NN with xN∈B(x,r)x_N \in B(x,r). Then xN∈X∖Fx_N \in X \setminus F, contradicting xN∈Fx_N \in F. Hence x∈Fx \in F. (⇐\Leftarrow) Suppose FF is not closed; we show the sequential property fails, which proves the contrapositive of this direction. Since FF is not closed, X∖FX \setminus F is not open, so there exists a point x∈X∖Fx \in X\setminus F such that no ball B(x,r)B(x,r) is contained in X∖FX \setminus F; equivalently, for every r>0r>0, B(x,r)∩F≠∅B(x,r) \cap F \ne \varnothing. Apply this with r=1/nr = 1/n for each positive integer nn: choose xn∈B(x,1/n)∩Fx_n \in B(x,1/n) \cap F (possible since this intersection is nonempty for every nn; this uses the axiom of countable choice implicitly, standard in this context). Then xn∈Fx_n \in F for all nn, and d(xn,x)<1/n→0d(x_n,x) < 1/n \to 0, so xn→xx_n \to x. But x∉Fx \notin F. This exhibits a sequence in FF converging to a point outside FF, so the sequential property fails. Combining both directions (each proved as a direct implication, together giving the stated "if and only if"): FF is closed iff every convergent sequence in FF has its limit in FF. Finally, the equivalence with limit points: if FF contains all its limit points, and xn→xx_n \to x with xn∈Fx_n \in F, then either xn=xx_n = x for some nn (so x∈Fx \in F already) or xn≠xx_n \ne x for all large nn, in which case every ball around xx contains points of FF other than xx (namely tail terms xnx_n), making xx a limit point of FF, hence x∈Fx \in F by hypothesis. Conversely if FF is closed and xx is a limit point of FF, then for every nn we may pick xn∈B(x,1/n)∩Fx_n \in B(x,1/n)\cap F with xn≠xx_n \ne x (using the definition of limit point), giving a sequence in FF with xn→xx_n \to x; by the sequential characterization already proved, x∈Fx \in F. Thus "FF closed"   ⟺  \iff "FF contains all its limit points." ■\blacksquare

∎

Worked examples

Example 1: A half-open rectangle in (R2,d2)(\mathbb{R}^2, d_2) with the Euclidean metric. Let

A={(x,y)∈R2:0≤x<2, 1<y≤5}.A = \{(x,y) \in \mathbb{R}^2 : 0 \le x < 2,\ 1 < y \le 5\}.

We claim AA is neither open nor closed, and we locate exactly which boundary pieces belong to AA. Not open: consider the point p=(0,3)∈Ap = (0, 3) \in A (on the left edge, x=0x=0). For any r>0r>0, the ball B(p,r)B(p,r) contains points with negative xx-coordinate, e.g. q=(−r/2,3)q = (-r/2, 3), since d2(p,q)=r/2<rd_2(p,q) = r/2 < r. Such q∉Aq \notin A because its xx-coordinate is negative. Hence no ball around pp fits in AA, so AA is not open. Not closed: consider p′=(1,1)p' = (1, 1), which lies on the bottom edge y=1y=1, excluded from AA (since AA requires y>1y>1 strictly), so p′∉Ap' \notin A. But p′p' is a limit point of AA: for any r>0r>0, the point q′=(1,1+min⁡(r/2,4))q' = (1, 1+\min(r/2, 4)) satisfies d2(p′,q′)=min⁡(r/2,4)<rd_2(p',q') = \min(r/2,4) < r (for r≤8r \le 8; for r>8r>8 take any point of AA near p′p', which still exists since AA meets every ball around p′p') and lies in AA (its yy-coordinate is in (1,5](1,5] and x=1∈[0,2)x=1 \in [0,2)). So every ball around p′p' meets AA, making p′p' a limit point of AA not contained in AA; by the sequential/limit-point characterization, AA is not closed. Boundary bookkeeping: the edges x=0x=0 and y=5y=5 belong to AA (matching the ≤\le signs), while x=2x=2 and y=1y=1 do not (matching strict inequalities). This asymmetric mix of open and closed edges is exactly why AA falls into neither the "open" nor "closed" category — a single strict inequality among several is enough to destroy openness, and a single non-strict inequality is enough to destroy closedness at the complementary edge.

Example 2: A ball in the space of bounded sequences ℓ∞\ell^\infty. Let X=ℓ∞X = \ell^\infty, the space of bounded real sequences x=(x1,x2,… )x = (x_1,x_2,\dots) with metric

d(x,y)=sup⁡k≥1∣xk−yk∣.d(x,y) = \sup_{k \ge 1} |x_k - y_k|.

(This is a metric: symmetry and positivity are immediate, and the triangle inequality follows from ∣xk−zk∣≤∣xk−yk∣+∣yk−zk∣≤d(x,y)+d(y,z)|x_k - z_k| \le |x_k-y_k|+|y_k-z_k| \le d(x,y)+d(y,z) for every kk, hence also for the supremum over kk.) Consider the set

C={x∈ℓ∞:sup⁡k∣xk∣≤1},C = \{x \in \ell^\infty : \sup_k |x_k| \le 1\},

the closed unit ball centered at 0=(0,0,… )\mathbf{0} = (0,0,\dots). We verify directly (not merely by name) that CC is closed, by showing X∖CX \setminus C is open. Let z∈X∖Cz \in X\setminus C, so sup⁡k∣zk∣>1\sup_k |z_k| > 1; write M:=sup⁡k∣zk∣=1+εM := \sup_k |z_k| = 1 + \varepsilon for some ε>0\varepsilon > 0 (finite since z∈ℓ∞z \in \ell^\infty is bounded). We claim B(z,ε)⊆X∖CB(z, \varepsilon) \subseteq X \setminus C. Let w∈B(z,ε)w \in B(z,\varepsilon), i.e. d(z,w)=sup⁡k∣zk−wk∣<εd(z,w) = \sup_k|z_k - w_k| < \varepsilon. Choose an index k0k_0 with ∣zk0∣|z_{k_0}| close to MM, say ∣zk0∣>M−ε/2|z_{k_0}| > M - \varepsilon/2 (possible since MM is a supremum). Then by the reverse triangle inequality,

∣wk0∣≥∣zk0∣−∣zk0−wk0∣>(M−ε/2)−ε=M−3ε/2=1+ε−3ε/2=1−ε/2.|w_{k_0}| \ge |z_{k_0}| - |z_{k_0}-w_{k_0}| > (M - \varepsilon/2) - \varepsilon = M - 3\varepsilon/2 = 1 + \varepsilon - 3\varepsilon/2 = 1 - \varepsilon/2.

This alone does not immediately exceed 11; we must be more careful and choose k0k_0 with ∣zk0∣>M−δ|z_{k_0}| > M - \delta for a small δ\delta depending on ε\varepsilon, then bound d(z,w)d(z,w) appropriately. Redo cleanly: given w∈B(z,ε)w \in B(z,\varepsilon), for every index kk,

∣wk∣≥∣zk∣−∣zk−wk∣>∣zk∣−ε.|w_k| \ge |z_k| - |z_k - w_k| > |z_k| - \varepsilon.

Taking the supremum over kk on both extreme sides (valid since the inequality holds for every fixed kk, so it holds for the index achieving the sup on the left, and the right side's sup is M−εM - \varepsilon... but we must take sup of ∣zk∣−ε|z_k|-\varepsilon, which equals M−εM - \varepsilon since ε\varepsilon is constant):

sup⁡k∣wk∣≥sup⁡k(∣zk∣−ε)=M−ε=(1+ε)−ε=1.\sup_k |w_k| \ge \sup_k \big(|z_k| - \varepsilon\big) = M - \varepsilon = (1+\varepsilon) - \varepsilon = 1.

This only gives sup⁡k∣wk∣≥1\sup_k|w_k| \ge 1, not strictly greater than 11, so we tighten the radius: use B(z,ε/2)B(z,\varepsilon/2) instead. Repeating the computation with ε/2\varepsilon/2 in place of ε\varepsilon gives

sup⁡k∣wk∣≥M−ε/2=1+ε/2>1,\sup_k|w_k| \ge M - \varepsilon/2 = 1 + \varepsilon/2 > 1,

so w∉Cw \notin C, i.e. w∈X∖Cw \in X \setminus C. This holds for every w∈B(z,ε/2)w \in B(z,\varepsilon/2), so B(z,ε/2)⊆X∖CB(z,\varepsilon/2) \subseteq X\setminus C. Since z∈X∖Cz \in X\setminus C was arbitrary, X∖CX\setminus C is open, so CC is closed — exactly as its name "closed unit ball" promises, now verified from the definitions rather than assumed.

CounterexampleWhy "finite" intersection cannot be weakened to "arbitrary" intersection

Theorem part (4) asserts finite intersections of open sets are open, and the proof crucially used that min⁡{r1,…,rn}>0\min\{r_1,\dots,r_n\} > 0 for finitely many positive numbers rir_i. Drop the finiteness hypothesis and allow a countably infinite intersection: the conclusion fails. Work in X=RX = \mathbb{R} with the usual metric. For each n=1,2,3,…n = 1,2,3,\dots define the open interval

Un=(−1n,1n),U_n = \left(-\frac1n, \frac1n\right),

which is open (it is the open ball B(0,1/n)B(0,1/n), open by Theorem part (1)). Consider

⋂n=1∞Un.\bigcap_{n=1}^\infty U_n.

We compute this intersection exactly: a real number xx lies in every UnU_n iff ∣x∣<1/n|x| < 1/n for all nn. If x≠0x \ne 0, choosing n>1/∣x∣n > 1/|x| gives 1/n<∣x∣1/n < |x|, so x∉Unx \notin U_n for that nn; hence xx fails to lie in the intersection. If x=0x=0, then ∣0∣=0<1/n|0| = 0 < 1/n for every nn, so 00 belongs to every UnU_n. Therefore

⋂n=1∞Un={0}.\bigcap_{n=1}^\infty U_n = \{0\}.

But {0}\{0\} is not open in R\mathbb{R}: for any r>0r>0, the ball B(0,r)=(−r,r)B(0,r) = (-r,r) contains nonzero points (e.g. r/2r/2), so B(0,r)⊈{0}B(0,r) \not\subseteq \{0\}, meaning no ball around 00 fits inside {0}\{0\}. Thus an intersection of infinitely many open sets produced a non-open (in fact closed, being a single point, verified via the sequential criterion or directly) set. This is precisely why the hypothesis "finite" in part (4) cannot be dropped or replaced by "countable" or "arbitrary": the proof's use of min⁡{r1,…,rn}>0\min\{r_1,\dots,r_n\} > 0 has no analogue for inf⁡nrn\inf_n r_n, which can legitimately equal 00.

Scope, edge cases & common traps

SituationWhat holdsWhat fails / trap
Finite intersections of open setsOpen (Theorem part 4)Infinite intersections can fail to be open (see counterexample)
Arbitrary unions of open setsAlways open (Theorem part 3)No restriction needed here — union is safe for any cardinality
A set that is both open and closedOccurs: e.g. ∅,X\varnothing, X always; in disconnected spaces, more examples ("clopen" sets)Students often assume "closed" means "not open" — false; the two are not exhaustive or exclusive
Single point {x}\{x\}Always closed in any metric space (its complement is open by an argument like Example 2/Theorem part 1 combined with the triangle inequality)Not always open — e.g. {0}⊂R\{0\}\subset\mathbb R is not open
Half-open interval (a,b](a,b]Neither open nor closed in R\mathbb{R}Easy to mistakenly call it "closed" because of the bracket at bb alone
Discrete metric (d(x,y)=1d(x,y)=1 if x≠yx\ne y)Every subset is open (and hence closed)Tempting to think "closed" sets must be small or bounded — false, depends entirely on the metric

The mathematician behind it

Origins · 1 minFelix Hausdorff and how this was discovered
FH
Felix Hausdorff
1868–1942 · Foundational topology and set theory, Germany

Felix Hausdorff was a German mathematician whose 1914 treatise Grundzüge der Mengenlehre (Foundations of Set Theory) gave one of the first systematic, rigorous treatments of topological spaces, building directly on the metric-space notions of open sets pioneered by Fréchet. Hausdorff recognized that the properties proved in the theorem above — arbitrary unions and finite intersections of open sets remaining open — could be taken as axioms defining a topological space abstractly, freeing topology from any dependence on a distance function. He also introduced the separation condition now called the Hausdorff property, ensuring distinct points can be separated by disjoint open sets, automatically satisfied by every metric space. Hausdorff's career ended in tragedy: as a Jewish academic in Nazi Germany, he was stripped of his position, and in 1942, facing deportation to a concentration camp, he and his wife and sister-in-law died by suicide. His mathematical legacy, however, is foundational to virtually every branch of modern analysis and geometry.

History
- 1906 — Maurice Fréchet introduces general metric spaces in his doctoral thesis, defining limits and continuity via distance functions.
- 1914 — Felix Hausdorff publishes Grundzüge der Mengenlehre, abstracting the open-set axioms away from metrics, founding point-set topology.
- 1922 — Kazimierz Kuratowski gives an axiomatic closure-operator formulation, an alternative but equivalent route to the same open/closed structure.
- 1930s — Textbook consolidation (Alexandroff, Hopf, and others) standardizes the open-ball-based definitions used in metric spaces today.
- 1975 — Munkres' Topology textbook popularizes the exact pedagogical sequence — metric spaces first, then abstract open sets — used in this article and used in most modern courses.
Is every open set a union of open balls, or just something that "locally looks like" a union of balls?

Every open set genuinely is a union of open balls, not merely something resembling one locally. If UU is open, then for each x∈Ux \in U there is some rx>0r_x > 0 with B(x,rx)⊆UB(x,r_x) \subseteq U; taking the union over all x∈Ux \in U gives ⋃x∈UB(x,rx)\bigcup_{x\in U} B(x,r_x). This union is contained in UU (each ball is), and it contains UU (each x∈Ux\in U lies in its own ball, since d(x,x)=0<rxd(x,x)=0<r_x). Hence U=⋃x∈UB(x,rx)U = \bigcup_{x \in U} B(x,r_x) exactly, a union of open balls — potentially uncountably many, but that is permitted since Theorem part (3) allows arbitrary unions.

Can a set be both open and closed at the same time?

Yes — such sets are called clopen. In any metric space, ∅\varnothing and XX are always clopen. In R\mathbb{R} (with the usual metric) these are in fact the only clopen sets, a fact equivalent to R\mathbb{R} being connected. But in disconnected spaces there can be more: in X=[0,1]∪[2,3]⊂RX = [0,1]\cup[2,3] \subset \mathbb{R} with the inherited metric, the piece [0,1][0,1] is clopen within XX, because its complement [2,3][2,3] is also open in XX (every point of [2,3][2,3] has a small ball, using the metric restricted to XX, that stays inside [2,3][2,3]). Clopen sets are exactly the obstruction to connectedness.

Does "closed" mean the same thing as "bounded" or "compact"?

No, and conflating them is a common error. Closed only means the complement is open; it says nothing about size. The whole space XX is always closed (Theorem part 2) yet is typically unbounded (e.g. X=RX=\mathbb{R}). Conversely a set can be bounded but not closed, like (0,1)(0,1). The Heine–Borel theorem shows that in Rn\mathbb{R}^n specifically, "closed and bounded" together are equivalent to compactness, but this equivalence is special to finite-dimensional Euclidean space and fails in general metric spaces (there exist closed, bounded sets in infinite-dimensional spaces, like the closed unit ball in ℓ∞\ell^\infty from Example 2, that are not compact).

Why do we require open balls to use strict inequality d(x,y)<rd(x,y) < r rather than ≤r\le r?

The strict inequality is what makes B(x,r)B(x,r) open in the first place, matching Theorem part (1). If we instead defined "balls" with ≤\le (the closed ball B‾(x,r)={y:d(x,y)≤r}\overline{B}(x,r) = \{y : d(x,y)\le r\}), the resulting set is generally closed, not open — for a point yy with d(x,y)=rd(x,y)=r exactly, every ball around yy pokes outside B‾(x,r)\overline B(x,r) in a typical metric space like Rn\mathbb{R}^n. Both notions are useful and standard; they are just different objects serving different roles (open balls generate open sets, closed balls are prototypical closed sets), and one should never conflate them.

If a set has no limit points at all, is it automatically closed?

Yes. The characterization in Theorem part (6) says FF is closed iff FF contains all its limit points. If FF has no limit points whatsoever, the condition "FF contains all its limit points" holds vacuously (there is nothing to check), so FF is closed. This explains why every finite set, and more generally every set with no accumulation points (such as {1,1/2,1/3,… }∪{0}\{1, 1/2, 1/3, \dots\} \cup \{0\} is not such an example since 00 is a limit point — but {1,2,3,… }=Z>0\{1,2,3,\dots\} = \mathbb{Z}_{>0} in R\mathbb{R} has no limit points and is indeed closed), is automatically closed.

How does this metric-space definition connect to the abstract definition of a topological space?

Theorem parts (2), (3), and (4) — that ∅\varnothing and XX are open, arbitrary unions of open sets are open, and finite intersections of open sets are open — are exactly the three axioms used to define a general topological space, except there the collection of "open sets" is given by fiat (a topology) rather than derived from a metric. Every metric space thus produces a topological space by taking the metric's open sets as the topology; this is called the metric topology. Not every topological space arises this way (non-metrizable spaces exist), but every metric space gives a legitimate topology, and the theorem proved here is precisely the verification that this construction is consistent.

Is the empty set really open, or is that just a technicality to avoid worrying about it?

It is genuinely open by the definition, not merely a convention adopted for convenience, though it is admittedly a vacuous case. The defining condition for openness is a universally quantified statement: "for every x∈Ux \in U, there exists r>0r>0 with B(x,r)⊆UB(x,r)\subseteq U." When U=∅U = \varnothing, there are no elements xx to produce a counterexample, so the universal statement is true by the standard logical convention that a universally quantified statement over an empty domain is vacuously true. This is the same logical principle used throughout mathematics (e.g., "every element of ∅\varnothing is prime" is also vacuously true), not a special exception invented for topology.

Before this

Where this leads