On a modern tuned instrument, an octave has twelve notes with a common frequency ratio of $2^{\frac{1}{12}}$

Of course, twelve is a very good choice for the number of notes, as


$2^{\frac{7}{12}}$ is very close to $\frac{3}{2}$,

$2^\frac{5}{12}$ is very close to $\frac{4}{3}$

$2^{\frac{4}{12}}$ is very close to $\frac{5}{4}$

Those are the simplest possible ratios and thus produce the most harmonious chords, so it seems quite natural that it was adopted.

But why is a twelve tone system the best for approximating these fractions?

Mathematically, here is the question:

Let $S_n$ be the set of all $2^{\frac{i}{n}}$ for some $n$

For which values of $n$ are the elements of $S_n$ closely approximated by rational numbers $\frac{a}{b}$ where $a,b$ are small natural numbers?

  • $\begingroup$ By the way I would like an error function pegged to the size of $n$ as ideally a musical scale should be as small as possible. Also, if two potential values of $n$ share a common factor the sets will share some values in common, so I am interested in enumerating coprime values of $n$ $\endgroup$ – aman Dec 25 '19 at 14:23
  • $\begingroup$ There are other values of $n$ that work pretty well and that some music theorists have used or suggested using in musical compositions. See e.g. en.wikipedia.org/wiki/Harry_Partch%27s_43-tone_scale $\endgroup$ – Gerry Myerson Dec 25 '19 at 15:10
  • $\begingroup$ It's not the best. If you add more tones you get closer approximations, and people do write music for a 53-tone equal-tempered scale. $\endgroup$ – MJD Dec 25 '19 at 15:11
  • 1
    $\begingroup$ I did. Don't know if it makes sense to tick my own answer? :) $\endgroup$ – aman Dec 29 '19 at 16:22
  • 1
    $\begingroup$ You may choose to accept the answer you’ve given. $\endgroup$ – Lubin Dec 29 '19 at 16:49

The accuracy of a particular interval when compared to the perfect (just) ratio is measured in cents, with one cents being a logarithmic unit with 1 cent calibrated to 0.01 semitones on a 12-tone equal-tempered scale

$12$ is very good for approximating a variety of different ratios quite accurately, especially the perfect 5th and 4th (the simplest ratios of $\frac{3}{2}$ and $\frac{4}{3}$ are approximated to a very accurate degree-only 2 cents off

One point to be noted, of course, is that in any equal-temperament scale, the perfect fifth and perfect fourth will be equally well approximated. This is proved below

Say that the $a^{th}$ and $b^{th}$ degrees of the scale approximate the ratios $4/3$ and $3/2$ respectively. Then the following represent their distance from just intonation (the amount by which the perfect fourth and fifth intervals are "of tune")

All logarithms are to the base of $2^{1/n}$ where $n$ is the number of intervals



Note that the difference between the RHS's above is clearly an integer (as $log(2)$ is an integer)

As the error in semitones is by definition less than $1$ (otherwise a and b would not be the best interval degrees), it is clear that both approximations are off by the same amount

Such intervals such as $4/3$ and $3/2$ are called "complementary intervals".

If we are only concerned with the best way to approximate these two ratios we can use https://oeis.org/A060528 to do so.

From a practical standpoint, for any widely applicable music system, we would want our number of intervals to be in that sequence, as the perfect fifth and fourth are by far the most significant ratios in music.

Furthermore, as there are relatively few ratios which are harmonious to the human ear, a scale with too many intervals would have too many dissonant sounding notes, simply by PHP.

The twelve-tone scale was selected in Europe in the 18th century due to both practical and mathematical factors

Since then, twelve tone equal temperament scale has largely taken precedence all over the world due to the mixing of cultures over the past few hundred years.

So, in conclusion, no, 12 is not the only number possible. However, due to the consonance-spotting capacity of human ear, it belongs to a very short list of possible numbers that could have worked.

Once selected, it worked well enough, there was never a need to change it.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.