MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Play rests using Mathematica MIDI

  • To: mathgroup at smc.vnet.net
  • Subject: [mg81979] Re: Play rests using Mathematica MIDI
  • From: Jean-Marc Gulliet <jeanmarc.gulliet at gmail.com>
  • Date: Mon, 8 Oct 2007 00:06:21 -0400 (EDT)
  • Organization: The Open University, Milton Keynes, UK
  • References: <fea9lr$k5i$1@smc.vnet.net>

mumat wrote:

> I am writing a music using MIDI mathematica. How can I play a rest,
> say for t=1 sec?
> 
> rest[t_]:=Sound[0,{x,0,t}];
> 
> 
> Is that possible to do it with the SoundNote function.
> 
> 
> Sound[SoundNote[Null],t]
> 
> doesn't work.

You were almost there. Use *None* rather than *Null*, as in the 
following example (first note lasts one second, then a silence for half 
a second followed by another note lasting tow seconds):

Sound[{SoundNote["G", 1], SoundNote[None, .5], SoundNote["C", 2]}]

Regards,
-- 
Jean-Marc


  • Prev by Date: Re: rule based program for "Deleting repeated members of a list."
  • Next by Date: Re: Re: rule based program for "Deleting repeated members of a list."
  • Previous by thread: Re: Play rests using Mathematica MIDI
  • Next by thread: Graphing the Separatix