Powers to The People

“You say logarithms and exponents have to do with growth, Mr Moire?”Log Exp and slide rule captioned

“Mm-hm.  Did they teach you about compound interest in that Modern Living class, Jeremy?”

“Yessir.  Like if I took out a loan of say $10,000 at 10% interest, I’d owe $11,000 at the end of the first year and, um…, $12,100 after two years because the 10% applies to the interest, too.”

“Nice mental arithmetic.  So what you did was multiply that base amount by 1+10% the first year and (1+10%)² the second, right?”

“Well, that’s not the way I thought of it, but that’s the way it works out, alright.”

“So it’d be (1+10%)³ the third year and in general (1+rate)n after n years, assuming you don’t make any payments.”

“Sure.”

“OK, how do we have to revise that formula if the interest is compounded daily and you get lucky and pay it off in a lump sum after 19 months?”

“Can I use your whiteboard?”

“Go ahead.”

“OK, first thing to change is the rate, because the 10% was for the whole year.  We need to use 10%/365 inside those parentheses.  But then we’re counting time by days instead of years.  Each day we multiply the previous amount by another (1+10%/365), which makes the exponent be the number of days the loan is out, which is 19 times whatever the average number of days in a month is.”

“Why not just use 19×(365÷12)?”

“Can we do that?  In an exponent?”

“Perfectly legal, done in all the best circles.”

“So what we’ve got is
10000×[1+(10%/365)]19×(365÷12).

“Try poking that into your smartphone’s spreadsheet app and format it for dollars.”

“In spreadsheet-ese that’d be
=10000*(1+(0.1/365))^(19*(365/12)).
Hah!  The app took it, and comes up with … $11,715.31.  Lemme try that with two years that’s 24 months.  Now it’s $12,213.69.  Hey, that’s $123 more than two years compounded once-a-year.  Compounding more often generates more interest, doesn’t it?”

“Which is why daily compounding is the general rule in consumer lending.  But there’s a couple more lessons to be learned here.  One, you can do full-on arithmetic inside an exponent.  That’s what the log log scales are for on a slide rule.  Two, the expression you worked up has the form
base×(growth factor)(time function).
Any time you’re modeling something that grows or shrinks in some percentage-wise fashion, you’re going to have exponential expressions like that.”

“Hey, I tried compounding more often and it didn’t make much difference.  I put in 3650 instead of 365 and it only added 30¢ to the total.”

“Which gives me an idea.  Load up cells A1:A7 in your spreadsheet with this series: 1, 3, 10, 30, 100, 300, 1000.  Got it?”

“Ahhh … OK.  Now what?”

“Now load cell B1 with +10000*(1+(0.1/A1))^(24*(A1/12)).”

“Says $12,100.”

“Fine.  Now copy that cell down through B7.”

“Hmm…  The answers go up but by less and less.”

“Right.  Now highlight A1:B7 and tell your spreadsheet to generate a scatter plot connected by straight lines.”

“Gimme a sec … OK.  The line goes straight up, then straight across almost.”

“Final step — click on the x-axis and tell the program to use a logarithmic scale.”diminishing returns

“Hey, the x-numbers scrunch and wrap like on the A, B and K scales on Dad’s slide-rule.”

“Which is what you’d expect, right?  They both use logarithmic scales.  The slide-rule uses logarithms to do its arithmetic thing.  The graphing software lets you use logarithms to display big numbers together with small numbers.  But the neat thing about this graph is that it shows two different flavors of a general pattern.  Adding something, say 20, to a number to the left on the x-axis moves you a longer distance than adding the same amount somewhere over on the right.  That’s diminishing returns.”

“Look, the heeling-over curve shows diminishing returns from compounding interest more and more often.”

Exploding returns“Good.  Now copy A1:A7 by value into C1:C7 and generate a scatter plot of B1:C7. This time apply the logarithmic scale to the y-axis. This’ll show us how often we’d need to compound to get the yield on the x-axis.”

“Whoa, it blows up, like there’s no way to get up to $12,300.”

“Call it exploding returns.  Increasing the exponent increases the growth factor’s impact.  Beyond a threshold, a small change in the growth factor can make a huge difference in the result.”

“Seriously huge.”

“Exponentially huge.”

~~ Rich Olcott

Advertisements

Log-rhythmic gymnastics

I recognized the knock.  “Come on in, Jeremy, the door’s open.”

“Hi, Mr Moire.  Can you believe this weather?  Did Miss Anne like her gelato?  What’s this funny ruler thing that my Dad sent me?  He said they used it to send men to the moon.”

log rhythm

“No, yes, it’s called a slide rule, and he’s right — back in the 1960s engineers used slip-sticks like that when they couldn’t get to a four-function mechanical calculator.  Now, though, they’re about as useful as a cast-iron bath towel.  Kind of a shame, because the slide rule is based on mathematical principles that are fundamental to just about all of mathematical physics.”

“Like what?”

“The use of exponents, for one.  Add exponents to multiply, subtract to divide.  Quick — what’s 100×100×100?”

“Uhh…  Ten million?”

“Nup.  But if I recast that as 102×102×102=102+2+2?”

“106.  Oh, that’s a million.”

“See how easy?  We’ve known that kind of arithmetic since Archimedes.  The big advance was in the early 1600s when John Napier realized that the exponents didn’t have to be integers.  Take square roots, for example.  What’s the square root of 100?”

“Ten.”

“Sure — √100=√(102)=102/2=101=10.  Now write √10 with exponents.”

“Would it be 101/2?”

“Let’s see.  Do you have a spreadsheet app on that tablet you carry?”

“Sure.”

“OK, bring it up.  Poke =10^(0.5) into cell A1, and =A1^2 into A2.  What do you get?”

“Gimme a sec … the first cell says 3.162278 and the second says … exactly 10.”

“Or as exact as that software is set up for.  So what we’ve got is that 0.5 is a perfectly good power of ten, and exponent arithmetic works the same with it and all the other rational numbers that it does with integers.  Too big a leap, or are you OK with that?”

“OK, I suppose, but what does that have to do with this gadget getting people to the Moon?”

“Take a good look at at the C scale, the lowest one on the middle ruler that slides back and forth.  Are the numbers evenly spaced out?”

“No, they’re stretched out at the low end, scrunched together at the high end.”Slide rule 3“Look for 3.16 on there.  You read it like a ruler — the number before the decimal point shows as a digit, then you locate the fractional part with the high and low vertical lines.”

“Got it.  About halfway across.”

“It’s exactly on center if that’s a good slide rule.  A number’s distance along the scale should be proportional to the exponent of 10 (we call it the logarithm) that gives you that number.  The C scale’s left end is 1.0, its right end is 10.0, and 3.162 is halfway.”

“Ah, I see how it works.  Adding distances is like adding exponents.  So if I want to multiply 2 by 3 I slide the middle ruler until its 1 is against 2 on the D scale, then I look for 3 on the C scale and, yes! it’s right next to 6 on the D scale!  Oh and the A and B scales wrap twice in the same distance so they must be logarithms for squares?  Hah, there’s 10 on B right above where I found 3.16 on CK wraps three times so it must be cubes, but why did they call it K?”

“Blame the Germans, who spell ‘cube‘ with a ‘k‘.  What do you suppose CI does?”

“Hmm, it runs backwards.  Adding with CI would be like subtracting distances which would be like dividing, so … I’ll bet it’s ‘C-Inverse‘!”

“You win the mink-lined frying pan.  So you see how even a simple 5- or 6-scale device can do a lot of calculation.  The really fancy ones had as many as a dozen scales on each side, ready for doing trigonometry, compound interest, all kinds of things.  That’s the quick compute power the rocket engineers used back in the 50s.”

“Logarithms did all that, eh?”

“Yup, that and the inverse operation, exponentiation.  Of course, you don’t have to build your log and exponent system around 10.  If you’re into information theory you might use powers of 2.  If you’re doing physics or pure math you’re probably going to use a different base, Euler’s number e=2.71828.  Looks weird, but it’s really useful because calculus.”

“So logarithms do calculating.  You said something about physical principles?”

“Calculating growth, for instance…”

~~ Rich Olcott