Sign in

Libre University uses your GitHub account. Signing in is only needed to sit a final test, so the score is kept on your profile.

The Mean Value Theorem

A derivative is a statement about a single point, and almost everything anyone wants to conclude from it is a statement about an interval, so a theorem is needed to carry the information across.

The previous lesson used two such conclusions without proof: that a function rises wherever its derivative is positive, and that concavity follows the sign of the second derivative. Both are consequences of one theorem, which also delivers the result the second half of this course is built on, that two functions with equal derivatives differ by a constant. This lesson proves it and then spends the rest of its length collecting what falls out.

Rolle's theorem

Start with the special case. Suppose f is continuous on the closed interval [a,b], differentiable on the open interval between, and f(a)=f(b). Then there is at least one point c strictly between a and b with f(c)=0.

The proof uses two earlier theorems and nothing else. By the Extreme Value Theorem, f attains a maximum and a minimum on [a,b]. If both occur at the endpoints, then the largest and smallest values of f are equal, so f is constant and its derivative vanishes everywhere in between. Otherwise at least one of them occurs at an interior point c, and by Fermat's theorem, an interior extreme of a differentiable function has f(c)=0.

That is the whole argument, and its shape is worth noticing: continuity supplies existence, differentiability supplies the equation. Michel Rolle published the result in 1691, which is a mild historical joke, since Rolle spent the same decade denouncing the infinitesimal calculus as a collection of ingenious fallacies. He was right about the reasoning of the time and wrong about the conclusions.

The Mean Value Theorem

The general version drops the condition f(a)=f(b) and tilts the conclusion by the same amount. If f is continuous on [a,b] and differentiable in between, there is a point c with

f(c)=f(b)-f(a)b-a

In words: somewhere in the interval the instantaneous rate of change equals the average rate of change over the whole interval. Geometrically, some tangent is parallel to the chord joining the endpoints.

The proof is Rolle's theorem applied to a tilted copy of f. Let L(x) be the straight line through the two endpoints, and set g(x)=f(x)-L(x), the vertical gap between the curve and the chord. Then g is continuous and differentiable wherever f is, and g(a)=g(b)=0 because the chord meets the curve at both ends. Rolle gives a point c with g(c)=0, and since L is a line with slope (f(b)-f(a))/(b-a), that says precisely f(c)=(f(b)-f(a))/(b-a).

The theorem is an existence statement: it promises a c and gives no way to find one, and there may be several. That is enough for everything it is used for, which is a recurring pattern in analysis.

There is a legal application, which is the clearest illustration of what the theorem says. Average speed enforcement on motorways photographs a vehicle at two points and divides the distance by the time. If a car covers 180 km in two hours, its average speed was 90 km/h, and the Mean Value Theorem says that at some instant the speedometer read exactly 90. The camera never observed that instant and does not need to: the mathematics guarantees it happened.

Example. Find a point satisfying the Mean Value Theorem for f(x)=x3-x on [0,2].

The endpoint values are f(0)=0 and f(2)=6, so the average slope is 3. The derivative is f(x)=3x2-1, and setting it equal to 3 gives x2=4/3, so c=1.1547, which lies in the interval as promised. The negative root, -1.1547, also satisfies the equation but is outside the interval and is not what the theorem is about.

Now you. Find a point satisfying the theorem for f(x)=x on [1,4].

Answer

The average slope is (2-1)/(4-1)=1/3. The derivative is 1/(2x), so 1/(2c)=1/3 gives c=1.5 and c=2.25.

What a zero derivative means

The first corollary looks too small to be worth stating and is the most important result in the lesson.

If f(x)=0 at every point of an interval, then f is constant on that interval. Here is the proof: take any two points p<q in the interval and apply the Mean Value Theorem to [p,q]. It gives a c with f(q)-f(p)=f(c)(q-p)=0, so f(q)=f(p). Since the two points were arbitrary, every value is the same value.

The statement cannot be proved without a theorem of this kind. Knowing the derivative is zero at each point separately says only that the function is momentarily flat at each point, and it takes the Mean Value Theorem to rule out a function that is flat everywhere and still manages to move. The hypothesis that the domain is an interval is also load-bearing: the function equal to 0 for x<0 and 1 for x>0 has zero derivative throughout its domain and is not constant, because its domain is in two pieces.

The second corollary follows immediately. If f(x)=g(x) everywhere on an interval, apply the first corollary to f-g, whose derivative is zero. So

f(x)=g(x)+C

for some constant C. Two functions with the same derivative differ by a constant and by nothing else.

This is the fact that makes the second half of the subject possible. It says that a derivative determines its function completely except for one number, so the question "which function has derivative 2x" has the answer "x2, plus a constant, and nothing else". Without it, running differentiation backwards would be hopeless, since there would be no way to know whether a discovered answer was the only one.

Rising, falling, and bending

The remaining corollaries retire the debts of the previous lesson.

If f>0 throughout an interval, then f is increasing on it. Proof: for any p<q in the interval, the Mean Value Theorem gives f(q)-f(p)=f(c)(q-p), in which both factors are positive, so f(q)>f(p). If f<0 the same argument gives decreasing. That is the first derivative test justified, and with it every sign chart drawn in the optimisation lesson.

Applying the same result to f instead of f justifies the concavity reading. If f′′>0 on an interval then f is increasing there, so the tangent slopes get steeper as x increases, which is what it means for a curve to bend upward. The second derivative test follows: at a critical point with f′′>0, the slope is negative just before and positive just after, so the first derivative test gives a local minimum.

The theorem also produces inequalities, which is a use that is easy to overlook. Since |cosc|1 for every c, the Mean Value Theorem applied to the sine gives |sinq-sinp|=|cosc||q-p||q-p|. So the sine function never changes faster than its argument, which is a bound valid for all real numbers, obtained from one fact about the derivative. Bounds of exactly this kind are what numerical analysis runs on.

The tangent line as an approximation

Near a point where a function is differentiable, the tangent line is a good approximation to the curve, and the Mean Value Theorem says how good. Write the linearisation of f at a:

L(x)=f(a)+f(a)(x-a)

The theorem gives f(x)-f(a)=f(c)(x-a) for some c between a and x, so the error f(x)-L(x) equals [f(c)-f(a)](x-a). Whenever the derivative varies slowly, that product is small, and it shrinks faster than x-a does, since the bracket also shrinks as x approaches a.

Example. Estimate 4.1 using the tangent line at x=4, and compare with the true value.

With f(x)=x we have f(4)=2 and f(4)=1/(2×2)=0.25, so L(4.1)=2+0.25×0.1=2.025. The true value is 2.0248457, so the estimate is high by 0.00015, an error of about 0.008 per cent from arithmetic that can be done in the head.

Now you. Estimate (1.02)10 using the tangent line at x=1, and compare.

Answer

With f(x)=x10, f(1)=1 and f(1)=10, so L(1.02)=1+10×0.02=1.2. The true value is 1.218994, so the linear estimate is low by about 1.6 per cent. The error is much larger here than in the square root case because the second derivative, 90x8, is large: the curve pulls away from its tangent quickly.

The pattern in those two errors is that the accuracy depends on how fast the slope is changing, which suggests including the second derivative in the approximation and then the third, and that idea is carried through in the last lesson of the course.

L'Hôpital's rule

One more consequence of the Mean Value Theorem deserves its own name, because it disposes of indeterminate forms that no algebraic trick will touch.

If f(a)=g(a)=0, both are differentiable near a, and g0 nearby, then

limxaf(x)g(x)=limxaf(x)g(x)

whenever the right side exists. The same holds for the / form and for limits at infinity. The proof uses a two-function version of the Mean Value Theorem due to Cauchy, in which the ratio of the two average rates equals the ratio of the two derivatives at a common point; the argument is short but adds nothing to the picture, so it is quoted here rather than derived. The rule appeared in the first calculus textbook, published by the Marquis de l'Hôpital in 1696, and was in fact discovered by Johann Bernoulli, whom l'Hôpital paid for the material.

Two limits from earlier lessons fall out at once. For (sinx)/x at zero, differentiating top and bottom gives cosx/11, matching the geometric squeeze, though it would be circular to use this as the proof, since the derivative of the sine was obtained from that limit. For (ex-1)/x the rule gives ex/11.

Example. Evaluate limx01-cosxx2.

Substituting gives 0/0. One application gives lim(sinx)/(2x), still 0/0, so apply it again: lim(cosx)/2=1/2. Numerically, at x=0.001 the original expression is 0.49999996, confirming it. This limit is why a pendulum's period barely changes for small swings, and it will reappear in the Taylor lesson as the second term of the cosine series.

Now you. Evaluate limx0sinx-xx3.

Answer

Three applications are needed, since each stage is still 0/0: first (cosx-1)/(3x2), then -sinx/(6x), then -cosx/6, which tends to -1/6. At x=0.01 the original expression is -0.1666658.

The rule has one failure mode, and it is common. It applies only to indeterminate forms, and applying it elsewhere gives confident nonsense. Take limx1(x2+x)/(x+1): the limit is plainly 2/2=1 by substitution, but differentiating top and bottom gives (2x+1)/13. Nothing warns you. The check is to confirm the form is 0/0 or / before each application, including the second and third.

Backwards

The corollary about constants leaves an obvious question hanging. If a derivative determines its function up to one number, then the process ought to be reversible: given a rate of change, recover the quantity.

That question has an answer, and there is a second, apparently unrelated question with the same answer. The area problem from the first lesson has been left untouched since then, and it is about to be defined properly, as a limit of sums rather than a search for a function with a given derivative. That the two turn out to be the same operation is the central theorem of the subject, and the next two lessons build to it.