$f(x)$ monotonic integrable function and $\lim_{x\to \infty}\frac{1}{x}\int_{0}^{x}f(t)dt=a$, Prove: $\lim_{x\to \infty}f(x)=a$ Let $f(x)$ be a monotonic increasing function on $[0,\infty)$ and for every $x>0$ it is integrable in $[0,x]$, so that $\lim_{x\to \infty}\frac{1}{x}\int_{0}^{x}f(t)dt=a$. I need to prove that  $\lim_{x\to \infty}f(x)=a$.
I tried to use the limit definition:
$|\frac{1}{x}\int_{0}^{x}f(t)dt -a|<\epsilon$ and to use the fact that $\int_{0}^{x}f(t)dt\geq x\inf f(x)$, but I can't see how does it help me eventually. 
I would love your help with this.
Thanks a lot!
 A: Here's a proof sketch:


*

*If $f$ is unbounded from above, then show that $\frac1x \int_{0}^{\infty} f(x) ~dx \to +\infty$, as $x \to \infty$ (which, of course, contradicts the hypothesis). This shows that $f$ is bounded above. 

*Define $b := \sup \{ f(x) \ :\ x \geqslant 0 \}$. (This indeed exists and is real, thanks to (1.).) Now, using the hypothesis that $f$ is monotone increasing, show that $f(x) \to b$ as $x \to \infty$. 

*If $f(x) \to b$ as $x \to \infty$, then show that $\frac1x \int_{0}^{\infty} f(x) ~dx \to b$. 

*From (3.) and the given hypothesis, since the limit of a function is always unique, conclude that $b = a$. Therefore, from (2.), conclude that $f(x) \to a$ as $x \to \infty$.

Note. It might be possible to simplify the proof by not discussing the unbounded case separately, but I deal with it separately because it helps me focus on the more interesting parts later. If it helps intuition, you could ignore (1.) initially and then come back to it after the rest of the proof.
A: For increasing $f$:
For $b$ fixed, we have  $\lim\limits_{x\rightarrow\infty}{1\over x}\int_0^b f =0$. From this and your hypothesis, we have
  $\lim\limits_{x\rightarrow\infty}{1\over x}\int_b^x f =a$.  
Now: $$
\tag{1}{f(b)\over x}(x-b)\le {1\over x}\int_b^x f\le  {f(x)\over x}(x-b). $$
Taking the limit as $x$ tends to infinity on both sides of the first inequality in (1) gives
$$
f(b)\le a .
$$
This is true for all $b$; thus, since $f$ is monotone, $\lim\limits_{x\rightarrow\infty} f(x)$ exists and
$$
\tag{2}\lim_{x\rightarrow\infty} f(x)\le a.
$$
Taking the limit as $x$ tends to infinity of both sides of the second inequality in (1) now produces
 $$
  a\le \lim_{x\rightarrow\infty}{f(x)};
$$
whence the result follows.
A: A simple interpretation:
Since if $F'(x) = f(x)$, then $$\int\limits_0^x f(t) dt = F(x)-F(0)$$ write the problem as
$$\lim\limits_{x \to \infty} \frac{F(x)-F(0)}{x}=a$$
Since $f$ is integrable in $[0,x)$, $F(0)$ must be finite, so that
$$\lim\limits_{x \to \infty} \frac{F(x)}{x}=a$$
this means that $F(x)$ is approaches $a \cdot x$ asymptotically for $x$ sufficiently large, so that
$$f(x) = F'(x) \to a  \text{ for } x \to \infty$$
You might also want to go $\Leftarrow$ and prove that the limit in the problem exists only if $f$ is bounded as $x \to \infty$.
