Music is Math

Gintautas Miliauskas blogs about a computer program that can generate something which reportedly really sounds like composer-written music; apparently it has passed a 'turing test' where people listened to music generated by this thing, and music written by a human composer.

I'm afraid, however, I'll have to disappoint him a bit, really. If we ignore the effect that music can have on the emotional state of a living being for a moment, then it's a plain and simple fact that music is pure math:

  • 'An octave' is the musician's term for 'a doubling in frequency'. As many people know, a center A on a piano is tuned at 440Hz; it follows that an A one octave higher is tuned at 880Hz, and that the one which is one octave lower will be 220Hz.
  • 'Chords' are based around that, too. A regular C chord, for example, contains the C, E, and G notes; and usually, a C at one octave above the first C is included, too. The frequency of a G is exactly halfway between the two C notes, and the E is about halfway between those. Most chords are built in such a manner; the sound waves of those notes will build an interference pattern that is perceived as a chord.
  • A melody usually starts with the base note of the key in which the piece is written, and almost always (except during a short time in the early baroque) ends with that same base note. Note that the 'base' note is not the same thing as the "bass" note (although the base is often used in the bass).

There are many other things in music that can be expressed as mathematical rules; learning to how to compose music involves learning those rules, which is a long and tedious process.

Now I'm not saying that following those rules will necessarily lead you to an interesting piece of music; the fact that it's possible to create something ugly while still using chords etc. But since so much of it already is math, I can imagine it not being extremely hard to figure out what the other rules are (the ones a composer figures out by imself as opposed to being taught them), transferring them into a computer program, and using that to generate music.

That's not to say that such a thing is easy to do, and I'm sure it's still an impressive feat to create a computer program which can create "nice" sounding music; but I don't think this would qualify as 'artificial intelligence'. At least not any more than Deep Blue