tamasmatko Posted July 3 Share Posted July 3 Hello, I am Tamas and kind of new in Opusmodus, but learning pretty quickly. It is probably in easy case but I'm stuck at the moment: I ha a rising c major scale, and then I always want to swap only 2 pitches at a time from the scale. At the next evaluation I want to repeat the same process but already with the previously processed new scale. Is there any way to automate this process because I only came up with this idea which is I am sure the most beginner solution (setf scale '(c3 d3 e3 f3 g3 a3 b3)) (setf first (position-swap (rnd-sample 2 '(0 1 2 3 4 5 6) :norep t) scale)) (setf second (position-swap (rnd-sample 2 '(0 1 2 3 4 5 6) :norep t) first)) (setf third (position-swap (rnd-sample 2 '(0 1 2 3 4 5 6) :norep t) second)) (setf fourth (position-swap (rnd-sample 2 '(0 1 2 3 4 5 6) :norep t) third)) (list first second third fourth) Thank you all in advance! All the best, Tamas Quote Link to comment Share on other sites More sharing options...
opmo Posted July 4 Share Posted July 4 With :seq set to T you will get what you are looking for: (setf scale '(c3 d3 e3 f3 g3 a3 b3)) (setf pos (gen-loop 4 (rnd-sample 2 '(0 1 2 3 4 5 6) :norep t))) => ((6 0) (0 4) (5 4) (0 2)) (position-swap pos scale :seq t) => ((e3 d3 c3 f3 g3 a3 b3) (e3 d3 g3 f3 c3 a3 b3) (e3 b3 g3 f3 c3 a3 d3) (c3 b3 g3 f3 e3 a3 d3)) Stephane Boussuge 1 Quote Link to comment Share on other sites More sharing options...
tamasmatko Posted July 5 Author Share Posted July 5 Ohh nice! Thank you, so simple. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.