Prove that $\lim_{x\rightarrow \infty} \frac{1}{x}\int_0^x f(t)dt=c \mbox{.}$

Let $\epsilon > 0$. Since $\lim\limits_{x\to \infty} f(x) = c$, there exists a positive number $M$ such that $|f(x) - c| < \epsilon$ for all $x \ge M$. So since

$$\frac{1}{x}\int_0^x f(t)\, dt - c = \frac{1}{x}\int_0^x f(t)\, dt - \frac{1}{x}\int_0^x c\, dt = \frac{1}{x}\int_0^x [f(t) - c]\, dt,$$

by the triangle inequality

$$\left|\frac{1}{x}\int_0^x f(t)\, dt - c\right| \le \frac{1}{x}\int_0^M |f(t) - c|\, dt + \frac{1}{x}\int_M^x |f(t) - c|\, dt.\tag{*}$$

whenever $x \ge M$. Since $M$ is a constant the first integral on the right of (*) tends to $0$ as $x\to \infty$. The second integral is bounded by $\left(1 - \frac{M}{x}\right)\epsilon$ for $x\ge M$. Using these facts, you can finish the proof.


For any $\varepsilon >0$ there exists $a_\varepsilon$ such that $x > a_\varepsilon$ implies $|f(x) - c| < \varepsilon$. Now for such an $x$ we have \begin{align} \frac{1}{x} \int_0^x f(t) \, dt &= \frac{1}{x} \left( \int_0^{a_\varepsilon} f(t) \, dt + \int_{a_\varepsilon}^x f(t) \, dt \right) \\ &= \frac{C_{a_\varepsilon}}{x} + \frac{1}{x} (x-{a_\varepsilon}) f(\xi_{a_\varepsilon,x}) \\ &= \frac{C_{a_\varepsilon}}{x} + \frac{x-{a_\varepsilon}}{x} f(\xi_{a_\varepsilon,x})\,, \end{align} where $C_{a_\varepsilon}$ is some constant and $\xi_{a_\varepsilon,x} \in ({a_\varepsilon}, x)$. By definition of $a_\varepsilon$ we then have $|f(\xi_{a_\varepsilon,x})-c| < \varepsilon$, so $$ \left| \frac{1}{x} \int_0^x f(t) \, dt-c \right| \leq \left| \frac{C_{a_\varepsilon}}{x} \right| + \left| \frac{x-a_\varepsilon}{x} \right| \left| f(\xi_{a_\varepsilon,x})-c \right| < \left| \frac{C_{a_\varepsilon}}{x} \right| + \left| \frac{x-a_\varepsilon}{x} \right| \varepsilon $$ Now by taking $\lim_{x \to \infty}$ from both sides we get $|\frac{1}{x} \int_0^x f(t) \, dt-c| < \varepsilon$ for any $\varepsilon > 0$.


Think about what this is saying: the average value of $f$ on $[0,\infty)$ must be the limit $\lim_{x\rightarrow\infty}f(x)=c$. It can be proved without too much difficulty by splitting the integral (in this case you don't even need $f$ to be continuous).

Elaborating, $f(x)$ is eventually close to $c$, say within $\epsilon$ after $N$, so writing $$ \lim_{x\rightarrow\infty}\frac{1}{x}\int_0^xf(t)dt=\lim_{x\rightarrow\infty}\frac{1}{x}\int_0^Nfdt+\lim_{x\rightarrow\infty}\frac{1}{x}\int_N^xfdt,$$ (assuming the limit exists so we can use linearity of $\lim$). The first integral obviously goes to zero, and the second integral can be estimated by, say $$N-\epsilon\leq\frac{1}{x}\int_N^xfdt\leq N+\epsilon.$$

Think about how this last inequality has to hold...