L ‘Hopital’s Rule and Indeterminate Forms

Who is L’Hospital, and why does he have a rule? What are indeterminate forms? I go over all these questions with many many examples. In fact, I give at least one instance of each of the seven types of indeterminate forms.

L’Hospital‘s rule is a general method for evaluating an indeterminate form. This rule can be applied to several types of indeterminate forms, using first an appropriate algebraic transformation. The expression “the limit has an indeterminate form” is used to convey that a limit has one of the seven indeterminate forms, usually before applying L’Hospital’s rule. We discuss these indeterminate forms giving examples of each.

Introduction to Indeterminate Forms

We say that $$ \lim_{x\to \infty }\frac{3^x-1}{x^3} $$ has the intermediate form\index{intermediate form} $\frac{\infty }{\infty }$ because $3^x\to \infty $ and $x^3\to \infty $ as $x\to \infty $ In this section we will consider the following seven indeterminate forms \begin{equation} \frac{\infty }{\infty }, \qquad \frac{0}{0}, \qquad \infty-\infty, \qquad 0\cdot \infty, \qquad \infty^0, \qquad 0^0, \qquad 1^{\infty}. \end{equation}

L’Hospital’s Rule

Our main investigative tool will be L’Hospital’s rule which says that the limit of a quotient of functions $f$ and $g$ is equal to the limit of the quotient of their derivatives $f’$ and $g’$ provided some conditions are satisfied. It is especially important to verify the conditions regarding the limits of $f$ and $g$ before applying L’Hospital’s rule.

Theorem. (L’Hospital’s Rule) Suppose $f$ and $g$ are differentiable functions and $g'(x)\neq 0$ on an open interval $I$ that contains $c.$ Suppose \begin{equation} \lim_{x\to c}\frac{f(x)}{g(x)} \end{equation} produces an intermediate form $\frac{0}{0}$ or $\frac{\infty }{\infty }$ and that \begin{equation} \lim_{x\to c}\frac{f'(x)}{g'(x)}\end{equation} exists or is infinite, then \begin{equation} \lim_{x\to c}\frac{f(x)}{g(x)} = \lim_{x\to c}\frac{f'(x)}{g'(x)}. \end{equation}

Keep in mind that L’Hospital’s ‘ rule also holds if $x\to c$ is replaced by $x\to c^+,$ $x\to c^-,$ $x\to \infty ,$ $x\to -\infty .$

Indeterminate Forms $0/0$ and $\infty/\infty$

To illustrate L’Hospital’s Rule we will evaluate several limits.

Example. Evaluate $$ \lim_{x\to \infty }\frac{\ln x}{x} $$ using L’Hospital’s rule.

Solution. The given limit has the indeterminate form $\frac{\infty }{\infty }$ since $$ \lim_{x\to \infty }\ln x=+\infty \quad \text{and}\quad \lim_{x\to +\infty }x=+\infty . $$ We apply L’Hospital’s rule to evaluate the limit as follows \begin{equation} \lim_{x\to +\infty }\frac{\ln x}{x}=\lim_{x\to +\infty }\frac{\frac{1}{x}}{1}=0. \end{equation} as desired.

Example. Evaluate \begin{equation} \lim_{x\to -\infty }\frac{x^2}{e^{-x}} \end{equation} using L’Hospital’s rule.

Solution. The given limit has the indeterminate form $\frac{\infty }{\infty }$ since $$ \lim_{x\to -\infty }x^2=+\infty \quad \text{and}\quad \lim_{x\to -\infty }e^{-x} = +\infty . $$ We apply L’Hospital’s rule to evaluate the limit as follows \begin{equation} \lim_{x\to -\infty }\frac{x^2}{e^{-x}}=\lim_{x\to -\infty }\frac{2x}{-e^{-x}}=\lim_{x\to -\infty }\frac{2}{e^{-x}}=0. \end{equation} Thus illustrating that L’Hospital’s rule can be used multiple times.

We are justified in calling $\frac{\infty}{\infty}$ an indeterminate form since \begin{equation} \lim_{x\to +\infty }\frac{\ln x}{x}=0 \neq 1=\lim_{x\to 0 }\frac{\sin x}{x}. \end{equation}

Example. Evaluate \begin{equation} \lim_{x\to 0 }\frac{\sin x}{x} \end{equation} using L’Hospital’s rule.

Solution. The given limit has the indeterminate form $\frac{0}{0 }$ since $$ \lim_{x\to 0 }\sin x=0 \quad \text{and}\quad \lim_{x\to 0 }x=0 . $$ We apply L’Hospital’s rule to evaluate the limit as follows \begin{equation} \lim_{x\to 0 }\frac{\sin x}{x}=\lim_{x\to 0 }\frac{\cos x}{1}=1. \end{equation} as desired.

Example. Evaluate \begin{equation} \lim_{x\to 0}\frac{e^{2x}-1}{x} \end{equation} using L’Hospital’s rule.

Solution. The given limit has the indeterminate form $\frac{0}{0}$ since $$ \lim_{x\to 0}e^{2x}-1=0 \quad \text{and} \quad \lim_{x\to 0}x=0. $$ We apply L’Hospital’s rule to evaluate the limit as follows \begin{equation} \lim_{x\to 0}\frac{e^{2x}-1}{x}=\lim_{x\to 0}\frac{2 e^{2 x}}{1}=2. \end{equation} as desired.

We are justified in calling $\frac{0}{0}$ an indeterminate form since \begin{equation} \lim_{x\to 0 }\frac{\sin x}{x}=1 \neq 2=\lim_{x\to 0}\frac{e^{2x}-1}{x}. \end{equation}

Example. Evaluate \begin{equation} \lim_{x\to 0} \frac{a^x-b^x}{x}
\end{equation} using L’Hospital’s rule, where $a,b>0.$

Solution. The given limit has the indeterminate form $\frac{0}{0}$ since $$ \lim_{x\to 0}a^x-b^x=0 \quad \text{and} \quad \lim_{x\to 0}x=0. $$ We apply L’Hospital’s rule to evaluate the limit as follows \begin{equation} \lim_{x\to 0}\frac{a^x-b^x}{x}=\lim_{x\to 0}\frac{(\ln a) a^x-(\ln b) b^x}{1}=\ln a-\ln b=\ln \frac{a}{b}. \end{equation} as desired.

Indeterminate Forms $\infty-\infty$ and $0\cdot \infty$

Example. Evaluate \begin{equation} \lim_{x\to +\infty }e^{-x}\sqrt{x} \end{equation} using L’Hospital’s rule.

Solution. The given limit has indeterminate form $0\cdot \infty $ since $$
\lim_{x\to +\infty }e^{-x}=0 \quad \text{and} \quad \lim_{x\to +\infty}\sqrt{x}=+\infty . $$ We apply L’Hospital’s rule to evaluate the limit as follows \begin{equation} \lim_{x\to +\infty }\frac{\sqrt{x}}{e^x}=\lim_{x\to +\infty }\frac{\frac{1}{2\sqrt{x}}}{e^x}=\lim_{x\to +\infty }\frac{1}{2\sqrt{x}e^x}=0. \end{equation} as desired.

Example. Evaluate \begin{equation} \lim_{x\to 1^+ } \left(\frac{1}{\ln x}-\frac{1}{x-1}\right) \end{equation} using L’Hospital’s rule.

Solution. The given limit has indeterminate form $\infty -\infty$ since $$ \lim_{x\to 1^+ }\frac{1}{\ln x}=+\infty \quad \text{and} \quad \lim_{x\to 1^+ }\frac{1}{x-1}=+\infty . $$ We apply L’Hospital’s rule to evaluate the limit as follows
\begin{align} & \lim_{x\to 1^+ } \left(\frac{1}{\ln x}-\frac{1}{x-1}\right) =\lim_{x\to 1^+ } \frac{x-1-\ln x}{(x-1)\ln x} =\lim_{x\to 1^+ } \frac{1-\frac{1}{x}}{\ln x+\frac{x-1}{x}} \\ & \qquad =\lim_{x\to 1^+ }\frac{x-1}{x\ln x+x-1}
=\lim_{x\to 1^+ } \frac{1}{\ln x+x\left(\frac{1}{x}\right)+1} =\frac{1}{2} \end{align} as desired.

Indeterminate Forms $\infty^0$, $0^0$, and $1^\infty$

The limit \begin{equation} \lim_{x\to a} f(x)^{g(x)} \end{equation} is said to an indeterminate form of the type

$(1) \quad \infty^0$ whenever $\displaystyle \lim_{x\to a} f(x)=\infty$ and $\displaystyle \lim_{x\to a} g(x)=0$,

$(2) \quad 0^0$ whenever $\displaystyle \lim_{x\to a} f(x)=0$ and $\displaystyle\lim_{x\to a} g(x)=0$, and

$(3) \quad 1^{\infty}$ whenever $\displaystyle \lim_{x\to a} f(x)=1$ and $\displaystyle \lim_{x\to a} g(x)=\pm \infty.$

With these three indeterminate forms we can apply the identity $$ f(x)^{g(x)}=e^{g(x)\ln f(x)}. $$ Since we know that the exponential function is continuous, we can use \begin{equation} \lim_{x\to a} f(x)^{g(x)}=\lim_{x\to a}e^{g(x)\ln f(x)}=e^{\left( \displaystyle \lim_{x\to a} g(x)\ln f(x)\right)} \end{equation} and then possibly apply L’Hospital’s rule, of course we must first check whether or not $$ \lim_{x\to a} g(x)\ln f(x) $$ exists first.

Example. Evaluate \begin{equation} \lim_{x\to 0^+}(\sin x)^x \end{equation} using L’Hospital’s rule.

Solution. The given limit has the indeterminate form $0^0$ since $$ \lim_{x\to 0^+} \sin x=0 \quad \text{and} \quad \lim_{x\to 0^+}x=0. $$ Since $$
\lim_{x\to 0^+}\ln (\sin x)=+\infty \quad \text{and} \quad \lim_{x\to 0^+}\frac{1}{x}=+\infty $$ we have indeterminate form of $\frac{\infty}{\infty }$ and so we apply L’Hospital’s rule to evaluate the following limit \begin{align} \lim_{x\to 0^+} x \ln \sin x & =\lim_{x\to 0^+}\frac{\ln (\sin x)}{\frac{1}{x}} = \lim_{x\to 0^+}\frac{\frac{\cos x}{\sin x}}{\frac{-1}{x^2}} \\ & =\lim_{x\to 0^+}\frac{-x^2}{\tan x} = \lim_{x\to 0^+}\frac{-2x}{\sec ^2x} =0. \end{align} Therefore, since the exponential function is continuous, \begin{equation} \lim_{x\to 0^+}(\sin x)^x =\lim_{x\to 0^+} e^{x \ln \sin x} = e^{\displaystyle \left( \lim_{x\to 0^+} x \ln \sin x\right) } = e^{\left(\displaystyle \lim_{x\to 0^+}\frac{\ln (\sin x)}{\frac{1}{x}}\right)} = e^0 = 1. \end{equation} as desired.

Example. Evaluate \begin{equation} \lim_{x\to +\infty }x^{1/x} \end{equation} using L’Hospital’s rule.

Solution. The given limit has the indeterminate form $\infty ^0$ since $$ \lim_{x\to \infty }\frac{1}{x}=0 \quad \text{and}\quad \lim_{x\to +\infty }\frac{1}{x}=+\infty . $$ Since $$ \lim_{x\to \infty}\ln x=+\infty \quad \text{and}\quad \lim_{x\to \infty}x=+\infty $$ the following limit has indeterminate form $\frac{\infty }{\infty }$ and so we apply L’Hospital’s rule as follows \begin{equation} \lim_{x\to +\infty }\frac{1}{x}\ln x =\lim_{x\to +\infty }\frac{\frac{1}{x}}{1} = 0
\end{equation} Since the exponential function is continuous \begin{equation}
\lim_{x\to +\infty }x^{1/x} =\lim_{x\to +\infty }e^{\frac{1}{x}\ln x} = e^{\left(\displaystyle \lim_{x\to +\infty }\frac{1}{x}\ln x \right)} =e^0 = 1. \end{equation} as desired.

Example. Evaluate \begin{equation} L=\lim_{x\to 0^+}(1+\sin 4x)^{\cot x}
\end{equation} using L’Hospital’s rule.

Solution. The given limit has the indeterminate form $1^{\infty }$ since $$ \lim_{x\to 0^+}1+\sin 4x=1 \quad \text{and}\quad \lim_{x\to 0^+}\cot x=+\infty . $$ Notice $\displaystyle \lim_{x\to 0^+}\frac{\ln (1+\sin 4x)}{\tan x}$ has indeterminate form $\frac{0}{0}$ since $$ \lim_{x\to 0^+}\ln (1+\sin 4x)=0 \quad \text{and} \quad \lim_{x\to 0^+}\tan x=0. $$ We apply L’Hospital’s rule to find \begin{equation} \lim_{x\to 0^+}\frac{\ln (1+\sin 4x)}{\tan x} =\lim_{x\to 0^+}\frac{\frac{4\cos 4x}{1+\sin 4x}}{\sec ^2x} =\frac{\frac{4}{1+0}}{1} =4. \end{equation} Since the exponential function is continuous \begin{align} \lim_{x\to 0^+}(1+\sin 4x)^{\cot x} & =\lim_{x\to 0^+}e^{\cot x \ln (1+\sin 4x)} \\ & =e^{\left( \displaystyle \lim_{x\to 0^+} \cot x \ln (1+\sin 4x) \right)} =e^4. \end{align} as desired.

Change of Variable

In the next example we show how making a change of variable can simplify the process of evaluating a limit.

Example. Evaluate \begin{equation} \lim_{x\to +\infty }x^5\left[\sin \left(\frac{1}{x}\right)-\frac{1}{x}+\frac{1}{6x^3}\right] \end{equation} using L’Hospital’s rule.

Solution. We make a change of variable to simplify the expression, namely $u=\frac{1}{x}.$ Since $u\to 0$ as $x\to +\infty ,$ we have \begin{align} \lim_{x\to +\infty }x^5\left[\sin \left(\frac{1}{x}\right)-\frac{1}{x}+\frac{1}{6x^3}\right] =\lim_{u\to 0}\frac{\sin (u)-u+\frac{1}{6}u^3}{u^5}
\end{align} Now we have indeterminate form $\frac{0}{0}$ and so applying l’H\^opital rule several times yields \begin{align*} & =\lim_{u\to 0}\frac{\sin (u)-u+\frac{1}{6}u^3}{u^5} \\ & =\lim_{u\to 0}\frac{(\cos u)-1+\frac{1}{2}u^2}{5u^4} \\ & =\lim_{u\to 0}\frac{(-\sin u )+u}{20u^3} \\ & =\lim_{u\to 0}\frac{(-\cos u )+1}{60u^2} \\ & =\lim_{u\to 0}\frac{\sin u }{120 u} \\ & =\lim_{u\to 0}\frac{\cos u }{120} \\ & =\frac{1}{120}. \end{align*} as desired.

When L’Hospital’s Rule Fails

In this final example we illustrate one way in which L’Hospital’s rule can fail even though the value of the limit is finite.

Example. Try to evaluate \begin{equation} \lim_{x\to +\infty }\frac{x+\sin x}{x-\cos x} \end{equation} using L’Hospital’s rule.

Solution. This limit has indeterminate form since \begin{equation} \lim_{x\to +\infty }(x+\sin x) = +\infty \hspace{.5cm}\text{and}\hspace{.5cm} \lim_{x\to +\infty }(x+\cos x)=+\infty . \end{equation} If we try to apply L’Hospitals’s Rule we find, \begin{equation} \lim_{x\to +\infty }\frac{x+\sin x}{x-\cos x}=\lim_{x\to \infty }\frac{1+\cos x}{1+\sin x}\end{equation} but the limit $$ \lim_{x\to \infty }\frac{1+\cos x}{1+\sin x} $$ does not exist because of osculating behavior, so we can not use L’Hospital’s rule. To correctly find this limit we divide by $x$ as follows \begin{align*} L & = \lim_{x\to +\infty }\frac{x+\sin x}{x-\cos x} \\ & =\lim_{x\to +\infty }\frac{\frac{x}{x}+\frac{\sin x}{x}}{\frac{x}{x}-\frac{\cos x}{x}} \\ & = \frac{1+0}{1-0} \\ & = 1. \end{align*} as desired.

Exercises on L ‘Hospital’s Rule and Indeterminate Forms

Exercise.
Use L’Hospital’s rule to find the following limits.

$(1) \quad \displaystyle \lim_{x\to 2}\frac{x-2}{x^2-4}$

$(2) \quad \displaystyle \lim_{x\to 1}\frac{x^3-1}{4x^3-x-3}$

$(3) \quad \displaystyle \lim_{x\to -5}\frac{x^2-25}{x+5}$

$(4) \quad \displaystyle \lim_{x\to 0}\frac{\sin x^2}{x}$

$(5) \quad \displaystyle \lim_{x\to 0}\frac{\sin x -x}{x^3}$

$(6) \quad \displaystyle \lim_{x\to \pi /2}\frac{1-\sin x}{1+ \cos 2x}$

$(7) \quad \displaystyle \lim_{x\to \pi /2}\frac{\ln ( \csc x)}{\left(x-\frac{\pi }{2}\right)^2}$

$(8) \quad \displaystyle \lim_{x\to \left(\frac{\pi }{2}\right)^-}\left(x-\frac{\pi }{2}\right)\sec x$

$(9) \quad \displaystyle \lim_{x\to 0}\frac{\left(\frac{1}{2}\right)^x-1}{x}$

$(10) \quad \displaystyle \lim_{x\to 0^+}\frac{\ln \left(e^x-1\right)}{\ln x}$

$(11) \quad \displaystyle \lim_{x\to \infty }(\ln 2x-\ln (x+1))$

$(12) \quad \displaystyle \lim_{x\to 0^+}\left(\frac{3x+1}{x}-\frac{1}{\sin x}\right)$

$(13) \quad \displaystyle \lim_{x\to 0}\frac{\cos x-1}{e^x-x-1}$

$(14) \quad \displaystyle \lim_{x\to \infty } x^2e^{-x}$

$(15) \quad \displaystyle \lim_{x\to \infty }(\ln x)^{1/x}$

$(16) \quad \displaystyle \lim_{x\to \infty }x^{1/ \ln x}$

$(17) \quad \displaystyle \lim_{x\to \infty }(1+2x)^{1/ 2 \ln x}$

$(18) \quad \displaystyle \lim_{x\to 0^+}\frac{\sqrt{x}}{\sqrt{\sin x}}$

Exercise. Let $f$ and $g$ be functions defined by \begin{equation*} f(x)= \left\{ \begin{array}{cc} x+2 & x\neq 0 \\ 0 & x=0 \end{array} \right. \qquad \text{and} \qquad g(x)=\left\{ \begin{array}{cc} x+1 & x\neq 0 \\ 0 & x=0 \end{array} \right. \end{equation*} Show that $$ \lim_{x\to 0}\frac{f'(x)}{g'(x)}=1 \quad \text{and}\quad \lim {x\to 0}\frac{f(x)}{g(x)}=2. $$ Explain why this does not contradict L’Hospital’s Rule.

Exercise. Find constant $a$ and $b$ so that $$ \lim_{x\to 0}\left(\frac{\sin 2x}{x^3}+\frac{a}{x^2+b}\right)=1. $$

Exercise. Find all values of $a$ and $b$ so that $$ \lim_{x\to 0}\frac{\sin a x+b x}{x^3}=36. $$

Exercise. Find the values of $a$ so that $$ \lim_{x\to 0}\frac{a-\cos b x}{x^2}=2. $$

Exercise. For a certain value of $a,$ the limit $$ \lim_{x\to +\infty} \left(x^4+5x^3+3\right)^a-x $$ is finite and nonzero. Find $a$ and then use L’Hospital’s rule to compute the limit.

Exercise. Evaluate $$ \lim_{x\to a}\frac{\sqrt{2a^3x-x^4}-a\sqrt[3]{a^2x}}{a-\sqrt[4]{a x^3}}. $$

Exercise. Determine which values of constants $a$ and $b$ is it true that \begin{equation} \lim_{x\to 0}\left(x^{-3}\sin 7x+a x^{-2}+b\right)=-2?\end{equation}

David A. Smith at Dave4Math

David Smith (Dave) has a B.S. and M.S. in Mathematics and has enjoyed teaching precalculus, calculus, linear algebra, and number theory at both the junior college and university levels for over 20 years. David is the founder and CEO of Dave4Math.

Leave a Comment