limx→af(x)=limx→ag(x)=0 or limx→af(x) and limx→ag(x) are both infinite.
limx→ag′(x)f′(x) exists or is infinite.
Then
x→alimg(x)f(x)=x→alimg′(x)f′(x).
It's slightly different from the textbook's definition because I wanted to focus on what I think are the more interesting conditions.
Pitfalls
Don't use the quotient rule!
Example 1.
Calculate x→∞limexx.
Solution.
As x→∞, the numerator and denominator both go to ∞ also, so we can apply L'Hôpital's rule. Sometimes, students will write something like this:
x→∞limexx=x→∞lime2xex−xex=0.
The problem with this is that instead of taking the derivative of the numerator and denominator separately, this is the derivative of the entire fraction, which is wrong. Instead, you should end up with
The problem here is that we didn't check condition (i) before applying L'Hôpital's rule. If we go back, you'll see that as x→0, the numerator goes to 0 but the denominator goes to 1, so we could've just plugged in to begin with:
x→0limcosxx2=0.
Example 3.
Calculate x→∞limxx+sinx.
Solution.
This is also wrong:
x→∞limxx+sinx=x→0lim11+cosx=DNE.
This is because condition (ii) failed: the limit of g′(x)f′(x) doesn't exist here, so you can't write the first equals sign. This means we need to try something else:
x→∞limxx+sinx=x→∞lim(1+xsinx)=1.
Your old techniques are still useful!
Even though L'Hôpital's rule is really useful, this doesn't mean that you can just forget all your old techniques for calculating limits. Example 3 above is one instance of this, and we also have this one:
Example 4.
Calculate x→∞limex+e−xex−e−x.
Solution.
The numerator and denominator both go to ∞ as x→∞, so we can apply L'Hôpital's rule:
x→∞limex+e−xex−e−x=x→∞limex−e−xex+e−x.
Same thing happens with the new limit, so you try it again:
Hopefully you realize that after two tries that L'Hôpital's isn't going to get you anywhere. This means that you will have to try one of your old techniques to calculate it. For this problem, you'll want to divide everything by the fastest growing function, which is ex in this case:
Before using L'Hôpital's, you should always take a minute to see if you can simplify anything. In this problem, if you don't do that, you end up with a horrible derivative in the denominator. But if you do simplify, you will just get sinx in the bottom—much nicer! If you use L'Hôpital's after this, you just get
Here, we're going to want to use logarithms to bring the exponent down, but we need to make sure we undo it so that we don't change the function:
x→0+limx2x=x→0+limelnx2x=elimx→0+2xlnx.
The second equality comes from continuity of ex. It's somewhat technical (you need to do some ε-δ stuff to prove it), so I'll just gloss over the details since they won't be important for our class.
To finish the problem, we just need to calculate limx→0+2xlnx. If we want to use L'Hôpital's rule, we need a fraction, but thankfully, we can always turn a product into a quotient:
2xlnx=x12lnx.
I could've moved lnx to the denominator instead, but then we'd have to calculate the derivative of lnx1 which will get messy, so it'll be easier to keep lnx in the numerator. Then
When x is large, (x2−4)3/2 is roughly (x2)3/2=x3, and the denominator is also roughly x3. So, we will multiply and divide by x31. Notice that x3=(x2)3/2, which gives