The invention relates to a method for automatic generation of melodies
where from one step to a following a new parameter value is generated
that is sent to a unit emitting sound. The parameters comprise a new note
pitch, a new window width, a life span for the window width, a window
offset and a life span for the window offset. The new note pitch is
selected according to a given probability distribution within the
interval of note pitches given by the note pitch in a previous step, the
window width and the window offset.