Why can we only talk about derivatives on an open interval?

Solution 1:

As @PeterFrank says in the comments, one can talk about so-called one-sided differentiability in the end points, e.g.

$$ f'(a)=\lim_{h \downarrow 0} \frac{f(a+h)-f(a)}{h}. $$

But the point is that if you only assume that $f$ has to be differentiable on $(a,b)$, the theorem is better/stronger.

For example, we can apply Rolle to $x\mapsto \sqrt{x}$ on $[0,1]$, although this map is not one-sidedly differentiable in $0$.

If you would assume that $f$ has to be differentiable on $[0,1]$, you could not apply Rolle in this case.