A Practical Use For Logarithms

What can you do when you have to describe phenomena that extend over many orders of magnitude? One option is to use different units; this is what we typically do in every-day life: We use centimetres or inches to describe distances on our desks, we use feet or yards or metres to quote the dimensions of a room, we use kilometres or miles to tell someone how far it is from here to another city, and we use light-years to communicate the distances to other stars.

This is fine, because in every-day discourse we find it convenient to quote relatively small numbers, perhaps up to the hundreds or thousands. However, it is awkward if we wish to compare distances. Consider the following table:

Distance from Earth to Alpha Centauri 4.37 light-years
Distance from Earth to Pluto (approx) 5.9 billion km
Distance (by airplane) from Toronto to Vancouver 3400 km
Height of average North American adult male 5′ 10”
Thickness of a human hair (approx) 100 micrometres
Bohr radius (of hydrogen atom in its ground state) 0.5 Angstrom

Because of our experience with our world, it’s pretty easy to see that the entries in the table are in order from largest to smallest, but if unknown items were listed, it would take some work to figure out the order of the sizes. That’s not good; a good table should allow for comparisons at a glance. Even with these figures, can you tell at a glance whether the ratio of the two astronomical distances is larger or smaller then the ratio of the height of an average male to the radius of a hydrogen atom? I can’t. This is another serious problem with using different units in the same table.

OK, so let’s repeat the table, but this time use the same unit for each entry. This will be awkward because of the great range of the data; we can get around this by using scientific notation, and indeed, this is one of the great advantages of scientific notation (the other is the ease with which significant digits can be reported):

Distance from Earth to Alpha Centauri 4.1 × 1016 m
Distance from Earth to Pluto (approx) 5.9 × 1012 m
Distance (by airplane) from Toronto to Vancouver 3.4 × 106 m
Height of average North American adult male 1.78 m
Thickness of a human hair (approx) 1.0 × 10-4 m
Bohr radius (of hydrogen atom in its ground state) 5.0 × 10-11 m

OK, this second table is much better. To compare measures effectively, they should all have the same unit. And it’s relatively easy to compare ratios: Just ignore the factor in front of the power of 10, and compare the powers of ten, which gives a rough, order-of-magnitude estimate. That is, we just look at the exponents in the table.

For example, the ratio of the distance from Earth to Pluto and the distance from Toronto to Vancouver is about

$\dfrac{10^{12}}{10^6} = 10^6$

so the distance from Earth to Pluto is about a million times the distance from Toronto to Vancouver.

Similarly, the ratio of the thickness of a human hair to the radius of a hydrogen atom is about

$\dfrac{10^{-4}}{10^{-11}} = 10^7$

Thus, we estimate that the latter ratio is about 10 times larger than the former ratio.

However, if we do the calculation precisely, then we’ll see that there is a problem with this estimate. The precise values of the two ratios are

$\dfrac{5.9 \times 10^{12}}{3.4 \times 10^6} = 1.74 \times 10^6$   and   $\dfrac{1.0 \times 10^{-4}}{5.0 \times 10^{-11}} = 2 \times 10^6$

which means that the latter ratio is only about 1.15 times as large as the former ratio. The two ratios are almost the same! The latter is only 15% larger than the former, not 10 times as large, as we originally estimated.

So looking only at exponents in scientific notation gives us only a very rough estimate, but the imprecision in this case is extremely annoying. Isn’t there a way to do the same sort of thing, only more accurately?

Yes. Remembering that a logarithm is an exponent, perhaps using logarithms can do the same job, but precisely. And indeed they can. The following table repeats the data of the previous table, but adds a column for the (base 10) logarithm of each number.

Distance (x) log10(x)
Earth to Alpha Centauri 4.1 × 1016 m 16.61
Earth to Pluto 5.9 × 1012 m 12.77
Toronto to Vancouver 3.4 × 106 m 6.53
Height of average North American adult male 1.78 m 0.25
Thickness of a human hair (approx) 1.0 × 10-4 m –4.00
Bohr radius (hydrogen atom in its ground state) 5.0 × 10-11 m –10.3

Now let’s repeat the previous calculations: The ratio of the Earth-Pluto distance to the Toronto-Vancouver distance is calculated by subtracting the logarithms in the final column, to obtain 6.24, and then raising 10 to this figure. The ratio of the hair thickness to the radius of the hydrogen atom is calculated by subtracting the logarithms in the final column, to obtain 6.30, and then raising 10 to this figure. Comparing the differences in the two logarithms shows us that the actual ratios will be very similar; the ratio of the two ratios is $10^{6.30 – 6.24} = 10^{0.06} = 1.15$, as we calculated before.

So this is the ticket! If we wish to compare numbers that extend over many orders of magnitude, the most accurate way of doing so is to use the same unit to express each number, and then take the logarithm of each number. This has the effect of compressing the very large range of the data into a much smaller range, which is approximately the range of the exponents of the powers of ten in the expression of the numbers in scientific notation.

You may recall the use of logarithmic scales in various applications: Richter scale for seismic activity, pH scale for acidity, decibels for measuring sound intensity, and the logarithmic scale for apparent stellar brightness. Links to other, perhaps less familiar, examples can be found here.

It’s not necessary to use the logarithmic function to compress an inconveniently large range of numbers into a more convenient smaller range; another function could serve, as long as it is monotonic and has relatively small slope. But logarithms are typically used for this purpose because of their relation to exponents, which gives us a beautiful connection with order of magnitude.

For Part 2, click here.

(This post first appeared at my other (now deleted) blog, and was transferred to this blog on 22 January 2021.)