Rolle's Theorem
Let \( f(x) \) be a function that is continuous on the closed interval \([a,b]\) and differentiable on the open interval \( (a,b) \). If \( f(a)=f(b) \), then there exists at least one point \(x_0 \in (a,b)\) such that \[ f'(x_0)=0 \]
In simple terms, if a smooth curve starts and ends at the same height, there must be at least one point between the endpoints where the tangent is horizontal.
This theorem is one of the fundamental results of differential calculus and serves as the basis for several important theorems, including the Mean Value Theorem.
A Simple Example
Consider the function
\[ f(x)=x^2-1 \]
on the interval \( [-1,1] \).
At the endpoints, the function has the same value:
\[ f(-1)=0 \]
\[ f(1)=0 \]
The function is continuous on the interval and differentiable at every interior point, so all the hypotheses of Rolle's Theorem are satisfied.
Now compute the derivative:
\[ f'(x)=2x \]
To find where the tangent is horizontal, set the derivative equal to zero:
\[ 2x=0 \]
Solving the equation gives
\[ x=0 \]
Since \(0\) belongs to the interval \((-1,1)\), Rolle's Theorem guarantees the existence of this interior point where
\[ f'(0)=0 \]
Proof
Let \(f\) be continuous on the closed interval \([a,b]\) and differentiable on the open interval \((a,b)\).
By the Extreme Value Theorem, the function attains both an absolute minimum and an absolute maximum on the interval. Therefore, there exist points \(x_1\) and \(x_2\) such that
$$ f(x_1) \le f(x) \le f(x_2) $$
We now examine the possible cases.
Case 1: An Extremum Lies Inside the Interval
If either the minimum point \(x_1\) or the maximum point \(x_2\) belongs to the open interval \((a,b)\), then that point is an interior extremum.
By Fermat's theorem, the derivative at an interior maximum or minimum must be zero.

Therefore, there exists at least one point \(x \in (a,b)\) such that
$$ f'(x)=0 $$
Case 2: Both Extrema Occur at the Endpoints
Suppose instead that the minimum and maximum are attained only at the endpoints of the interval:
$$ f(x_1)=f(a) $$
$$ f(x_2)=f(b) $$
Since the theorem assumes that
$$ f(a)=f(b) $$
it follows that
$$ f(x_1)=f(x_2) $$
In other words, the absolute minimum and absolute maximum have the same value.
A function whose minimum and maximum coincide must be constant throughout the interval.
Indeed, from
$$ f(x_1) \le f(x) \le f(x_2) $$
and from
$$ f(x_1)=f(x_2) $$
we obtain
$$ f(x_1)=f(x)=f(x_2) \qquad \forall x \in [a,b] $$
Thus, the function is constant on the entire interval.
A constant function has a zero derivative at every interior point:
$$ f'(x)=0 \qquad \forall x \in (a,b) $$

Therefore, there are infinitely many points in \((a,b)\) where the derivative is zero.
Combining the two cases proves that whenever \(f(a)=f(b)\), there is at least one point in the interval \((a,b)\) where
$$ f'(x)=0 $$
Alternative Proof
Another proof can be obtained directly from the existence of an absolute minimum and an absolute maximum.
By the Extreme Value Theorem, there exist points \(x_1\) and \(x_2\) such that
$$ m=f(x_1) $$
$$ M=f(x_2) $$
with
$$ f(x_1) \le f(x) \le f(x_2) $$
Consider the following two possibilities.
Case 1: \(m=M\)
If the minimum and maximum are equal, then the function is constant on the interval:
$$ m=f(x)=M \qquad \forall x \in [a,b] $$
Consequently,
$$ f'(x)=0 \qquad \forall x \in (a,b) $$
Case 2: \(m<M\)
If the minimum and maximum are different, the function cannot be constant.
Because \(f(a)=f(b)\), at least one of the two extrema must occur at an interior point of the interval. Suppose that
$$ x_1 \in (a,b) $$
Since \(f(x_1)=m\) is the minimum value, every sufficiently small increment \(h\) satisfies
$$ f(x_1+h)\ge f(x_1) $$
Subtracting \(f(x_1)\) from both sides gives
$$ f(x_1+h)-f(x_1)\ge0 $$
For \(h>0\), dividing by \(h\) yields
$$ \frac{f(x_1+h)-f(x_1)}{h}\ge0 $$
Taking the limit as \(h\to0^+\), we obtain
$$ \lim_{h\to0^+}\frac{f(x_1+h)-f(x_1)}{h}\ge0 $$
For \(h<0\), dividing by \(h\) reverses the inequality:
$$ \frac{f(x_1+h)-f(x_1)}{h}\le0 $$
Taking the limit as \(h\to0^-\), we obtain
$$ \lim_{h\to0^-}\frac{f(x_1+h)-f(x_1)}{h}\le0 $$
Since \(f\) is differentiable at \(x_1\), the right-hand and left-hand limits must be equal.
The only number that is simultaneously greater than or equal to zero and less than or equal to zero is zero. Therefore,
$$ \lim_{h\to0}\frac{f(x_1+h)-f(x_1)}{h}=0 $$
Hence,
$$ f'(x_1)=0 $$
which completes the proof.
Note. The same reasoning can be applied if the interior extremum is the maximum point \(x_2\) instead of the minimum point \(x_1\).
And so on.
