You are here

The intermediate value theorem

20 January, 2016 - 10:05

Another way of thinking about continuous functions is given by the intermediate value theorem. Intuitively, it says that if you are moving continuously along a road, and you get from point A to point B, then you must also visit every other point along the road; only by teleporting (by moving discontinuously) could you avoid doing so. More formally, the theorem states that if y is a continuous real-valued function on the real interval from a to b, and if y takes on values y_1 and y_2 at certain points within this interval, then for any y_3 between y_1 and y_2 , there is some real x in the interval for which y(x)=y_3.

media/image1.png
Figure 3.2
The intermediate value theorem states that if the function is continuous, it must pass through 
 
y_3

The intermediate value theorem seems so intuitively appealing that if we want to set out to prove it, we may feel as though we’re being asked to prove a proposition such as, “a number greater than 10 exists.” If a friend wanted to bet you a six-pack that you couldn’t prove this with complete mathematical rigor, you would have to get your friend to spell out very explicitly what she thought were the facts about integers that you were allowed to start with as initial assumptions. Are you allowed to assume that 1 exists? Will she grant you that if a number n exists, so does n+1? The intermediate value theorem is similar. It’s stated as a theorem about certain types of functions, but its truth isn’t so much a matter of the properties of functions as the properties of the underlying number system. For the reader with a interest in pure mathematics, I’ve discussed this in more detail in The intermediate value theorem and given an abbreviated proof. (Most introductory calculus texts do not prove it at all.)

Example

Show that there is a solution to the equation 10^x+x=1000.

We expect there to be a solution near x=3, where the function f(x)=10^x+x=1003 is just a little too big. On the other hand, f(2)=102 is much too small. Since f has values above and below 1000 on the interval from 2 to 3, and f is continuous, the intermediate value theorem proves that a solution exists between 2 and 3. If we wanted to find a better numerical approximation to the solution, we could do it using Newton’s method, which is introduced in Newton’s method.

Example

Show that there is at least one solution to the equation \textrm{cos }x=x, and give bounds on its location.

This is a transcendental equation, and no amount of fiddling with algebra and trig identities will ever give a closed-form solution, i.e., one that can be written down with a finite number of arithmetic operations to give an exact result. However, we can easily prove that at least one solution exists, by applying the intermediate value theorem to the function x-\textrm{cos }x . The cosine function is bounded between −1 and 1, so this function must be negative for x<-1 and positive for x>1. By the intermediate value theorem, there must be a solution in the interval -1\leq x\leq 1. The graph, c, verifies this, and shows that there is only one solution.

media/image2.png
Figure 3.3

x- \textrm{cos }x constructed in Example.

Example

Prove that every odd-order polynomial P with real coefficients has at least one real root x , i.e., a point at which P(x)=0.

Example might have given the impression that there was nothing to be learned from the intermediate value theorem that couldn’t be deter- mined by graphing, but this example clearly can’t be solved by graphing, because we’re trying to prove a general result for all polynomials.

To see that the restriction to odd orders is necessary, consider the polynomial x^2+1, which has no real roots because x^2>0 for any real number x.

To fix our minds on a concrete example for the odd case, consider the polynomial P(x)=x^3-x+17. For large values of x, the linear and constant terms will be negligible compared to the x^3 term, and since x^3 is positive for large values of x and negative for large negative ones, it follows that P is sometimes positive and sometimes negative.

Making this argument more general and rigorous, suppose we had a polynomial of odd order n that always had the same sign for real x. Then by the transfer principle the same would hold for any hyperreal value of x. Now if x is infinite then the lower-order terms are infinitesimal compared to the x^n term, and the sign of the result is determined entirely by the x^n term, but x^n and (-x)^n have opposite signs, and therefore P(x) and P(-x) have opposite signs. This is a contradiction, so we have disproved the assumption that P always had the same sign for real x. Since P is sometimes negative and sometimes positive, we conclude by the intermediate value theorem that it is zero somewhere.

Example

Show that the equation x=\textrm{sin } 1/x has infinitely many solutions.

This is another example that can’t be solved by graphing; there is clearly no way to prove, just by looking at a graph like d, that it crosses the x axis infinitely many times. The graph does, however, help us to gain intuition for what’s going on. As x gets smaller and smaller, 1/x blows up, and \textrm{sin }1/x oscillates more and more rapidly. The function f is undefined at 0, but it’s continuous everywhere else, so we can apply the intermediate value theorem to any interval that doesn’t include 0.

We want to prove that for any positive u, there exists an x with 0<x<u for which f(x) has either desired sign. Suppose that this fails for some real u. Then by the transfer principle the nonexistence of any real x with the desired property also implies the nonexistence of any such hyperreal x. But for an infinitesimal x the sign of f is determined entirely by the sine term, since the sine term is finite and the linear term infinitesimal. Clearly \textrm{sin }1/x can’t have a single sign for all values of x less than u, so this is a contradiction, and the proposition succeeds for any u. It follows from the intermediate value theorem that there are infinitely many solutions to the equation.

media/image3.png
Figure 3.4 The function

x-\textrm{sin }1/x