---
title: "Compactness in Metric Spaces"
description: "Compare the open-cover and sequential definitions, prove they agree in a metric space, and see what compactness buys for continuous functions."
canonical: https://lightmysky.com/learn/mathematics/compactness-in-metric-spaces-mt_dBLXU0wSN9
source: https://lightmysky.com/learn/mathematics/compactness-in-metric-spaces-mt_dBLXU0wSN9.md
retrieved: 2026-09-12
---

> **Agent view.** This is the Markdown twin of the page, for tools and assistants.
> When to use this site, and the call that answers each job: https://lightmysky.com/agent-instructions.md
> API description (OpenAPI 3.1): https://lightmysky.com/openapi.json · Authentication: https://lightmysky.com/auth.md
> Pricing: https://lightmysky.com/pricing.md · Catalog: https://lightmysky.com/llms.txt · Full catalog: https://lightmysky.com/llms-full.txt
> Every machine-readable file on this domain: https://lightmysky.com/.well-known/ai-catalog.json
> Ask for Markdown with `Accept: text/markdown`, a `.md` address, or `?mode=agent`.

# Compactness in Metric Spaces

Compare the open-cover and sequential definitions, prove they agree in a metric space, and see what compactness buys for continuous functions.

Subject: Mathematics · Area: Topology · Ages 21 to 22
Page: https://lightmysky.com/learn/mathematics/compactness-in-metric-spaces-mt_dBLXU0wSN9

## Ready when they can

- Prove that a continuous function on a compact space is bounded and attains its bounds
- Show closed and bounded is not enough for compactness outside finite dimensions
- State the Heine-Borel theorem and identify exactly where its proof uses completeness

## Lesson: Compact domains tame functions

Continuous functions on compact domains behave well. Their images stay compact, hence bounded, and maxima are attained. The closed unit interval is the model case. Drop an endpoint and the promise breaks: sequences escape toward the missing point with no inside limit to catch them.

In the reals, compact means closed plus bounded, the Heine Borel rule. Closed keeps the limits, bounded keeps the spread fenced. Sequentially, every sequence lands a convergent subsequence with its limit inside, with Bolzano Weierstrass supplying it. Completeness of the reals is the engine underneath that proof.

**Example.** Outside finite dimensions the equivalence collapses. The closed unit ball in infinite dimensions is closed and bounded yet not compact: it cradles a sequence with no convergent subsequence. Rationals inside [0, 1] fail nearer home by missing irrational limits. Closed plus bounded alone is not enough.

**Tip.** To certify a maximum, first certify compactness. Name the set, check closed, check bounded, check the space is finite dimensional. Never trust half open intervals or bare rationals with your extremes.

**Recap.** In the reals closed plus bounded is compact, and compact domains tame continuous maps.

## Practice

17 questions on this page, each with its working shown.

## Needs first

- [Completeness and the Contraction Mapping Theorem](https://lightmysky.com/learn/mathematics/completeness-and-the-contraction-mapping-theorem-mt_DYsLzg-IaK)

## Opens up

- [Topological Spaces: Continuity Without Distance](https://lightmysky.com/learn/mathematics/topological-spaces-continuity-without-distance-mt_D2oPq0AVhI)
