# Intermediate Value Theorem

The **intermediate value theorem** states that if a continuous function attains two values, it must also attain all values in between these two values. Intuitively, a continuous function is a function whose graph can be drawn "without lifting pencil from paper." For instance, if \(f(x)\) is a continuous function that connects the points \([0,0]\) and \([5,20]\), then there must be some \(x_a\) between \(0\) and \(5\) where \(y=1,\) also some \(x_b\) where \(y=19\), another \(x_c\) where \(y= \frac{19}{5}\), etc. For this function there is an \(x\in [0,5]\) for any \(y\) value between \(0\) and \(20\).

(Intermediate Value Theorem)For two real numbers \(a\) and \(b\) with \(a < b\), let \(f\) be a continuous function on the closed interval \([a, b].\) Then for every \(y_0\) between \(f(a)\) and \(f(b),\) there exists a number \(x_0\in [a, b]\) with \(f(x_0)=y_0\).

The idea of the proof is as follows: take the two points \((a,f(a))\) and \((b,f(b))\) on the graph of the continuous function \(f: [a,b] \to \mathbb{R}\). These points demarcate a segment of the graph which connects the two points, as in the picture above. Since this segment has no holes or breaks in it (by continuity of the function), it must pass through each "level curve" \(y=c,\) where \(\min(f(a), f(b)) \le c \le \max(f(a), f(b)) \).

Note that the \(x_0\) guaranteed by the theorem may not be unique; the theorem implies that there is at least one \(x_0\) such that \(f(x_0) = y_0,\) but there may be more than one, depending on \(f\) and \(y_0.\)

#### Contents

## Common Misinterpretations

The statement of the theorem has multiple requirements, all of which are necessary for the conclusion to hold. Here is an illustrative example:

For the function \(f(x) = x^2 - \dfrac{9}{x} + 1\), over which of the following intervals does the intermediate value theorem guarantee a root:

\[\begin{array} &\left[-3, -1\right], &\left[-1, 1\right], &\left[1, 3\right]? \end{array}\]

In order for the intermediate value theorem to guarantee a root on a specified interval \(\left[a, b\right]\), not only must the function \(f\) be continuous on the interval, but 0 must be contained between \(f(a)\) and \(f(b).\) Let's check the values of \(f(-3), f(-1), f(1),\) and \(f(3):\)

\[\begin{array} &f(-3) = 13, &f(-1) = 11, &f(1) = -7, &f(3) = 7. \end{array} \]

For the first interval \(\left[-3, -1\right],\) the values returned by \(f\) are both positive which do

notsandwich 0, meaning the intermediate value theorem does not guarantee a root.For the second interval \(\left[-1, 1\right],\) the values returned by \(f\) are on either side of 0, which seems to suggest that \(f\) has a root on the interval \(\left[-1, 1\right].\) However, it's important to note that \(f(x)\) has a discontinuity at \(x = 0,\) meaning the intermediate value theorem does not hold. Indeed, \(f(x)\) does not have an \(x\)-intercept on the interval \(\left[-1, 1\right].\)

For the last interval \(\left[1, 3\right],\) the values returned by \(f\) are on either side of 0, which implies that \(f\) has a root on the interval \(\left[1, 3\right].\) This is confirmed by the intermediate value theorem because \(f\) is continuous on \(\left[1, 3\right].\) \(_\square\)

## Examples and Applications

As in the above example, one simple and important use of the intermediate value theorem (hereafter referred to as IVT) is to prove that certain equations have solutions. Consider the following example:

Does the equation \(\cos x = x\) have solution(s) \(x\in \mathbb{R}\)? If so, how many solutions does it have?

We study the function \(f(x) = x-\cos x\). Note that \(f(0) = -1 < 0\) and \(f(\pi) = \pi + 1 > 0\). Thus, by the IVT, there must be some \(y\in [0,\pi]\) such that \(f(y) = 0 \), i.e. \(y = \cos y\).

One root of the equation has been identified. Is this the only root? Note that \(f'(x) = 1-\sin x\) is everywhere non-negative, so \(f\) is increasing monotonically. Hence, \(f\) can only have one root. \(_\square\)

Is there a solution to \(x^5 - 2 x^3 - 2 = 0,\) where \(x\in [0,2]\)?

At \(x=0\), we have \(0^5 - 2 \times 0^3 - 2 = -2.\)

At \(x=2\), we have \(2^5 - 2 \times 2^3 - 2 = 14.\)So the IVT implies that there is a solution to \(x^5 - 2 x^3 - 2 = 0\) in the interval \( [0, 2]\). \(_\square\)

Suppose that \(f\) is continuous on \([0, 1]\) and \(f(0) = f(1)\). Let \(n\) be any positive integer, then prove that there is some number \(x\) such that

\[f(x) = f\left(x +\dfrac{1}{n}\right).\]

Define \(g(x) = f(x) − f\left(x +\dfrac{1}{n}\right)\).

Consider the set of numbers \(S =\left\{f(0), f\left(\dfrac{1}{n}\right), f\left(\dfrac{2}{n}\right), \ldots , f(1)\right\}\).

Let \(k\) be such that \(f\left(\dfrac{k}{n}\right)\) is the largest number in \(S\). Suppose that \(k \ne 0\) and \(k \ne n\).

Then \(g\left(\dfrac{k}{n}\right) = f\left(\dfrac{k}{n}\right) − f\left(\dfrac{k+1}{n}\right) \geq 0\), and \(g\left(\dfrac{k-1}{n}\right) = f\left(\dfrac{k-1}{n}\right) − f\left(\dfrac{k}{n}\right)\leq 0\).

By the Intermediate value theorem, there is \(c\in \left[\dfrac{k-1}{n},\dfrac{k}{n}\right]\) with \(g(c) = 0\), so that \(f(c) − f\left(c + \dfrac{1}{n}\right) = 0\), or \(f(c) = f\left(c + \dfrac{1}{n}\right)\) as desired.

Finally, if the largest number in \(S\) is \(f(0) = f(1)\), then the same argument works with \(k\) chosen such that \(f\left(\dfrac{k}{n}\right)\) is the minimum number in \(S\). \(_\square\)

Note that if \(f(0)\) is both the largest and smallest number in \(S\), then they are all the same and \(f(0) = f\left(\dfrac{1}{n}\right)\).

Suppose that \(f\) is continuous on \([0, 1]\) and \(f(0) = f(1)\). Let \(\varepsilon\) be the hyperreal unit, then prove that there is some number \(x\) such that\[f(x) = f\left(x +\varepsilon \right).\]

First, assume \(f(x)\) is not constant on \([0,1]\). The result holds trivially if it is.

Then, let \(g(x)=f(x)-f(x+\varepsilon)\)

Since \(f\) is not constant, there exists a \(c\in[0,1]\) such that \(f(c)\) is a maximum (or a minimum, but assume for now that it is a max, a min is handled similarly).

Then, \(g(c) = f(c) - f(c+\varepsilon) \geq 0\) and \(g(c-\varepsilon) = f(c-\varepsilon) - f(c) \leq 0\)

Now, by the Intermediate Value Theorem, if \(\varepsilon >0\), there exists a \(y\in[c-\varepsilon,c]\) such that \(g(y)=0\).

(If \(\varepsilon < 0, y\in[c,c-\varepsilon]\), instead.)

Thus, \(f(y) = f(y+\varepsilon)\), as wanted.

If \(\varepsilon = 0\), \(f(x) = f(x+\varepsilon) \forall x\).

Of the four statements below, which are true?

**I.** The equation \(x^4 -3x+ 1 = 0\) has a unique real solution.

**II.** The equation \(\sin x = x\) has a unique real solution.

**III.** The equation \(3x^5 - 20x^3 + 60x +16=0\) has a unique real solution.

**IV.** The equation \(\tan x = x\) has a unique real solution.

A real-valued function \(f\) is said to have the *intermediate value property* if for every \( [a,b] \) in the domain of \(f\), and for every \[x \in \Big[\min\big(f(a), f(b)\big), \max\big(f(a), f(b)\big)\Big],\] there exists some \(c\in [a,b]\) such that \(f(c) = x\).

The intermediate value theorem states that if \(f\) is continuous, then \(f\) has the intermediate value property. Is the converse of this theorem true? That is, if a function has the intermediate value property, must it be continuous on its domain?

Since it can detect zeroes of functions, the IVT is an important tool for the analysis of continuous functions. However, through some clever contortions, IVT can give even more impressive results. For instance, one can prove the **Borsuk-Ulam theorem** in dimension 1. This theorem states that for any continuous real-valued function \(f\) on a circle, there is some point \(p\) on the circle such that \(f\) takes the same value at \(p\) and at the point on the circle directly opposite to \(p\) (the *antipode* of \(p\)).

This implies that on any great circle of the globe, any continuously varying information will take on the same value at some two antipodal points. For instance, there must exist two antipodal points on the equator at which the air temperature is the same.

Let \(S^1\) denote a circle, and suppose that \(f: S^1 \to \mathbb{R}\) is a continuous function. Then, there exists \(\mathbf{x}\in S^1\) such that \(f(\mathbf{x}) = f(-\mathbf{x})\). \(_\square\)

Note: Here, by the circle \(S^1\), we mean the set of vectors in \(\mathbb{R}^2\) of length precisely 1. In other words, \(S^1\) is the set of points \((x,y) \in \mathbb{R}^2\) such that \(x^2 + y^2 = 1\).

There is a function \(p: [0,2\pi) \to S^1\) given by \(p(\theta) = (\cos \theta, \sin \theta)\). Composing this with \(f\) gives \(g:= f\circ p : [0,2\pi) \to \mathbb{R}\). Define a function \(h:[0,2\pi) \to \mathbb{R}\) by \[h(\theta) := g(\theta + \pi) - g(\theta),\] where we take \(\theta + \pi \pmod{2\pi}\) if \(\theta >\pi\).

Note that \[h(0) = g(\pi) - g(0) = -(g(0) - g(\pi)) = -h(\pi).\] In particular, \(h(0)\) and \(h(\pi)\) have opposite signs. Thus, by the IVT, there is some \(t \in (0,\pi)\) such that \(h(t) = 0\). This means \(g(t + \pi) = g(t)\).

Let \(\mathbf{x} = (\cos t, \sin t)\). Since \(p(t+\pi) = -\mathbf{x}\), we conclude \[f(-\mathbf{x}) = g(t+\pi) = g(t) = f(\mathbf{x})\] as desired. \(_\square\)

Any *die* is modeled by some polyhedron. If the polyhedron is *completely symmetric* in the sense that any face can be taken to any other face via a rigid motion, then the die will be *fair*; when the die is rolled, the probability of landing on any face will equal the probability of landing on any other face.

Do there exist fair dice that are not completely symmetric?

**Hint**: Start with a prism \(P\) whose cross-sections are regular \(n\)-gons. Now consider the *dual* polyhedron \(P^{\star}\), the polyhedron whose vertices are the centers of the faces of the original prism. This \(P^{\star}\) looks like two pyramids with regular \(n\)-gon cross-sections that have been glued together at their bases. Now, can you modify \(P^{\star}\) to obtain a fair die that isn't completely symmetric?

## Proofs of the Intermediate Value Theorem

One standard proof of the intermediate value theorem uses the **least upper bound property** of the real numbers, that every nonempty subset of \(\mathbb R\) with an upper bound has a least upper bound. This is an important property that helps characterize the real numbers--note that the rational numbers do not have the least upper bound property \((\)consider e.g. the set of all rational numbers less than \(\sqrt{2})\). For a discussion of this property, see the Infimum/Supremum wiki. Here is a proof of the intermediate value theorem using the least upper bound property.

Let \(f \colon [a,b] \to {\mathbb R}\) be a continuous function. Let \(y\) be a number between \(f(a)\) and \(f(b).\) Suppose without loss of generality that \( f(a) \le f(b), \) and consider \[ S = \{ x \in [a,b] \colon f(z) \le y \text{ for all } z \in [a,x] \}. \] Then \( S \) is nonempty since \( a \in S,\) and it has an upper bound (namely \( b \)), so there is a least upper bound. Call that least upper bound \( c. \)

Suppose \( f(c) > y.\) Then let \( \epsilon = f(c) - y > 0.\) By continuity, there is a \( \delta >0 \) such that \( |x-c|<\delta \) implies \( |f(x)-f(c)|<\epsilon. \) But \( |f(x)-f(c)|<\epsilon \) implies \( f(x) > y \) for all \( x \) in that range, so no \( x\)'s in that range lie in \( S. \) So \( c-\delta \) is an upper bound for \( S \) as well, which is a contradiction of the "leastness" of \( c.\)

Suppose \( f(c) < y \). Then let \( \epsilon = y-f(c) > 0.\) By continuity, there is a \( \delta>0 \) such that \( |x-c|<\delta \) implies \( |f(x)-f(c)|<\epsilon. \) But \( |f(x)-f(c)|<\epsilon\) implies \( f(x) < y \) for all \( x \) in that range, so every \( x \) in that range lies in \( S. \) So for instance \( x = c+\delta/2 \) is in \( S \), which is a contradiction since \( c \) is an upper bound.

The conclusion is that \( f(c)=y,\) as desired. \(_\square\)

In fact, the intermediate value theorem is equivalent to the least upper bound property: suppose the intermediate value theorem holds, and for a nonempty set \(S\) with an upper bound, consider the function \(f\) that takes the value \(1\) on all upper bounds of \(S\) and \(-1\) on the rest of \(\mathbb R.\) Then \(f\) is not continuous, by the intermediate value theorem (it takes on the values \(-1\) and \(1,\) but never \(0\)), and it is straightforward to show that a point \(x\) where \(f\) is discontinuous must be a least upper bound for \(S.\)

The intermediate value theorem can also be reframed and generalized in terms of connected sets in \(\mathbb R.\) Recall that a connected set is a set which is not a disjoint union of two open subsets. The continuous image of a connected set is connected, so the image of a continuous function on a closed interval is connected, and thus must contain every point between any two points in the image. Here is a formal translation of this idea, adapted from the wiki on connected sets:

Let \(f\colon [a,b] \to \mathbb R \) be a continuous function, and \( y\) be any real number between \(f(a)\) and \(f(b).\) We want to show that there is a \(c \in [a,b] \) such that \(f(c) = y.\) Because \([a,b]\) is connected, the image of \(f\) is connected. If \( y \notin f\big([a,b]\big),\) then the sets \( \big\{ (-\infty,y) \cap f([a,b]) \big\} \) and \( \big\{(y,\infty) \cap f([a,b])\big\}\) are disjoint nonempty sets which are open in the subspace topology on \(f\big([a,b]\big).\) And their union is \( f\big([a,b]\big),\) which is a contradiction. \(_\square\)

Note that the least upper bound property is used in a relatively subtle way: it is needed in order to prove that the domain, the closed interval \([a,b],\) is connected. Any proof of the intermediate value theorem must appeal to a property equivalent to the least upper bound property, which uses the completeness of the real numbers.

This framing in terms of connected subsets explains why the intermediate value theorem does not generalize easily to continuous functions whose image lies in \({\mathbb R}^n\) for \(n > 1\) \((\)or in \({\mathbb C})\); the connected subsets of \(\mathbb R\) are just the intervals, but the connected subsets of \({\mathbb R}^n\) are potentially much more complicated.

**Cite as:**Intermediate Value Theorem.

*Brilliant.org*. Retrieved from https://brilliant.org/wiki/intermediate-value-theorem/