# Compact space

#### Background Information

SOS believes education gives a better chance in life to children in the developing world too. Do you want to know about sponsoring? See www.sponsorachild.org.uk

In mathematics, a subset of Euclidean space **R**^{n} is called **compact** if it is closed and bounded. For example, in **R**, the closed unit interval [0, 1] is compact, but the set of integers **Z** is not (it is not bounded) and neither is the half-open interval [0, 1) (it is not closed).

A more modern approach is to call a topological space **compact** if each of its open covers has a finite subcover. The Heine–Borel theorem shows that this definition is equivalent to "closed and bounded" for subsets of Euclidean space.

Note: Some authors such as Bourbaki use the term "**quasi-compact**" instead, and reserve the term "compact" for topological spaces that are Hausdorff and "quasi-compact". A single compact set is sometimes referred to as a **compactum**; following the Latin second declension (neuter), the corresponding plural form is **compacta**.

## History and motivation

The term *compact* was introduced by Fréchet in 1906.

It has long been recognized that a property like compactness is necessary to prove many useful theorems. It used to be that "compact" meant "sequentially compact" (every sequence has a convergent subsequence). This was when primarily metric spaces were studied. The "covering compact" definition has become more prominent because it allows us to consider general topological spaces, and many of the old results about metric spaces can be generalized to this setting. This generalization is particularly useful in the study of function spaces, many of which are not metric spaces.

One of the main reasons for studying compact spaces is because they are in some ways very similar to finite sets: there are many results which are easy to show for finite sets, whose proofs carry over with minimal change to compact spaces. It is often said that "compactness is the next best thing to finiteness". Here is an example:

- Suppose
*X*is a Hausdorff space, and we have a point*x*in*X*and a finite subset*A*of*X*not containing*x*. Then we can separate*x*and*A*by neighbourhoods: for each*a*in*A*, let*U*(*x*) and*V*(*a*) be disjoint neighbourhoods containing*x*and*a*, respectively. Then the intersection of all the*U*(*x*) and the union of all the*V*(*a*) are the required neighbourhoods of*x*and*A*.

Note that if *A* is infinite, the proof fails, because the intersection of arbitrarily many neighbourhoods of *x* might not be a neighbourhood of *x*. The proof can be "rescued", however, if *A* is compact: we simply take a finite subcover of the cover {*V*(*a*)} of *A*. In this way, we see that in a Hausdorff space, any point can be separated by neighbourhoods from any compact set not containing it. In fact, repeating the argument shows that any two disjoint compact sets in a Hausdorff space can be separated by neighbourhoods -- note that this is precisely what we get if we replace "point" (i.e. singleton set) with "compact set" in the Hausdorff separation axiom. Many of the arguments and results involving compact spaces follow such a pattern.

## Definitions

### Compactness of subsets of **R**^{n}

For any subset of Euclidean space **R**^{n}, the following four conditions are equivalent:

- Every open cover has a finite subcover. This is the most commonly used definition.
- Every sequence in the set has a convergent subsequence, the limit point of which belongs to the set.
- Every infinite subset of the set has an accumulation point in the set.
- The set is closed and bounded. This is the condition that is easiest to verify, for example a closed interval or closed
*n*-ball.

In other spaces, these conditions may or may not be equivalent, depending on the properties of the space.

Note that while compactness is a property of the set itself (with its topology), closedness is relative to a space it is in; above "closed" is used in the sense of closed in **R**^{n}. A set which is closed in e.g. **Q**^{n} is typically not closed in **R**^{n}, hence not compact.

### Compactness of topological spaces

The "finite subcover" property from the previous paragraph is more abstract than the "closed and bounded" one, but it has the distinct advantage that it can be given using the subspace topology on a subset of **R**^{n}, eliminating the need of using a metric or an ambient space. Thus, compactness is a topological property. In a sense, the closed unit interval [0,1] is intrinsically compact, regardless of how it is embedded in **R** or **R**^{n}.

A topological space X is defined as compact if all its open covers have a finite subcover. Formally, this means that

- for every arbitrary collection of open subsets of such that , there is a finite subset such that .

An often used equivalent definition is given in terms of the finite intersection property: if any collection of closed sets satisfying the finite intersection property has nonempty intersection, then the space is compact. This definition is dual to the usual one stated in terms of open sets.

Some authors require that a compact space also be Hausdorff, and the non-Hausdorff version is then called **quasicompact**.

## Examples of compact spaces

- Any finite topological space, including the empty set, is compact. Slightly more generally, any space with a finite topology (only finitely many open sets) is compact; this includes in particular the trivial topology.
- The closed unit interval is compact. This follows from the Heine-Borel theorem; proving that theorem is about as hard as proving directly that is compact. The open interval is not compact: the open cover for does not have a finite subcover.
- For every natural number
*n*, the*n*-sphere is compact. Again from the Heine-Borel theorem, the closed unit ball of any finite-dimensional normed vector space is compact. This is not true for infinite dimensions; in fact, a normed vector space is finite-dimensional if and only if its closed unit ball is compact. - The Cantor set is compact. Since the
*p*-adic integers are homeomorphic to the Cantor set, they also form a compact set. Since a finite set containing*p*elements is compact, this shows that the countable product of finite sets is compact, and is thus a special case of Tychonoff's theorem. - Consider the set of all functions from the real number line to the closed unit interval, and define a topology on so that a sequence in converges towards if and only if converges towards for all . There is only one such topology; it is called the topology of pointwise convergence. Then is a compact topological space, again a consequence of Tychonoff's theorem.
- Consider the set of all functions satisfying the Lipschitz condition for all and consider on the metric induced by the uniform distance . Then by Ascoli-Arzelà theorem the space is compact.
- Any space carrying the cofinite topology is compact.
- Any locally compact Hausdorff space can be turned into a compact space by adding a single point to it, by means of Alexandroff one-point compactification. The one-point compactification of is homeomorphic to the circle ; the one-point compactification of is homeomorphic to the sphere . Using the one-point compactification, one can also easily construct compact spaces which are not Hausdorff, by starting with a non-Hausdorff space.
- The spectrum of any continuous linear operator on a Hilbert space is a compact subset of the complex numbers
**C**. If the Hilbert space is infinite-dimensional, then any compact subset of**C**arises in this manner, as the spectrum of some continuous linear operator on the Hilbert space. - The spectrum of any commutative ring or Boolean algebra is compact.
- The Hilbert cube is compact.
- The right order topology or left order topology on any bounded totally ordered set is compact. In particular, Sierpinski space is compact.
- The prime spectrum of any commutative ring with the Zariski topology is a compact space, important in algebraic geometry. These prime spectra are almost never Hausdorff spaces.

## Theorems

Some theorems related to compactness (see the Topology Glossary for the definitions):

- A continuous image of a compact space is compact.
- The extreme value theorem: a continuous real-valued function on a nonempty compact space is bounded and attains its supremum.
- A closed subset of a compact space is compact.
- A compact subset of a Hausdorff space is closed.
- A nonempty compact subset of the real numbers has a greatest element and a least element.
- A subset of Euclidean
*n*-space is compact if and only if it is closed and bounded. ( Heine–Borel theorem) - A metric space (or uniform space) is compact if and only if it is complete and totally bounded.
- The product of any collection of compact spaces is compact. ( Tychonoff's theorem, which is equivalent to the axiom of choice)
- A compact Hausdorff space is normal.
- Every continuous map from a compact space to a Hausdorff space is closed and proper. It follows that every continuous bijective map from a compact space to a Hausdorff space is a homeomorphism.
- A metric space (or more generally any first-countable uniform space) is compact if and only if every sequence in the space has a convergent subsequence.
- A topological space is compact if and only if every net on the space has a convergent subnet.
- A topological space is compact if and only if every filter on the space has a convergent refinement.
- A topological space is compact if and only if every ultrafilter on the space is convergent.
- A topological space can be embedded in a compact Hausdorff space if and only if it is a Tychonoff space.
- Every topological space
*X*is a dense subspace of a compact space which has at most one point more than*X*. ( Alexandroff one-point compactification) - If the metric space
*X*is compact and an open cover of*X*is given, then there exists a number δ > 0 such that every subset of*X*of diameter < δ is contained in some member of the cover. ( Lebesgue's number lemma) - If a topological space has a sub-base such that every cover of the space by members of the sub-base has a finite subcover, then the space is compact. ( Alexander's sub-base theorem)
- Two compact Hausdorff spaces
*X*_{1}and*X*_{2}are homeomorphic if and only if their rings of continuous real-valued functions C(*X*_{1}) and C(*X*_{2}) are isomorphic. ( Gelfand-Naimark theorem)

## Other forms of compactness

There are a number of topological properties which are equivalent to compactness in metric spaces, but are inequivalent in general topological spaces. These include the following.

**Sequentially compact**: Every sequence has a convergent subsequence.**Countably compact**: Every countable open cover has a finite subcover. (Or, equivalently, every infinite subset has an ω-accumulation point.)- Pseudocompact : Every real-valued continuous function on the space is bounded.
- Weakly countably compact (or
**limit point compact**): Every infinite subset has an accumulation point.

While all these conditions are equivalent for metric spaces, in general we have the following implications:

- Compact spaces are countably compact.
- Sequentially compact spaces are countably compact.
- Countably compact spaces are pseudocompact and weakly countably compact.

Not every countably compact space is compact; an example is given by the first uncountable ordinal with the order topology. Not every compact space is sequentially compact; an example is given by 2^{[0,1]}, with the product topology.

A metric space is called pre-compact or totally bounded if any sequence has a Cauchy subsequence; this can be generalised to uniform spaces. For complete metric spaces this is equivalent to compactness. See relatively compact for the topological version.

Another related notion which (by most definitions) is strictly weaker than compactness is local compactness.