Rolle's Theorem Questions and Examples

Examples, Graphical Interpretations, and Practice Questions

Rolle's theorem is a special case of the mean value theorem. It is discussed here through examples and questions.

In what follows, \( C \) represents the constant of integration where applicable.

Rolle's Theorem

Rolle's theorem is a direct consequence of the mean value theorem where, under the conditions that \( f(x) \) is a continuous function on the interval \( [a, b] \) and differentiable on the open interval \( (a, b) \), there exists at least one value \( c \) of \( x \) such that:

\[ f'(c) = \dfrac{f(b) - f(a)}{b - a} \]

Now, if the condition \( f(a) = f(b) \) is also satisfied, then the above simplifies to: \( f'(c) = 0 \).

In other words, under these three conditions, we can always find a tangent to the curve of \( f \) that is horizontal (slope = \( f'(c) = 0 \)).

Rolle's Theorem

If \( f(x) \) is:
1) a continuous function on the interval \( [a, b] \)
2) differentiable on the open interval \( (a, b) \)
3) and \( f(a) = f(b) \)

then there is at least one value \( c \) of \( x \) in the interval \( (a, b) \) such that: \[ f'(c) = 0 \]

Examples with Detailed Solutions

Click on each example to view its detailed step-by-step solution.

Example 1

The graph of \( f(x) = -x^2 + 6x - 6 \) for \( 1 \le x \le 5 \) is shown below. \( f(1) = f(5) = -1 \) and \( f \) is continuous on \( [1, 5] \) and differentiable on \( (1, 5) \), hence, according to Rolle's theorem, there exists at least one value of \( x = c \) such that \( f'(c) = 0 \).

Show Solution to Example 1
\[ f'(x) = -2x + 6 \] \[ f'(c) = -2c + 6 = 0 \]

Solve the above equation to obtain:

\[ c = 3 \]

Therefore, at \( x = 3 \), there is a tangent to the graph of \( f \) that has a slope equal to zero (horizontal line) as shown in Figure 1 below.

use of Rolle's theorem example 1
Figure 1. Rolle's Theorem, Example 1

Example 2

The graph of \( f(x) = \sin(x) + 2 \) for \( 0 \le x \le 2\pi \) is shown below. \( f(0) = f(2\pi) = 2 \) and \( f \) is continuous on \( [0, 2\pi] \) and differentiable on \( (0, 2\pi) \), hence, according to Rolle's theorem, there exists at least one value (there may be more than one!) of \( x = c \) such that \( f'(c) = 0 \).

Show Solution to Example 2
\[ f'(x) = \cos(x) \] \[ f'(c) = \cos(c) = 0 \]

The above equation has two solutions on the interval \( [0, 2\pi] \):

\[ c_1 = \dfrac{\pi}{2} \quad \text{and} \quad c_2 = \dfrac{3\pi}{2} \]

Therefore, at both \( x = \dfrac{\pi}{2} \) and \( x = \dfrac{3\pi}{2} \), there are tangents to the graph that have a slope equal to zero (horizontal lines) as shown in Figure 2 below.

use of Rolle's theorem example 2, two tangents
Figure 2. Rolle's Theorem, Example 2 with two tangents

Example 3

Function \( f \) in Figure 3 does not satisfy Rolle's theorem: although it is continuous and \( f(-1) = f(3) \), the function is not differentiable at \( x = 1 \), and therefore \( f'(c) = 0 \) with \( c \) in the interval \( (-1, 3) \) is not guaranteed. In fact, it is easy to see that there is no horizontal tangent to the graph of \( f \) on the interval \( (-1, 3) \).

Graphs of a function with at least one of the conditions not satisfied
Figure 3. Graph of function that does not satisfy the condition of differentiability in Rolle's Theorem

Practice Questions with Detailed Solutions

Click on each question to view its detailed step-by-step solution.

Question 1

Which of the functions given below satisfy all three conditions of Rolle's theorem?

a) \( f(x) = \cos(x) \), for \( x \) in \( [0, 2\pi] \)
b) \( g(x) = |x - 2| \), for \( x \) in \( [0, 4] \)
c) \( h(x) = \dfrac{1}{x^2} \), for \( x \) in \( [-1, 1] \)
d) \( k(x) = |\sin(x)| \), for \( x \) in \( [0, 2\pi] \)

Show Solution to Question 1

a) \( f(0) = 1 \) and \( f(2\pi) = 1 \), therefore \( f(0) = f(2\pi) \). \( f \) is continuous on \( [0, 2\pi] \) and differentiable in \( (0, 2\pi) \). Function \( f \) satisfies all conditions of Rolle's theorem.

b) Function \( g \) has a V-shaped graph with a vertex at \( x = 2 \) and is therefore not differentiable at \( x = 2 \). Function \( g \) does not satisfy all conditions of Rolle's theorem.

c) Function \( h \) is undefined at \( x = 0 \). Function \( h \) does not satisfy all conditions of Rolle's theorem.

d) \( k(x) = |\sin(x)| \) for \( x \) in \( [0, 2\pi] \). The graph of function \( k \) is shown below and reveals that function \( k \) is not differentiable at \( x = \pi \). Function \( k \) does not satisfy all conditions of Rolle's theorem.

Graph of k(x) = |sin(x)| , for x in [0 , 2π]
Figure 4. Graph of \( k(x) = |\sin(x)| \), for \( x \) in \( [0, 2\pi] \)

Question 2

Check that function \( f(x) = x^2 - 4x + 3 \) on the interval \( [1, 3] \) satisfies all conditions of Rolle's theorem, and then find all values of \( x = c \) such that \( f'(c) = 0 \).

Show Solution to Question 2

\( f \) is a polynomial function and is therefore continuous on the interval \( [1, 3] \) and differentiable on the interval \( (1, 3) \). Also, \( f(1) = f(3) = 0 \), and therefore function \( f \) satisfies all three conditions of Rolle's theorem, ensuring at least one value of \( x = c \) exists such that \( f'(c) = 0 \).

\[ f'(x) = 2x - 4 \] \[ f'(c) = 2c - 4 = 0 \implies c = 2 \]

The graph below shows \( f \), and the tangent at \( x = c = 2 \) is horizontal with \( f'(2) = 0 \).

use of Rolle's theorem question 2, f(x) = x^2 - 4x + 3
Figure 5. Rolle's Theorem, Question 2, \( f(x) = x^2 - 4x + 3 \)

Question 3

Check that function \( g(x) = \cos(x) \) on the interval \( \left[-\dfrac{\pi}{2}, \dfrac{3\pi}{2}\right] \) satisfies all conditions of Rolle's theorem, and then find all values \( x = c \) such that \( g'(c) = 0 \).

Show Solution to Question 3

Function \( g \) is a cosine function and is therefore continuous on the interval \( \left[-\dfrac{\pi}{2}, \dfrac{3\pi}{2}\right] \) and differentiable on the interval \( \left(-\dfrac{\pi}{2}, \dfrac{3\pi}{2}\right) \). Also:

\[ g\left(-\dfrac{\pi}{2}\right) = g\left(\dfrac{3\pi}{2}\right) = 0 \]

Therefore, function \( g \) satisfies all three conditions of Rolle's theorem, and there is at least one value of \( x = c \) such that \( g'(c) = 0 \).

\[ g'(x) = -\sin(x) \] \[ g'(c) = -\sin(c) = 0 \implies c = n\pi, \quad n = 0, \pm 1, \pm 2, \dots \]

Solutions on the interval \( \left[-\dfrac{\pi}{2}, \dfrac{3\pi}{2}\right] \) are:

\[ c_1 = 0 \quad \text{and} \quad c_2 = \pi \]

The graph below shows \( g \) and the tangents at \( x = c_1 = 0 \) and \( x = c_2 = \pi \) are horizontal, with \( g'(0) = 0 \) and \( g'(\pi) = 0 \).

use of Rolle's theorem question 3 , g(x) = cos(x)
Figure 6. Rolle's Theorem, Question 3, \( g(x) = \cos(x) \)

More References and Links