Quasi Random Music: Executable or Text Version
Despite the seemingly odd anomalies in musical scales (the intervals between the notes of the standard Major and Minor scales are not all the same, for example), ALL the Major and Minor scales and their standard chords lend themselves to a scaleable mathematical structure. That's not evident on a piano keyboard, but it's sort-of "obvious" to every guitar player, since each chord shape can be shifted up and down the fretboard, and it sounds "the same", but higher or lower in pitch.
My program revolves around randomly chosen arpeggios of the 7 extended Triads in each Major or Minor key.
To finish, there's also a Coda of one of my own pieces (it sounds infinitely better on a real guitar, of course), which uses one of my favourite weird chords - the "add #11". The piece uses the A6, E6, Dsus2 and D(#11) chords, and is in the key of A Major.