Thursday 6 May 2010

Algorithmic Composition | OpenMusic Rhythm Trees Tutorial Part 2

In our last algorithmic composition tutorial we introduced using Rhythm Trees in OpenMusic. Rhythm trees are powerful ways of representing complex musical rhythms, the downside is that they can be a little cumbersome to enter by hand.

Fortunately we can use some of the built in objects in OpenMusic and simple algorithmic composition techniques to generate rhythm trees and musically interesting rhythms for us.

Rhythm Trees in OpenMusic
In today's algorithmic composition tutorial we'll look at some further techniques you can use to create Rhythm Trees, but first a quick recap:

The simplest way to create a rhythm tree is to enter rhythmic values into a list directly into the tree input of a voice class.

Rests can be entered by using negative numbers

We can create complex rhythms simply by using irregular proportions:

When working in this way, OpenMusic assumes a 4/4 time signature. We can specify the time signature directly by creating a proper rhythm tree using a nested list:

The time signature is specified first, followed by the note proportions:

Rests can be included anywhere in the group by putting a minus symbol in front of the rhythm value.

To create ties between notes use floating point numbers, for example:

Creating rhythm trees by hand can be quite laborious as each element needs to be specified and the nested lists become difficult to read:

More Rhythm Tree Functions
Our last algorithmic composition tutorial looked at using the maketree function to create rhythm trees, today's tutorial introduces another two useful functions maketreegroups and pulsemaker.

The maketreegroups function has three inlets where you can specify:

  • a number of rhythmic sequences
  • the order that these sequences should follow
  • a list of time signatures
In the following example, we've specified 2 different rhythmic patterns (the first inlet) and have specified an alternating sequence (the 2nd inlet):

In this next example we've listed four rhythmic patterns, have sequenced in order and then in reverse order and have listed two time signatures:

Using the maketreegroups function is a much easier way of sequencing rhythms than typing the rhythm tree in by hand. It also allows us to include algorithmic composition techniques, in this example we're using the nth-random function to choose one of the possible sequences at random and the repeat-n function to repeat this 8 times.

Using Pulsemaker Function to create Rhythm Trees
The pulsemaker function is also used to create OpenMusic rhythm trees, it has three inlets:
  • List of time signature numerators (the number of beats in the bar)
  • List of time signature denominators (the type of beats in the bar)
  • A list of pulses - one for each bar
The best way to illustrate how pulsemaker works is to give a few examples. In this first pulsemaker example, we're creating two 4/4 bars (specified by the first two inlets), the first bar has four pulses and the second two pulses (the last inlet)

In this next example, we create one 4/4 bar and one 4/8 bar. The first bar has two pulses and the second bar one. Notice the duration of the pulses is automatically adjusted to fit the time signature.

In this example we have 3 bars 4/4, 4/8 then 4/4. The pulses listed in the last inlet include a nested list (1 1 2).

We can also include rests in our list of pulses. As before, these are specified using negative numbers:

Using pulsemaker maketreegroups and mktree functions together with some other rhythm tree functions that we'll explore in future tutorials, makes composing algorithmically with Rhythm Trees in OpenMusic much easier.

Subscribe to the RSS feed and check back soon for more Algorithmic Composition tutorials using OpenMusic, Max, PureData, CommonMusic and other algorithmic composition software.

No comments:

Post a Comment