Logarithms are everywhere. Ever use the following phrases?

- 6 figures
- Double digits
- Order of magnitude
- Interest rate

You're describing numbers in terms of their powers of 10, a logarithm. And an interest rate is the logarithm of the growth in an investment.

Surprised that logarithms are so common? Me too. Most attempts at *Math In the Real World (TM)* point out logarithms in some arcane formula, or pretend we're geologists fascinated by the Richter Scale. "Scientists care about logs, and you should too. Also, can you imagine a world without zinc?"

No, no, no, no no, no no! (Mama mia!)

Math expresses concepts with notation like "ln" or "log". Finding "math in the real world" means encountering ideas in life and seeing how they *could* be written with notation. Don't look for the literal symbols! When was the last time you wrote a division sign? When was the last time you chopped up some food?

## Ok, ok, we get it: what are logarithms about?

**Logarithms find the cause for an effect, i.e the input for some output**

A common "effect" is seeing something grow, like going from $100 to $150 in 5 years. How did this happen? We're not sure, but the logarithm finds a possible cause: A continuous return of ln(150/100) / 5 = 8.1% would account for that change. It might not be the actual cause (did all the growth happen in the final year?), but it's a smooth average we can compare to other changes.

By the way, the notion of "cause and effect" is nuanced. Why is 1000 bigger than 100?

- 100 is 10 which grew by itself for 2 time periods (10 · 10)
- 1000 is 10 which grew by itself for 3 time periods (10 · 10 · 10)

We can think of numbers as outputs (1000 is "1000 outputs") and inputs ("How many times does 10 need to grow to make those outputs?"). So,

```
1000 outputs > 100 outputs
```

because

```
3 inputs > 2 inputs
```

Or in other words:

```
log(1000) > log(100)
```

Why is this useful?

**Logarithms put numbers on a human-friendly scale.**

Large numbers break our brains. Millions and trillions are "really big" even though a million seconds is 12 days and a trillion seconds is 30,000 years. It's the difference between an American vacation year and the entirety of human civilization.

The trick to overcoming "huge number blindness" is to write numbers in terms of "inputs" (i.e. their power base 10). This smaller scale (0 to 100) is much easier to grasp:

- power of 0 = 10
^{0}= 1 (single item) - power of 1 = 10
^{1}= 10 - power of 3 = 10
^{3}= thousand - power of 6 = 10
^{6}= million - power of 9 = 10
^{9}= billion - power of 12 = 10
^{12}= trillion - power of 23 = 10
^{23}= number of molecules in a dozen grams of carbon - power of 80 = 10
^{80}= number of molecules in the universe

A 0 to 80 scale took us from a single item to the number of things in the universe. Not too shabby.

**Logarithms count multiplication as steps**

Logarithms describe changes in terms of multiplication: in the examples above, each step is 10x bigger. With the natural log, each step is "e" (2.71828...) times more.

When dealing with a series of multiplications, logarithms help "count" them, just like addition counts for us when effects are added.

## Show me the math

Time for the meat: let's see where logarithms show up!

**Six-figure salary or 2-digit expense**

We're describing numbers in terms of their digits, i.e. how many powers of 10 they have (are they in the tens, hundreds, thousands, ten-thousands, etc.). Adding a digit means "multiplying by 10", i.e.

Logarithms count the number of multiplications *added on*, so starting with 1 (a single digit) we add 5 more digits (10^{5}) and 100,000 get a 6-figure result. Talking about "6" instead of "One hundred thousand" is the essence of logarithms. It gives a rough sense of scale without jumping into details.

Bonus question: How would you describe 500,000? Saying "6 figure" is misleading because 6-figures often implies something closer to 100,000. Would "6.5 figure" work?

Not really. In our heads, 6.5 means "halfway" between 6 and 7 figures, but that's an adder's mindset. With logarithms a ".5" means halfway in terms of multiplication, i.e the square root (9^.5 means the square root of 9 -- 3 is halfway in terms of multiplication because it's 1 to 3 and 3 to 9).

Taking log(500,000) we get 5.7, add 1 for the extra digit, and we can say "500,000 is a 6.7 figure number". Try it out here:

**Order of magnitude**

We geeks love this phrase. It means roughly "10x difference" but just sounds cooler than "1 digit larger".

In computers, where everything is counted with bits (1 or 0), each bit has a doubling effect (not 10x). So going from 8 to 16 bits is "8 orders of magnitude" or 2^{8} = 256 times larger. ("Larger" in this case refers to the amount of memory that can be addressed.) Going from 16 to 32 bits means an extra 16 orders of magnitude, or 2^{16} ~ 65,536 times more memory that can be addressed.

**Interest Rates**

How do we figure out growth rates? A country doesn't intend to grow at 8.56% per year. You look at the GDP one year and the GDP the next, and take the logarithm to find the *implicit* growth rate.

My two favorite interpretations of the natural logarithm (ln(x)), i.e. the natural log of 1.5:

- Assuming 100% growth, how long do you need to grow to get to 1.5? (.405, less than half the time period)
- Assuming 1 unit of time, how fast do you need to grow to get to 1.5? (40.5% per year, continuously compounded)

Logarithms are how we figure out how fast we're growing.

**Measurement Scale: Google PageRank**

Google gives every page on the web a score (PageRank) which is a rough measure of authority / importance. This is a logarithmic scale, which in my head means "PageRank counts the number of digits in your score".

So, a site with pagerank 2 ("2 digits") is 10x more popular than a PageRank 1 site. My site is PageRank 5 and CNN has PageRank 9, so there's a difference of 4 orders of magnitude (10^{4} = 10,000).

Roughly speaking, I get about 7000 visits / day. Using my envelope math, I can guess CNN gets about 7000 * 10,000 = 70 million visits / day. (How'd I do that? In my head, I think 7k · 10k = 70 · k · k = 70 · M). They might have a few times more than that (100M, 200M) but probably not up to 700M.

Google conveys a lot of information with a very rough scale (1-10).

**Measurement Scale: Richter, Decibel, etc.**

Sigh. We're at the typical "logarithms in the real world" example: Richter scale and Decibel. The idea is to put events which can vary drastically (earthquakes) on a single scale with a small range (typically 1 to 10). Just like PageRank, each 1-point increase is a 10x improvement in power. The largest human-recorded earthquake was 9.5; the Yucatán Peninsula impact, which likely made the dinosaurs extinct, was 13.

Decibels are similar, though it can be negative. Sounds can go from intensely quiet (pindrop) to extremely loud (airplane) and our brains can process it all. In reality, the sound of an airplane's engine is millions (billions, trillions) of times more powerful than a pindrop, and it's inconvenient to have a scale that goes from 1 to a gazillion. Logs keep everything on a reasonable scale.

**Logarithmic Graphs**

You'll often see items plotted on a "log scale". In my head, this means one side is counting "number of digits" or "number of multiplications", not the value itself. Again, this helps show wildly varying events on a single scale (going from 1 to 10, not 1 to billions).

Moore's law is a great example: we double the number of transistors every 18 months (image courtesy Wikipedia).

The neat thing about log-scale graphs is exponential changes (processor speed) appear as a straight line. Growing 10x per year means you're steadily marching up the "digits" scale.

## Onward and upward

If a concept is well-known but not well-loved, it means we need to build our intuition. Find the analogies that work, and don't settle for the slop a textbook will trot out. In my head:

- Logarithms find the root cause for an effect (see growth, find interest rate)
- They help count multiplications or digits, with the bonus of partial counts (500k is a 6.7 digit number)

Happy math.

## Leave a Reply

61 Comments on "Using Logarithms in the Real World"

I actually got lost right at the beginning, unfortunately. It says that: ln(150/100) = 8.1%. How does one get the number 8.1%?

ln(150/100) and divide answer by 5. and than multiply 100 to change it to percentage..it will tell you that if you pay 100 you paid and after 5 years you have to pay to bank. what is rate of interest you paying???

That was a typo, it should be ln(150/100) /5 = 8.1%. ln(150/100) is the total rate over the entire time period (about 40%), and we divide by 5 to get the rate each year.

@Titus: Whoops, I had a typo there (forgot the / 5) and should clarify!

The natural log starts with some growth amount, and gives us the corresponding growth rate (if it happened in 1 period).

So, ln(150/100) = .405, which means “In one period, you can go from 100 to 150 with a 40.5% continuous growth rate”.

However, our growth happened in 5 periods, so we split up that 40.5% growth rate among 5 years: 40.5 / 5 ~ 8% each year.

I guess most of the people out there don’t even know what the notation log_2 8 means, and even less people know that the result is 3.

For newbies, a good introduction offers this youtube video (in German):

http://youtu.be/oDOXeO9fAg4

Kalid, get out of my head! :) We JUST finished our logs unit, and as happens every year with logs, the kids were so fed up with them….. But they were also wondering why they had to learn about them – where in the real world does this come up? When I saw this, I immediately went to our brand new classblog site at http://learnmathclassblogs.blogspot.com/, and posted about your post. I hope this gets you some more comments, and I know your work will once again enlighten anyone who reads it. I love the human-friendly explanation of why we use logs – so simple, so true. I never even thought of that!

@Audrey: Haha, the coincidences keep popping up! :). Happy it was timely :).

You know, I’m realizing that there are lots of little examples where we use math but because it isn’t labeled as such, we miss it. Over time I’ll probably be adding to this article as new items sneak in!

Hi Kalid,

Enjoyed this very informative post. Can you also write about electricity voltage, current etc.

Nilesh Joglekar

@Audrey;

I don’t know who told you we were fed up with logs! It was quite a fascinating unit and I’ve learned a lot from it. I haven’t mastered it, obviously, but I now understand the basic concept. Thanks Miss and thanks Kalid for the slightly different overview of logs! :D

@Joey: Thanks for the comment — glad it came in handy :).

@Shiv: Thanks, I love that video :). Negative numbers are an interesting topic too. A lot of stereo systems show the decibel reading (-10, -20, etc.) and this is an attenuation from the max level (0 = no attenuation, i.e. no decrease in signal).

Hi Kalid,

Been a long time. I thought I’d share this little analogy since it seems apros. When thinking of large numbers, I was reminded of the Piranaha Tribe in South America whose number system seems to only go up to 2. Everything else is just “a lot”. That’s how we are…just on a different scale. 1 billion… 1 trillion… what’s the difference? They’re both just bigger than 2 :P

Sebastian

When I was educated in the early seventies we were told we’d need to provide a slide rule, I remember it didn’t get much use. Found it yesterday in a drawer I was clearing out.

You have not only educated me in a way I didn’t dream of in my teens but renewed an interest in old technology, I’d seen a film documentary which showed a navigator in a Lancaster bomber using one on a night raid over Germany, no doubt calculating time to the next way point.

I’ve worked in IT since 1985 and seen enormous advances in technology, but am amazed at what this gadget can do.

cheers

Martin

Thanks Charl!

is that the practical applications of logarithm in real life? pardon me. this is part of our project and i’m having trouble with it. if you’re not busy,can you help me? i need 10 practical applications/real life applications of logarithms. thanks a lot.

thanks for the information about logarithm .keep up

How is logarithm used irl? My teacher is offering to boost anyone up an entire letter grade if someone can find how it is used in irl situations.

Very good

Hey kalid, thanks for this entire site in general – I’m a huge fan of your work. Your conception of taking e as a scaled version of the final growth product and ln as the amount of time has helped tremendously – on an intuitive level, how do these metaphors intuit the law that says the log of a power of a number is the exponent times the logarithm of the number? This is one of those rules that I memorized in high school, but i’m having a hard time seeing it with the metaphors that you have offered.

Thanks again!

Hey Alex, really glad it’s helping. Check out http://betterexplained.com/articles/demystifying-the-natural-logarithm-ln/ for more discussion on the laws of logs and how multiplication/powers work.

At its heart, something like 3^4 means “take 3x growth, then wait and grow 3x again, then wait and grow 3x again, then wait and grow 3x again.”

How long should that entire process take? If the time to grow a single 3x is log(3), then the time to grow 3x four times should be:

log(3) + log(3) + log(3) + log(3) = 4 * log(3)

And we can check our intuition and see that log(3^4) = 4 * log(3). Check out the post for more details/examples.

[…] right? Read Using Logarithms in the Real World for more […]

Hi Tanvi, great question, glad you’re enjoying it :).

Logarithms count the number of multiplications needed to reach a number from a certain base (like 10).

For example, to get from 1 to 100 in base 10, we need two multiplications: 1 x 10 x 10 = 100.

However, the number of digits in 100 is clearly 3.

This difference (number of multiplications vs. number of digits) means the digit count is different from the logarithm.

The reason for this difference: we start with a single digit (1) and each multiplication by 10 gives us another digit. The logarithm is a count of the “extra multiplications we added in” but not our starting point.

When looking at 500,000, we can say the logarithm is 5.7. But how many digits does it have? Six — and I’d even describe it as a “6.7” digit number to distinguish it from a number like 100,000 which is *exactly* 6 digits.

Oh I got it now. Thanks Khalid. :)

[…] khả năng cảm nhận sự thay đổi về số lớn, hãy sử dụng hàm log (xem thêm sự kỳ diệu của hàm log ở […]

Forty years after my last maths lesson, I now find I have to get up to speed on logarithms. Excellent post, clear and well written, it brought it all back to me in a few minutes.

Thanks David, happy to hear it clicked.

100 increases to $150 in 5 years. What is the yearly interest rate? I got 5√150/100=8.45%. and when working it out logically, that’s the right answer. How did you get ln (150/100) /5=8.12%?

logerthems are very tuff

awesome,….

helpfull man,….

thanx for share

Richter’s scale does NOT end at 10, but there just have never been any earthquake with higher magnitude. (I think that even magnitude 10 was not reached.)