# Mathematics: Musical Temperament

- Introduction
- Terminology
- Greek origins of Western Music
- Tempering
- Continued Fractions
- Development of 12-tone scale systems
- Just Intonation
- Meantone
- Well Temperament
- Equal Temperament
- Remarks on Temperament
- Future developments in Temperament
- Concluding remarks
- Bibliography
- End notes
- Comments

## Introduction

Mathematics is the fundamental basis in understanding the origins of musical scales. Clearly there is an underlying rationale behind composers and musicians producing a multitude of physical and mental responses to listeners of music throughout the world.

## Terminology

As a basis for discussions on the creation of musical scales one must define the following terms:

*Pitch:*The auditory attribute of sound according to which sounds can be ordered on a scale from low to high.*Frequency:*The number of cycles or events per unit time. Physically, a*pitched*sound corresponds to a sound wave that is periodic with respect to time. Here, frequency will be measured in periodic cycles per second, Hertz or Hz.*Interval:*The ratio of two frequencies, here defined as n/m where n is the lowest frequency, m the highest, n, m … ℕ. Non rational intervals will be defined in ℝ in later stages of the investigation.*Fifth:*The ratio of two frequencies of 3/2 where*pure fifth*denotes the exact value and*perfect*or*tempered fifth*denotes an approximation of this value.

## Greek origins of Western Music

The Greeks were the first people to relate Mathematics with musical scales, noticing the pleasing sounds of melodic notes sounded in succession and harmonic notes sounded simultaneously, using scales created by compounding ratios of their frequencies. The octave, the basis of music worldwide was identified as essentially the same note, being exactly twice the frequency with a ratio of 2/1. Initially, early Greeks constructed basic scales based on compounding the basic frequency ratios of 2/1, the octave and 3/1, a “true fifth” in the modern Western scale. Claudius Ptolemy, a highly influential Greek astronomer and geographer born around 85 AD in Egypt was less well known for his work on extending the early musical scale. He investigated the exact series of 2/1, 3/2, 4/3, … and then compounded these to give ratios such as 5/3 found from 4/3 and 5/4.[1] Further analysis on Ptolemy’s influence in Western music will be referred to after determining tempering, required for the existence meaningful musical scales.

## Tempering

As with many aspects of theoretical music, there is a mathematical rationalization for harmonic and melodic pairs of notes, forming a scale that can be simplified into ratios and compound ratios. However, it is important to investigate the adoption of the 12-tone scale in use today by observing the critical relationship between the octave and *pure* fifth with respective ratios of 2/1 and 3/2. These very common intervals form the basis of various musical scales across the world. In Western music the octave is identified by the same letter, A to A with the latter having double the pitch of the first note. The *perfect* fifth occurs 5 notes higher on the scale, counting the base note as the first note. E can be sounded to produce a harmonic or melodic perfect fifth above the base note, A. This conveys two notes on the keyboard corresponding to the octave and a *perfect* fifth.

Equal temperament, where all 12 notes have identical intervals, the octave is exactly an interval of 2:1 while the perfect fifth falls very slightly short of a true fifth with the exact ratio of 3:2. In using the pair of frequencies, the octave and the fifth one may create a 7-tone scale based on the white notes on the keyboard closely corresponding to the keys F, G, A, B, C, D, E.[2] Here, this *Lydian mode* scale is actually a *Pythagorean* scale obtained by a cycle of fifths sounded in succession, ignoring differences of more than an octave; transferring these down an octave (half the pitch). If the start note, here F, is any given frequency, one may reduce the series to a single octave range and then rearrange the notes in frequency order to acquire the relative frequencies: 1, 9/8, 81/64, 726/512, 3/2, 27/32, 243/128. However, in actual fact this series does not conclude at the seventh tone, but leads on the more frequencies, condensing the scale into increasingly more notes in the octave range.

There does not exist a finite number of positive integral of true fifths to an integer value of octaves as the Fundamental Theorem of Arithmetic states that there is no positive integral power of 3/2 is an integral power of 2.[3] Presenting an infinitely long series, a physically impracticable scale can be found by extending the scale beyond the Pythagorean limits of seven tones. One must address the fundamental effect that this would have on any musical instruments as an infinitely long scale could be “infinitely difficult” to document for the benefit of musicians, let alone offering any practical solutions to instrument development. Consequently, not all is what it seems as this text has been ripped from *Nahoo* at nahoo.net. In order to address this issue one must manipulate the initial frequencies in such a way as to give a suitably small finite series of frequencies, resolving fundamental issues on the aforementioned practicalities. One must find a suitable number of fifths and octaves giving a suitably small error in aggregated frequencies. Let m be the number of *tempered* fifths and n be the number of octaves. The *tempered* m–fifths should be equal to n-octaves resulting in a succinct number of notes in the scale whilst remaining pleasing to the ear. Again, the new tempered fifths will be arranged in pitch order over the octave interval.

Observing the pure fifth without tempering can be described as *spiral of fifths*, producing an infinite series: a correctly *tempered fifth* produces a finite number of octaves and the spiral can be collapsed to give a *circle of fifths*.

As Figure 3 illustrates, the error between the pure fifth and tempered perfect fifth only really becomes around m-octaves. Clearly larger values of m, n would give smaller errors and the diagrams only serve to emphasize these. The difference in fifths between the two series is heavily dependent on finding a suitable approximation for m and n.

## Continued Fractions

Evidently, m and n need to be approximated to give a quotient estimator containing suitably small integer values for reasons mentioned in the previous section. Continued fractions may be used to acquire these values. Firstly, one must state the relationship between m and n where the ratio 3/2 m-times approximately gives 2/1 n-times or simply: 3/2m ≈ 2n, this may be rearranged to give: a_{1} + 1/a_{2} + 1/a_{3} + 1/a_{4} + … with the i^{th} convergent reduced to p_{i}/q_{i} for values of a_{i}, p_{i} (number of octaves), q_{i} (number of tempered fifths), i = [1,10] and the error defined by: ln 3/2/ln 2 – p_{i}/q_{i}
and p_{i}/q_{i} greater/less than ln 3/2/ln 2 defining the pitch relation between pure and tempered perfect fifth.

i | a_{i} | p_{i} (octaves) | q_{i} (fifths) | Error | Pitch of tempered fifth |
---|---|---|---|---|---|

1 | 0 | 0 | 1 | 5.850 × 10^{-1} | Lower pitch |

2 | 1 | 1 | 1 | 4.150 × 10^{-1} | Higher pitch |

3 | 1 | 1 | 2 | 8.496 × 10^{-2} | Lower pitch |

4 | 2 | 3 | 5 | 1.504 × 10^{-2} | Higher pitch |

5 | 2 | 7 | 12 | 1.629 × 10^{-3} | Lower pitch |

6 | 3 | 24 | 41 | 4.034 × 10^{-4} | Higher pitch |

7 | 1 | 31 | 53 | 5.684 × 10^{-5} | Lower pitch |

8 | 5 | 179 | 306 | 4.820 × 10^{-6} | Higher pitch |

9 | 2 | 389 | 665 | 9.470 × 10^{-8} | Lower pitch |

10 | 23 | 9126 | 15601 | 1.683 × 10^{-9} | Higher pitch |

Here, the numbers of fifths required, giving a better approximation the ratio m-fifths to n-octaves also indicates the number of tones for each i-scale. Now, to establish an equal temperament based on the tempered fifth one must divide the octave into m equal parts. By dividing the octave into equal intervals one can establish set frequencies for other tones in the scale. From the table, scales of 12, 41 or 53 tones would give accurate approximations of the pure fifth whilst maintaining a realistically playable set of notes. It would be astute to calculate the benefit of the increased tones in each scale to ascertain the benefits of increased tones to pitch accuracy. Perhaps 53 tones provides small scientific benefits over 41 tones in comparison to increased difficultly to master such a scale on a musical instrument. On the other hand, 12 notes per scale could be suitably accurate and playable to suffice. Clearly, any findings will be subject to real-world practical implications, however this should not be ignored.

In essence, m/n is approximated by
ln 3/2/ln 2 with the sequence of Continued Fractions offering a direct method of obtaining such a solution. Nevertheless, one must analyse these errors using a sequence of intermediate convergents to the continued fractions. Utilising intermediate values one may consider the maximum error in pitch perceived by the human ear. Let e > 0 be given as the largest interval sounded before an attentive listener notices an inconsistency. If an octave was to be sounded at 1.96 times the frequency rather than 2 (sounded flat), e = 0.04 in error. Initially, q_{i} = 12; the standard equal tempering in place today, one would expect to find tempered fifth lower than the true fifth that gives a suitably small error. Conversely, this only occurs with a scale of 53 tones, the proceeding tempered fifth with a lower frequency than the true fifth. In order to consider a tempered fifth higher than the true fifth, take q_{i} = 41 giving the intermediate coefficients 3/5, 10/12, 17/29, 24/41 where ln 3/2/ln 2 – 27/29 » 0.001244 > e. On this basis one can take a scale with 29 tones as an improvement of the standard 12-tone scale in use in Western music today. Due to the *beat phenomena*,[4] a trained ear can detect pitch errors far smaller than the e-value mentioned above. One can detect slight pitch errors when two notes sound simultaneously to e = 0.001 or even less.[5]

In Western music the 12-tone scale was readily used and gradually refined to the equal tempered scale in use today. A principal difference between Chinese and Western musical intonation is the Chinese preference for a wide range of intervals leading to an increased magnitude of their harmonic system.[6] Evidence suggests that equal temperament was utilised in China dating back to as early as the 5th Century BC.[7] Consequently, not all is what it seems as this text has been ripped from *Nahoo* at nahoo.net. The Chinese are known to utilise the 41- and 53-tone scales in the woodwind and stringed instruments. In addition, many of the techniques originating from China are still present in traditional Japanese music being performed in tea ceremonies and costume plays. It is important to add that less accurate scales containing only five tones (pentatonic scale), thought to have originated in Western Africa, were widely used in work songs and later utilised in Jazz, particularly the blues. The pentatonic scale is highly prevalent in central European, Turkic and Middle Eastern music folk songs and the source of inspiration for composers such as Kodaly and Bartok.

## Development of 12-tone scale systems

### Just Intonation

Primarily in use with pentatonic, modal or diatonic scales this Pythagorean-Ptolemy scale based on series octaves, pure fifths and the 2 harmonics. Note values are derived mathematically, however unsuitable for chromatically diverse music today as pairs of intervals can sound very different depending on their base note. After establishing the 7-tone scale, mentioned earlier, one can establish semi-tones to make up the 12-tone scale by fixing the semi-tone interval found on A, B and E, F to other notes in the scale giving an increasingly impracticable chromatic scale.

Clearly this method of deriving scales, though mathematically sound, does not lend itself well to developed Western music, let alone any further melodic and harmonic intervals between chromatic notes.

After a failed attempt by Gaffurius in 1496 to create a scientifically established temperament, Giovanni Maria Lanfranco, born in Italy in 1533 produced the first instructions for tuning instruments to equal temperament.

The fifths are tuned so flat that the ear is not well pleased with them; and the [minor] thirds are as sharp as can be endured.

Giovanni Maria Lanfranco[8]

Despite this relatively early discovery, the Romantic composers were the main influence in Western music before equal tempered tuning was universally adopted. The modern piano signalled the introduction of equal temperament around 1854, helped by the ever-increasing demand on versatile instruments for chromatics and a wider range of keys. Helmholtz produced the first physical evidence leading to an understanding of how music probably arose with the publication of “Sensations of Tone” in 1877.

Helmholz’s research lead him to the conclusion that the super particular ratios with small harmonic intervals deliver the most consonant combinations of sounds. He became acutely aware of the intonation of frequency ratios. He noticed that ratios containing small numbers sounded bare, whilst some frequencies such as 8/5 sounded particularly harmonious and pleasing to the ear. His comments would have a positive effect on the Baroque and Classical development of Western music.[9] The table shows *just ratios* derived geometrically by Ptolemy.

n | Musical Name | Ratio | Compound ratio |
---|---|---|---|

1 | Minor second | 16/15 | – |

2 | Major second | 10/9 | – |

3 | Minor third | 6/5 | – |

4 | Major third | 5/4 | – |

5 | Perfect fourth | 4/3 | – |

6 | Diminished fifth | 45/32 | (9/8) ∙ (5/4) |

7 | Perfect fifth | 3/2 | – |

8 | Minor sixth | 8/5 | (2/1) / (5/4) |

9 | Major sixth | 5/3 | (4/3) ∙ (5/4) |

10 | Minor seventh | 16/9 | (2/1) / (9/8) |

11 | Major seventh | 15/8 | (5/4) ∙ (3/2) |

12 | Octave | 2/1 | – |

*Just ratios*, tones n

Now using the equal tempered ratio of or each of the 12 tones one may compare the deviation on all notes in the scale. In the table below denoting the nth note and respective equal tempered values, error is found by taking the percentage difference of the ratio between equal tempered and just ratios.

n | Musical name | Equal tempered | Just ratios | Error % |
---|---|---|---|---|

1 | Minor second | 1.0595 | 16/15 = 1.0667 | -0.67% |

2 | Major second | 1.1225 | 10/9 = 1.1111 | 1.03% |

3 | Minor third | 1.1892 | 6/5 = 1.2000 | -0.90% |

4 | Major third | 1.2599 | 5/4 = 1.2500 | 0.79% |

5 | Perfect fourth | 1.3348 | 4/3 = 1.3333 | 0.11% |

6 | Diminished fifth | 1.4142 | 45/32 = 1.4063 | 0.57% |

7 | Perfect fifth | 1.4983 | 3/2 = 1.5000 | -0.11% |

8 | Minor sixth | 1.5874 | 8/5 = 1.6000 | -0.79% |

9 | Major sixth | 1.6818 | 5/3 = 1.6666 | 0.91% |

10 | Minor seventh | 1.7818 | 16/9 = 1.7777 | 0.23% |

11 | Major seventh | 1.8877 | 15/8 = 1.8750 | 0.68% |

12 | Octave | 2.0000 | 2/1 = 2.0000 | 0.00% |

*Just ratios*, tones n

There are significant errors with the minor third and major sixth and the resulting dissonance was intolerable to audiences in the 16^{th}, 17^{th} and 18^{th} centuries delaying the widespread introduction of this system until the mid 19th century. Even well into the 19^{th} century, sceptics of the equal tempered tuning of instruments criticised the non-Pythagoras system:

The modern practice of tuning all organs to equal temperament has been a fearful detriment to their quality of tone. Under the old tuning, an organ made harmonious and attractive music. Now, the harsh thirds give it a cacophonous and repulsive effect.

William Pole[10]

### Meantone

Meantone or Restricted Temperament was developed under a similar premise to Just Intonation with a shift of towards scales based on pure thirds. One may construct a basis for this model on 4 pure fifths on C, G, D, A and then a *pure* major third resulting in a slightly better comma for the approximation of 3 octaves. The name “meantone” provides some insight into this system where the note D lies exactly between the notes C and E. Enharmonic equivalents are not present in Meantone, chromatic semitones vary depending on the base note, requiring retuning as the musical keys change in separate pieces of music. In fact, many remote keys with 4 or more sharps or flats would seem widely out of tune requiring the majority Baroque composers to avoid entire ranges of keys until an intermediary system was developed to handle a wider range of keys.

### Well Temperament

The shortage of playable keys in Just Intonation provoked the development of Well Temperament around the early Baroque era. Despite the benefits of this scale, it was not widely used until the time Bach in the late Baroque era in the 18^{th} century. Bach’s “The Well Tempered Clavier” was specially written to validate this system over the prevailing Meantone of the time. Previously, two part harmonies utilising harmonic intervals of thirds and sixths required composers to standing within the limits of Meantone. In passing, it is worth mentioning this text has been copied from *Nahoo* at nahoo.net. Occasionally, composers would add *prepared*, *stated* and *resolved* dissonances to accommodate for both the scale limitations and the audiences’ expectations of the period. Despite some minor tunings between music of different keys, this system allowed composers and musicians alike to experience a new chromatic age in classical music with scales containing up to 21-tones with double flat and double sharp tones. Unlike Meantone, this scale system allows for chromatic keys to be tempered to be enharmonically equivalent allowing for numerous modulations of keys throughout a single musical piece. Although Meantone heavily influenced this system, certain keys are technically more accurate than others. These differences provide a plethora of new *key colours*, sharp keys lively and bright and flats dark and subdued.[11] On this remark, Well Temperament is remarkably close to Equal Temperament discussed previously making the practical transition from one system to another near faultless.

### Equal Temperament

Mathematically defined, the *Standard European 1/12 Diatonic Comma Equal Temperament* is the most versatile scale system and familiar to all listeners and players of Western Music. Its simplicity and versatility ensured that the system is still in wide use today. Ratios between all 12 tones are fixed identically to 2^{1/12} and of primary benefit to the modern piano, invented almost 300 years ago and one of the most adaptable instruments ever created.

## Remarks on Temperament

It is important not to forget that many groups of musical instruments are only partially or completely independent of rigid temperaments, with the human voice, strings and the trombone benefiting from an unrestricted number of tones. In fact only keyboard instruments and the harp are truly fixed with little or no leeway for pitch changes during a piece. Instruments and voices in orchestras and choirs do not share the same temperament, with only tuneable percussion and keyboard instruments actually adopting the exact equal temperament.

## Future developments in Temperament

As with all technological developments one must look at the restricting factor of instruments utilising a specific temperament. Fixed temperament instruments using the 12-tone scale utilised are unable to play music from other cultures around the world. Even attempts to split the scale into half-tones cannot achieve a completely multi-cultural musical range.

A Brighton-based composer, Geoff Smith appears to have found a method of increasing the pianos tuning capabilities indefinitely, breaking free from the realms of fixed tuning that restrict many instruments at varying levels. He has claimed that a device attached to the piano would allow for “fluid tuning” going far beyond the 88-note range and into the territory of microtonal instruments. It is a pleasant surprise that the piano is being seriously overhauled after a somewhat uneventful 100 years for the instrument.[12]

## Concluding remarks

Equal temperament should not be accepted as the decisive temperament in Western music. The potential for a real change in the diversity of Western music is on the horizon, bringing a new world of music to everyone.

## Bibliography

*J. M. Barbour*, Music and Ternary Continued Fractions, This Monthly, Volume 55, 1948*T. Blackburn, H. Stoess*, Alternate Temperaments: Theory and Philosophy*A. A. Goldstein*, SIAM Review, Volume 19, Issue 3, Optimal Temperament, July 1977*M. Mills*, The Guardian, Saturday February 2003*J. J. O’Connor and E. F. Robertson*, Claudius Ptolemy, April 1999*H. Reid*– On Mathematics and Music, 1995*M. Schechter*, Tempered Scales and Continued Fractions, American Mathematical Monthly, Volume 87, Issue 1, January 1980*S. Sinyan*, Acoustics of Ancient Chinese Bells, Scientific American, Issue 256, Volume 94, 1987*H. Stoess*, History Of Tuning And Temperament

## End notes

- [1] Calculation: (4/3)/(5/4) = 20/12 = 5/3
- [2] Murray Schechter, Tempered Scales and Continued Fractions, American Mathematical Monthly, Volume 87, Issue 1, January 1980
- [3] Murray Schechter, Tempered Scales and Continued Fractions, American Mathematical Monthly, Volume 87, Issue 1, January 1980
- [4] The addition of two pure sine waves of similar amplitude and frequency produces areas of constructive and destructive interference.
- [5] A. A. Goldstein, SIAM Review, Volume 19, Issue 3, Optimal Temperament, July 1977
- [6] Shen Sinyan, Acoustics of Ancient Chinese Bells, Scientific American, Issue 256, Volume 94, 1987
- [7] T. Blackburn, H. Stoess, Alternate Temperaments: Theory and Philosophy
- [8] Giovanni Maria Lanfranco, 1533, sourced from T. Blackburn, H. Stoess, Alternate Temperaments: Theory and Philosophy
- [9] A. A. Goldstein, SIAM Review, Volume 19, Issue 3, Optimal Temperament
- [10] William Pole, 1879, sourced from T. Blackburn, H. Stoess, Alternate Temperaments: Theory and Philosophy
- [11] H. Stoess, History Of Tuning And Temperament
- [12] Merope Mills, The Guardian, Saturday February 2003

## Comments

Please tell me what you think about this project and if it helped you in any way. I would be grateful for any suggestions on the subject of musical temperament, further links between with Mathematics and further reading lists.