Math Atom · M-A04

Logarithms

8 minMath AtomAlgebra

By the end you will be able to

  1. 1Explain a logarithm as the inverse of a power: it answers "what power gives this number?"
  2. 2Use the log rules for products, quotients and powers.
  3. 3Use the natural log, ln, and the log button on a calculator.
  4. 4Solve (1 + r)ⁿ = k for n, and use the rule of 72 as a quick check.

Why you need it

“At 6% a year, how long until my money doubles?” The unknown is the number of years, and it sits up in the exponent. Logarithms are the tool that brings it down.

The idea

A power, asked backwards

A power answers: “multiply 2 by itself 3 times; what do you get?” (8). A logarithm asks the same thing backwards: “how many times must I multiply 2 to get 8?” (3). It is the inverse of a power.

Power

You know the base and the exponent. Find the result.

23= ?⇒82^3 = \,?\quad\Rightarrow\quad 8

Logarithm

You know the base and the result. Find the exponent.

2 ?=8⇒log⁡28=32^{\,?} = 8 \quad\Rightarrow\quad \log_2 8 = 3

Think firstCount the multiplications

  • How many 2s multiply together to make 32? That is, what is log⁡232\log_2 32?

  • What is log⁡101000\log_{10} 1000?

  • What is log⁡101\log_{10} 1?

The rules

The definition. One fact, written two ways.

The log rules. Each is a rule of exponents in disguise.

Which log? ln and log₁₀. Calculators have two log buttons. log is the log base 10. ln is the natural log, whose base is a special number called e, about 2.718 (M-A05 is all about it). Finance uses ln far more often. Both follow the same rules.

Solving for time. The reason logs matter in finance.

The rule of 72. A mental shortcut for doubling, and where it comes from.

The rules on one card

log⁡bx=y  ⟺  by=xlog⁡b1=0log⁡bb=1\log_b x = y \iff b^y = x \qquad \log_b 1 = 0 \qquad \log_b b = 1
log⁡(xy)=log⁡x+log⁡ylog⁡xy=log⁡x−log⁡ylog⁡xp=plog⁡x\log(xy) = \log x + \log y \qquad \log\tfrac{x}{y} = \log x - \log y \qquad \log x^p = p \log x
(1+r)n=k  ⇒  n=ln⁡kln⁡(1+r)doubling: n≈72rate in %(1 + r)^n = k \;\Rightarrow\; n = \frac{\ln k}{\ln(1 + r)} \qquad \text{doubling: } n \approx \frac{72}{\text{rate in \%}}

How good is the rule of 72? Very good at everyday rates, and worse at high ones:

RateExact years to doubleRule of 72Error
1%69.6672.002.34
4%17.6718.000.33
8%9.019.00−0.01
12%6.126.00−0.12
20%3.803.60−0.20
50%1.711.44−0.27

Try it

Slide the rate and pick a target. The blue curve is the exact answer from logs. For doubling, the dashed curve is the rule of 72: see where it hugs the exact one and where it drifts away.

Target: multiply the start by k

Solving (1.060)ⁿ = 2 with logs: n = ln 2 ÷ ln 1.060 = 0.6931 ÷ 0.0583

Years to reach ×2

11.90

In whole years12
(1.060)122.012
Rule of 72: 72 ÷ 6.012.00
Rule's error0.10 yrs
exact: ln k ÷ ln(1 + r)rule of 72
01020302%5%10%15%20%25%30%years

Across: the growth rate. Up: the years needed.

Worked examples

1. How long does money take to double at 6% a year?

Step 1 of 3
  1. 1

    Set up

    1.06n=21.06^n = 2

2. How long does 1,000 take to grow to 5,000 at 7% a year?

Step 1 of 3
  1. 1

    Turn it into a growth factor

    5,000 is 5 times 1,000, so solve 1.07n=51.07^n = 5.

3. Log changes add up: a price goes 100 → 110 → 99

Step 1 of 3
  1. 1

    The log change of each move

    ln⁡110100=0.09531ln⁡99110=−0.10536\ln\tfrac{110}{100} = 0.09531 \qquad \ln\tfrac{99}{110} = -0.10536

Common mistakes

Each of these is tempting. Decide what is wrong before you reveal the fix.

  • “ln(a + b) = ln a + ln b.”

  • “ln 2 ÷ ln 1.06 is the same as ln(2 ÷ 1.06).”

  • “n = ln 2 ÷ log 1.06.”

  • “At 6%, n = ln 2 ÷ ln(1 + 6).”

  • “ln 0 = 0”, or taking the log of a negative number.

  • “At 50% a year, the rule of 72 says money doubles in 1.44 years.”

Reaction

Check what stuck

Question 1 · objective 1

What is log₂ 64?

Question 2 · objective 2

Which of these is always true (for positive a and b)?

Question 3 · objective 4

Exactly how many years does money take to double at 9% a year, compounded yearly? Two decimals.

years

Question 4 · objective 4

Using the rule of 72, roughly how many years does money take to double at 4% a year?

years

Question 5 · objective 4

Solve 1.05ⁿ = 3 for n, to two decimals.

Glossary

Logarithm (log)
The power you must raise the base to, to get a number. log₂ 8 = 3 because 2³ = 8.
Natural log (ln)
The natural logarithm: a log with base e, a constant close to 2.71828. Written ln.
Log base 10
A log with base 10, written log₁₀ or just log on most calculators.
Inverse
An operation that undoes another. Taking a log undoes raising to a power.
Rule of 72
A shortcut: the years to double at r% a year are roughly 72 ÷ r.
Log change
ln(new ÷ old). Log changes over several periods add up to the log change over the whole time.