4. Simple tree.
This post is on what we often ponder: that what shapes our life as we grow is a combination of our genes, our environment, the decisions we make along the way, and random unforeseeable events which had an impact on the path we were traveling on. I choose to compare our lives with the shape of trees. An Oak is as different from a Coconut Tree as a Fern is different from a bush of Roses. An Oak cannot turn into a Coconut Tree and yet each Oak is different. The analogy with Life is that to a certain extent there is a boundary beyond which your Life cannot cross, yet within this boundary, there is considerable freedom for you to choose the the eventual 'shape' you will become. Let us illustrate this with Lindenmayer systems:
Example 8: Fractal plant
- variables : X F
- constants : + −
- start : X
- rules : (X → F-[[X]+X]+F[+FX]-X), (F → FF)
- angle : 25°
Here, F means "draw forward", - means "turn left 25°", and + means "turn right 25°". X does not correspond to any drawing action and is used to control the evolution of the curve. [ corresponds to saving the current values for position and angle, which are restored when the corresponding ] is executed. Those who are familiar with Turtle graphics will see that these plan algorithms are very simple and clear. As in all complex systems, there are a lot of variations and Lindenmayer's book " The Algorithmic Beauty of Plants give the details to accommodate these variations into the general system.