# Can I apply L'Hôpital to $\lim_{x \to \infty} \frac{x+\ln x}{x-\ln x}$?

Can I apply L'Hôpital to this limit: $$\lim_{x \to \infty} \frac{x+\ln x}{x-\ln x}?$$ I am not sure if I can because I learnt that I use L'Hôpital only if we have $\frac{0}{0}$ or $\frac{\infty}{\infty}$ and here $x-\ln x$ is $\infty-\infty$ and x tends to infinity.

• Just differentiate numerator and denominator and simplify both. Then you differentiate again (both numerator and denominator) and get your answer. – Stefan Gruenwald Mar 28 '17 at 17:58
• @StefanGruenwald: That is only a valid procedure if the numerator and denominator either both go to $\pm\infty$ or both go to $0$ in the first place, and the OP is asking whether he can be sure that is the case. – Henning Makholm Mar 28 '17 at 18:08

As an alternative to Stefano's calculation, note that the derivative of $x-\log x$ is $1-\frac1x$, which is $\ge \frac12$ whenever $x\ge 2$. Thus, by the mean value theorem we have $$x-\log x \ge 2-\log 2 + \frac{x-2}{2}$$ for all $x\ge 2$, and the right-hand side of this clearly goes to $\infty$.

So $x-\log x\to \infty$ when $x\to\infty$.

It is also abundantly clear that $x+\log x$ goes to $\infty$ for $x\to\infty$, so you're allowed to try using L'Hospital on your fraction.

• Just a remark: there is no need to check the numerator. De l'hopital works for indeterminate forms of the kind $\frac{\text{anything}}{\infty}. – Lonidard Mar 28 '17 at 21:42 • We're all thinking too hard. log x grows really slowly, but x does not. x - log x = O(x), which clearly goes to infinity. – Kevin Mar 29 '17 at 1:50 HINT Not sure you really need L'Hospital's Rule here. Note that you can divide the top and bottom of the fraction by$x$, to get $$\frac{x+\ln x}{x-\ln x} = \frac{1+\frac{\ln x}{x}}{1-\frac{\ln x}{x}}$$ Does this make things easier? • Well$\frac{lnx}{x}$is still$\frac{\infty}{\infty}$when x tends to infinity. – Ghost Mar 28 '17 at 17:52 • @OvyOvy yes, you can just apply the limit to that fraction. But it is quite easy to see $$\lim_{x \to \infty} \frac{\ln x}{x} = 0$$ even without such technique. You can use Taylor series for example – gt6989b Mar 28 '17 at 17:54 • @OvyOvy yes, you can apply it from the start, provided you know the denominator goes to$\infty$... – gt6989b Mar 28 '17 at 17:56 • @gt6989: It is not obvious what you have in mind for using Taylor series to show it because no Taylor series will apply for$\ln(x)$as$x\to \infty$. Using$\ln(x)=-\ln(1/x)$gives$\ln(x)=(1-\frac1x)+\frac12(1-\frac1x)^2+\frac13(1-\frac1x)^3+\cdots$, and you could make a substitution to consider$\frac{t}{e^t}$instead, but is there something simpler using Taylor series? – Jonas Meyer Mar 29 '17 at 4:03 • @JonasMeyer: I think the substitution is indeed the fastest way, because$\exp(t) > t^2/2$for every real$t > 0$. – user21820 Mar 29 '17 at 11:38$x -\ln x$goes to$+\infty$if and only if$e^{x-\ln x}$does. And this is the case, since $$e^{x-\ln x} = \frac{e^x}{x} \ge \frac{1+x+\dfrac{x^2}{2}}{x} \to +\infty$$ as$x \to +\infty$. So yes, you can apply de l'Hopital from the beginning. • I think this is best answer, especially because, unlike so many others, it actually answered the question. – The Count Apr 6 '17 at 0:05 Maybe it is better to just write: $$\lim_{x \to \infty} \frac{x+\log x}{x-\log x}=\lim_{x \to \infty} \frac{1+\frac{\log(x)}{x}}{1-\frac{\log(x)}{x}}$$ • Well$\frac{lnx}{x}$is still$\frac{\infty}{\infty}$when x tends to infinity. – Ghost Mar 28 '17 at 17:53 • Actually no, it is well-known that it tends to zero. Try to apply l'Hopital to$\lim_{x \rightarrow +\infty}\frac{\log(x)}{x}$... – GaC Mar 28 '17 at 17:54 • I know what you are saying but can I apply L'Hospital from start? – Ghost Mar 28 '17 at 17:55 • The limit of$x-\log(x)$as$x$approaches infinity is an indeterminate form$\infty - \infty$, but the limit is actually infinity, so yes, you can. – GaC Mar 28 '17 at 17:58 You are quite correct to observe that$\infty-\infty$makes no sense. But that's not how one goes about evaluating$\lim_{x\to\infty}(x-\ln x)$. Among the correct ways is to note that, for$x\gt2$, $$x-\ln x=1+\int_1^x\left(1-{1\over t}\right)dt\gt\int_2^x\left(1-{1\over t}\right)dt\gt\int_2^x{1\over2}dt={x-2\over2}\to\infty$$ The first inequality here simply throws away some stuff that's clearly positive; the second inequality amounts to subtracting from$1$the largest value that$1\over t$takes on for$t\ge2$, namely$1\over2$. Once you know that$\lim_{x\to\infty}(x+\ln x)=\lim_{x\to\infty}(x-\ln x)=\infty$, then it's OK to apply L'Hopital and get $$\lim_{x\to\infty}{x+\ln x\over x-\ln x}=\lim_{x\to\infty}{1+{1\over x}\over1-{1\over x}}={1+0\over1-0}=1$$ If you have a form other than$\frac{\infty}{\infty}$or$\frac{0}{0}$, then you cannot use L'Hôpital's rule directly. If you have an indeterminate form in either or both of the numerator or denominator, then you need to resolve these individually to determine whether the fraction is actually in one of the allowed forms. Thus, the answer you're looking for is no, you cannot just use L'Hôpital's rule from the start. However, after you resolve the top and bottom, you will see that it is in one of the forms and so you can use the rule once that has been determined. Let us look at the limit of $$\lambda(x):=\frac{f(x)+g(x)}{h(x)+i(x)}$$ where all four functions tend to$\pm\infty$without canceling the denominator. We can rewrite $$\lambda(x)=\frac{f(x)}{h(x)}\frac{1+\dfrac{g(x)}{f(x)}}{1+\dfrac{i(x)}{h(x)}},$$ where the ratios are now$\frac\infty\infty$undeterminate forms. If those ratios do have limits, we can find them by L'Hospital (provided the conditions are fulfilled), by evaluating $$\lim_{x\to\infty}\frac{f'(x)}{h'(x)}\frac{1+\dfrac{g'(x)}{f'(x)}}{1+\dfrac{i'(x)}{h'(x)}}.$$ But if those limits exist and if the lower one$\ne-1\$, the expression is also the limit of

$$\mu(x):=\frac{f'(x)+g'(x)}{h'(x)+i'(x)}.$$

This establishes a generalized L'Hospital rule.

Indeed

$$\lim_{x \to \infty} \frac{x+\ln x}{x-\ln x}=\lim_{x \to \infty} \frac{1+\dfrac1x}{1-\dfrac1x}=1.$$