MathGroup Archive 1999

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

Search the Archive

about musical functions

  • To: mathgroup at
  • Subject: [mg20070] about musical functions
  • From: "Postman" <cmannu at>
  • Date: Wed, 29 Sep 1999 03:33:27 -0400
  • Organization: CompuServe Interactive Services
  • Sender: owner-wri-mathgroup at

Hi all,

I'm using Mathematica 3, and trying to play songs simultaneously.

I've read the composer's guide which is really good, but i don't find it
clear enough to make a function such as the one for scales (on part 7)...

I wanted mainly to play "accords", two different notes from a given scale in
a same time.

Scale is given in cents such as :
MeanChromatic = {0,76,193.2,310.3,386.3,503.4,579.5,

and i want to play 76 and 772.6 in the same time....

The function :

PlayScale[scaleType_,startingFreq_,totalDuration_] :=

    scaleList =
     Map[(N[startingFreq * 10^(#/(1200/Log[10,2]))])&,
    noteDuration = Length[scaleList]/totalDuration;

      Sin[ 2 Pi t scaleList[[ 1+Floor[t * noteDuration] ]] ],

Many thanks.

  • Prev by Date: Ordering output in a polynomial
  • Next by Date: Calculus of variations
  • Previous by thread: Ordering output in a polynomial
  • Next by thread: Calculus of variations