JulioHerrlein Posted November 4, 2024 Posted November 4, 2024 Dear Friends, I´m trying to make a function to get the complementary diatonic set for a diatonic chord. For example, if you relate the key of C major (C D E F G A B) with the chord Cmaj7 (C E G B), the complementary set is (D F A). Elliott Carter did this a lot in his Harmony Book, making all kinds of complementarities. This works for comparing stuff. Is there something easier in the system ? For comparing a sequence of chords in relation to a sequence of tonalities for getting the difference ? (defun compare-list-pairs (list-pairs) (loop for (list1 list2) in list-pairs collect (set-difference list1 list2 :test 'equal))) (compare-list-pairs '(((c4 d4 e4) (c4 e4)) ((5 6 7 8 9) (5 7 8)))) ;> ((d4) (9 6)) If you want to work to the diatonic scales as integers, this can be useful, but maybe would be easier with embbeded tonality functions. (position-filter (pitch-to-integer '(e4 eb4 e4 eb4 b4 gb4 e4 db4)) '((0 2 4 5 7 9 11) (1 3 5 6 8 10 0) (2 4 6 7 9 11 1) (4 6 8 9 11 1 3) (5 7 9 10 0 2 4) (6 8 10 11 1 3 5) (7 9 11 0 2 4 6) (8 10 0 1 3 5 7) (9 11 1 2 4 6 (10 0 2 3 5 7 9) (11 1 3 4 6 8 10))) Any idea ? Thanks ! AM 1 Quote
JulioHerrlein Posted November 4, 2024 Author Posted November 4, 2024 I had this question before: Here is the answer by Janusz , back in 2021. Thanks, Janusz ! I´m obssessed by the same problems over and over. Best ! (let ((rem (ambitus '(c5 b5) (expand-tonality '((c5 major) (db5 major) (gb5 major))))) (super (ambitus '(c5 b5) '((d5 f5 a5 c6) (eb4 gb4 bb4 db4) (fs4 as4 cs4))))) (loop for s in super for r in rem collect (loop for i in s do (setf r (remove i r)) finally (return r)))) jon and Stephane Boussuge 2 Quote
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.