rot: {x_(x+#y)#y}
i2n: {+\0,(-1_x)}
m: {n:i2n@y; `name`inter`notes`ex!(x;y;n;nstr@n)}
major: 2 2 1 2 2 2 1
mel: 2 1 2 2 2 2 1
harm: 2 1 2 2 1 3 1
Harm: 2 2 1 2 1 3 1
dim: 2 1 2 1 2 1 2 1
aug: 3 1 3 1 3 1
nstr: " "\"C C# D D# E F F# G G# A A# B"
a: ","\"Ionian/Major,Dorian,Phrygian,Lydian,Mixolydian,Aeolian/Minor,Locrian"
ms: {m[x@1;rot[*x;major]]}'+(!#a;a)
a: ","\"Melodic Minor,Dorian b2,Lydian aug,Lydian dom,Aeolian dom,Half dim,Locrian aug"
ms,: {m[x@1;rot[*x;mel]]}'+(!#a;a)
a: ","\"Harmonic minor,Aug dom bb7,Locrian,Major aug,Dorian #4,Phrygian dom,Lydian #2,Aug dom bb7"
ms,: {m[x@1;rot[*x;harm]]}'+(!#a;a)
a: ","\"Harmonic major,Dorian b5,Phrygian b4,Lydian b3,Mixolydian b2,Lydian aug #2,Locrian bb7"
ms,: {m[x@1;rot[*x;Harm]]}'+(!#a;a)
ms,: m["Augmented";aug]
ms,: m["Inv augmented";rot[1;aug]]
colw: 15 14 15 20
:" ",""/($).'+(colw;("name";"intervals";"notes";"ex"))
p: {
n:x[`name]; i:"-"/$x[`inter]; s:"-"/$x[`notes]; e:"-"/x[`ex]
:""/($).'+(colw;(n;i;s;e))
}
p'ms
learn k