Rolle's theorem without compact domain hypothesis Good evening everyone,
I'm asking for a proof of "Rolle's theorem generalization". The thesis is as follows:
Let be $a \in \mathbb{R}$ and $f:[a,\infty) \longrightarrow \mathbb{R}$ a continuous function such that $\lim_{{x\to \infty}} {f(x)} = f(a)$. Prove that if the derivative exists in $(a,\infty)$ then $\exists$  $x_0>a$ such that $f'(x)=0$.
I tried to prove that but I wasn't able to do it, so if you can help me I'll appreciate it a lot.
Thank you for your time. 
 A: If there is no point $x_0$ with $f'(x_0) = 0$, then either $f'(x) > 0$ or $f'(x)<0$ for all $x$. WLOG $f'(x) >0$, so the function is strictly increasing. Thus $f(a+1) > f(a)$, and $\forall x: x > a+1 \implies f(x) > f(a+1)$, so $\lim_{x \to \infty} f(x) \ge f(a+1) > f(a)$, a contradiction.
A: Suppose we say the domain is $[a,+\infty],$ an interval closed at both ends, the a basic open neighborhood of $+\infty$ is any interval of the form $(b,+\infty],$ and we define $f(+\infty)$ to be $\lim_{x\to+\infty} f(x) = f(a).$ Then the extreme value theorem applies because topologically the domain $[a,+\infty]$ is the same as any closed bounded interval, and $f$ is continuous on that interval. So let $M= \max_x \left| f(x)\right|$ and we have some point $c\in(a,+\infty)$ for which $f(c) = M.$ Can you show $f'(c) \le 0$ and $f'(c)\ge 0$ by squeezing?
A: Define $g\colon [0,1/a]\to \mathbb{R}$ by
$$
g(x)=\begin{cases}
f(1/x) & x > 0\\
f(a) & x = 0
\end{cases}
$$
By your hypotheses, this function is continuous, and the derivative $g'(x)$ exists on $(0,1/a)$.  Specifically,
$$
g'(x) = -\frac{f'(1/x)}{x^2}\,,
$$
by the chain rule.
By Rolle's Theorem, we know that $g'(x)=0$ for some $x\in (0,1/a)$. It follows from the formula for $g'$ that $f'(1/x)=0$.
