rule(1).before = 'F';
rule(1).after = 'FF';
rule(2).before = 'G';
rule(2).after = 'F[+G][-G]F[+G][-G]FG';
Which generates this tree.
However, I decided to use this simpler L-system:
rule(1).before = 'F';
rule(1).after = 'F[-F][+F]';
I thought it would be much, MUCH easier to analyze. It would be cool to come up with an expansion that makes the trunk grow more, but keeps the binary relation, but I'm probably not going to be up for that... Here are the different trees that it generates depending on the number of repetitions.
No comments:
Post a Comment