Improper integral quotient in a limit statement This seemingly straightforward problem has been giving me a lot of trouble. 
For $f$ and $g$, which are positive and continuous functions on $[1,\infty)$, show that if $$L = \lim_{x\to\infty} \frac{f(x)}{g(x)}$$ is a real number, then $$L = \lim_{x\to\infty} \frac{\int_x^\infty f}{\int_x^\infty g}$$
The intuition is rather clear, but the position of $x$ in the second limit statement is throwing me off. Any help is greatly appreciated.
 A: For any $\epsilon\gt0$, there is an $N$ so that for $x\ge N$, we have
$$
(L-\epsilon)g(x)\le f(x)\le g(x)(L+\epsilon)\tag{1}
$$
Thus, for $x\ge N$, we have
$$
(L-\epsilon)\int_x^\infty g(x)\,\mathrm{d}x\le\int_x^\infty f(x)\,\mathrm{d}x\le(L+\epsilon)\int_x^\infty g(x)\,\mathrm{d}x\tag{2}
$$
Therefore, assuming the integrals converge,
$$
L-\epsilon\le\lim_{x\to\infty}\frac{\int_x^\infty f(x)\,\mathrm{d}x}{\int_x^\infty g(x)\,\mathrm{d}x}\le L+\epsilon\tag{3}
$$
Since $(3)$ is true for any $\epsilon\gt0$, we have
$$
\lim_{x\to\infty}\frac{\int_x^\infty f(x)\,\mathrm{d}x}{\int_x^\infty g(x)\,\mathrm{d}x}=L\tag{4}
$$
A: This looks like an excellent example where L'Hospital's theorem might help. Intuitively, $\lim \limits _{x \to \infty} \int \limits _x ^\infty f(t) \ \Bbb d t = \infty$, but we need to make this rigorous. The problem is that, if you want to differentiate this integral with respect to $x$, what do you do to $\infty'$? This doesn't make any sense. Therefore, write
$$\int \limits _x ^\infty f(t) \ \Bbb d t = \int \limits _x ^1 f(t) \ \Bbb d t + \int \limits _1 ^\infty f(t) \ \Bbb d t$$
and notice that
$$\frac {\Bbb d} {\Bbb d x} \int \limits _x ^\infty f(t) \ \Bbb d t = \frac {\Bbb d} {\Bbb d x} \int \limits _x ^1 f(t) \ \Bbb d t + 0 = - f(x) ,$$
which means that the application of l'Hospital's theorem gives us
$$\lim \limits _{x \to \infty} \frac {\int \limits _x ^\infty f(t) \ \Bbb d t} {\int \limits _x ^\infty g(t) \ \Bbb d t} = \lim \limits _{x \to \infty} \frac {-f(x)} {-g(x)} = L .$$

Let's address the issue of the convergence of these integrals. First, if $L>0$ then the two integrals converge (otherwise the fraction $\frac {\int _x ^\infty f} {\int _x ^\infty g}$ wouldn't make sense).
If $L = 0$, then there exist an $x_0 > 1$ such that $f(x) \le g(x)$ for $x \ge x_0$. This rules out the possibility that $\int _x ^\infty f$ diverges, because in this case we would also have $\int _x ^\infty g$ divergent and this situation has been ruled out. There remains the possibility of having $\int _x ^\infty f$ convergent and $\int _x ^\infty g$ divergent, but this case gives us immediately that
$$\frac {\int \limits _x ^\infty f(t) \ \Bbb d t} {\int \limits _x ^\infty g(t) \ \Bbb d t} = \frac {\text {finite}} \infty = 0 ,$$
whence it follows that the limit of the fraction with integrals is $0$ too, therefore equal to $L$ as required.
The case $L = \infty$ is ruled out by the requirement that $L$ be a real number, which $\infty$ is not.
