L system: sympodial tree

https://en.wikipedia.org/wiki/Sympodial_branching

 

let us go to 3D now.... I tried the sympodial tree, with the same modeling way as my previous post, but performance not good. so I decided to put more actions into a loop and get rid of the first loop which is the long sentence.

I had another issue with previous way. I did not know how to take into account ratios to control lengths and angles.

the modeling is getting more complex. I lose the ability to use the grammar in input. it is not anymore a pure L-system, yet I will continue to call it as the logic is followed (rewriting)

along with the book "the algorithmic beauty of plant" by Przemyslaw Prusinkiewicz Aristid Lindenmayer, here is the logic (page 59) -> the pdf can be downloaded on this internet and it is a good read (can take years...)



my loop is like this

2 inputs (axis system;length) for A and B. in fact A could have been done out of the loop because only B is rewritten. anyway, I copied...

A -> move forward, then pitch 10deg and output (B; lenght X 0.9), back to A, roll 180 then pitch 65 deg and output (B; length X ,0.7)

B -> move forward, then yaw 10deg, roll to get local Y horizontal and output (B; lenght X 0.9), back to A, roll 180 then yaw -65 deg, roll to get local Y horizontal and output (B; length X ,0.7)

the function to get Y horizontal is explained in the book as well. I used cross product between local X and global Z in a user feature.

 

if you just want to play with the model, you can change the driving parameters using the tab "experiments" on the right

​​​​​​​