Jaime – L-Systems

Part 1: Turtle Geometry

polygonHalt(1, 1);

polygonHalt(2, 2);

The size of the images don’t illustrate it very well, but the radius of the circle is the same. The number of segments the circle is divided in the second is fewer, however (360 / 2 = 180).

For infinite precision, the circumference of the circle is 360. The radius would then be 2*Pi*r = 360 => r = 360/2Pi

Part 2: L-Systems

The plants I chose to model were String of Pearls, Weeping Willow, and Saguaro Cactus. I have a String of Pearls plant that I am currently propagating that was easy to examine. I was inspired by a potted cactus that I have, which reminded me of the many drives to Arizona staring out the window at the bizarre shapes Saguaro Cacti make, and I grew up playing around a Weeping Willow Tree as a child.

I referenced photos online for the Weeping Willow and Saguaro Cacti.

I wrote my code in such a way that I could switch between models dynamically while it was running with the ‘w’, ‘p’ and ‘c’ keys for changing between Willow, Pearls, and Cactus. I also found that the view benefited from the ability to dynamically resize the scale, which I do with the up and down arrow keys in the keyPressed function. Rather than iterating every draw cycle, I chose to have my model iterate when the mouse is clicked. Because I have some randomness in each of my models, this results in slight movement every draw cycle, making the LSystems look animated.

When generating my String of Pearls, I knew I wanted it to grow mostly linearly with occasional branching structures, all the while it should also produce nodes in the form of pearls. My branching “X” variable is the only variable that continues to propagate:

I have an “S” variable that represents drawing a stem or short section of the string, utilized in branching off to draw the pearls (“P”) and when branching into new strings. I added some curvature with the stems when branching in order to simulate the strings making room due to volume of their pearls.

For my cactus, I knew I wanted a similar behavior, but growing upwards. After experimenting for a bit, my rules look like:

Because cacti tend to grow upward, I added a conditional statement to my drawCactus(…) code to orient the turtle upwards slowly:

My Weeping Willow tree rules were a change from the other two. I wanted to simulate the twisting path the tree trunk and branches often taken, so I added some rules to my “F” variable:

The growth has the possibility of changing to an angled path before righting itself (once again attempting to simulate gravity). I also wrote two different leaf drawing functions, one that emulates the appearance of actual Weeping Willow Leaves and one that simulates the appearance of them because drawing that many detailed leaves significantly slows down the draw function:

I also had the stroke color and weight change on every push/pop to indicate when the LSystem would branch, trying to show new versus older growth in the tree:

I was inspired by the Willow Tree shape to make an earring stand for my partner. I turned off the leaf drawing so that the leaves could be the earrings, generated svgs out of the subsequent shapes, and laser cut them out of wood:

I intended to have them slot together in a base, but the print I did for bending the wood wasn’t fine enough and the piece broke. Instead, I glued them to a cardboard base and wrapped them with thread, because I found the aesthetics of the glue ugly.

6 thoughts on “Jaime – L-Systems

  1. Hello, Jaime,
    I like all your works! But the first one is the most attractive one. It’s a good idea to let the drawing starting from the top. Very unique.

    Jingbo

  2. Hi Jaime!
    I made a comment of this in class, but your approach to solving physical characteristics with pseudo physics. All three of your systems demonstrate this and each in a different way which is awesome. I think your cactus came out particularly nice! Great job with this!

  3. Hi Jaime, I love your work and design, especailly the 3d cut work. I’m not sure I’d be able to figure out how to replicate a willow tree in Processing. Great Work!

  4. Hi Jaime! I really love how intuitive and efficient you solved issues with modeling the plants, like how you were able to get the cactus arms to keep going up no matter which side they were on. I also love how your tree earring stand looks so organic yet was generated through computation. It’s pretty neat that you modeled a tree on wood too. I love how the earrings become like the willow leaves too.

  5. All of your plants are so amazing Jaime. Your commitment to accurately representing the physical characteristics of the plants through code is very impressive. I also love how the randomization and the way you controlled the iterations made your string of pearls look like it was swinging!

  6. Hey Jaime,

    the tree art came out amazing! You did a great job documenting your process. Overall great post!

    Best,
    -Daniel

Comments are closed.