For my Nature of Code final, I presented a part of my working thesis to show how the lighting pattern of the project was using principles learned from class. I struggled for some time to try to come up with a sketch that would make sense for the project but also stay true to the nature of the piece. As the development for Radical Everything began from ideas regarding emergent ecologies and thus the idea of simple interactions creating more complex behaviors and patterns, I thought it at first appropriate to come up with a lighting pattern that would mimic more closely that of a cellular automata pattern. So I began to code a 1-Dimensional sketch that would turn my LEDs from a HIGH to LOW state based on these simple algorithms. However, I began to quickly realize that any user who would be entering the field of this installation would quickly become confused at what would be a seemingly random pattern of lighting without any basis or grounding in what the sketch was actually doing. Therefore I began a second sketch based on Dan Shiffman’s advice that more closely adhered to my midterm in which “seeds” were generated (in this case by a threshold value in my potentiometer, which will soon be replaced by a proximity sensor) that would cause neighboring lights in the array to fade on, based on a passing function of time as it looped through each LED in my array. For future iterations, I would love to add more dynamic behavior to the lighting pattern such as: (a) adding oscillation to the timing so that the lights would fade on and off more dynamically, and (b) adding genetic behavior to the lighting so that each subsequent generation of the lighting pattern would adhere more towards areas of higher activity in the installation.
Detailed view showing the LEDs arrayed around one node of the installation.
source code for lighting sketch here
In the end, I forewent using Toxi’s library and instead opted to implement particle systems because I wanted a better understanding of how to use them. Here is a video of the end result. I added some perlin noise to vary the color and add a bit more sparkle to the “crystals.” But the code is using four particle systems which hit the “seeds,” each of which are generated upon a mouse press. As the particles hit the seeds, they will become part of the seed and expand the cluster, forming the branching-like DLA pattern.
source code here
For my midterm in Nature of Code, I’d like to be able to simulate a part of my evolving thesis idea which broadly speaking, is the notion of a parasitic lighting system that draws electricity to nourish its own expanding, growing needs. This ‘nourishment’ is redirected towards the dynamic growth of crystal structures grown on reconfigurable, modular ‘offsprings’.
The crystallization process can occur through what is known as DLA (Diffusion Limited Aggregation) in which particles move randomly due to Brownian motion until it collides with the base seed particles with a “sticking coefficient”.
I think this is better explained here: http://www.physics.uc.edu/~pinskia/dla/DLA.html
and here: http://classes.yale.edu/fractals/panorama/physics/dla/DLA.html
I’ve been looking at ways to develop a sketch which will use camera tracking to have the crystal growth start a seed based on where a person is standing, and using motion detection so that the less he or she moves, the more the seed will have a chance to grow into larger aggregations…
Toxi recently posted about a library called simultis which explores this DLA process with some amazing looking results: http://toxiclibs.org/2010/02/new-package-simutils/
I’ve been roughly experimenting with this and using a more traditional 2-dimensional approach to the issue but haven’t decided yet what would be the best course of action from here on out. I feel like the toxiclibs library would take a long time to get through (let alone render and process!) but the results would be stunning. On the other hand, there’s nothing wrong with using particle systems to simulate the process as well.
For Nature of Code last week, we had to program an example of something demonstrating oscillating movement. Although I originally thought of the particular forces that exist between the nucleus and electrons of an atom, I decided to play up the idea by relating the gravitational mass of the “nucleus” in my sketch with the degree of oscillation between the corresponding “electrons”.
This code was heavily adapted from Shiffman’s code.