Math concepts

L'Hôpital's Rule: When It Applies and Four Worked Limits

November 1, 20268 min read
L'Hôpital's Rule: When It Applies and Four Worked Limits

You substitute the target value into a fraction and see 0/00/0. Should you differentiate its top and bottom? Sometimes. First you should ask whether the expression simplifies by ordinary algebra, whether the numerator and denominator really form an eligible pair, and whether differentiating makes the limit easier. L'Hôpital's rule is a conditional theorem, not a command to differentiate every fraction with a troublesome denominator.

This guide puts an eligibility table before the calculations, then follows it through four worked limits. One is faster by factoring, one is outside the rule altogether, one uses the rule at infinity, and one becomes eligible only after taking logarithms. If the idea of a limit is new, read our limits guide first. The derivative guide covers the other prerequisite.

Eligibility before differentiation

At the target, inspect the numerator and denominator separately. Direct L'Hôpital applies to quotients of the forms 0/00/0 or ±∞/±∞\pm\infty/\pm\infty, subject to the theorem's other conditions. It does not directly apply to 5/05/0, 0⋅∞0\cdot\infty, ∞−∞\infty-\infty, or a power such as 1±∞1^{\pm\infty}. Some of those other forms can be rewritten as an eligible quotient; some need a different method.

Case in this guideInitial formDirect L'Hôpital?Better first move
(x2−9)/(x−3)(x^2-9)/(x-3) as x→3x\to30/00/0Eligible, but unnecessaryFactor and cancel for x≠3x\ne3
5/x5/x as x→0x\to05/05/0NoCompare the one-sided limits
(2x2+3x)/(x2−1)(2x^2+3x)/(x^2-1) as x→+∞x\to+\infty∞/∞\infty/\inftyYesCompare leading powers or differentiate
(1+x)1/x(1+x)^{1/x} as x→0x\to01±∞1^{\pm\infty}No, not directlyTake a logarithm, then test its quotient

The rule, in a common form, says that under its hypotheses,

lim⁡x→af(x)g(x)=lim⁡x→af′(x)g′(x),\lim_{x\to a}\frac{f(x)}{g(x)} =\lim_{x\to a}\frac{f'(x)}{g'(x)},

provided the right-hand limit exists as a finite or appropriate infinite limit. Near the approach point, ff and gg must be differentiable on the relevant punctured interval, and g′(x)g'(x) must be nonzero there. The original pair must both tend to zero or both grow without bound in the permitted direction. The same logic can be used for a one-sided limit or a limit at infinity when its corresponding hypotheses hold. OpenStax Calculus, Volume 1, §4.8 gives the theorem and transformations; Paul's Online Notes emphasizes checking the form before applying it.

If the limit of f′/g′f'/g' does not exist, that attempt may simply be inconclusive; it does not by itself prove that the original limit fails to exist. Conversely, seeing 0/00/0 after substitution is only the first check. The functions and derivative denominator must still satisfy the theorem near the point. Throughout the examples we stay on the relevant domain and state which direction xx approaches from.

Case 1: algebra solves a 0/0 limit first

Consider

lim⁡x→3x2−9x−3.\lim_{x\to3}\frac{x^2-9}{x-3}.

Both numerator and denominator tend to zero, so the form is 0/00/0. The first table row says the rule could apply, but factoring is simpler. For x≠3x\ne3,

x2−9x−3=(x−3)(x+3)x−3=x+3.\frac{x^2-9}{x-3}=\frac{(x-3)(x+3)}{x-3}=x+3.

The fraction is undefined at x=3x=3, but a limit uses neighboring values. On those values it equals x+3x+3, so the limit is 66. As a cross-check, differentiating numerator and denominator separately would give lim⁡x→32x/1=6\lim_{x\to3}2x/1=6. The two approaches agree, but the factorization makes the removable hole and the reason for cancellation visible.

There is a useful choice here: eligible does not mean best. Factoring, rationalizing, or simplifying a complex fraction often removes the obstacle before derivatives are needed. The existing limits explanation uses a different removable-hole example to explain why the value at the hole need not equal the limit. Here the decision is which valid method is shortest and clearest.

Case 2: 5/0 is not an indeterminate form

Now take

lim⁡x→05x.\lim_{x\to0}\frac{5}{x}.

The numerator tends to 55, not zero or infinity, while the denominator tends to zero. This is the second table row, 5/05/0, so L'Hôpital's rule does not apply. Direction settles the limit: as x→0+x\to0^+, 5/x→+∞5/x\to+\infty; as x→0−x\to0^-, 5/x→−∞5/x\to-\infty. The two-sided limit therefore does not exist, though each one-sided behavior is clear.

Blindly differentiating the top and bottom would produce 0/1=00/1=0, a false answer. That result is not a failed use of the theorem; it is a calculation made without satisfying the theorem. Do the eligibility check before any differentiation. The sign of the denominator on each side often tells you more than another line of algebra.

This example also shows why “the denominator approaches zero” is not enough to diagnose a limit. Compare it with Case 1: both denominators tend to zero, but the numerator in Case 1 also tends to zero, and the quotient approaches a finite value. The initial form determines which methods are available; sidedness determines whether a two-sided answer exists.

Case 3: infinity over infinity

Let x→+∞x\to+\infty in

2x2+3xx2−1.\frac{2x^2+3x}{x^2-1}.

The numerator and denominator both grow toward +∞+\infty, giving the eligible ∞/∞\infty/\infty form in the third table row. For sufficiently large positive xx, the denominator and its derivative are nonzero. Differentiate the numerator and denominator separately:

lim⁡x→+∞2x2+3xx2−1=lim⁡x→+∞4x+32x=2.\lim_{x\to+\infty}\frac{2x^2+3x}{x^2-1} =\lim_{x\to+\infty}\frac{4x+3}{2x}=2.

The final step follows because 3/(2x)→03/(2x)\to0. Notice that one application was enough; do not keep differentiating after the new quotient has a clear limit. A direct algebra check is even shorter: divide the original numerator and denominator by x2x^2 to get (2+3/x)/(1−1/x2)→2(2+3/x)/(1-1/x^2)\to2. Both methods show that the leading quadratic coefficients control this example.

This comparison matters when choosing a method. Differentiation is helpful when it simplifies the quotient. If dividing by the highest power of xx settles the limit immediately, use that. L'Hôpital's rule is valid here but does not make the simpler algebra invalid or inferior.

Case 4: a power needs a logarithmic rewrite

Consider the positive expression (1+x)1/x(1+x)^{1/x} as x→0x\to0, with x>−1x>-1 and x≠0x\ne0. The base tends to 11 while the exponent grows in magnitude, producing the indeterminate power form 1±∞1^{\pm\infty}. This is not a quotient, so the fourth table row says not to apply L'Hôpital directly to the power.

Set y=(1+x)1/xy=(1+x)^{1/x} and take natural logarithms on its positive domain:

ln⁡y=ln⁡(1+x)x.\ln y=\frac{\ln(1+x)}{x}.

Now both numerator and denominator of the logarithmic quotient tend to zero. Near zero, both are differentiable, and the derivative of the denominator is 11. Apply the rule to this quotient:

lim⁡x→0ln⁡y=lim⁡x→01/(1+x)1=1.\lim_{x\to0}\ln y =\lim_{x\to0}\frac{1/(1+x)}{1}=1.

Exponentiation is continuous, so the original limit is e1=ee^1=e. The expression approaches the same value from both sides within x>−1x>-1. The essential distinction is that L'Hôpital evaluated the limit of ln⁡y\ln y, not the power directly. Our guide to Euler's number develops why limits involving ee appear throughout calculus.

Do not take logarithms of an expression that can be nonpositive without checking its domain. Here 1+x>01+x>0 near zero, so the logarithm is legitimate. The log step changes the problem into a quotient; the exponentiation step changes the answer back. Omitting either step leaves the argument incomplete.

Do not confuse two different derivative operations

L'Hôpital's rule compares the limit of f/gf/g with the limit of f′/g′f'/g'. The quotient rule, by contrast, computes the derivative of the entire function f/gf/g:

ddx(fg)=f′g−fg′g2.\frac{d}{dx}\left(\frac{f}{g}\right)=\frac{f'g-fg'}{g^2}.

These are different objects. In Case 1, the fraction equals x+3x+3 for x≠3x\ne3, so its ordinary derivative nearby is 11. But its limit as x→3x\to3 is 66. Substituting the quotient-rule derivative for f′/g′f'/g' would therefore answer the wrong question. Likewise, applying f′/g′f'/g' to Case 2 gave a wrong result because the theorem's initial form was absent.

A quick decision routine is: substitute or inspect the two parts, name the form, simplify if possible, check the domain and theorem conditions, then differentiate top and bottom separately only if the eligible quotient still benefits from it. Keep the approach direction in the notation. For practice, change Case 3 to x→−∞x\to-\infty and check its form and answer afresh. Math Zen's limits topic and derivatives topic cover the underlying skills one problem at a time.

Frequently asked questions

Can I use L'Hôpital whenever substitution gives 0/00/0? It is a candidate, not an automatic instruction. Check differentiability on the relevant punctured neighborhood, a nonzero denominator derivative there, and whether the derivative quotient has a suitable limit. Try simple algebra first.

Can the rule be applied more than once? Yes, if the new quotient again satisfies the conditions and another application helps. Recheck the new form each time. Stop as soon as an ordinary limit calculation is available.

Why not use the quotient rule? The quotient rule finds the derivative of f/gf/g. L'Hôpital compares limits of f/gf/g and f′/g′f'/g' under special conditions. The two operations are not interchangeable.

What if the numerator does not tend to zero? If the denominator tends to zero while the numerator tends to a nonzero finite value, the form is not 0/00/0. Examine the sign and one-sided behavior instead, as in 5/x5/x near zero.

Put This Into Practice