Section4.CExponential and Logarithmic Equations
¶
In this section we will develop techniques for solving equations involving exponential and logarithmic functions. Suppose, for instance, we wanted to solve the equation \(2^x = 128.\) If we happen to see that \(128 = 2^7\) then we have the solution to the equation: \(x = 7.\) However, if we change the equation slightly to \(2^x = 129,\) this method leaves a lot to be desired. The exponent we need on \(2\) to get \(129\) does not easily come to mind. Here's were logs come to the rescue. Just like squaring both sides of an equation is a reasonable strategy when working with radicals, "logging" both sides allows us to use the rules of logarithms to solve exponential equations. We could take the logarithm base \(2\) of both sides, but this sometimes presents a problem:
\begin{align*}
2^x\amp = 129\amp\amp\\
\log_2(2^x)\amp = \log_2(129)\amp\amp\text{Take the logarithm base \(2\) of both sides}\\
x\amp = \log_2(129)\amp\amp\text{Use the fact that \(\log_2(x)\) is the inverse function of }2^x
\end{align*}
We've solved for \(x\text{,}\) but how do we calculate \(\log_2(129)\text{?}\) Most calculators do not have a button for a logarithm base \(2\text{.}\) If you think about it, there are an infinite number of bases we could consider for a logarithm. Your calculator probably has two logarithm buttons, one for \(\ln(x)\) and another for \(\log(x)\text{,}\) base \(e\) and \(10\) respectively. Fortunately, all is not lost. Let's see how we would solve the problem limited by our choice of bases. We'll use base \(e\) for this problem.
Example4.C.1Solve an Exponential Equation Using the Natural Logarithm
Solve \(2^x = 129\) for \(x.\)
\begin{align*}
2^x\amp = 129\amp\amp\\
\ln(2^x)\amp = \ln(129)\amp\amp\text{Take the natural logarithm of both sides}\\
x\ln(2)\amp = \ln(129)\amp\amp\text{Use the Power Rule for logs to bring down the \(x\) in the exponent}\\
\dfrac{x\ln(2)}{\ln(2)}\amp = \dfrac{\ln(129)}{\ln(2)}\amp\amp\text{Since \(\ln(2)\) is a perfectly good number, divide both sides by it}\\
x\amp = \dfrac{\ln(129)}{\ln(2)}\amp\amp\text{We have solved for }x\\
\amp \approx 7.011227\amp\amp\text{Use a calculator to get the approximate value}
\end{align*}
Check our answer: \(2^{7.011227} \approx 128.9999.\checkmark\)
Note that if we had used the common log instead of the natural log our last step would have been \(x = \dfrac{\log(129)}{\log(2)}\) and punching this into a calculator gives \(x \approx 7.011227\text{.}\) Using either base \(e\) or base \(10\) gives the same answer–what a comforting thought!
We'll work a few more examples of solving exponential equations and then move on to solving equations involving logs.
Example4.C.2Solve an Exponential Equation Using the Common Logarithm
Solve the equation: \(4^{x+1} = 11.\)
Let's try this one using the common logarithm.
\begin{align*}
4^{x+1}\amp = 11\amp\amp\\
\log(4^{x+1})\amp = \log(11)\amp\amp\text{Take the log of both sides}\\
(x+1)\log(4)\amp = \log(11)\amp\amp\text{Use the Power Rule}\\
\dfrac{(x+1)\log(4)}{\log(4)}\amp = \dfrac{\log(11)}{\log(4)}\amp\amp\text{Divide both sides by }\log(4)\\
x+1\amp = \dfrac{\log(11)}{\log(4)}\amp\amp\text{Reduce and subtract \(1\) from both sides}\\
x\amp = \dfrac{\log(11)}{\log(4)} - 1\amp\amp\text{This answer is fine or use a calculator to get a decimal approximation}\\
x\amp \approx 0.729716\amp\amp\text{Our Solution}\checkmark
\end{align*}
Example4.C.3Solve an Exponential Equation Using the Natural Logarithm
Solve \(3^{2-3t} = 2(5^t)\) for \(t.\)
The issue is that the variables are in the exponent.
\begin{align*}
3^{2-3t}\amp = 2(5^t)\amp\amp\\
\ln(3^{2-3t})\amp = \ln(2(5^t))\amp\amp\text{Take the natural log of both sides to bring down exponents}\\
(2-3t)\ln(3)\amp = \ln(2(5^t))\amp\amp\text{We can bring down the exponent on the left,}\\
\amp\amp\amp\text{but on the right the exponent is only on the }5\\
\amp\amp\amp\text{so we'll need to separate the \(2\) from the }5^t\\
\amp\amp\amp\text{before we can use the Power Rule}\\
(2-3t)\ln(3)\amp = \ln(2) + \ln(5^t)\amp\amp\text{Use the Product Rule}\\
(2-3t)\ln(3)\amp = \ln(2) + t\ln(5)\amp\amp\text{Now we can use the Power Rule on the }5^t\\
2\ln(3)-3t\ln(3)\amp = \ln(2) + t\ln(5)\amp\amp\text{Distribute the \(\ln(3)\) to separate the \(-3t\) from the }2\\
2\ln(3)- \ln(2)\amp = t\ln(5)+3t\ln(3)\amp\amp\text{Add \(3t\ln(3)\) and subtract \(\ln(2)\) from both sides}\\
\amp\amp\amp\text{to get the \(t\)'s on one side}\\
2\ln(3)- \ln(2)\amp = t\left(\ln(5)+3\ln(3)\right)\amp\amp\text{Factor out the \(t\) on the right}\\
\dfrac{2\ln(3) - \ln(2)}{\ln(5)+3\ln(3)}\amp = t\amp\amp\text{Divide both sides by }\ln(5)+3\ln(3)\\
t\amp \approx 0.3066245\amp\amp\text{If you wish, use a calculator to get an approximation.}\checkmark
\end{align*}
Example4.C.4Solve an Exponential Equation Using the Natural Logarithm
Solve \(5^{2x} + 1 = 9\) for \(x.\)
Taking the log of a sum will not help us since there is no “Sum” Rule.
\begin{align*}
5^{2x} + 1\amp = 9\amp\amp\\
5^{2x}\amp = 8\amp\amp\text{Subtract \(1\) from both sides}\\
\log(5^{2x})\amp = \log(8)\amp\amp\text{Now, we can take the log of both sides}\\
2x\log(5)\amp = \log(8)\amp\amp\text{Apply the Power Rule}\\
x\amp = \dfrac{\log(8)}{2\log(5)}\amp\amp\text{Divide both sides by }2\log(5)\\
x\amp \approx 0.646015\amp\amp\text{Our Solution}\checkmark
\end{align*}
The next example is a special case for when the bases are the same.
Example4.C.5Solve an Exponential Equation Using Same Base
Solve \(3^{x+2} = 9^{x}\) for \(x.\)
We could solve this one by taking logs of both sides, but let's consider another approach.
\begin{align*}
3^{x+2}\amp = 9^{x}\amp\amp\\
3^{x+2}\amp = (3^2)^x\amp\amp\text{Rewrite the right side to use base \(3\) by writing \(9\) as \(3^2\)}\\
3^{x+2}\amp = 3^{2x}\amp\amp\text{Combine the exponents on the right with the Power Rule for exponents}\\
\amp\amp\amp\text{Exponential functions have unique output for each input}\\
x+2\amp = 2x\amp\amp\text{Since the outputs are equal, the inputs must be equal}\\
2\amp = 2x - x\amp\amp\text{Subtract \(x\) from both sides}\\
2\amp = x\amp\amp\text{Our Solution}\checkmark
\end{align*}
Okay, let's get a few log equations under our belts and this section will soon be history! It shouldn't surprise you that solving log equations usually involves reverting to an exponential form.
Example4.C.6Solve a Logarithmic Equation Using Exponentiation
Solve \(\log_3(x+1) = 2\) for \(x.\)
\begin{align*}
\log_3(x+1)\amp = 2\amp\amp\text{We have to get the \(x\) out of the logarithm in order to solve for it}\\
3^{2}\amp = x+1\amp\amp\text{Change the equation to exponential form}\\
9 - 1\amp = x\amp\amp\text{Subtract \(1\) from both sides}\\
x\amp = 8\amp\amp\text{Our Solution}
\end{align*}
Let's check our answer: \(\log_3(8+1) = \log_3(9) = \log_3\left(3^2 \right) = 2.\checkmark\)
One problem that may arise when we switch a log equation into an exponential equation is the difference in the domains of the two functions. While exponential functions will accept any number, logarithms can only have positive numbers as input. So, a solution to an exponential equation may not work in the original log equation. This situation is similar to when you solved equations with square roots by squaring. You may get extra answers and the only way to know if a solution is really a solution is to check your answers.
Example4.C.7Solve a Logarithmic Equation
Solve \(\log_2(x) + \log_2(x+2) = 3\) for \(x.\)
\begin{align*}
\log_2(x) + \log_2(x+2)\amp = 3\amp\amp\text{We can rewrite this as an exponential if we have one log}\\
\log_2\left(x(x+2)\right)\amp = 3\amp\amp\text{Use the Product Rule to combine the logs}\\
2^3\amp = x(x+2)\amp\amp\text{Change to exponential form}\\
8\amp = x^2 + 2x\amp\amp\text{Multiply out the expressions}\\
0\amp = x^2 + 2x - 8\amp\amp\text{This is a quadratic equation, so set it equal to zero}\\
0\amp = (x + 4)(x - 2)\amp\amp\text{Factor}\\
x + 4 = 0\text{ or }\amp x - 2 = 0\amp\amp\text{Set each factor equal to zero}\\
x = -4\text{ or }\amp x = 2\amp\amp\text{Solve each equation}
\end{align*}
Now, we have to check both answers to make sure they work in the original log equation.
\begin{align*}
\underline{\text{Check: }}x = -4:\amp\amp\underline{\text{Check: }}x = 2:\amp\\
\log_2(-4) + \log_2(-4+2)\amp\amp\log_2(2) + \log_2(2+2)\amp=\log_2(2) + \log_2(4)\\
\text{You cannot take the}\amp\amp\amp= 1 + 2\\
\text{logarithm of a negative number.}\amp\amp\amp = 3\text{ This one works.}
\end{align*}
Only \(x = 2\) is a solution.\(\checkmark\)
Example4.C.8Solve a Logarithmic Equation
Solve \(\log x = 1 - \log(x-3)\) for \(x.\)
\begin{align*}
\log x\amp = 1 - \log(x-3)\amp\amp\text{We need to have only one log to convert to exponential form}\\
\log x + \log(x-3)\amp = 1\amp\amp\text{Add \(\log(x-3)\) to both sides}\\
\log(x(x-3))\amp = 1\amp\amp\text{Use the Product Rule}\\
10^1\amp = x(x-3)\amp\amp\text{Switch to exponential form}\\
10\amp = x^2 - 3x\amp\amp\text{Multiply out the expressions}\\
0\amp = x^2 - 3x - 10\amp\amp\text{Set equal to zero to solve the quadratic equation}\\
0\amp = (x - 5)(x + 2)\amp\amp\text{Factor}\\
x - 5 = 0\text{ or }\amp x+2 = 0\amp\amp\text{Set each factor equal to zero}\\
x = 5\text{ or }\amp x = -2\amp\amp\text{Solve each equation}
\end{align*}
Checking the answers:
\begin{align*}
\underline{\text{Check: }}x = 5:\amp\amp\amp\underline{\text{Check: }}x = -2:\amp\\
\log 5 \approx 0.69897\text{ and}\amp\amp\amp\text{We run into problems}\amp\\
1 - \log(5-3)\amp = 1 - \log(2)\amp\amp\text{with}\log(-2)\amp\\
\amp\approx 0.69897\amp\amp\text{This one doesn't work.}\amp
\end{align*}
The only solution is \(x = 5.\checkmark\)
For this next example, we will use the fact that logarithm functions give unique output values. If the output values are equal, then the input values have to be equal.
Example4.C.9Solve a Logarithmic Equation
Solve \(\ln(c) + \ln(2c) = \ln(x+1)\) for \(c.\)
\begin{align*}
\ln(c) + \ln(2c)\amp = \ln(x+1)\amp\amp\text{Use the Product Rule on the left side to combine the logarithms}\\
\ln(2c^2)\amp = \ln(x+1)\amp\amp\text{Here, the results of the two logarithms are equal,}\\
\amp\amp\amp\text{so the input values must be equal}\\
2c^2\amp = x+1\amp\amp\text{Divide both sides by }2\\
c^2\amp = \dfrac{x+1}{2}\amp\amp\text{Now, take the square root of both sides}\\
c\amp = \pm\sqrt{\dfrac{x+1}{2}}\amp\amp\text{Note that the original equation will not allow}\\
\amp\amp\amp\text{a negative value to be plugged in}\\
c\amp = \sqrt{\dfrac{x+1}{2}}\amp\amp\text{Our Solution}\checkmark
\end{align*}
Example4.C.10Investment Account
Suppose you invest \(P_0\) dollars in a bank account with an annual interest rate of \(2\%\) (i.e. interest is paid once per year). The amount, \(A\text{,}\) in your account after \(t\) years, if you make no other deposits and no withdrawals, may be calculated by the following formula:
\begin{gather*}
A = P_0(1.02)^t.
\end{gather*}
Now, suppose you invested \(\$1000\) in the account. Assume no other deposits and no withdrawals are made.
-
How much will be in the account after \(10\) years?
Solution: We just need to substitute \(t=10\) and \(P_0 = 1000\) and calculate the result:
\begin{align*}
A\amp = 1000(1.02)^{10}\\
A\amp \approx 1,218.99
\end{align*}
The account will have \(\$1,218.99\) at the end of \(10\) years.
-
How many years will it take before the account has \(\$1500\) in it?
Solution: This time we know, \(A = 1500\) and \(P_0 = 1000.\) We need to find the value for \(t\text{:}\)
\begin{align*}
1500\amp = 1000(1.02)^t\\
\frac{1500}{1000}\amp = (1.02)^t\\
\ln(1.5)\amp = \ln(1.02)^t\\
\ln(1.5)\amp = t\ln(1.02)\\
\frac{\ln(1.5)}{\ln(1.02)}\amp = t\\
t\amp \approx 20.475
\end{align*}
The account will have at least \(\$1,500\) roughly in the middle of year \(20\text{.}\) Since the bank only pays interest once a year, you will get the amount at the end of year \(20.\checkmark\)