nagymusic

Hello!
I’d like to set up a process whereby a list of pitches is recursively “perturbed” (distorted) using the CONTROLPERTB function found in the OMProfile library. I’ve been working on this for some time now, so I appreciate any guidance on this challenge.
I’d like to construct a controlpertb omloop to automate a process in order to produce longer and more complex lists of pitches that become gradually and systematically perturbed. In addition to taking in a list of pitches, the omloop would also input an arithmetic list of index values, and then group the arithmetic serie into sublists that correspond to the number of pitches in the given melodic sequence, while also applying a reiterative process to the flat list of nums. For example, given the arithmetic list (0 5 10 15 20), the resulting sublist corresponding to a fournote melody should produce the following sublists of index values ((0 0 0 0) (0 0 0 5) (0 0 5 10) (0 5 10 15) … (20 20 20 20)). In turn, each of the sublists should be then applied to the fournote melody, producing a pitch sequence in the chordseq. I attached my working patch if anyone would like to have a look; the patch includes my attempt in building the omloop process and the original setup that only perturbs the given melody once by applying a set of index values.
I welcome any suggestions or ideas! I also hope this project is a good learning experience for the better understanding of omloops and nested recursive patterns.
Thank you!

anders

Hi nagy. To get your horizontally sliding window, you could pad the front and back of the index list, then loop through that list using ‘onloop’, taking care to collect only the (firstn n) idxs each time.
Another approach could be using Patterns, collecting a series of pline streams, each holding a shifted version of your indexes. Then map #’pnext over the collection to get the next set of idxs, repeating this until all lines are done.
anders

nagymusic

Thanks, Anders. I was able to construct my patch by applying your shiftedwindowsifidxs solution. See attached.
Thank you once again!
