Posted May 13, 20232 yr Dear Opmo users, i would like to merge voices from one single list. So I would like this (not-working) merge-voice function: (setf test '((s) (-s s) (-e s))) (merge-voices test) To work like this: (merge-voices '(s) '(-s s) '(-e s)) Does anyone has an Idea how to achieve it? Best, Vili
May 14, 20232 yr Author Dear Stephane, thank you, even if try with "OMN expressions" in a list , if i understand it correctly, is pretty same. (setf test '((s c4) (-s s c4) (-e s c4))) (merge-voices test) (merge-voices '(s c4) '(-s s c4) '(-e s c4)) But anyways, does anyone knows how this function is programmed so I could program own one, with result I wanna achieve. Best, Vili
May 14, 20232 yr some "ugly code" ...but it works.... 😃 you want to use (merge-voices) with ONE list as input? (setf test '((w c2) (h c4 d4) (q g5 g5 g5 g5))) (defun your-merge-voices (alist) (merge-voices (first alist) (second alist) (third alist) (fourth alist) (fifth alist))) (your-merge-voices test)
May 14, 20232 yr Dear friends, I got the result (z^w c2 z^h c4 q g5 g5 z^h d4 q g5 g5) in this operation, using André´s function. What is the meaning of z and ^ in the OMN language ? THanks, best, Julio
May 15, 20232 yr Common Lisp's APPLY function applies the function of the first argument to the remaining arguments. (setf test '((s c4) (-s s c4) (-e s c4))) (apply #'merge-voices test) => ((s c4) (s c4) (s c4))
May 15, 20232 yr oh, thx, did not know, that APPLY works on functions "first to the remaining arguments."!
May 15, 20232 yr 22 hours ago, JulioHerrlein said: Dear friends, I got the result (z^w c2 z^h c4 q g5 g5 z^h d4 q g5 g5) in this operation, using André´s function. What is the meaning of "z" and "^" in the OMN language ? THanks, best, Julio This is OM polyphonic notation. S.
May 15, 20232 yr Thanks, Stephane !! Is there some documentation about it ? Very good to know. Best, Julio
Create an account or sign in to comment