go-music-theory / music-theory

Go models of Note, Scale, Chord and Key
https://gopkg.in/music-theory.v0
GNU General Public License v3.0
440 stars 44 forks source link

First implementation of Scale #5

Closed charneykaye closed 8 years ago

charneykaye commented 8 years ago

Scale

In music theory, a scale is any set of musical notes ordered by fundamental frequency or pitch. A scale ordered by increasing pitch is an ascending scale, and a scale ordered by decreasing pitch is a descending scale. Some scales contain different pitches when ascending than when descending. For example, the Melodic minor scale.

https://en.wikipedia.org/wiki/Scale_(music)

Has Mode:

MajorMode               // Ionian
MinorMode               // NaturalMinorMode
NaturalMinorMode        // Aeolian 
DiminishedMode          // Locrian
AugmentedMode           // Lydian

MelodicMinorAscendMode  // intervals:T-s-T-T-T-T-s example:C-D-Eb-F-G-A-B-C
MelodicMinorDescendMode // intervals:T-s-T-T-s-T-T example:C-D-Eb-F-G-Ab-Bb-C
HarmonicMinorMode       // intervals:T-s-T-T-s-Ts-s example:C-D-Eb-F-G-Ab-B-C    

IonianMode              // intervals:T-T-s-T-T-T-s example:C-D-E-F-G-A-B-C 
DorianMode              // intervals:T-s-T-T-T-s-T example:D-E-F-G-A-B-C-D 
PhrygianMode            // intervals:s-T-T-T-s-T-T example:E-F-G-A-B-C-D-E 
LydianMode              // intervals:T-T-T-s-T-T-s example:F-G-A-B-C-D-E-F 
MixolydianMode          // intervals:T-T-s-T-T-s-T example:G-A-B-C-D-E-F-G 
AeolianMode             // intervals:T-s-T-T-s-T-T example:A-B-C-D-E-F-G-A 
LocrianMode             // intervals:s-T-T-s-T-T-T example:B-C-D-E-F-G-A-B