Iâ€™ve written before about three simple approximations for logarithms, for base 10

log_{10}(*x*) â‰ˆ (*x* â€“ 1)/(*x* + 1)

base *e*,

log* _{e}*(

*x*) â‰ˆ 2(

*x*â€“ 1)/(

*x*+ 1)

and base 2

log_{2}(*x*) â‰ˆ 3(*x* â€“ 1)/(*x* + 1).

These can be used to mentally approximate logarithms to moderate accuracy, accurate enough for quick estimates.

Hereâ€™s whatâ€™s curious about the approximations: the proportionality constants are apparently wrong, and yet the approximations are each fairly accurate.

It is **not** the case that

log* _{e}*(

*x*) = 2 log

_{10}(

*x*).

In fact,

log* _{e}*(

*x*) = log

*(10) log*

_{e}_{10}(

*x*) = 2.3 log

_{10}(

*x*)

and so it seems that the approximation for natural logarithms should be off by 15%. But itâ€™s not. The error is less than 2.5%.

Similarly,

log_{2}(*x*) = log_{2}(10) log_{10}(*x*) = 3.32 log_{10}(*x*)

and so the approximation for logarithms base 2 should be off by about 10%. But itâ€™s not. The error here is also less than 2.5%.

Whatâ€™s going on?

First of all, the approximation errors are nonlinear functions of *x* and the three approximation errors are not proportional. Second, the approximation for log* _{b}*(

*x*) is only good for 1/âˆš

*b*â‰¤

*x*â‰¤ âˆš

*b*. You can always reduce the problem of calculating log

*(*

_{b}*x*) to the problem of calculating the log in the range 1/âˆš

*b*â‰¤

*x*â‰¤ âˆš

*b*and so this isnâ€™t a problem.

Hereâ€™s a plot of the three error functions.

This plot makes it appear that the approximation error is much worse for natural logs and logs base 2 than for logs base 10. And it would be if we ignored the range of each approximation. Hereâ€™s another plot of the approximation errors, plotting each over only its valid range.

When restricted to their valid ranges, the approximations for logarithms base *e* and base 2 are *more* accurate than the approximation for logarithms base 10. Both errors are small, but in opposite directions.

Hereâ€™s a look at the relative approximation errors.

We can see that the relative errors for the log 2 and log *e* errors are less than 2.5%, while the relative error for log 10 can be up to 15%.

Â