I seem to have answered several times the question "why 12 tones per octave?" Here are the posts, with some email and followups. dave ============================================================================== Date: Wed, 28 Jul 93 16:06:05 CDT From: rusin (Dave Rusin) To: bert@netcom.com Subject: log3/log2 I use log3/log to explain the importance of the 12-note scale of Western music. Here is my reasoning. One note does not music make (the "One Note Samba" notwithstanding). Now, which notes sound best with a note of a given frequency? The ancient greeks more or less decided it was those whose frequencies were integer multiples of the first (Indeed, those other frequencies are present in practice because the Fourier expansion of a single note on an instrument includes those other frequencies with small but not tiny coefficients). Now, unless you play nothing but octaves, say, you have two frequencies which are multiples of the first but not of each other. The most audible will be the lowest two, which are in a 3:2 ratio. This is the pure fifth, and still makes a pleasing chord. Other ratios can be tried but as a rule the larger the integers necessary to describe the ratio, the worse the sound. If we build fifths above the fifths, we get more tones in the scale (typically we reduce by an octave, i.e., a factor of 2, whenever producing a tone of more than twice the original frequency). This of course is the construction of the circle of fifths. I have gotten pretty good at using this to tune pianos. Unfortunately, the process never terminates: no power of (3/2) is ever a whole number of octaves (or indeed any integer multiple of the first frequency). I make this observation whenever teaching about Unique Factorization. Thus, we introduce more and more tones describing more complex ratios which, as I noted above, sound worse and worse. So we fudge the fifth to make the equal-tempered scale: find a ratio r roughly equal to 3/2 so that some small power of r is a power of 2. This amounts to finding good integer approximations for the solutions of (3/2)^x = 2^y, which we rewrite as 3^k=2^l, or l/k=log3/log2=1.584962501... The theory of continued fractions tells us how to do this: Form the continued fraction expansion of this real number, stop at certain points, and reevaluate the fraction l/k which will approximate log3/log2. Lots is known about this process, but two facts are useful here: The fractions so attained are better approximants than any others with smaller denominators; and the approximations are unreasonably good iff we stop just before a big term shows up in the cont. frac. expansion. So here it is: log3/log2= cont.frac[1,1,1,2,2,3,1,5,2,23,...], which gives the following optimal approximations: 1/1, 2/1, 3/2, 8/5, 19/12, 65/41, 84/53. 485/306, 1054/667,... (I stop here because the next term to use, 23, is really large, so that 1054/667 is a much better appproximation than the 667 leads you to expect; the next best approximation has a huge denominator). Musically, these numbers tell us that by building a pure fifth repeatedly we get closer and closer to a real octave if we use 1, 2, 5, 12, 41, 53, ... fifths; other numbers of fifths offer no particular advantage. I find it a curious twist of nature that the highly-divisible number 12 shows up here; had it been 11 or 13, music would have developed a lot differently as you noted in your news post. Also I think it is interesting that the 12 shows up corresponding to the [1,1,1,2,2] part of the fraction; the next number (3) is larger so 19/12 is a pretty good approximant to log3/log2, considering the size of its terms; the 65/41, by contrast, is less impressively good. I guess nature just provided for us well. I think this explains the prevalence of the 5-note and 12-note scales. I have heard compositions written in n-note scales where n was in the range of 10 to 20; all were (necessarily?) Bach-like and kept suggesting 12-note music which was "slipping" from time to time. From the mathematics of it I would expect that no really good new music would result until we tried a 41-note scale. Just offhand I would expect a keyboard with 3 or 4 levels of blackness of keys instead of the current 2 (white and black), which would be used with decreasing frequency (no pun intended) to correspond to the fact that they corresponded to the higher powers of 2^(24/41) ("higher" meaning mod 41 I guess) As my electronic music equipment is limited to the world-class IBM PC speaker, I am not in a position to try this out, but I think it would be a real kicker to turn a 5-row computer keyboard into this kind of musical instrument. I am a better mathematician than musician, but I have a good time linkning the two anyway. Ask me sometime about the shape of a harp. dave rusin@math.niu.edu ============================================================================== Date: Thu, 29 Jul 93 03:44:50 -0700 From: bert@netcom.com (Roberto Sierra) To: rusin@math.niu.edu Subject: Re: A new sound on comp.music > This is fun. It sure is. I've heard of works for 19-tone systems all over the place, but haven't had the time to check them out. The 72-tone system (and derivatives thereof) sounds quite amazing, though of course there MIDI would become a hindrance since it only allows 128 notes -- not quite two octaves! I think John Cage did some microtonal work at some point, or else he just severely detuned a piano. The nice thing about setting various microtonal scales up in MIDI is that you can get back to 'home' (Equal- or Well- tempered scale) at the push of a button or two instead of spending all day fiddling with a hex wrench on a piano. FYI -- My keyboard spans 76 keys, all plastic, and three really good piano patches (the Roland D-70 is known for its piano) I'll send you a tape and you'll see what I mean. Till later, -- Roberto ============================================================================== Date: Mon, 31 Oct 94 00:03:17 CST From: rusin (Dave Rusin) To: rec-music-classical@cs.utexas.edu Subject: What is "tonality"? (why 12 tones) Not to discount the many human factors involved in this discussion, there is a valid reason for selecting 12 tones rather than 11 or 19 (say). If you grant that you want intervals the ratios of whose frequencies is the ratio of small integers, and you grant that you want music transposable (so that if an interval of frequency ratio r show up, then an interval of ratio r*r also arises), then as has been noted you can't be satisfied with anything much more complex than pure octaves. We live with the 12-tone arrangement because 12 fifths is really close to a whole number (7) of octaves: (3/2)^12 is almost 2^7. Now in a scale with a different number of tones, you will likely have another interval almost equal to a fifth. If you then take a circle of fifths, you should come round to an octave after n steps (n is the number of tones per octave, or perhaps a divisor of that number). This gives an approximation (3/2)^n is almost 2^k. Equivalently, (n/k) is a rational number giving a good approximation to the irrational number log(2)/log(3/2) = 1.709540... There is a process called "continued fractions" which will produce all fractions approximating a number, with the property that each such fraction is a better approximation than any fraction you might try with a smaller denominator. Applied to the number above we get the sequence: (2/1), (5/3), (12/7), (41/24), (53/31), ... Musically this suggests the following are "natural" choices for numbers of tones per octave: 2 -- In an equal tempered scale, the frequencies are in a ratio of 2^(1/2) to 1 (1.414:1) -- not wildly close to 3:2 5 -- frequencies in ratios 2^(1/5):1 (1.14869:1). The full set of ratios is 1, 1.15, 1.32, 1.52, 1.74, and of course 2 to 1. The third of these is the interval we call the fifth. 12 -- standard in Western music. The seventh term is the one we call the "fifth". quite close to a 3:2 ratio. The next best scale, according to this theory, would be a (get this) 41-tone scale; consecutive frequencies are in ratios of 2^(1/41) to 1, about 1.01707974:1. The 24th tone in this sequence has a relative frequency of 1.50041943, which is really quite close to a true fifth. (Relative to an A440, the true and false "fifths" would produce a beat frequency of something like 12 seconds!) (The 53-tone scale offers an improvement well beyond what might be expected from adding a few tones. I leave this to the mathematically inclined to ponder) If you wish to accept a different number of tones per octave, you would either need to take a multiple of these numbers (that is, strictly interleave more frequencies into a pentatonic or 12-tone scale) or sacrifice the quality of your "fifth" (perhaps with the intent of improving your "fourth", say). The former possibility is really rather tame -- you could keep all the repertoire for the 12-tone scale in a 24-tone scale; really all you lose is the "circle of fifths" (you'd need a circle of something else -- not too many choices in 24 tones, and none easy to hear). The latter possibility is on the other hand a more interesting departure from the standard western literature. It is possible to attempt a uniform optimization of several intervals; I won't discuss this as it, too, involves subjective choices. Dave rusin@math.niu.edu ============================================================================== [I was going to post the following file to clarify the preceding one, but I think I decided it was not worth the bandwidth.] A couple of corrections to my previous post: 1) The topics I posted previously, as well as some of those below, are known to people who study microtonal tunings and so on (err, "theoretical music"?), so this is not intended to be original or an optimal exposition. Indeed I am told there exist compositions in 41-tone scales, but I haven't any references. I will concede that as a musical traditionalist I find this kind of work to sound mechanisitic and artificial. Incidentally, one can program a PC easily to use the standard keyboard as an interface for a 41-tone system. I use the top row to hold the 12 most commonly used tones in the scale, with the other rows holding intermediate intervals (see how the keys on the keyboard are slightly shifted one row to the next?). I use the shift keys to add a second octave. I use the long row to hold the tones whose frequencies are roughly (3/2)^k of a base tone, for k=-5 through +6. Recall the "fifth" in this scale is the 24th interval, so calculating mod 41 we are using tones 24, 48=7, 31, 14, 38, and 21 as well as -24=17, 34, 10, 27 and 3, so in increasing order I would expect the 12 most useful tones in this scale to be tones 0 (the base), 3 7 10 14 17 21 24 27 31 34 38 (very close to the usual 12-tone scale, with a surprisingly uniform distribution of gaps between them). The next row holds frequencies (3/2)^k for k=7 thru 18, then one for k=19 thru 30, and finally one for k=31 thru 35 (k=36 and up are in the top row.) Thus rows hold tones 0 3 7 10 14 17 21 24 27 31 34 38 41 1 4 8 11 15 18 22 25 28 32 35 39 2 5 9 12 16 19 23 26 29 33 36 40 and x 6 x 13 x 20 x x 30 x 37 respectively (x = keys not producing sound). On my keyboard, I had to fudge a little so as not to use the ENTER and RSHIFT keys. Exercise: improve the program to allow chords, dynamic levels, greater numbers of octaves, etc. 2) I had implied that interesting divisions of the octave might result from seeking to approximate a perfect fourth (4:3 ratio of frequencies). But since (4/3)x(3/2) = (2/1) (an octave), the scales which provide good fourths are the same as those providing good fifths. To get a new variant on Western music we would have to seek scales allowing some other nice ratio of frequencies besides these two. 3) After fifths (or fourths) the next simplest ones are 5:3 (which are good in the same scales as the 6:5 ratios) and 5:4 (equivalently, 5:1); subsequent ratios (7:4, 7:5, 7:6, 9:5, 9:7, 9:8, etc.) seem less likely to be useful as fundamental ratios in a musical composition; they tend to be harder to hear and more likely to be called "dissonance". Applying the theory of the previous post, we get other scales which are arguably "natural": emphasizing the 5:3 ratio (C up to a slightly flat A): 3-tone, 4-tone, and 19-tone. (With 19 tones a wonderful approximation to 5:3 occurs at the 14th tone. To get the next great approximation would require 418 or more tones per octave!) emphasizing the 5:4 ratio (C up to a slightly flat E): 3-tone, 28-tone, and 59-tone. (I would have to say that such a high number of tones is in practice likely to be almost like allowing a _continuous_ frequency distribution.) 4) As other posters have noted, much of this theory is based on the assumption that the available intervals are constant from one octave to the next, that is, that among the ratios of frequencies available will be 2:1. If we relax this assumption we can get other sets of tones from which other, naturally more unusual, music can be constructed. The mathematical theory works just as well with any pair of ratios which one wants to approximate (e.g. the original discussion considered 2:1 and 3:2). For example, we could ask that the set of frequencies repeat with factors of three: if A440 is included, we replace the "octave" with the range of frequencies from A440 to (E-ish)1320 (a twelfth). If within this set we try to approximate a frequency ratio of 2:1, we find that the twelfth would be naturally divided into 17 steps; step number 12 here would be a good approximation of an A880. (The continued fractions method dictates we try dividing the twelfth into 3, 7, 17, 58, ... tones) But of course, such scales produce good octaves and fifths, just as we have already done (although they do produce slightly different tunings). To get something more radically bizarre, try for divisions of, say, a twelfth as above, but now selected to allow a good approximation of a 5:3 ratio or a 5:4 ratio. My calculations suggest the former is best achieved with 13, 14, 28, 43,... intervals in the twelfth; the latter, with 4, 5, 64,... intervals. In the last case, one would have a basic chord (almost a third) which, when added to itself 5 times would just lap the twelfth, ending just one interval too high, leading to a very transparent circle of 64, uh, quasi-thirds: approximate notes: C E G# C E G#(but flatter) twelfths: C G (transposing down a twelfth from this point takes us down to the next interval after the low C, where the cycle repeats another 5 times. After 12 sets of 5 and one final set of only 4, we are exactly at the high G at the top of the twelfth.) As it happens, the approximation (5/4)^64 of 3^13 is terrifically good. 5) One unusual property of the number 12 is its number of proper divisors. I am reluctant to cite this as a reason why it makes a good basis of the traditional western scale since I don't see how this divisibility is translated into music. The fact that the intervals C-> F# and F#-> C are roughly equal (each about sqrt(2) ) seems to me little used in composition. I might suggest that this divisibility has something to do with the _rhythms_ used in music: for example, a chromatic scale across one octave fits neatly as 4 triplets in common time. But I think the effect of the divisibility of 12 on the rhythm is at best a feature, not an asset -- different lengths of a run of notes are likely to suggest other timing patterns which are just as interesting, such as the many different ways one can incorporate a natural octave (7 intervals) into ordinary time signatures. Conclusion: I find little mathematical basis to recommend a number of tones per octave greater than 5 and fewer than 24 apart from the usual 12 and perhaps the oft-suggested 19. The taste of the composer, of course, is the ultimate authority. Dave Rusin, rusin@math.niu.edu ============================================================================== From: rusin@washington.math.niu.edu (Dave Rusin) Newsgroups: sci.math,sci.math.num-analysis Subject: Re: Relationship(s) between Music and Math: References please? Date: 7 Dec 1994 22:04:59 GMT In article <3c27t5$gk1@ucsbuxb.ucsb.edu>, will@crseo.ucsb.edu (William C. Snyder) writes: |> I don't know how this relates to the aforementioned method for obtaining a |> musical scale, but here is an interesting experiment. I'd like to hear if |> others have seen this: |> |> Postulate just two requirements for a musical scale. |> |> 1. Ability to transpose. |> 2. Existance of many "good" intervals. |> |> I plotted the results and found that 12 steps is "unusually" efficient |> in providing the above requirements. You have to go several more steps |> to get any improvement in the number of intervals supported. There is also |> a peak at seven steps, which I believe is the number for certain eastern |> scales. This topic comes up from time to time and also appeared a couple of months ago over in some of the rec.music groups. The two postulates above (with "good" intervals meaning good approximations of fifths and fourths, the most important intervals after octaves) lead one to finding good rational approximations for log_2(3) (if k/n is a good approximation, then an n-tone scale has a good approximation to the "fifth" at the k'th tone). After some really small cases, the next good approximations have n= 5, 12, 41, 53, ... The pentatonic scale is indeed used in some traditional asian music, while the 12-tone scale is the one used in classic (and contemporary) western music. I wrote a little pascal program to turn my computer keyboard into a 41-tone player. It takes some doing to hear the differences that result in chords when a single-step change is made in one of the notes. There is a small but significant literature of music written for other tone numbers, most significantly the 19-tone scale. This one provides good approximations for 5:3 ratios of frequencies within the octave. A more sophisticated approach might try to optimize several intervals simultaneously. I have not pursued the diophantine approximation questions this raises. In article <3c4hg5$75r@hpsystem1.informatik.tu-muenchen.de>, Gerhard Niklasch wrote: > >With respect to the above postulates, you should really go one step >further: Ability to transpose doesn't require the octave to be >represented _exactly_ . You could have scales that produce more >accurate fifths than octaves... perhaps also approximating the 4:1 ratio >well, or 8:1, but not necessarily 2:1 ... > This can be incorporated into the framework as above. If you assume your set of tones includes all frequencies 3^n.f (say) whenever it includes a frequency f, then you can look to see: into how many steps to divide a single "twelfth" (a precise 3:1 ratio of frequencies) so as to find good approximations to other ratios of frequencies. This requires approximating log_3(r) where r is a ratio with low numerator and denominator, and between 1 and 3 -- for example r=2/1, 4/3, etc. These particular examples can be simultaneously well-approximated (since (2/1)^2 x (4/3)^(-1) = 3). It turns out that the approximations with low numbers of tones are just the ones you'd expect from trying to divide an octave in a way producing good fifths. For example, the normal 12-tone scale takes 19 steps to make an approximate "twelfth". If you divide the true 3:1 frequency range into precisely 19 steps, the 12'th one is almost exactly an octave. So to get something really novel, you'd have to decide you want to break the 3:1 frequency range into a number of pieces with the intent of approximating some other interval besides a 2/1 ratio. The "smallest" novel ratio would be a 5:3 ratio. I leave it to the reader to imagine the music that would result which contains no good approximation to octaves and fifths but rather centers on twelfths and slightly-sharpened thirds. And, of course, the one assumed basic ratio can be anything you want rather than 3, such as 3/2, 4/3, or even something irrational. I've saved a number of posts, email messages, and so on related to this, so if someone is interested in this end of "theoretical music" they're welcome to contact me. Really the discussion above is neither deep math nor creative music, but it makes for a good talk to undergrad math majors. dave ============================================================================== Date: Wed, 7 Dec 94 09:59:15 CST From: rusin (Dave Rusin) To: will@crseo.ucsb.edu Subject: Re: Relationship(s) between Music and Math: References please? In article <3c27t5$gk1@ucsbuxb.ucsb.edu> you write: >Postulate just two requirements for a musical scale. > >1. Ability to transpose. > In other words, the scale should have equal geometric steps > in the octave so that a piece could be moved up or down > without changing the relation between notes. > step = r*f, r=step ratio, f=frequency > number of steps = n, > k^n = 2 (octave), --> nlogk = 2 You mean nlogk = log2, i.e., n = 1/log_2(k). And I assume k is the same as r. >2. Existance of many "good" intervals. > The scale should provide many or all of the small integer > ratios of frequecies. ( 2:1, 3:2, 4:3, ... ). These ratios > should be accurate enough to sound good to the human ear (1%). > If you want both fifths and fourths, what you need is to have an integer m so that r^m is roughly 3/2 (Then for free you'll get that r^(n-m) = r^n/r^m ~~ 2 / (3/2) = 4/3.) This time the formula is that m log_2(r) should be about log_2(3) - 1, so that m/n will be about log_2(3) -1. Now, there is the mathematical theory of continued fractions which is perfect for this problem. Given any irrational number x it finds a bunch of rational numbers p/q which approximate x really well, in fact | x - p/q | is less than 1/q^2. Moreover, p/q is a better approximation than any rational number with denominator at most q. Clearly "good" scales will come from "good" approximations to log_2(3)-1, so if you interpret "good" in this way, there is an explicit way to compute the ideal numbers of tones in a scale. The first non-trivial approximation uses n = 5 (not 7), which is the structure of some oriental music. The next approximation happens to have n=12 -- our familiar western music. The next two terms in the continued fraction expansion have n=41 and n=53 respectively. ... ============================================================================== Date: Thu, 08 Dec 1994 11:02:07 -0800 To: rusin@math.niu.edu (Dave Rusin) From: will@crseo.ucsb.edu (Will Snyder) Subject: Re: Relationship(s) between Music and Math: References please? ... You're right. I'd like to try the 41-tone scale myself. But note that the remaining inaccuracy w/12 can dealt with by "tempering" the scales in fixed tuned instruments and by vibrato and small adjustments in continuous tuned instruments. In addition to the references given in the thread of the same subject, you could obtain a copy of "Auditory Demonstrations" CD: Phillips 1126-061. This has an excellent manual with a brief description of each experiment with references. These experiments are based on the "Harvard Tapes." They include beat frequencies, difference tones, etc. ============================================================================== From: andrew@rentec.com (Andrew Mullhaupt) Newsgroups: sci.math,sci.math.num-analysis Subject: Re: Relationship(s) between Music and Math: References please? Date: 7 Dec 1994 22:30:21 GMT Public Cluster Macintosh (ph@directory.yale.edu) wrote: : These books are good and all contain much interesting mathematics: In the usual tradition of shamelessly advertising my own work: Douthett, Entringer and Mullhaupt, "Musical Scale Construction: The Continued Fraction Compromise", Utilitas Mathematica, v. 42 (1992). This paper is about how different notions of best approximation apply to the construction of "fifth harmonious" equal tempered systems. The most interesting part mathematically, is that an actual new theorem. ============================================================================== From: gerry@macadam.mpce.mq.edu.au (Gerry Myerson) Newsgroups: sci.math Subject: Re: Relationship(s) between Music and Math: References please? Date: 7 Dec 1994 00:49:45 -0600 In article <3c27t5$gk1@ucsbuxb.ucsb.edu>, will@crseo.ucsb.edu (William C. Snyder) wrote: => [I've edited this a lot] => Postulate just two requirements for a musical scale. => => 1. Ability to transpose. => => 2. Existence of many "good" intervals. => => I plotted the results and found ... Something resembling the diagram on p. 45 of Steinhaus, Mathematical Snapshots, 3rd American edition, Oxford 1969? For other editions, look up "scale" in the index. ============================================================================== From: kornhaus@oasys.dt.navy.mil (Daniel Kornhauser) Newsgroups: sci.math,sci.math.num-analysis Subject: Re: Relationship(s) between Music and Math: References please? Date: 7 Dec 1994 17:29:44 -0500 In sci.math, Gene Ward Smith Subject: Re: Relationship(s) between Music and Math: References please? Date: Mon, 5 Dec 1994 22:21:18 GMT Gene Ward Smith/Brahms Gang/University of Toledo gsmith@math.utoledo.edu On Mon, 5 Dec 1994, Dave Rusin wrote: > OK, I'll bite. I had decided that the number of steps in an equal step > scale ought to occur in the continued fraction approximation of > ln(3)/ln(2). What's your connection with zeta? Zeta(s+it) = 1 + 2^(-s)(cos(t) + isin(t)) + ... when s > 1, so if you chose a place like you suggest, it makes both the "2" and the "3" term large outside the critical strip--and even inside, by the Riemann-Siegel formula, etc. Really, though, we want to do better than just approximate thirds and fourths, which is what your method aims at. ============================================================================== From: gerry@macadam.mpce.mq.edu.au (Gerry Myerson) Newsgroups: sci.math Subject: Re: Graph Theory and Music Date: 26 Apr 1995 18:59:33 -0500 In article , Stephen J Munn wrote: => => I am searching for connections between graph theory and music.... See John Clough and Gerald Myerson, Musical scales and the generalized circle of fifths, American Mathematical Monthly 93 (1986) 695--701. It's more number theory than graph theory, but at least it's short. Gerry Myerson (gerry@mpce.mq.edu.au) Centre for Number Theory Research (E7A) Macquarie University, NSW 2109, Australia ============================================================================== From: kurtsi@kurtsi.pp.fi (Erkki Kurenniemi) Newsgroups: sci.math Subject: Re: Twelve is special Date: 26 Mar 1995 07:12:31 GMT Twelve is special, what about 8640? ... I don't know but would like to. The funny thing is that its divisors give quite a long stretch of the musical diatonic scale (with a certain catch, a reference is: Thomas D. Rossing, The Science of Sound, Addison-Wesley, 1982, p. 155). In Mathematica, evaluate: d = Divisors[8640] ; Table[d[[i+1]]/d[[i]],{i,15,41}] ============================================================================== Newsgroups: sci.math From: roy@dsbc.icl.co.uk (Roy Lakin) Subject: Re: Music Date: Wed, 1 Nov 1995 17:43:55 GMT ... The "cycle of 53" is more accurate: split the octave into 53 equal divisions. The major scale is approx 9 8 5 9 8 9 5 divisions between successive notes (tones being 8 or 9 and semitones 5). Helmholtz's "Sensation of Tone" describes this more thoroughly. There have been 53-note keyboards invented for this temperament but they never caught on, probably because modulation was so difficult. roy ============================================================================== From: gwsmith@cats.ucsc.edu (Gene Ward Smith) Newsgroups: sci.math Subject: Re: Music Date: 6 Nov 1995 08:05:08 GMT In article , Roy Lakin wrote: >The "cycle of 53" is more accurate: split the octave into 53 equal divisions. >There have been 53-note keyboards invented for this temperament but they never >caught on, probably because modulation was so difficult. That's only part of the reason. Another part is that any such division can be viewed as a homomorphism from a finitely-generated subgroup of the positive rationals under multiplication to a rank-one free abelian group (the "keyboard"), and the kernel of this map related crucially to the structure of the harmony. If the "diatonic comma = 81/80 is not in this kernel, things will happen that you may not want. This means that 19 and 31 tones are not only easier to handle than 41 or 53, they are also closer to the system we now use, and so easier to work with. ==============================================================================