Playing with Familiar Periodic Phenomena: Music and Instruments

Let's see if we can play this:    l"index_11.gif"

"index_12.gif"

We will play it, but it probably not what was intended...

"index_13.gif"

"index_14.gif"

We create a rest of  a fixed length, and then use Riffle to insert a rest after each note. We use a new function, called SoundNote, with None as the first argument, we get no sound.

"index_15.gif"

"index_16.gif"

"index_17.gif"

SoundNote can take general strings for arguments as well, here we enter the musical notes from above (as characters), but one octave lower..

"index_18.gif"

The default is to use a piano to make the sound; here we ask for a duration of 6/10 of a second.

"index_19.gif"

"index_20.gif"

"index_21.gif"

We can use other MIDI instruments as well; here is a bagpipe

"index_22.gif"

"index_23.gif"

And, now for the birds.

"index_24.gif"

"index_25.gif"

Now, a little Bach meets Beethoven

"index_26.gif"

"index_27.gif"


Created by Wolfram Mathematica 6.0  (24 October 2007) Valid XHTML 1.1!