Create Melody

This page is an experiment in creating melodies by modifying relatively long durations of a melodic contour phrase (default set to 'c2 ees aes g f d c2'). Each note of the melodic contour is ornamented with a common practice non-harmonic tone technique such as neighboring tones, passing tones, or a short melodic cell from the prevailing scale (default set to C harmonic minor). You can specify which ornament to use for each note by editing the ornament list (default set to '* * * * * * no'). The '*' symbol indicates a random ornament will be applied. The symbol 'no' means no change will be applied to your melodic contour note. Other ornament codes are listed below. For example an ornament list of 'lnt lnt lnt lnt lnt lnt no' would apply a lower neighbor tone to each of the melodic contour notes except the last one. There will be a randomly selected rhythm used for that neighbor note. Below is an example of the lilypond output of a random melody created using the default values. The odds are against this exact melody being created again anytime soon with these settings.



When you click play you won't hear this melody, you'll hear a newly created melody using your ornament list input as a guide. To see your melody in lilypond you'll need to copy the code at the botton of the page and paste it into lilypond. In lilypond, save the file then choose 'typeset file' to see a pdf of the melody and the melodic contour together (similar to the image above, for more info see link at the bottom of the page). Of course you can change the contour melody to anything you want as well as change the ornament list but be sure there is the same number of elements in both the ornament list and the notes of the melodic contour. Have your melodic contour contain notes that are in your scale context notes. Your can use any scale context you want (make sure you include the octave note). However if you choose a note in your melodic contour that isn't in your scale context you'll get weird results (unless you've also set the ornament to 'no' for that 'outside' note)

NOTE: Each time you change anything in the melodic contour field it will cause a new default ornament list to be generated. So beware if you change only a duration in the melodic contour field it will trigger a new default ornament list and write over any list you had been experimenting with, so you should copy your edited ornament field before making the change in the melodic contour field (so you can paste it back in). If you add more notes to the melodic contour and plan on pasting in an edited ornament list, then be sure to match the total number of ornaments to the total number of notes in the new melodic contour. One strategy for melody creation is to set all ornaments to 'no', then change only some of the values to specific ornaments or '*'. Then you can create a melody that has only some sections randomly created.

    (click stop in between plays)

| tempo: | | volume: |

(uncheck to hear original melodic contour)
Enter your lilypond melodic contour here:

enter one octave of a scale context for creating the melody:

ornament list for each note of melodic contour:

A discussion of the coding of this page.

Full lilypond score output:

Paste this code into lilypond to view the music notation. See instructions here

Back to the Tone.js Setup page.