I posted the following on sci.math.research in response to something, but I think I’ll put it here as well, because I think it’s pretty interesting:
Here’s a question for you, that you might want to know the answer to: *Historically*, why are there twelve notes in the scale? And why are seven white and five black?
The answer is that one that ties in lots of stuff about continued fractions, but goes along these lines: one is looking at the octave, and divides it up by looking at the first n fifths (in our scale c,g,d,a,e,b,…) – this divides up the scale.
Pythagoras et al. thought that one should try to keep the variety of intervals between consecutive notes as small as possible – in the end, deciding that the fewer different intervals present the better. Scales generated by fifths that have only two intervals present between side-by-side notes are called Pythagorean. None have just one interval, and the first three Pythagorean scales have 5,7, and 12 notes. 12 was thought pretty much enough, I’m guessing, and it can have nicely embedded into it the two smaller scales (as white and black notes).
I should have a reference for the original article where I read this (some Irish maths society bulletin I think), but I’ve said enough that the material should be findable online. Ah yes, here it is: IMS BULLETIN Number 35 Christmas 1995, p24, “Musical Scales”, MarÃa José Garmendia RidrÃguez, Juan Antonio Navarro González , for all the good it’ll do you.