Music Package
The functions defined in Music` allow you to make conversions between cents and hertz, and play scales in one of the common tuning systems, or in a user‐specified tuning system. In addition, a set of equal‐tempered pitch/frequency equivalents is defined.
When you try the examples in this documentation, your computer display may not look exactly the same, since the graphic displays accompanying the Wolfram Language's sound generation vary from platform to platform.
MusicScale[ilist,freq,dur] | create a Sound object that is a sequence of pitches corresponding to ilist, a list of intervals measured in cents, starting at freq hertz and lasting dur seconds |
MusicScale creates a pitch sequence from a predefined interval list or an arbitrary list of numbers interpreted as intervals measured in cents.
QuarterTone | PythagoreanMajor |
PythagoreanChromatic | MeanMajor |
MeanMinor | MeanChromatic |
SixthTone | JustMajor |
JustMinor | TemperedMajor |
TemperedMinor | TemperedChromatic |
Predefined interval lists measured in cents.
HertzToCents[flist] | convert a list of frequencies measured in Hertz to a list of intervals measured in cents |
CentsToHertz[ilist] | convert a list of intervals measured in cents to a list of frequencies measured in Hertz, beginning at frequency 440 Hertz |
CentsToHertz[ilist,f] | convert a list of intervals measured in cents to a list of frequencies measured in Hertz, beginning at frequency f |
Converting between Hertz and cents.
The two functions HertzToCents and CentsToHertz convert a list of one type to its complementary type.
The Music` package provides a list of equal‐tempered pitch/frequency equivalents. Pitches are named in pitch class/octave notation, where the pitch class is given by a letter from A to G, and the octave is an integer from 0 and 7. The names of flat and sharp notes are written as Bflat, GSharp, and so on.
Most chromatic equivalences are available; for example, C‐flat is the same as B, and E‐sharp is the same as F. Double‐flats and double‐sharps are not defined.