I am trying to prove that if $f:[1,\infty) \to \mathbb{R}$ is a continuous function with $f(x) \to 0$ as $x \to \infty$, then $$\lim_{X \to \infty} \frac{1}{X}\int_1^Xf(x)dx = 0.$$
I am stuck. Here is what I have thought of so far:
- $f$ is continuous, and hence bounded on $[1,X]$.
- $f(x) \to 0$ as $x\to\infty$, so for any $\varepsilon > 0$ there is some $K(\varepsilon) \in \mathbb{R}$ such that $x>K(\varepsilon) \implies |f(x)|<\varepsilon$.
- Since $f$ is continuous on $[1,X]$, there is some $c_X \in [1,X]$ such that $\int_1^Xf(x)dx = (X-1)f(c_X)$. If somehow I can show that $f(c_X)\to 0$ as $X\to\infty$, then that is sufficient to prove the statement.
Let $\varepsilon > 0$. Then since $f(x) \to 0$ as $x \to \infty$, there exists $K_\varepsilon > 1$ such that $x>K_\varepsilon \implies |f(x)| < \varepsilon$.
Let $C_\varepsilon := \sup\limits_{x\in[1,K_\varepsilon]}|f(x)|$. The supremum exists since $f$ is continuous, and hence bounded, on $[1,K_\varepsilon]$.
Let $M_\varepsilon := \max\left\{K_\varepsilon,\frac{(K_\varepsilon-1)C_\varepsilon}{\varepsilon}\right\}$. If $X > M_\varepsilon$, then
\begin{align} \left|\frac{1}{X}\int_1^Xf(x)dx\right| &\leq \frac{1}{X}\int_1^X|f(x)|dx \\ &= \frac{1}{X}\int_{1}^{K_\varepsilon}|f(x)|dx + \frac{1}{X}\int_{K_\varepsilon}^{X}|f(x)|dx \\ &\leq \frac{1}{X}(K_\varepsilon-1)C_\varepsilon + \frac{1}{X}(X-K_\varepsilon)\varepsilon \\ &< 2\varepsilon \end{align}
So, we have shown that given any $\varepsilon > 0$, there exists $M_\varepsilon > 1$ such that $X > M_\varepsilon \implies \left|\frac{1}{X}\int_1^Xf(x)dx\right|<2\varepsilon$, which means that $$\lim_{X\to\infty}\frac{1}{X}\int_1^Xf(x)dx = 0$$ as required.
Alternative answer, using L'Hôpital's Rule:
Define $F:[1,\infty) \to \mathbb{R}$ by $F(X) := \int_1^Xf(x)dx$.
By the first fundamental theorem of calculus, since $f$ is continutous, $F$ is differentiable, and $F'(X) = f(X)$.
Let $G:[1,\infty) \to \mathbb{R}$ be defined by $G(X) := X$. Then $G'(X) = 1 \neq 0$ for all $X \in (1,\infty)$.
Also, $\lim\limits_{X\to\infty} G(X) = \infty$, so the conditions for L'Hôpital's Rule are satisfied. Therefore, \begin{align} \lim_{X\to\infty}\frac{1}{X}\int_1^Xf(x)dx &= \lim_{X\to\infty} \frac{F(X)}{G(X)} \\ &= \lim_{X\to\infty} \frac{F'(X)}{G'(X)} \\ &= \lim_{X\to\infty} f(X) \\ &= 0 \end{align} as required.