Jump to content

AM

Members
  • Posts

    792
  • Joined

  • Last visited

Everything posted by AM

  1. listen to the processes... (make-omn :pitch (integer-to-pitch (pascal-triangle 50 :johnson-modulo (1+ (random 23)))) :length '(t) :span :pitch) an example with parallel processes (chordized).. (setf chordlist (loop for i in (flatten (integer-to-pitch (pascal-triangle 20 :johnson-modulo (1+ (random 23))))) for j in (flatten (integer-to-pitch (pascal-triangle 20 :johnson-modulo (1+ (random 23))))) for k in (flatten (integer-to-pitch (pascal-triangle 20 :johnson-modulo (1+ (random 23))))) append (chordize (list i j k)))) (make-omn :pitch chordlist :length '(t) :span :pitch)
  2. here is a short program (based on JOHNSON's writing... pascal-code found in www and modified) to generate TOM JOHNSON's series of numbers for "pascal's triangle ...". maybe interesting to play with the MODULO like JOHNSON did (mod 7)... try it! greetings andré ;;; SUB (defun pascal-next-row (a &key (johnson-modulo nil)) (loop :for q :in a :and p = 0 :then q :as s = (if (null johnson-modulo) (list (+ p q)) (list (mod (+ p q) johnson-modulo))) :nconc s :into a :finally (rplacd s (list 1)) (return a))) ;;; MAIN (defun pascal-triangle (n &key (johnson-modulo nil)) (loop :for a = (list 1) :then (pascal-next-row a :johnson-modulo johnson-modulo) :repeat n :collect a)) ;;; => pascal-triangle (pascal-triangle 7) => ((1) (1 1) (1 2 1) (1 3 3 1) (1 4 6 4 1) (1 5 10 10 5 1) (1 6 15 20 15 6 1)) ;;; => pascal-triangle with MODULO like tom johnson in PASCAL'S TRIANGLE MODULO SEVEN (pascal-triangle 21 :johnson-modulo 7) => ((1) (1 1) (1 2 1) (1 3 3 1) (1 4 6 4 1) (1 5 3 3 5 1) (1 6 1 6 1 6 1) (1 0 0 0 0 0 0 1) (1 1 0 0 0 0 0 1 1) (1 2 1 0 0 0 0 1 2 1) (1 3 3 1 0 0 0 1 3 3 1) (1 4 6 4 1 0 0 1 4 6 4 1) (1 5 3 3 5 1 0 1 5 3 3 5 1) (1 6 1 6 1 6 1 1 6 1 6 1 6 1) (1 0 0 0 0 0 0 2 0 0 0 0 0 0 1) (1 1 0 0 0 0 0 2 2 0 0 0 0 0 1 1) (1 2 1 0 0 0 0 2 4 2 0 0 0 0 1 2 1) (1 3 3 1 0 0 0 2 6 6 2 0 0 0 1 3 3 1) (1 4 6 4 1 0 0 2 1 5 1 2 0 0 1 4 6 4 1) (1 5 3 3 5 1 0 2 3 6 6 3 2 0 1 5 3 3 5 1) (1 6 1 6 1 6 1 2 5 2 5 2 5 2 1 6 1 6 1 6 1)) ;;; look!! (list-plot (flatten (pascal-triangle 50 :johnson-modulo 7)) :point-radius 0 :style :fill) (list-plot (flatten (pascal-triangle 50 :johnson-modulo 11)) :point-radius 0 :style :fill) (list-plot (flatten (pascal-triangle 80 :johnson-modulo 17)) :point-radius 0 :style :fill) (list-plot (flatten (pascal-triangle 50 :johnson-modulo 3)) :point-radius 0 :style :fill) ;;; rnd-testing (list-plot (flatten (pascal-triangle 80 :johnson-modulo (1+ (random 23)))) :point-radius 0 :style :fill) Bildschirmvideo aufnehmen 2021-04-10 um 23.47.59.mov
  3. yes, but i do not compose with OPMO - it's too strange with rhythm/instrumentation/notation. most of the time i'm sketching with OPMO and compose "by hand". guitar-scordatura: i thought i'd rather "pull the pitches out of MIDI/XML" and then convert them.. i will see... but, THANX! greetings andré could look like that (excerpt of a piece for solo trp - also with some SORT-ALGORITHMS inside (sketched/calculated with OPMO) works fine with SIBELIUS for layouting etc...
  4. thanks, dear julio, i'll take a look at it, but depending on the situation, programming takes more time than doing it by hand
  5. i am currently working on a piece for piano, guitar and drums. the guitar will have a "scordatura" so that i can do different harmonics and resonances than with the usual tunings. so that I can now make a more readable score, I would like to write the guitar part on two systems: one system as it sounds and one readable for the guitarist (because of the scordatura/fingerings)... it would be nice if we could do a FUNCTION which transforms the "sounding pitch part" (readable in score) into the "guitar-specific-part" (how to play for guitarist)...
  6. dear julio i would code it! you could do a "systematic/formalized sketch" (not in LISP) and with that you would try to program a function best a.
  7. here it is... but NOT microtonal. just for equal tempered tunings it was too complicated (and not necessary) for me to code it (with attributes and cents, it's a bit ... ), so i coded it just for my needs ... for equal tempered tunings... could use it for guitar/strings, just to have a list of your SCORDATURA-harmonics to work with. would be interesting if someone could CODE a function which transforms a "sounding-pitch-guitar-score" into the "play-score". so i wouldn't have to do it by hand... where are the guitar players here? julio? janusz? greetings andré (defun sort-to-pitch-events (events sort) (let* ((int (loop for i in events collect (list (pitch-to-integer (second i)) i))) (out (sortcar sort int))) (loop for i in out collect (second i)))) ;;----------------------------------------------------------------------------------- (defun gen-natural-harmonics (openstrings &key (scale nil) (n 16)) (progn (add-text-attributes '(str1 "str1") '(str2 "str2") '(str3 "str3") '(str4 "str4")'(str5 "str5") '(str6 "str6")) (let* ((cent-list (cents-to-attribute '(0 2 0 -14 2 -31 0 4 -14 -49 -2 41 -31 -12 0))) (harmonic (loop for i from 2 to n collect (compress (list 'num i)))) (harmonic-seq (loop for i in openstrings for j in (list 'str6 'str5 'str4 'str3 'str2 'str1) collect (make-omn :pitch (rest (harmonics i n)) :length '(q) :articulation (loop for i in cent-list for x in harmonic collect (if (equal i '-) (compress (list x '+ j)) (compress (list i '+ x '+ j)))) :span :pitch)))) (if (null scale) harmonic-seq (sort-to-pitch-events (single-events (flatten harmonic-seq)) '<))))) ;;----------------------------------------------------------------------------------- ;;----------------------------------------------------------------------------------- ;; attributes: string number + partial number + CENTS ;; sorted by strings (gen-natural-harmonics '(e1 a1 ds2 g2 a2 b2) :n 7) => ((q e2 num2+str6 b2 2c+num3+str6 e3 num4+str6 gs3 -14c+num5+str6 b3 2c+num6+str6 d4 -31c+num7+str6) (q a2 num2+str5 e3 2c+num3+str5 a3 num4+str5 cs4 -14c+num5+str5 e4 2c+num6+str5 g4 -31c+num7+str5) (q eb3 num2+str4 bb3 2c+num3+str4 eb4 num4+str4 g4 -14c+num5+str4 bb4 2c+num6+str4 cs5 -31c+num7+str4) (q g3 num2+str3 d4 2c+num3+str3 g4 num4+str3 b4 -14c+num5+str3 d5 2c+num6+str3 f5 -31c+num7+str3) (q a3 num2+str2 e4 2c+num3+str2 a4 num4+str2 cs5 -14c+num5+str2 e5 2c+num6+str2 g5 -31c+num7+str2) (q b3 num2+str1 fs4 2c+num3+str1 b4 num4+str1 eb5 -14c+num5+str1 fs5 2c+num6+str1 a5 -31c+num7+str1)) ;; sorted by pitch (gen-natural-harmonics '(e1 f1 a1 d2) :n 7 :scale t) => ((q e2 mf num2+str6) (q f2 mf num2+str5) (q a2 mf num2+str4) (q b2 mf 2c+num3+str6) (q c3 mf 2c+num3+str5) (q d3 mf num2+str3) (q e3 mf num4+str6) (q e3 mf 2c+num3+str4) (q f3 mf num4+str5) (q gs3 mf -14c+num5+str6) (q a3 mf -14c+num5+str5) (q a3 mf num4+str4) (q a3 mf 2c+num3+str3) (q b3 mf 2c+num6+str6) (q c4 mf 2c+num6+str5) (q cs4 mf -14c+num5+str4) (q d4 mf -31c+num7+str6) (q d4 mf num4+str3) (q eb4 mf -31c+num7+str5) (q e4 mf 2c+num6+str4) (q fs4 mf -14c+num5+str3) (q g4 mf -31c+num7+str4) (q a4 mf 2c+num6+str3) (q c5 mf -31c+num7+str3))
  8. thanx! (i'm doing a little function to get all the natural harmonics for guitar tunings equal tempered or microtonal...)
  9. hi all little question: i would like to SORT an (single-event)-list by pitch... and be able to keep the event-data "in the set" (=> the attribute-cents should be bound to pitch!) ((e e4 mf) (e a4 mf) (e d5 mf) (e g5 mf) (e b5 mf) (e d6 mf) (e b4 mf 2c) (e e5 mf 2c) (e a5 mf 2c) (e d6 mf 2c) (e fs6 mf 2c) (e a6 mf 2c) (e e5 mf) (e a5 mf) (e d6 mf) (e g6 mf) (e b6 mf) (e d7 mf) (e gs5 mf -14c) (e cs6 mf -14c) (e fs6 mf -14c) (e b6 mf -14c) (e eb7 mf -14c) (e fs7 mf -14c) (e b5 mf 2c) (e e6 mf 2c) (e a6 mf 2c) (e d7 mf 2c) (e fs7 mf 2c) (e a7 mf 2c) (e d6 mf -31c) (e g6 mf -31c) (e c7 mf -31c) (e f7 mf -31c) (e a7 mf -31c) (e c8 mf -31c) (e e6 mf) (e a6 mf) (e d7 mf) (e g7 mf) (e b7 mf) (e d8 mf)) any solutions? thanx! andré
  10. real LISP knowledge is very helpful for me. i think it's enough if you know (work with) the fundamentals - like... list/append/cons/loop/loop-inside-a-loop/progn/push/pop/collect/defun... ... so that you can code your specific solutions! greetings andré
  11. i know i'm not a programmer, but it probably makes sense to be able to enter both variants/formats for some functions, but not for others...
  12. you have to put the bar-numbers into a list... i makes sense in my opinion - perhaps you want to "find" more then one bar... (find-bar '(1 2) mat) => ((c4 db4 ab4 f4 g4 bb4) (a4 eb4 b4 e4 d4 gb4))
  13. dear all here's a function (revised, should work correct now) to work with rotations - based on the work of karel goeyvaerts (defun goeyvaerts-rotation* (&key pitches static-pitches generations goeyvaerts-transpose-interval (direction 'up) low-border high-border correction-interval) (let ((pitches (filter-remove (pitch-to-midi static-pitches) (pitch-to-midi pitches)))) (midi-to-pitch (append (list (append pitches (pitch-to-midi static-pitches))) (cond ((equal direction 'up) (loop repeat generations for x in (gen-repeat 50 goeyvaerts-transpose-interval) collect (append (setf pitches (append (loop for i in pitches when (> (+ i x) (pitch-to-midi high-border)) collect (+ x (- i (abs correction-interval))) else collect (+ i x)))) (pitch-to-midi static-pitches)))) ((equal direction 'down) (loop repeat generations for x in (gen-repeat 50 goeyvaerts-transpose-interval) collect (append (setf pitches (append (loop for i in pitches when (< (- i x) (pitch-to-midi low-border)) collect (+ i correction-interval) else collect (- i x)))) (pitch-to-midi static-pitches))))))))) EXAMPLE: ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; an example with multiple objects inside a chord / GOEYVAERTS uses it woth octave-rotations and with static pitches ;;; here i do it different.... ;;; :goeyvaerts-transpose-interval => in every generation the elements are transposed by next interval (circular) ;;; :static-pitches => will not rotate!! ;;; :high-border => if a pitch is higher then this it will be transposed down by :correction-interval ;;; EVALUATE THIS (setf groups (loop for i in (goeyvaerts-rotation* :pitches '(b3 d4 eb4 gb4 f5 e5 g5 ab5 a4 bb4 db5 c6) :static-pitches nil;'(e4 eb5) :direction 'up :generations 20 :goeyvaerts-transpose-interval '(2 3 5 7 5 3) :low-border 'a2 :high-border 'eb6 :correction-interval -36) collect (gen-divide '(5 3 2 2) i))) ;;; AND THIS / cmd1 => so you see the chords an see the rotation etc.. (setf chordized-groups (loop for i in groups collect (chordize i))) => you see the process of the elements
  14. violà... now it works fine - OPMO could integrate it.... it's easier than i thought: a single index-series is read from the r-i and only this one is used! similar to LACHEMANN, only he determines this index-series himself (for that i coded this simple row-permutation-function)... greetings a. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; SUB (defun row-permutation (n row rules &key (one-based nil)) (let* ((rules (if (equal one-based t) (mapcar '1- rules) rules))) (loop repeat n collect (setf row (position-filter rules row))))) ;;; MAIN (defun serie-proliferantes (n row) (let ((index-no (loop for x in (pitch-to-midi (pitch-invert (gen-retrograde row))) collect (or (position x (pitch-to-midi row)) (position (- x 12) (pitch-to-midi row)) (position (+ x 12) (pitch-to-midi row)))))) (list row (pitch-invert (gen-retrograde row)) (row-permutation n (pitch-invert (gen-retrograde row)) index-no)))) (serie-proliferantes 6 '(c5 ab4 g4 db5 e4 d4 bb4 eb4 b4 f4 fs4 a4)) => ((c5 ab4 g4 db5 e4 d4 bb4 eb4 b4 f4 fs4 a4) (a4 c5 cs5 g4 eb5 gs4 e5 d5 f4 b4 bb4 fs4) ((fs4 a4 g4 cs5 d5 c5 eb5 gs4 b4 f4 e5 bb4) (bb4 fs4 cs5 g4 gs4 a4 d5 c5 f4 b4 eb5 e5) (e5 bb4 g4 cs5 c5 fs4 gs4 a4 b4 f4 d5 eb5) (eb5 e5 cs5 g4 a4 bb4 c5 fs4 f4 b4 gs4 d5) (d5 eb5 g4 cs5 fs4 e5 a4 bb4 b4 f4 c5 gs4) (gs4 d5 cs5 g4 bb4 eb5 fs4 e5 f4 b4 a4 c5)))
  15. row-permutation (with rule) for n-generations (defun row-permutation (n row rules &key (one-based nil)) (let ((rules (if (equal one-based t) (mapcar '1- rules) rules))) (loop repeat n collect (setf row (position-filter rules row))))) (row-permutation 5 '(a4 c5 cs5 g4 eb5 gs4 e5 d5 f4 b4 bb4 fs4) '(0 1 6 5 2 3 7 8 11 9 4 10)) => ((a4 gs4 eb5 c5 cs5 e5 d5 bb4 f4 g4 b4) (a4 e5 cs5 gs4 eb5 d5 bb4 b4 f4 c5 g4) (a4 d5 eb5 e5 cs5 bb4 b4 g4 f4 gs4 c5) (a4 bb4 cs5 d5 eb5 b4 g4 c5 f4 e5 gs4) (a4 b4 eb5 bb4 cs5 g4 c5 gs4 f4 d5 e5)) (row-permutation 5 '(a4 c5 cs5 g4 eb5 gs4 e5 d5 f4 b4 bb4 fs4) '(1 4 6 5 2 3 7 8 11 9 10 12) :one-based t) => ((a4 g4 gs4 eb5 c5 cs5 e5 d5 bb4 f4 b4 fs4) (a4 eb5 cs5 c5 g4 gs4 e5 d5 b4 bb4 f4 fs4) (a4 c5 gs4 g4 eb5 cs5 e5 d5 f4 b4 bb4 fs4) (a4 g4 cs5 eb5 c5 gs4 e5 d5 bb4 f4 b4 fs4) (a4 eb5 gs4 c5 g4 cs5 e5 d5 b4 bb4 f4 fs4))
  16. thanks, julio... could you have a quick look to the function? and to the article from didier.... perhaps you see my mistake (or the mistake in the article) subito ? barraqué described the mechanism and it seems easy to code it. but where is the mistake with more then 3 gens? perhaps didier has an idea?
  17. thanks, julio...!!! if i got it right, it works like this: 1. take a basic row 2. the r-i of the basic row 3. read the positions of all pitches of the r-i within the basic row 4. apply this positionlist to r-i => outout is : ordre 0 => basic row ordre 1 => r-i ordre 2 => proliferante 1 = more or less ONE GEN of production ... so the question could be: is ordre 1 the new basic row, or proliferante 1 ... to produce the next GEN? here is some code to check it... i have no idea at the moment... ;;; ONE GEN (defun serie-proliferantes (row) (let* ((basic_row row) (ri_row (pitch-invert (gen-retrograde row))) (row (loop for z in (loop for x in (pitch-to-midi ri_row) collect (or (position x (pitch-to-midi row)) (position (- x 12) (pitch-to-midi row)) (position (+ x 12) (pitch-to-midi row)))) collect (nth z ri_row)))) (list basic_row ri_row row))) ;;;; X GENS (defun serie-proliferantes** (n row) (loop repeat n collect (setf x (serie-proliferantes row)) do (setf row (third x)))) ;; when you write here second/third x => then it would be ordre 1 ; ;or prolifer 1 as new starting point (serie-proliferantes** 3 '(c5 ab4 g4 db5 e4 d4 bb4 eb4 b4 f4 fs4 a4))
  18. i tried to program it briefly for several generations, but I didn't quite get it - something i do not understand.... so i got wrong outputs after 3 generations... maybe OPMO would like to CODE this? this is my new version... but when i have i look to the barraqué-examples (order 0 - x)... there is a different output after 3 gens... Ordre 0: C Ab G Db E D Bb Eb B F Gb A (c5 ab4 g4 db5 e4 d4 bb4 eb4 b4 f4 fs4 a4) Ordre 1: A C Db G Eb Ab E D F B Bb Gb (a4 c5 cs5 g4 eb5 gs4 e5 d5 f4 b4 bb4 fs4) Ordre 2: Gb A G Db D C Eb Ab B F E Bb (fs4 a4 g4 cs5 d5 c5 eb5 gs4 b4 f4 e5 bb4) Ordre 3: Bb Gb Db G Ab A D C F B Eb E (bb4 e4 eb5 a4 c5 f4 gs4 fs4 g4 cs5 b4 d5) ???? wrong... Ordre 4: E Bb G Db C Gb Ab A B F D Eb Ordre 5: Eb E Db G A Bb C Gb F B Ab D Ordre 6: D Eb G Db Gb E A Bb B F C Ab Ordre 7: Ab D Db G Bb Eb Gb E F B A C efun serie-proliferantes* (basicrow &key (gen 10)(ordre nil)) (let* ((row basicrow) (ri_row (pitch-invert (gen-retrograde basicrow))) (serie (cons basicrow (loop repeat gen append (list ri_row (setf row (loop for z in (loop for x in (pitch-to-midi ri_row) collect (or (position x (pitch-to-midi row)) (position (- x 12) (pitch-to-midi row)) (position (+ x 12) (pitch-to-midi row)))) collect (nth z ri_row)))) do (setf ri_row (pitch-invert (gen-retrograde row))))))) (if (not (null ordre)) (position-filter ordre serie) serie))) (serie-proliferantes* '(c5 ab4 g4 db5 e4 d4 bb4 eb4 b4 f4 fs4 a4)) => ((c5 ab4 g4 db5 e4 d4 bb4 eb4 b4 f4 fs4 a4) (a4 c5 cs5 g4 eb5 gs4 e5 d5 f4 b4 bb4 fs4) (fs4 a4 g4 cs5 d5 c5 eb5 gs4 b4 f4 e5 bb4) (bb4 e4 eb5 a4 c5 f4 gs4 fs4 g4 cs5 b4 d5) (d5 b4 gs4 e4 f4 cs5 fs4 bb4 eb5 a4 g4 c5) (c5 f5 eb5 a4 d5 fs5 b4 g5 gs5 e5 cs5 bb4) (bb4 d5 gs5 e5 c5 b4 f5 cs5 eb5 a4 fs5 g5) (g5 gs5 f6 b5 cs6 a5 eb6 d6 bb5 fs5 c6 e6) (e6 f6 eb6 a5 d6 fs5 bb5 gs5 g5 c6 cs6 b5) (b5 a5 bb5 eb6 d6 c6 e6 gs5 cs6 g5 f5 fs5) (fs5 eb6 e6 bb5 d6 g5 b5 gs5 f5 cs6 a5 c6) (c6 eb6 b5 g6 e6 cs6 f6 bb5 d6 gs5 a5 fs6) (fs6 eb6 f6 cs6 b5 gs5 d6 g6 e6 bb5 a5 c6) (c6 eb6 d6 gs5 f5 bb5 e6 cs6 b5 g5 a5 fs5) (fs5 eb6 e6 bb5 d6 g5 b5 gs5 f5 cs6 a5 c6) (c6 eb6 b5 g6 e6 cs6 f6 bb5 d6 gs5 a5 fs6) (fs6 eb6 f6 cs6 b5 gs5 d6 g6 e6 bb5 a5 c6) (c6 eb6 d6 gs5 f5 bb5 e6 cs6 b5 g5 a5 fs5) (fs5 eb6 e6 bb5 d6 g5 b5 gs5 f5 cs6 a5 c6) (c6 eb6 b5 g6 e6 cs6 f6 bb5 d6 gs5 a5 fs6) (fs6 eb6 f6 cs6 b5 gs5 d6 g6 e6 bb5 a5 c6))
  19. thank you for the LINKS, i will read the papers! greetings andré
  20. thanx, dear julio. the "serialists" often have suitable concepts for formalization greetings andré
  21. one other interesting approach could be, to use l-systems on a "higher level"... (a lot of work to this is already made in OPENMUSIC) a sequence like '(a b a c a d a a b a e ...) ;; as a "nonsense-l-system-example-seq" could be used as a seq for FUNCTIONS... means: an input/omn-seq would be transformed by an l-system-function-sequence, for example... a = rotate pitches and lengths b = invert pitches c = sample-seq pitches d = change velocities so you could work with more complex input-gestalts... and when you are doing this on a second/third-level inside of such GESTALTS you will have something like this MODEL... Hypercycle (chemistry) - Wikipedia EN.WIKIPEDIA.ORG i think HANSPETER KYBURZ is "the MASTER" for L-SYSTEMS in MUSICAL COMPOSITION, and i he talked about this things in his lectures Details - Hochschule für Musik Hanns Eisler Berlin WWW.HFM-BERLIN.DE Hanspeter Kyburz - Wikipedia EN.WIKIPEDIA.ORG famous pieces with/on this are: CELLS or PARTS https://www.youtube.com/channel/UCkBcN66Y0mYZ8EJ_ihZvkdg
  22. Das Wachstumprinzip von L-Systemen in der Musik von Hanspeter Kyburz - PDF Kostenfreier Download DOCPLAYER.ORG Hochschule für Musik Hanns Eisler Abteilung D Charlottenstr Berlin Masterarbeit Das Wachstumprinzip von L-Systemen in der Musik von Hanspeter Kyburz Eres Holz 30. April 2012 Inhaltsverzeichnis
×
×
  • Create New...

Important Information

Terms of Use Privacy Policy