Skip to content
Topos Uranos

The theorems of Fermat, Rolle, Lagrange and Cauchy

Summary

This lesson moves from what the derivative says at a point to what it says on an interval. It defines local extrema and proves Fermat’s theorem: if a function attains a local extremum at an interior point of its domain and is differentiable there, its derivative vanishes; the proof comes from the proposition on the sign of the derivative at a point, from the lesson on rates of change. Together with the Weierstrass theorem, from the preceding lesson, Fermat yields Rolle’s theorem; Rolle, applied to the difference between the function and its chord, yields Lagrange’s mean value theorem, according to which some tangent is parallel to the chord; and, applied to a combination of two functions, Cauchy’s mean value theorem, with which the following lesson will prove L’Hôpital’s rule. From the mean value theorem follow the first global consequences: a function with zero derivative on an interval is constant, two functions with the same derivative differ by a constant, a bound on the derivative bounds the increments, between two roots of a function there is a root of its derivative, and the limit of the derivative, if it exists, is the derivative. Simple examples show that no hypothesis of the theorems can be dropped.

Learning objectives

  1. Express with quantifiers what a local extremum is, and prove Fermat’s theorem, distinguishing the necessary condition it gives from a sufficient condition.
  2. Prove Rolle’s theorem, Lagrange’s mean value theorem and Cauchy’s mean value theorem, read them on the graph and show with counterexamples that their hypotheses cannot be dropped.
  3. Deduce from the mean value theorem that a function with zero derivative on an interval is constant, and obtain inequalities and error bounds from a bound on the derivative.
  4. Count the roots of an equation, bounding their number from above with Rolle’s theorem and from below with Bolzano’s theorem.

Local extrema and Fermat’s theorem

The lesson on the Weierstrass theorem guarantees that a function continuous on a closed and bounded interval attains its maximum and its minimum, but does not say where. To locate them, it helps to have a notion that only looks near the point: a value can be the largest among the nearby ones without being the largest of all.

DefinitionLocal extremum and interior point

Let ff be a function defined on a set AA and x0x_0 an element of AA. We say that ff attains a local maximum at x0x_0 if there exists a δ>0\delta > 0 such that no value of ff at the points of AA whose distance from x0x_0 is less than δ\delta exceeds f(x0)f(x_0), and that it attains a local minimum at x0x_0 if none of those values is less than f(x0)f(x_0):

(∃δ>0)(∀x∈A)(∣x−x0∣<δ→f(x)≤f(x0)),(∃δ>0)(∀x∈A)(∣x−x0∣<δ→f(x0)≤f(x))(\exists \delta > 0)(\forall x \in A)\left(\abs{x - x_0} < \delta \rightarrow f(x) \leq f(x_0)\right), \qquad (\exists \delta > 0)(\forall x \in A)\left(\abs{x - x_0} < \delta \rightarrow f(x_0) \leq f(x)\right)

A local extremum is a local maximum or a local minimum. The point x0x_0 is an interior point of AA if there exists an r>0r > 0 such that (x0−r,x0+r)⊆A\ioo{x_0 - r}{x_0 + r} \subseteq A.

If ff attains its maximum on AA at the point x0x_0, in the sense of the preceding lesson, it attains a local maximum there, with any δ\delta; the converse is false. Consider f(x)=x3−3xf(x) = x^3 - 3x. Since 2−f(x)=(x+1)2(2−x)2 - f(x) = (x + 1)^2 (2 - x), we have f(x)≤2=f(−1)f(x) \leq 2 = f(-1) for every x≤2x \leq 2: the function attains at −1-1 a local maximum, with δ=3\delta = 3, which is not its maximum on R\mathbb{R}, because f(3)=18f(3) = 18. The interior points of an interval are all its points except the endpoints that belong to it; those of [a,b]\icc{a}{b} are those of (a,b)\ioo{a}{b}. A local extremum can lie on the boundary: the function xx, on [0,1]\icc{0}{1}, attains its minimum at 00 and its maximum at 11.

TheoremFermat’s theorem

Let ff be a function defined on a set AA and aa an interior point of AA. If ff attains at aa a local extremum and is differentiable at aa, then f′(a)=0f'(a) = 0. If the derivative were positive, the proposition on the sign of the derivative would place to the right of aa, very close to it, values greater than f(a)f(a); if it were negative, it would place them to the left. The figure shows, with f(x)=x3−3xf(x) = x^3 - 3x and its local maximum at a=−1a = -1, why neither of the two slopes is possible.

Proof

  1. x∈A, ∣x−a∣<δ0→f(x)≤f(a),F′(a)=f′(a)x \in A, \ \abs{x - a} < \delta_0 \rightarrow \dato{max}{f(x) \leq f(a)}, \qquad \resaltar{F'(a) = f'(a)}

    Suppose first that ff attains at aa a local maximum, with some δ0>0\delta_0 > 0, and let r>0r > 0 be such that the interval I=(a−r,a+r)I = \ioo{a - r}{a + r} is contained in AA. Let FF be the restriction of ff to II. Every xx of AA with ∣x−a∣<r\abs{x - a} < r lies in II; by the lemma on the local character of the derivative, from the lesson on differentiation rules, FF is differentiable at aa, with the same derivative.

  2. f(a+ρ2)>f(a),f(a+ρ2)≤f(a)f\left(a + \frac{\rho}{2}\right) > f(a), \qquad \resaltar{f\left(a + \frac{\rho}{2}\right) \leq f(a)}

    If f′(a)>0f'(a) > 0, the proposition on the sign of the derivative at a point, from the lesson on rates of change, applied to FF on the open interval II, gives a δ>0\delta > 0 such that f(x)>f(a)f(x) > f(a) for every xx of II with a<x<a+δa < x < a + \delta. Let ρ\rho be the smallest of the numbers δ\delta, δ0\delta_0 and rr. The point a+ρ2a + \frac{\rho}{2} lies in II, satisfies that condition and its distance from aa is less than δ0\delta_0: its value would be at the same time greater than f(a)f(a) and not greater. Therefore, f′(a)>0f'(a) > 0 is impossible.

  3. f(a−ρ2)>f(a),f(a−ρ2)≤f(a)→f′(a)=0f\left(a - \frac{\rho}{2}\right) > f(a), \qquad f\left(a - \frac{\rho}{2}\right) \leq f(a) \qquad \rightarrow \qquad \resaltar{f'(a) = 0}

    If f′(a)<0f'(a) < 0, the same proposition, with the inequalities between the values reversed, gives a δ>0\delta > 0 such that f(x)>f(a)f(x) > f(a) for every xx of II with a−δ<x<aa - \delta < x < a, and the point a−ρ2a - \frac{\rho}{2} produces the same contradiction. Since the derivative is neither positive nor negative, it is zero.

  4. (−f)′(a)=−f′(a)=0→f′(a)=0(-f)'(a) = -f'(a) = 0 \rightarrow \resaltar{f'(a) = 0}

    If ff attains at aa a local minimum, −f-f attains a local maximum there, and it is differentiable at aa, with derivative −f′(a)-f'(a), by the theorem on the derivative of a linear combination, from the lesson on differentiation rules. By what has already been proved, that derivative is zero.

The theorem gives a necessary condition, not a sufficient one: x3x^3 has zero derivative at 00 and attains no local extremum there, because it takes negative values to the left of 00 and positive values to the right. The other two hypotheses cannot be dropped either. If aa is not interior, the derivative may fail to vanish: the function xx, on [0,1]\icc{0}{1}, attains its maximum at 11, and its derivative there, which is the limit of the difference quotient from the left because the domain has no points to the right of 11, equals 11. If ff is not differentiable at aa, the theorem says nothing: ∣x∣\abs{x} attains its minimum at 00, where it is not differentiable. Therefore, the local extrema of a function are sought among the interior points at which the derivative vanishes, the points at which it is not differentiable and the points that are not interior; the lesson on monotonicity will give them a name and a test for deciding which of them are extrema. Solved problem 1 of the lesson on differentiation rules observed that the horizontal tangents of xx2+1\frac{x}{x^2 + 1} touch the graph at its largest and smallest values, and announced that this was not a coincidence: a function differentiable on R\mathbb{R} that attains its maximum attains it at an interior point, where Fermat’s theorem makes the derivative vanish.