Existing in Mathlib · Topology
Heine–Cantor Theorem
A continuous map from a compact uniform space into any uniform space is automatically uniformly continuous.
- compact spaces
- uniform spaces
- continuous maps
- uniform continuity
- uniformity filters
- diagonal neighborhoods
Exact theorem
Exact Mathlib statement
theorem CompactSpace.uniformContinuous_of_continuous {α β : Type*} [UniformSpace α] [UniformSpace β] [CompactSpace α] {f : α → β} (h : Continuous f) : UniformContinuous fThe theorem at a glance
Heine–Cantor theorem at a glance
A visual guide to the theorem's hypotheses, structure, and conclusion; the exact statement gives the formal detail.
Heine–Cantor theorem at a glance

Detailed visual description
The poster states the whole-space CompactSpace theorem and follows its checked source route. Nested neighborhoods around the diagonal in α × α represent the domain uniformity; a paired map sends both coordinates through f; continuity carries those pair-neighborhoods toward the diagonal in β × β; and the final comparison reaches the target uniformity. The scope footer rules out a converse and the nearby compact-subset variant.
Statement structure
From hypotheses to conclusion
This map summarizes the statement's structure; the exact Mathlib declaration remains authoritative.
Paired neighborhoods through a compact source

Detailed visual description
A warm-paper source field is closed by a charcoal oval with four small gold clasps. Eight paired motifs—circles, squares, diamonds, triangles, hexagons, pentagons, stars, and striped variants—sit on both sides of one glowing diagonal seam. Dashed paired strands cross a central double aperture and reappear as the same eight identities inside separate nested halos in a blue target field around a second diagonal seam. The abstract fields have no axes, distances, labels, or subset boundary.
Why it matters
A mathematical landmark
Heine–Cantor is a central compactness principle in analysis and topology: a pointwise local continuity condition becomes one uniform condition across the entire domain. Mathlib's compact abstract proof makes the bridge especially clear by expressing uniformity through neighborhoods of the diagonal.
ProofAtlas record
What has been checked
Mathlib is the source of the theorem; the local Lean replay and page review are separate.
Claim boundary
No new theorem is claimed
This page indexes Mathlib's whole-space CompactSpace form of the Heine–Cantor theorem: for uniform spaces α and β, a CompactSpace instance on α, and a map f : α → β, continuity of f implies uniform continuity. It is not the nearby compact-subset theorem for ContinuousOn and UniformContinuousOn, it does not assert a converse, and it does not specialize the abstract uniform-space statement to metric spaces or intervals.
- The selected declaration concerns the whole compact domain through a CompactSpace instance; it is not the nearby compact-subset theorem using ContinuousOn and UniformContinuousOn.
- The theorem proves that continuity implies uniform continuity under compactness; it does not assert the converse.
- The declaration is abstract over uniform spaces and adds no metric, Hausdorff, separatedness, interval, epsilon-delta modulus, or quantitative Lipschitz hypothesis.
- ProofAtlas is indexing an existing Mathlib theorem, and generated explanations and visuals are not proof evidence.
Source and local evidence
Where the theorem comes from
- Existing declaration
CompactSpace.uniformContinuous_of_continuousin mathlib- Relationship
- The checked artifact is the upstream declaration itself
- Local Lean evidence
artifact.library.mathlib.heine-cantor-theorem.v001