[livecode] live coding lsystems

From: Dave Griffiths <dave_at_pawfal.org>
Date: Tue, 1 Jun 2004 18:21:07 +0100

Hi all,

A little report on livecoding lsystem descriptions of melodies.

I'm not sure this is manefesto compliant or even counts as code, but I've
recently got a simple livecoding thing going on in some of my music software.
You basically enter the axiom and rules of an lsystem which are then expanded
as the melody is playing.

There is a simple score language the lsystem produces where:
o = note on
+ = up one note (the exact frequency change is configured elsewhere)
- = down one note
! = reset to root note
. = rest one beat

and numeric tokens are used as rule replacements for the lsystem.

so:

axiom = 1
rule '1' = o+1-1

expands to:

generation 1: o+o+1-1-o+1-1
generation 2: o+o+o+1-1-o+1-1-o+o+1-1-o+1-1
generation 3: o+o+o+o+1-1-o+1-1-o+o+1-1-o+1-1-o+o+o+1-1-o+1-1-o+o+1-1-o+1-1

well, you get the idea (just basic lsystem search/replace) :)

the results are actually quite nice, and playing it live feels pretty much
like programming to me. simple rules expand into quite complex melodies
quickly. I've used this lsystem score idea before, but in a genetic
programming environment where you had a choice of lsystem rules to breed from
- but doing it by hand is more satisfying (if a little slower)

cheers,

dave
Received on Tue Jun 01 2004 - 17:21:29 BST

This archive was generated by hypermail 2.4.0 : Sun Aug 20 2023 - 16:02:24 BST