You are currently browsing the category archive for the ‘music’ category.

In this post, I will explain some different tuning systems and their advantages and disadvantages. First, let’s see what the basic goals are of tuning systems.

1. There should be 12 notes per octave, in half-step intervals.
2. An octave (12 half steps) should be at a ratio of 2:1.
3. A fifth (7 half steps) should be at a ratio of 3:2.

We’ll look at some other goals later on, but let’s start with these. Since 7 and 12 are relatively prime, these goals are sufficient to generate an entire tuning system. However, this would require that 7 octaves be the same as 12 fifths, or $2^7=(3/2)^{12}$. Unfortunately, this is not the case; in fact, it’s not even particularly close. We call the discrepancy, $3^{12}/2^{19}$, a Pythagorean comma.

The first two principles really cannot be compromised. (Well, in some Indian, Arabic, and Turkish tuning systems, the first principle is modified. A common Turkish tuning system consists of 53 notes to an octave, for reasons we will see later on.) The first principle is essential because pianos and other keyboard instruments have 12 notes per octave, and Western music is always written with the 12 notes per octave model in mind. The second principle is essential since we want to treat two notes that differ by an octave as being the same note in many cases; therefore any fudging on goal 2 leads to unacceptable results.

The third principle, however, can be modified, if necessary (and, as we have just seen, it is necessary). The most naïve way of fudging is to make 11 out of 12 fifths be in a 3:2 ratio, and fit the last one to whatever is needed to make the cycle work out. This is known as Pythagorean tuning.

One immediate drawback of Pythagorean tuning is that it makes the so-called “wolf” fifth unusable beyond repair; it just sounds awful. But there are also more subtle problems with Pythagorean tuning. To see these, let’s see one other goal.

4. A major third (4 half steps) should be at a ratio of 5:4.

For simplicity, let’s ignore the problem of the wolf fifth for now. There are other more relevant problems to worry about already. Since $4=7\times 4-12\times 2$, a major third should be four fifths minus two octaves. In terms of the ratios, this means that it would be necessary that $5/4=(3/2)^4/2^2=81/64$. In other words, we’re off by a factor of $81/80$. While this ratio may seem rather small, it turns out to be a very serious problem with the Pythagorean tuning system.

Mathematically, the problem is that we’re trying to factor rational numbers in terms of only powers of two and powers of three. Therefore, as soon as we need to use any prime greater than 3 (in this case, 5), we end up in trouble. However, we don’t really have to factor all rational numbers in terms of powers of two and three; we just have to approximate these factorizations reasonably well. Still, our goals so far are quite mutually incompatible, so we have to sacrifice something, somewhere.

As we pointed out, 5:4 is a better major third than 81:64, so let’s try to construct a tuning system that takes that into account. For simplicity, we’ll assume that our scales always start with C, and we’ll construct ratios for intervals above C. A good possibility is the following:

C 1

C-sharp 16/15

D 9/8

E-flat 6/5

E 5/4

F 4/3

F-sharp 45/32

G 3/2

A-flat 8/5

A 5/3

B-flat 9/5

B 15/8

C 2

This list is generated by using the rules described so far and using the ratio with smallest denominator when there are multiple choices. This tuning system is known as (5-limit) Just intonation, the 5 meaning that we have allowed ourselves to use rational numbers whose factorizations contain primes up to 5.

Naturally, the Just intonation chart should be compared to the chart for Pythagorean tuning, which is as follows (assuming we place the wolf between the G-sharp and the E-flat, which is as good a place as any):

C 1

C-sharp 2187/2048

D 9/8

E-flat 32/27

E 81/64

F 4/3

F-sharp 729/512

G 3/2

G-sharp 6561/4096

A 27/16

B-flat 16/9

B 243/128

C 2

Note the much larger denominators needed in Pythagorean tuning.

So, I pulled these goals out of thin air at the beginning, so I really ought to explain why they are natural goals. For that, it is necessary to discuss the overtone series.

On a string instrument, when a note is sounded, all integer mutliple frequencies are also sounded simultaneously. However, the higher multiples are quieter than the lower ones. Therefore, it is beneficial to have a tuning system that emphasizes at least the first few overtones, while possibly discarding higher ones. The first overtone, at a ratio of 2, sounds one octave higher than the original note (called the fundamental). The second overtone, at a ratio of 3, sounds an octave and a fifth higher than the original note. Subtracting the octave (or, equivalently, dividing by 2) tells us that fifths should be in a ratio of 3:2 above the fundamental. Continuing on, the third overtone is at a ratio of 4, so it sounds two octaves above the fundamental. The next overtone, at a ratio of 5, sounds two octaves and a third above the fundamental.

We really want all these notes to be part of a scale, since we tend to play several notes together, and common overtones yield pleasant sounds. So that’s where these goals I mentioned above come from.

So, it would appear that Just intonation is a good tuning system. However, again there are serious drawbacks. For example, from D to A, which is a perfect fifth, we have a ratio of 40:27, rather than the desired 3:2. There are many other intervals that are similarly problematical, always differing by a factor of 81/80 from the desired ratio. The result is that many such intervals must be avoided in Just intonation. Therefore, Just intonation is only usable in music which specifically avoids certain intervals. So, it’s really not a very nice solution.

One really obvious solution to the entire problem of tuning is just to make all the half steps equal, in a ratio of $2^{1/12}$. In fact, this temperament, known as equal temperament, is what is generally used on pianos today. What is gained by using equal temperament is that there are no wolf tones, and all intervals are usable. However, $2^{1/12}$ is irrational, so we do not get any perfect overtones or intervals with perfect ratios, except the octaves. So, in using equal temperament, one sacrifices all the overtones (except octaves) in order to get a uniformly playable system.

To many people, the sacrifice of overtones is unacceptable. Therefore, we’ll ignore equal temperament from now on.

One attempt to resolve our problems is to use the idea of Pythagorean tuning, but instead of putting the wolf tone all in one place, we spread it out over the octave by putting a quarter of a Pythagorean comma in four different places. To do this, we make the fifths C-G, G-D, D-A, and B-F-sharp a quarter of a comma smaller than the usual 3/2 ratio. Here is that system, known as Werckmeister I:

C 1

C-sharp 256/243

D $64/81\times \sqrt{2}$

E-flat 32/27

E $256/243\times 2^{1/4}$

F 4/3

G $8/9\times 8^{1/4}$

G-sharp 128/81

A $1024/729\times 2^{1/4}$

B-flat 16/8

B $128/81\times 2^{1/4}$

C 2

(Werckmeister also devised several other temperaments, but this one is the most popular.) Of course, we’ve lost many of the perfect fifths here. However, they’re not that bad, and the thirds are also pretty good. (The ratio of the C-E here, $256/243\times 2^{1/4}$, and the desired C-E, 5:4, is about 1.002; that’s definitely acceptable. Of course, some thirds aren’t very good, but these ones are likely to be played less frequently in most “reasonable” keys. So Werckmeister I seems like a pretty good temperament.

I’ll post about some other temperaments (such as quarter comma and sixth comma meantone) another day, but this is a math blog, so I’d like to say something that has some semi-serious mathematical content. In particular, I mentioned earlier that 53 notes to an octave can lead to a very nice tuning system, so I’ll explain where I got that number. Ideally, we’d like some number of fifths to be equal to some other number of octaves. This would allow us to satisfy goals 2 and 3 perfectly. This means that we would like to solve $(3/2)^x=2^y$ as a Diophantine equation (meaning, look for integer solutions). Unfortunately, the only solution is $(0,0)$, which is completely useless. But all is not lost, as it is possible to approximate solutions to this equation. Really, we only require that $(3/2)^x\approx 2^y$. I prefer to get rid of the variable $y$ and look for approximate rational solutions to $(3/2)^x\approx 2$. In other words, I want good rational approximations of $\log_2(3/2)$.

We can easily find the best possible rational approximations by using continued fractions. The continued fraction coefficients begin with 0, 1, 1, 2, 2, 3, 1, 5, 2, 23, meaning that

$\log_2(3/2)=\frac{1}{1+}\frac{1}{1+}\frac{1}{2+}\frac{1}{2+}\frac{1}{3+}\frac{1}{1+}\frac{1}{5+}\frac{1}{2+}\frac{1}{23+\cdots}$.

(I can’t figure out how to get WordPress to allow nested fractions, unfortunately.) Cutting this off at various points gives the following sequence of rational approximations for $\log_2(3/2)$:

1, 1/2, 3/5, 7/12, 24/41, 31/53, 179/306, 207/353, and I don’t really want to work out the next one. In these fractions, the numerator represents the number of units that are to be in a fifth, and the denominator represents the number of units that are to be in an octave. So the usual system corresponds to the approximation 7/12. Good rational approximations are ones whose denominators are much smaller than the next term of the continued fraction approximation. Therefore, 7/12 is quite good, as is 31/53. Thus a 53-note scale is a very natural alternative to the standard 12-note scale.