[CM] sharps & flats from CM key

Adam ahcnz at ihug.co.nz
Thu May 13 22:43:39 PDT 2010


Sorry about these Grace CM queries. 

Here below I came to after running into trouble with Fomus 
mixing sharps and flats within the one key.   I thought if 
I defined the scales closely, then that would correct it. 

It doesn't, and whether there's a hack or hook in Fomus for 
fixing this common problem later on, I don't know. 

For example in the E major output below, is there any way to 
coerce the output to use only sharps ?  And only flats for F 
Bf Ef Af etc ?

Perhaps an option for "note", such as 
(note 34 :coerce f)   ; use bf1
(note 34 :coerce s)  ; use as1
with the 4th degree of Gb maj being treated as Cf and B respectively.   

Maybe its intractable here, and more an issue at the 
Fomus Lilypond interface. 

Thanks and best,    Adam. 


>>
(define C  '(c0  d0  e0 f0  g0  a0  b0)) 
(define Cs '(cs0 ds0 f0 fs0 gs0 as0 c1)) 
(define D  '(d0 e0 fs0 g0 a0 b0 cs1))
(define Ef '(ef0 f0 g0 af0 bf0 c1 d1)) 
(define E  '(e0 fs0 gs0 a0 b0 cs1 ds1)) 
(define F  '(f0 g0 a0 bf0 c1 d1 e1)) 
(define Fs '(fs0 gs0 as0 b0 cs1 ds1 es1)) 
(define Gf '(gf0 af0 bf0 cf1 df1 ef1 f1)) 
(define G  '(g0  a0  b0  c1  d1  e1 fs1)) 
(define Af '(af0 bf0 c1  df1 ef1 f1 g1)) 
(define A  '(a0  b0  cs1 d1  e1  fs1 gs1)) 
(define Bf '(bf0 c1  d1  ef1 f1  g1 a1)) 
(define B  '(b0  cs1 ds1 es1 f1 as1 bs1)) 


(define (playlist klist ndur)
  (process for nl in klist
           for ldur = (* ndur (+ (* 2 (length nl)) 1))
           do 
           (print (newline))
           (sprout (play2octs nl ndur))
           (wait ldur)))

(define (play2octs xa ndur)
  (process for n in (concat xa (transpose xa 12) (transpose (first xa) 24))
           for nk = (transpose (key n) 36)
           do 
           (send "mp:midi" :key nk :amp 0.9 :dur ndur)
           (display (note nk))
           (display " ")
           (wait (* ndur 0.9))))

(sprout (play2octs E 0.2))

(sprout (playlist (list C Cs E) .2))

e3 fs3 af3 a3 b3 df4 ef4 e4 fs4 af4 a4 b4 df5 ef5 e5 

c3 d3 e3 f3 g3 a3 b3 c4 d4 e4 f4 g4 a4 b4 c5 
df3 ef3 f3 fs3 af3 bf3 c4 df4 ef4 f4 fs4 af4 bf4 c5 df5 
e3 fs3 af3 a3 b3 df4 ef4 e4 fs4 af4 a4 b4 df5 ef5 e5  <---



More information about the Cmdist mailing list