easy and effective ways of creating random/generative melodies
what are the easy and effective ways of creating random/generative melodies?
If you have M4L there are a good few examples of probability and randomly generated pitch, velocity and gate devices. There is also NWDLBOTS and if you only Max maybe look at the RTC Library.
Given the melody you provide:
Generate a row of numbers in the midi range you want the melody (between 0-127), save them as a list, output the numbers in the list sequentially, then rhythmically, ever bar, change the base number to change the key, send them to a scaler and then convert them to midi or frequency. The reason to save the numbers as a list is because the melody repeats. If you want a whole new melody generate another row of numbers. If you want a variation of the same melody look into Markov chains to mutate based on rules.
A good blog is the algorithmic composer.
Here’s a commercial Max app I created (for a client) that generates random, but parameter-controlled, melodies for ear-training. Free full time-limited demo available. Windows only.
For your own tinkering, [zl] with your melodies is a good start, lots of things you can do with an otherwise straight-ahead list of pitches and rhythms.
i think if "effective", "random" and "keeping the flow" is the whole concept, the concept should be extended a bit _before trying to patch that.
"The reason to save the numbers as a list is because the melody repeats."
Is there a non signal chucker like object?
These are hardly "high art" :), but might be instructive…
Controlling the range of a set of numbers
Algorithmic composition with math functions
A 16-stage note sequencer
Read MIDI pitches from a lookup table
Repeated notes at 6 related tempi, with different probabilities
Minimal loops, using a portion of a table (scroll to "Example 3")
Yep. Chucker basically rearranges which slice of audio is played. Instead of playing the loop straight – slice 12345678 you get slice 34251768. Zl.scramble will do the same thing for lists. Like Seejayjames said if you want to mess with lists the the zl family of objects and vexpr are your friends.