If $f(x)\rightarrow a$ and $f'(x)\rightarrow b$ as $x\rightarrow\infty$ then $b=0$ Given: $f:\mathbb{R}\rightarrow\mathbb{R}$ is differentiable; $f(x)\rightarrow a$ as $x\rightarrow\infty$; $f'(x)\rightarrow b$ as $x\rightarrow\infty$
Show that $b=0$.
*Proof:
$f'(x)=\lim_{h\rightarrow 0}\frac{f(x+h)-f(x)}{h}$. Given $f'(x)=\lim_{h\rightarrow 0}\frac{f(x+h)-f(x)}{h}\rightarrow b$ as $x\rightarrow\infty$. For all $\epsilon>0$, there exists a $\delta>0$ such that as long as $h$ is within $\delta$ distance away from $0$, $|\frac{f(x+h)-f(x)}{h}-b|<\epsilon$. As $x$ goes to infinity, we have $|b|<\epsilon$.
Anything wrong with my proof? Thanks in advance.
 A: Hint: Take limits on the following equation as $x\to\infty$ $$f(x+1)-f(x)=f'(\xi)\text{ for some }\xi\in(x, x+1)$$
A: Suppose $b\neq 0$. Then lets assume $b>0$ (case for $b<0$ can be considered in a similar manner).
Then by definitions, for any arbitrary 
$\epsilon, \epsilon'>0, \exists A, A' \in \mathbb{R} \ \mbox{such that}$,
$$|f(x)-a|<\epsilon \ \forall x>A, \\ |f'(x)-b|<\epsilon' \ \forall x>A'$$
Take $B:=\mbox{max}\{A, A'\}$ so both of the above are satisfied whenever $x>B$
Now, in particular, if $\epsilon'<b$, then $\forall x>B, \ f'(x)>c$ for some positive real number $c$.
Do you see the problem with this when combining this with the fact that $\forall x>B, |f(x)-a|<\epsilon$?
A: Prove by contradiction. Suppose that $b\neq0$. Without loss of generality
(replacing $f$ with $-f$ if necessary), assume that $b>0$. Then
there exists $M$ such that $f'(x)>\frac{b}{2}$ whenever $x\geq M$.
For any $x>M$, by mean value theorem, we have 
$$
f(x)-f(M)=f'(\xi)(x-M)\geq\frac{b}{2}(x-M),
$$
where $M<\xi<x$. Note that $\lim_{x\rightarrow+\infty}\frac{b}{2}(x-M)=+\infty$.
Therefore $\lim_{x\rightarrow+\infty}f(x)=+\infty$, which is a contradiction
(here, I assume that your $a$ is a real number).
A: Your proof unfortunately doesn't work. The problem is that you write:

For all $\epsilon>0$, there exists a $\delta>0$ such that as long as
  $h$ is within $\delta$ distance away from $0$,
  $|\frac{f(x+h)-f(x)}{h}-b|<\epsilon$.

If you read carefully, you will see that this says that $f'(x) = b$, which is much stronger than the assumption. Even if you tried to remedy this and substitute $b$ with some $b(x)$ that converges to $b$ (well, this $b(x)$ is just $f'(x)$), there is still problem on directly taking limit $x\to \infty$ on that expression. Here is what we do have:
$$(\forall x\in\mathbb R)(\forall \epsilon > 0)(\exists \delta(x,\epsilon)>0)\ |h|<\delta(x,\epsilon)\implies \left|\frac{f(x+h)-f(x)}{h}-b(x)\right|<\epsilon.$$
I want to stress out the importance that $\delta$ is dependent on both $x$ and $\epsilon$. What you'd like to do is take expression 
$$\left|\frac{f(x+h)-f(x)}{h}-b(x)\right|<\epsilon\tag{*}$$
and apply $\lim_{x\to\infty}$ on it. But for that, you need to fix some $h$, and the trouble now is that $(*)$ might just fail along the way because $\delta$ depends on $x$ and nobody can guarantee that $|h|$ won't become greater than $\delta$ at some point, which would make $(*)$ break apart. 
Esentially, what you would like to do is along the lines of commuting the limits, i.e. you would like to do this:
$$\lim_{x\to\infty}\lim_{h\to 0}\frac{f(x+h)-f(x)}{h} = \lim_{h\to 0}\lim_{x\to\infty}\frac{f(x+h)-f(x)}{h} = 0$$ but unfortunately, you can't do this a priori, you must use some special properties of derivative, like mean value theorems.
Let me demonstrate what I mean. Essentially, we are given some function $F(x,h)$ such that $$\lim_{x\to\infty} F(x,h) = 0,\quad \lim_{x\to\infty}\lim_{h\to 0} F(x,h) = b.$$ You can easily check that function $F(x,h) =\frac{b}{hx+1}$ satisfies the above, but $$\lim_{x\to\infty}\lim_{h\to 0} F(x,h) \neq \lim_{h\to 0}\lim_{x\to\infty} F(x,h)$$ when $b\neq 0$. Of, course, we are ignoring the fact that in your problem there is another special requirement, and that is $(x\mapsto \lim_{h\to 0}F(x,h)) = f'$ for some function $f$, but then again, so does your proof.

Here is one cute way to prove the claim.
Since $\lim_{x\to\infty} f'(x)$ exists, by L'Hôpital's rule$^{[1]}$ we have $\lim_{x\to\infty}\frac{f(x)}{x} = \lim_{x\to\infty}f'(x).$
Let $\varepsilon>0$ and $M$ such that $x>M$ implies $|f(x)-a|<\varepsilon$. Then we have $$\frac{a-\varepsilon}{x}<\frac{f(x)}x<\frac{a+\varepsilon}{x}$$ so $\lim_{x\to\infty}\frac{f(x)}x = 0$ follows from squeeze theorem.

$[1]$ Contrary to the popular belief that $\lim_{x\to\infty}\frac{f(x)}{g(x)}$ must be of indeterminate form $\frac{\infty}{\infty}$ (along the other usual assumptions), this is not true. It is sufficient that $\lim_{x\to\infty}g(x) = \infty$, and $\lim_{x\to\infty}f(x)$ doesn't have to exist at all! You can read it in General proof, Case 2 section of Wikipedia article on L'Hôpital's rule.
A: OP proof problem ...

$f'(x)=\lim_{h\rightarrow 0}\frac{f(x+h)-f(x)}{h}$. Given $f'(x)=\lim_{h\rightarrow 0}\frac{f(x+h)-f(x)}{h}\rightarrow b$ as $x\rightarrow\infty$. For all $\epsilon>0$, there exists a $\delta>0$

For all $x$ and for all $\epsilon>0$, there exists $\delta > 0$ ...
Note that $\delta$ may depend on $x$

such that as long as $h$ is within $\delta$ distance away from $0$,  

so  $h$ also depends on $x$

$|\frac{f(x+h)-f(x)}{h}-b|<\epsilon$. As $x$ goes to infinity, we have $|b|<\epsilon$.

Well, for a fixed $h$, as $x \to \infty$ we would get $|b| \le \epsilon$.  But (as noted) $h$ depends on $x$, so this step does not work.
