Extreme Value Theorem
Statement
Let be a compact topological space (e.g., a closed bounded interval ) and a continuous function. Then is bounded and attains both its maximum and minimum:
Compactness is essential. On an open or unbounded domain, continuous functions need not attain their extrema.
Visualization
Counterexample without compactness: on the open interval .
f(x) = x sin(1/x) on (0,1)
1 | /\/\/\/\/\/\___ ← oscillates, |f(x)| ≤ x
| /
0 |--+--+--+--+--+--
| \
-1 | \/\/\/\/\/\/\ ← oscillates below
+-+--+--+--+--+--+-
0 1
The supremum is approached but never attained on — compactness fails.
Valid case: on (compact).
| 0.0 | 0.00 |
| 0.25 | |
| 0.5 | ← minimum ✓ |
| 0.75 | |
| 1.0 | 0.00 |
Maximum value: (attained at both endpoints and ). Minimum: at .
Proof Sketch
- Boundedness: The continuous image of a compact set is compact (general topology). A compact subset of is bounded.
- Supremum exists: Since is bounded above, exists in .
- Supremum is attained: By compactness of (closed and bounded in ), . So for some .
- Minimum: Apply the same argument to (or directly to ).
Connections
- Intermediate Value TheoremIntermediate Value TheoremA continuous function on a closed interval hits every value between its endpointsRead more → — the IVT shows continuous functions on attain all intermediate values; the EVT shows they attain the extreme values
- Heine-Borel Theorem — the Heine-Borel theorem characterises compactness in as closed and bounded, which is what makes the canonical domain for the EVT
- Bolzano-Weierstrass Theorem — alternatively, the EVT follows from Bolzano-Weierstrass: take a sequence with ; by BWT it has a convergent subsequence
Lean4 Proof
import Mathlib.Topology.Order.Compact
/-- Extreme Value Theorem (maximum): a continuous function on a compact nonempty set
attains its maximum. Wraps `IsCompact.exists_isMaxOn`. -/
theorem evt_max {α : Type*} [TopologicalSpace α] {f : α → ℝ}
{s : Set α} (hs : IsCompact s) (hne : s.Nonempty)
(hf : ContinuousOn f s) :
∃ x ∈ s, IsMaxOn f s x :=
hs.exists_isMaxOn hne hf
/-- Extreme Value Theorem (minimum): a continuous function on a compact nonempty set
attains its minimum. Wraps `IsCompact.exists_isMinOn`. -/
theorem evt_min {α : Type*} [TopologicalSpace α] {f : α → ℝ}
{s : Set α} (hs : IsCompact s) (hne : s.Nonempty)
(hf : ContinuousOn f s) :
∃ x ∈ s, IsMinOn f s x :=
hs.exists_isMinOn hne hfReferenced by
- Darboux's TheoremCalculus
- Weierstrass Approximation TheoremCalculus