Hallo, Frank Barknecht hat gesagt: // Frank Barknecht wrote: > - inversion: That's a bit more complicated. Quoting Wikipedia: > > Inverted melodies > > When applied to melodies, the inversion of a given melody is the > melody turned upside-down. For instance, if the original melody has a > rising major third (see interval), the inverted melody has a falling > major third (or perhaps more likely, in tonal music, a falling minor > third, or even some other falling interval). Similarly, in twelve-tone > technique, the inversion of the tone row is the so-called prime series > turned upside-down. > http://en.wikipedia.org/wiki/Inversion_(music)#Inverted_melodies > > In inversion.pd this is realised by walking through the list with > list-map, taking the difference between the current element and the > previous element, then substracting this from the current element. > The first element in a list is treated specially as it has no > previous element (it's just copied).
Ah, sorry: The patch is correct, but my explanation is wrong. Here's an update: In inversion.pd this is realised by walking through the list with list-map. The interval to use next is calculated by taking the difference between the current element and the previous element. This interval is substracted (not added, because we are "retro"-grading) from the previous note, the resulting note is stored for the next step and inserted into the result list. The first element in a list is treated specially as it has no previous element: it's just copied and used as the starting note. Ciao -- Frank _______________________________________________ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list