Renick Bell, Tama Art University
May 2, 2014
My name is Renick Bell.
I'm a doctoral student at Tama Art University in Tokyo.
I'm researching live coding.
To do live coding, I use, among other things, a Haskell library I have written called Conductive.
(photo: me live coding at Soup in Tokyo on 14/04/05, visuals on the right by Yousuke Fuyama)
"Experimenting with a Generalized Rhythmic Density Function for Live Coding"
My library didn't give me as much freedom in generating rhythm patterns as I wanted, so I'm experimenting with a pattern-generation function that has been generalized to get greater modularity.
I'm trying to get a set of abstractions to maximize my freedom while performing.
Right now my focus is mostly on rhythm.
Butch Morris conducting an ensemble of Paal Nilssen-Loves and Han Benninks.
Photo of Butch Morris by Claudio Casanova. Photo of Paal Nilssen-Love by Heiko Purnhagen. Photo of Han Benninks by Mark A. Lunt.
Photo of robot drummer by m anima: https://www.flickr.com/photos/banky177/2790867763 Photo of me by Xavier Ho.
I modified my functions for generating rhythm patterns to make them more flexible, particularly to generate more styles of rhythms.
If you want to know more about how Conductive works, check my 2011 and 2013 LAC papers.
interonset interval (IOI) = the time between the onset of two events, determines rhythm
rhythmic density = a number describing the relative quantity of events within a particular period of time
An IOIMap is a data type that combines a looping rhythm pattern and its variations at different rhythmic densities.
"a function that takes a function as an argument or returns a function as a result is called higher-order." Graham Hutton. 2010. Programming in Haskell.
one of two important kinds of "glue" that increase modularity, "the key to successful programming", according to John Hughes in "Why functional programming matters", a 1989 article in The Computer Journal.
One function generates the base rhythmic pattern according to a specified pattern length.
Another function uses that base rhythmic pattern and generates an ordered collection of variations at different densities. The function describes how the density should be increased.
This function increases density by reducing IOIs by one of a specified number of ratios.
*> densifier 0.25 [0.5] [1,1,1,1]
[1.0,1.0,1.0,0.5,0.5]
*> densifier 0.25 [0.5] it
[0.5,0.5,1.0,1.0,0.5,0.5]
*> densifier 0.25 [0.5] it
[0.5,0.5,1.0,0.5,0.5,0.5,0.5]
*> densifier 0.25 [0.5] it
[0.5,0.5,0.5,0.5,0.5,0.5,0.5,0.5]
*> densifier 0.25 [0.5] it
[0.25,0.25,0.5,0.5,0.5,0.5,0.5,0.5,0.5]
Lindemayer systems, abbreviated to L-systems, were developed by Aristid Lindenmayer in 1968 as "a theory of growth models for filamentous organisms" (Lindenmayer, 1968).
They are string-rewriting systems in which an input string is transformed according to a set of rules in which each item in the string is rewritten. By inputting this output back through the rule-set, successive generations can be obtained (DuBois, 2003).
Image: © Nevit Dilmen found at Wikimedia commons
rules: a -> b
b -> ab
input: a
output: b
ab
bab
abbab
bababbab
abbabbababbab
bababbababbabbababbab
*LSystem> getGeneration2 5 rules "a"
"abbab"
*LSystem> let a = it
*LSystem> randomFinalizer2 [0.25,0.5..1.25] a
[1.25,0.25,0.25,1.25,0.25]
*LSystem> randomFinalizer2 [0.25,0.5..1.25] a
[1.25,1.0,1.0,1.25,1.0]
*LSystem> randomFinalizer2 [0.25,0.5..1.25] a
[0.5,0.75,0.75,0.5,0.75]
*LSystem> getGeneration2 5 "a:b b:ab" "a"
"abbab"
*LSystem> let a = it
*LSystem> let b = nub a
*LSystem> b
"ab"
*LSystem> let c = zip (map (\x -> [x]) b) [(1+),(0.5*)]
*LSystem> let d = flatFinalizer c a
*LSystem> :t d
d :: [Double -> Double]
*LSystem> transform 2 d
[2.0,3.0,1.5,0.75,1.75,0.875]
"abbab"
[(1+),(0.5*),(0.5*),(1+),(0.5*)]
*LSystem> transform 2 [(1+),(0.5*),(0.5*),(1+),(0.5*)]
[2.0,3.0,1.5,0.75,1.75,0.875]
It works, and the ugly code is available from my website.
It needs to be cleaned up and then properly packaged for Hackage.
I need practice with it to use it effectively when performing live.
I have been using these two example functions to make a series of "fractal beats".
http://www.renickbell.net/doku.php?id=fractal_beats
I would like to thank my advisors Akihiro Kubota and Yoshiharu Hamada for research support.
My explanation might have been unclear. What questions do you have?
Do you have comments? Criticisms?
You're welcome to ask me questions by email: renick at gmail.com.
If I make changes, I'll mention updates on Twitter at least: @renick
My website gets updated sometimes: http://renickbell.net