Statement

The extreme value theorem states: if KK is a nonempty and f:KRf:K\to\mathbb R is a , then ff attains its maximum and minimum values.

That is, there exist xmax,xminKx_{\max}, x_{\min} \in K such that

f(xmin)f(x)f(xmax)for all xK.f(x_{\min}) \leq f(x) \leq f(x_{\max}) \quad \text{for all } x \in K.
Classical version

If aba\leq b, every continuous function f:[a,b]Rf:[a,b]\to\mathbb R attains a maximum and a minimum on [a,b][a,b].

Why compactness matters
  • The function f(x)=xf(x)=x on (0,1)(0,1) has neither a maximum nor a minimum.
  • The function f(x)=xf(x)=x on [1,)[1,\infty) has no maximum.
Image formulation

Equivalently, f(K)Rf(K)\subseteq\mathbb R has a and a . The result follows from and the order properties of nonempty compact subsets of R\mathbb R.