Open, Closed and Compact Sets in Metric Spaces Guide
In a metric space, a set is open if every point has a small ball around it contained in the set, closed if it contains all its limit points (equivalently, its complement is open), and compact if every open cover has a finite subcover — in metric spaces, equivalently, every sequence has a convergent subsequence whose limit lies in the set. These three notions organise all of topology and analysis.
They matter because the big theorems need them as hypotheses: continuous functions attain maxima on compact sets, closed subsets of complete spaces are complete, and open sets are where local arguments live. Confusing open with "not closed" is the classic beginner error — a set can be both, or neither.
Key Concepts
- Open set: U is open if for every x ∈ U there is r > 0 with B(x, r) ⊆ U. Open balls themselves are open, and arbitrary unions of open sets are open.
- Closed set: F is closed if it contains the limit of every convergent sequence of its points; equivalently, X ∖ F is open. Finite intersections of closed sets are closed.
- Limit point: x is a limit point of E if every ball B(x, r) contains a point of E different from x; closed means containing all limit points.
- Compactness: K is compact if every collection of open sets covering K has a finite subcollection still covering K. In metric spaces this is equivalent to sequential compactness.
- Heine–Borel theorem: in ℝn, a set is compact if and only if it is closed and bounded. This fails in general metric spaces.
Formulas
- Open cover definition: K compact ⟺ for every family {Ui} of open sets with K ⊆ ∪Ui, there are i₁, …, ik with K ⊆ Ui₁ ∪ … ∪ Uik.
- Sequential compactness: K compact ⟺ every sequence in K has a subsequence converging to a point of K (in metric spaces).
- Heine–Borel: K ⊆ ℝn compact ⟺ K closed and bounded.
- Continuous image: the continuous image of a compact set is compact — hence a continuous real function on a compact set attains its maximum and minimum.
Worked Example
Show that (0, 1) is open but not closed and not compact in ℝ with the usual metric.
- Open: for any x ∈ (0, 1), take r = min(x, 1 − x) > 0; then (x − r, x + r) ⊆ (0, 1), so every point has a ball inside the set.
- Not closed: the sequence 1/n lies in (0, 1) and converges to 0, which is a limit point outside the set; hence (0, 1) does not contain all its limit points.
- Not compact: consider the open cover Un = (1/n, 1) for n = 2, 3, …. Every x ∈ (0, 1) lies in some Un since 1/n → 0, so they cover (0, 1).
- But any finite subcollection has a largest n, say N, and then points x ≤ 1/N are uncovered. No finite subcover exists, so (0, 1) is not compact.
By contrast [0, 1] is closed and bounded, hence compact by Heine–Borel — adding the two endpoints changes everything.
Common Misconceptions
- "Closed means not open." In ℝ, [0, 1) is neither open nor closed, while ∅ and ℝ are both open and closed. Open and closed are not opposites.
- "Compact is the same as closed and bounded." Only in ℝn. In a general metric space, closed and bounded does not imply compact — the closed unit ball in infinite-dimensional spaces is the standard counterexample.
- "An infinite set cannot be compact." The set {1/n : n ≥ 1} ∪ {0} is infinite and compact in ℝ, since every sequence in it has a subsequence converging to 0 or to some 1/n.
Real-World Applications
- Optimization: a continuous function on a compact set attains its maximum — the theoretical basis for "an optimal solution exists" in economics and engineering.
- Numerical analysis: compactness arguments prove that minimizing sequences have convergent subsequences, justifying iterative algorithms.
- Topology and geometry: compactness is the rigorous version of "finite in spirit", letting infinite problems be reduced to finite checks.
Open sets are where every point has breathing room, closed sets are the ones that keep their limit points, and compact sets are those from which every open cover admits a finite subcover. The worked example shows the hierarchy in action: (0, 1) is open but neither closed nor compact, while [0, 1] gains compactness from its endpoints via Heine–Borel. Keep the definitions separate — openness and closedness are independent properties, and compactness is strictly stronger than either.
Related blogs
- The Real Number System and Field Axioms Explained Simply
- Order Axioms and Completeness: Real Numbers Full Guide
- Supremum and Infimum: Definitions, Examples and Key
- Archimedean Property: Explained with Proofs
- Sequences of Real Numbers: Convergence and Key Theorems
- Convergence and Divergence of Sequences: Notes and FAQs