The intermediate value theorem
If you walk up a hill from 100 m to 300 m above sea level, at some moment you were at exactly 200 m. You can't teleport past it. That's the intuition behind the first great theorem.
The intermediate value theorem (IVT)
If \(f\) is continuous on \([a, b]\) and \(c\) is any number between \(f(a)\) and \(f(b)\), then \(f(x) = c\) for at least one \(x\) in \([a, b]\).
ContinuousEvery value between \(f(a)\) and \(f(b)\) is hit.
Not continuousA jump can skip a value.
Proof
Say \(f(a) < c < f(b)\). Let \(S = \{x \in [a, b] : f(x) < c\}\). It contains \(a\) and is bounded by \(b\), so by completeness \(s = \sup S\) exists. If \(f(s) < c\), continuity would keep \(f\) below \(c\) a little to the right of \(s\), so \(s\) wouldn't be an upper bound of \(S\). If \(f(s) > c\), continuity would keep \(f\) above \(c\) on a small interval to the left of \(s\), so a smaller number would be an upper bound. The only possibility left is \(f(s) = c\). ∎
The proof needs completeness, and the theorem fails in the fractions: \(f(x) = x^2 - 2\) is continuous on \(\{x \in \mathbb Q : 1 \le x \le 2\}\), goes from \(-1\) to \(2\), and never equals 0 there. In \(\mathbb R\), the IVT finds \(\sqrt 2\) for us, and in the same way \(\sqrt[n]{c}\) for any \(c > 0\).
Example: every odd-degree polynomial has a real root
For \(p(x) = x^3 - 4x^2 + 7\) (or any polynomial whose highest power is odd), \(p(x) \to -\infty\) as \(x \to -\infty\) and \(p(x) \to +\infty\) as \(x \to +\infty\). So \(p\) takes a negative value somewhere and a positive value somewhere else, and by the IVT it takes the value 0 in between. Even-degree polynomials have no such guarantee: \(x^2 + 1\) has no real root.
Finding roots by bisection
The IVT says a root exists. Halving the interval repeatedly, as in Unit 1, finds it. To solve \(x^3 - x - 1 = 0\): \(f(1) = -1 < 0\) and \(f(2) = 5 > 0\), so there's a root in \([1, 2]\). Check the midpoint and keep the half where the sign changes.
| Step | Interval | Midpoint \(m\) | \(f(m)\) | Keep |
|---|---|---|---|---|
| 1 | [1, 2] | 1.5 | +0.875 | left half |
| 2 | [1, 1.5] | 1.25 | −0.297 | right half |
| 3 | [1.25, 1.5] | 1.375 | +0.225 | left half |
| 4 | [1.25, 1.375] | 1.3125 | −0.052 | right half |
| 5 | [1.3125, 1.375] | 1.34375 | +0.083 | left half |
| 6 | [1.3125, 1.34375] | 1.328125 | +0.015 | left half |
Each step halves the uncertainty: after 6 steps the root is pinned inside an interval of width \(\tfrac1{64}\), and 20 steps would give about six decimal places. The root is about \(1.3247\). Bisection is slow compared with cleverer methods, but it never fails, and its correctness is exactly the IVT plus nested intervals.
Fixed points
A fixed point theorem
If \(f : [0, 1] \to [0, 1]\) is continuous, then \(f(x) = x\) for some \(x\).
Example: opposite points on the equator
At any moment, there are two diametrically opposite points on the equator with exactly the same temperature. Let \(T(\theta)\) be the temperature at angle \(\theta\), and \(g(\theta) = T(\theta) - T(\theta + 180°)\). Then \(g(\theta + 180°) = -g(\theta)\), so \(g\) changes sign between \(\theta\) and \(\theta + 180°\) (or is zero already), and by the IVT it's zero somewhere.
The extreme value theorem
The extreme value theorem (EVT)
If \(f\) is continuous on a closed, bounded interval \([a, b]\), then \(f\) is bounded and reaches its maximum and minimum: there are points \(p, q \in [a, b]\) with \(f(p) \le f(x) \le f(q)\) for every \(x \in [a, b]\).
Closed interval \([a, b]\)The max and min are reached.
Half-open interval \((0, 1]\)\(1/x\) has no maximum.
Proof
Bounded: if not, for each \(n\) pick \(x_n\) with \(|f(x_n)| > n\). By Bolzano–Weierstrass (Unit 3) some subsequence converges to a point \(x^\ast\), which lies in \([a, b]\) because the interval is closed. By continuity, \(f\) of the subsequence tends to \(f(x^\ast)\), a finite number. But those values are unbounded. Contradiction.
Maximum reached: let \(M = \sup f\), which exists since \(f\) is bounded. Choose \(x_n\) with \(f(x_n) > M - \tfrac1n\). Again a subsequence converges to some \(q \in [a, b]\), and continuity gives \(f(q) = M\). ∎
The EVT is what makes optimisation possible: before searching for the best value of a continuous quantity on a closed interval, you know a best value exists. Unit 7 shows how derivatives help locate it.
Uniform continuity
In the definition of continuity at a point \(a\), the \(\delta\) is allowed to depend on \(a\) as well as on \(\varepsilon\). For some functions, one \(\delta\) works everywhere at once.
Definition
\(f\) is uniformly continuous on a set \(I\) if for every \(\varepsilon > 0\) there's a \(\delta > 0\) such that for all \(x, y \in I\), \(|x - y| < \delta\) implies \(|f(x) - f(y)| < \varepsilon\).
The Heine–Cantor theorem
A function that is continuous on a closed, bounded interval \([a, b]\) is uniformly continuous there.
The proof is another application of Bolzano–Weierstrass. This theorem is the key to Unit 9: it's why every continuous function on \([a, b]\) can be integrated. Chop the interval into pieces narrower than \(\delta\), and on every piece the function varies by less than \(\varepsilon\).
Inverse functions
The IVT also explains why familiar inverse functions are well behaved. If \(f\) is continuous and strictly increasing on an interval, it hits every value between its endpoints exactly once, so it has an inverse function \(f^{-1}\). And that inverse is automatically continuous and increasing too.
This is how \(\sqrt{x}\) (the inverse of \(x^2\) on \([0, \infty)\)), \(\ln x\) (the inverse of \(e^x\)) and \(\arcsin x\) (the inverse of \(\sin x\) on \([-\tfrac\pi2, \tfrac\pi2]\)) are known to exist and be continuous.
Practice set
Mixed questions covering the whole unit. Try each one before opening the answer.
1. Show that \(x^5 + x - 1 = 0\) has a solution between 0 and 1.
Show answer
\(f(x) = x^5 + x - 1\) is a polynomial, so continuous. \(f(0) = -1 < 0\) and \(f(1) = 1 > 0\). By the IVT, \(f(x) = 0\) for some \(x \in (0, 1)\).
2. Show that \(\cos x = x\) has a solution.
Show answer
Let \(g(x) = \cos x - x\). Then \(g(0) = 1 > 0\) and \(g(\pi/2) = -\pi/2 < 0\). By the IVT, \(g\) has a zero in \((0, \pi/2)\). (It's about 0.739.)
3. \(f(x) = 1/x\) has \(f(-1) = -1\) and \(f(1) = 1\), but never equals 0. Why doesn't this contradict the IVT?
Show answer
\(f\) isn't continuous on \([-1, 1]\): it isn't even defined at 0. The IVT needs continuity on the whole interval.
4. Does \(f(x) = x\) have a maximum on \((0, 1)\)? On \([0, 1]\)?
Show answer
On \((0, 1)\): no. The supremum is 1, but it isn't attained, since 1 isn't in the interval. On \([0, 1]\): yes, at \(x = 1\), as the EVT guarantees.
5. Is \(f(x) = x^2\) uniformly continuous on \([0, 10]\)? On all of \(\mathbb R\)?
Show answer
On \([0, 10]\): yes, \(|x^2 - y^2| = |x + y||x - y| \le 20|x - y|\), so \(\delta = \varepsilon/20\) works (or just cite Heine–Cantor). On \(\mathbb R\): no. For \(y = x + \delta/2\), \(|x^2 - y^2| = (2x + \delta/2)\delta/2\), which is huge for large \(x\), however small \(\delta\) is.
6. Bisection starts with an interval of width 1. How many steps guarantee the root to within \(10^{-6}\)?
Show answer
After \(n\) steps the interval has width \(2^{-n}\). We need \(2^{-n} < 10^{-6}\), so \(n > 6\log_2 10 \approx 19.9\). Twenty steps suffice.
Summary and glossary
- IVT: a continuous function on \([a, b]\) takes every value between \(f(a)\) and \(f(b)\). Bisection turns this into a root-finding method.
- Consequences: roots of odd-degree polynomials, \(n\)th roots, fixed points, opposite points with equal temperature.
- EVT: a continuous function on a closed, bounded interval is bounded and reaches its max and min.
- Uniform continuity: one \(\delta\) for all points. Continuous functions on \([a, b]\) are uniformly continuous (Heine–Cantor).
- All of these depend on completeness and fail for functions on the fractions.
- Intermediate value theorem
- Continuous functions on intervals don't skip values.
- Bisection
- Repeatedly halving an interval where a function changes sign, to trap a root.
- Fixed point
- A point with \(f(x) = x\).
- Extreme value theorem
- Continuous functions on closed bounded intervals reach a max and a min.
- Uniformly continuous
- A single \(\delta\) works for every point of the domain.