THREE DIMENSIONAL TREE SCRIPTING AND CONSTRUCTION By Ryan
THREE DIMENSIONAL TREE SCRIPTING AND CONSTRUCTION By Ryan Pierce and Marco Rathjen
Goal �Set out to discover algorithms for building pre-rendered, relatively realistic tree systems for use in 3 D modeling.
�Lindenmayer Systems L-Systems �Introduced in 1968 by Astrid Lindenmayer, a Hungarian theoretical biologist and botanist. �Used to model the behavior of plant cells and subsequent plant development. �Also, fractals.
Parametric L-Systems �Parametric L-Systems are defined as a tuple: G = (V, ω, P) �V is the alphabet, basically a set of strings that are used as variables. �ω is the initiator, a string of several initial conditions �P is a set of production rules defining the system’s growth.
Basic L-System (Algae) ω = A n = 0: A n = 1: AB n = 2: ABA n = 3: ABAAB �Alphabet -> V: A, B �Axiom - > ω: A �Production Rules -> P: n = 4: ABAABABA n = 5: ABAABAAB n = 6: ABAABABAABABA (A-> AB) (B-> A)
Sierpinski Triangles (n=2, 4, 6, 8) Dragon Curve (n=10) Basic L-Systems http: //www. kevs 3 d. co. uk/dev/lsystems/ - Demos Square Koch (n=3)
Fractal Plant System (n=6, angle=25 degrees)
Turtles A turtle has: a location an orientation a pen
Dielectric Breakdown Model �Simulates branching pattern that occurs during electrical discharge. �Breakdown occurs when an insulator (dielectric) is converted into a conductor. �Given a grid G, growing an aggregate by size n takes at best O(n * G^1. 5) �G is especially large in 3 D 1. ) Calculate electric potential φ on a regular grid. 2. ) Select grid cell as growth site based on φ. 3. ) Add growth site to boundary condition. 4. ) Repeat until desired aggregate is obtained.
Modern Algorithms �Space Colonization �Laplacian Growth Various Laplacian Growth techniques
Modern Algorithms �Space Colonization a. b. c. d. e. f. g. h. Attraction points Closest nodes Normalized vector Adding vectors and normalizing Lateral branching/extending main axis Neighborhood of Removing attraction points Closest nodes �Laplacian Growth Initial: 1. Insert a point charge at the origin. 2. Locate the candidate sites around charge (8 or 26 neighbors) 3. Calculate potential at each site according to the above equation. Recursive: 1. Randomly select weighted growth site according to preferences. 2. Add new point charge to site. 3. Update potential at all candidate sites. 4. Add new candidate sites. 5. Calculate potential at new candidate sites using equation.
Space Colonization �
Space Colonization
Space Colonization vs. Laplacian Growth Space Colonization Laplacian Growth �Runtime: O(n) for attraction �Runtime: O(n 2) point calculation �More “convincing” for mature trees �Simulates fight for resources during growth �Wide variety of shapes with small parameter set, and little variation of algorithm �Memory: O(n) where n is the number of growth sites in the final aggregate. �Extra negative charges can be inserted to stunt or encourage growth �Allows for global simulations (light, wind)
For the Test! Know the three basic parts of an L-System: Alphabet, Initiator, and Production Systems (aka Variables, Initial Conditions, and Rules)
Sources �Images/L-Systems: http: //en. wikipedia. org/ wiki/L-system �Laplacian Growth: http: //scholar. google. co m/scholar_url? hl=en&q =https: //www. mat. ucsb. edu/Publications/tkim_l aplacian_small. pdf&sa= X&scisig=AAGBfm 10 e 7 e v. R 4 Qc. XYO 8 KKl. Kcec. Py. Q GRWA&oi=scholarr �Space Colonization: http: //algorithmicbotany. org/papers/colonization. egwnp 2007. html
- Slides: 16