# The Most Interesting Logs in the World

I occasionally get a comments from people who see “log” in one of my posts and think “log base 10.” They’ll say they get a different result than I do and ask whether I made a mistake. So to eliminate confusion, let me explain my notation.

When I say “log,” I always mean natural log, that is, log base *e*. This is the universal convention in advanced mathematics. It’s also the convention of every programming language that I know of. If I want to use logarithms to a different base, I specify the base as a subscript, such as log_{10} for log base 10.

The reason logs base *e* are called natural, and the reason they’re most convenient to use, is that base *e* really is natural in a sense. For example, the function *k ^{x}* is its own derivative only when

*k*=

*e*. And the derivative of log

*(*

_{k}*x*) is 1/

*x*only when

*k*=

*e*.

All logarithms are proportional to each other. That is, log* _{b}*(

*x*) = log

*(*

_{e}*x*) / log

*(*

_{e}*b*). That’s why we can say something is logarithmic without specifying the base. So we might as well pick the base that is easiest to work with, and most people agree that’s base

*e*. (There are some exceptions. In computer science it’s often convenient to work with logs base 2, sometimes written lg.)

Logarithms base 10 have the advantage that they’re easy to compute mentally for special values. For example, the log base 10 of a 1,000,000 is 6: just count the zeros. So it’s good pedagogy to introduce logs base 10 first. But natural logs are simpler to use for theoretical work, and just as convenient to compute numerically.

Along these lines, when I use trig functions, I always measure angles in radians. Just like all advanced mathematics and all programming languages.

As with natural logs, radians are natural too. For example, the derivative of sine is cosine only when you work in radians. If you work in degrees, you pick up a proportionality constant every time you differentiate a trig function.

Natural logs and radian measure are related: Euler’s formula *e ^{ix}* = cos(

*x*) +

*i*sin(

*x*) assumes the base

*e*and assumes that

*x*measured in radians.

Published at DZone with permission of {{ articles[0].authors[0].realName }}, DZone MVB. (source)

Opinions expressed by DZone contributors are their own.

{{ nComments() }}