How to Draw a Tree L-Systems in Computer Graphics Steven Janke.

Slides:



Advertisements
Similar presentations
Jason Stredwick, MSU 2004 L-Systems Lindenmayer Systems algorithmicbotany.org.
Advertisements

Lecture # 8 Chapter # 4: Syntax Analysis. Practice Context Free Grammars a) CFG generating alternating sequence of 0’s and 1’s b) CFG in which no consecutive.
L-System Aristid Lindenmayer (1968), biologist. L-System A method of constructing a FRACTAL that is also a MODEL for plant growth. The Computational Beauty.
Procedural Content Generation James Grisetti. Overview Introduction Brief History of Procedural Generation Basic Generators Contemporary Generators Future.
SCRIPTING AND CONSTRUCTION THREE DIMENSIONAL TREE By Ryan Pierce and Marco Rathjen.
L systems (Aristid Lindenmayer)
L-systems Presented by Luv Kohli COMP258 October 30, 2002 Images copyright © 1992 D. Fowler, P. Prusinkiewicz, and J. Battjes.
Procedural Modeling L-Systems Procedural Terrain Procedural Behavior Based on the slides from Spring 2007.
79 Regular Expression Regular expressions over an alphabet  are defined recursively as follows. (1) Ø, which denotes the empty set, is a regular expression.
Lindenmayer Systems . Lindenmayer systems There is no distinction between terminal and non-terminal symbols. All the words derived from a given word.
CS39N The Beauty and Joy of Computing Lecture #11 Recursion III It has been a challenge to power electronic components implanted within a body.
CS 3240 – Chuck Allison.  A model of computation  A very simple, manual computer (we draw pictures!)  Our machines: automata  1) Finite automata (“finite-state.
Context-Free Grammars Chapter 3. 2 Context-Free Grammars and Languages n Defn A context-free grammar is a quadruple (V, , P, S), where  V is.
LANGUAGE AND GRAMMARS © University of LiverpoolCOMP 319slide 1.
Synthetic Topiary. Premislaw Prunsinkiewicz (Prof. P) Mark James Radomír Měch.
Final Exam Review Cummulative Chapters 0, 1, 2, 3, 4, 5 and 7.
Morphogenesis and Lindenmayer Systems (L-systems) Gabriela Ochoa
IlliDOL: A Framework for Exploration of L- Systems in Three Dimensions Vilas Dhar Math 198 Spring 2003.
Formal Grammars Denning, Sections 3.3 to 3.6. Formal Grammar, Defined A formal grammar G is a four-tuple G = (N,T,P,  ), where N is a finite nonempty.
Modelling of Ecosystems by Tools from Computer Science Summer School at Czech University of Life Sciences, Prague, September, 2013 Winfried Kurth.
Finite State Machines Chapter 5. Languages and Machines.
Andrew Leeuwenberg.  Hypothesis & Aim  Methodology summary  Result  Discussion and Future work  Conclusion.
L-Systems and Procedural Plants CSE 3541 Matt Boggus.
College of Computer and Information Science, Northeastern UniversityOctober 13, CS U540 Computer Graphics Prof. Harriet Fell Spring 2007 Lecture.
The Artificial Life of Plants Przemyslaw Prusinkiewicz, Mark Hammel, Radom´ır Mˇech Department of Computer Science University of Calgary Calgary, Alberta,
Examining the World of Fractals. Myles Akeem Singleton Central Illinois Chapter National BDPA Technology Conference 2006 Los-Angeles, CA.
1 Language Definitions Lecture # 2. Defining Languages The languages can be defined in different ways, such as Descriptive definition, Recursive definition,
1 Context-Free Languages Not all languages are regular. L 1 = {a n b n | n  0} is not regular. L 2 = {(), (()), ((())),...} is not regular.  some properties.
Chapter 5 Context-Free Grammars
Languages & Grammars. Grammars  A set of rules which govern the structure of a language Fritz Fritz The dog The dog ate ate left left.
Lecture # 9 Chap 4: Ambiguous Grammar. 2 Chomsky Hierarchy: Language Classification A grammar G is said to be – Regular if it is right linear where each.
L-Systems Lindenmayer Systems Prusinkiewicz and Lindenmayer
Summer School „Modelling and Simulation with GroIMP“ / Tutorial for beginners University of Göttingen (Germany), September, 2010 Winfried Kurth Some.
Lindenmayer systems Martijn van den Heuvel May 26th, May 26th, 2011.
Computing languages by (bounded) local sets Dora Giammarresi Università di Roma “Tor Vergata” Italy.
1 10/27/ :26 UML Simplicity in Complexity. 2 10/27/ :26 UML Rewriting Systems Classic Example: Koch 1905 Initiator Generator.
Regular Grammars Chapter 7. Regular Grammars A regular grammar G is a quadruple (V, , R, S), where: ● V is the rule alphabet, which contains nonterminals.
Context Free Grammars.
Tutorial and workshop „Modelling with GroIMP and XL“ / Tutorial for beginners University of Göttingen, 27 February, 2012 Winfried Kurth Introduction to.
LINDFERN Lindenmayer Systems in VPython Nick Langhammer.
Copyright © 2011 Pearson, Inc. 5.5 Law of Sines Goal: Solve triangles that have no solution, one solution, or two solutions.
CSCI 3130: Formal languages and automata theory Tutorial 4 Chin.
1 A well-parenthesized string is a string with the same number of (‘s as )’s which has the property that every prefix of the string has at least as many.
1 Simplification of Context-Free Grammars Some useful substitution rules. Removing useless productions. Removing -productions. Removing unit-productions.
CS 3240 – Chapter 5. LanguageMachineGrammar RegularFinite AutomatonRegular Expression, Regular Grammar Context-FreePushdown AutomatonContext-Free Grammar.
1 Efficient Parsing and Ambiguity. Ambiguity A grammar G is ambiguous if – There exists w ∊ L(G) such that – There are two parse trees for w Allows multiple.
Experimenting with Grammars to Generate L-Systems October 29, 2007
Lecture # 4.
Mathematical Foundations of Computer Science Chapter 3: Regular Languages and Regular Grammars.
Lecture 2 Theory of AUTOMATA
1 A well-parenthesized string is a string with the same number of (‘s as )’s which has the property that every prefix of the string has at least as many.
Week 14 - Friday.  What did we talk about last time?  Simplifying FSAs  Quotient automata.
Experimenting with Grammars to Generate L-Systems – in JFLAP March 31, 2011 Prof. Susan Rodger Computer Science Dept.
Grammars, L-Systems Jim Whitehead UC Santa Cruz School of Engineering courses.soe.ucsc.edu/courses/cmps265/Spring14/01 23 Apr 2014.
BCT 2083 DISCRETE STRUCTURE AND APPLICATIONS
Busch Complexity Lectures: Turing Machines
Theory of Languages and Automata
L-systems L-systems are grammatical systems introduced by Lyndenmayer to describe biological developments such as the growth of plants and cellular organisms.
Complexity and Computability Theory I
Context Sensitive Languages and Linear Bounded Automata
Theory Of Automata By Dr. MM Alam
Discrete Math II Howon Kim
A HIERARCHY OF FORMAL LANGUAGES AND AUTOMATA
Exercise: fourAB Write a method fourAB that prints out all strings of length 4 composed only of a’s and b’s Example Output aaaa baaa aaab baab aaba baba.
Chapter 7 Regular Grammars
5. Context-Free Grammars and Languages
Trees and Colored Edge Detection
MA/CSSE 474 Theory of Computation
CSC312 Automata Theory Lecture # 5 Chapter # 4 Cont…
Prof. Susan Rodger Computer Science Dept
Presentation transcript:

How to Draw a Tree L-Systems in Computer Graphics Steven Janke

Natural Trees

Tree Shapes

Euclidean Geometry Approach

Self-Similarity of Organic Forms

Computation = Processing Strings Input: Output: aababccacabb adfeeefg Computer Interpretation: 00110010 00101011 00110011 00110101 2 + 3 5

Alphabet of characters. L-System (Named after biologist Astrid Lindemayer in 1970’s) Alphabet of characters. First string called the axiom. Set of productions showing how to replace characters. All appropriate productions applied at once. Example: Alphabet: {a, b} Axiom: ab Productions: a bab , b a Derivation: ab baba abababab

Languages: L(G) = set of strings that can be derived from the system G. Example 1: Axiom: ab Productions: a a b ab ab aab aaab aaaab L(G) = { an b | n > 0 } Example 2: Axiom: a Productions: a b b ab a b ab bab abbab bababbab L(G) = ?

Languages: L(G) = set of strings that can be derived from the system G. Example 1: Axiom: ab Productions: a a b ab ab aab aaab aaaab L(G) = { an b | n > 0 } Example 2: Axiom: a Productions: a b b ab a b ab bab abbab bababbab L(G) = { s | s0 = a, s1 = b, sn = sn-2 sn-1 }

Turtle Interpretation: Simple L-System: Alphabet: { F, +, - } Axiom: F-F-F-F Production: F FF Turtle Interpretation: F means draw a line segment in current direction. + means turn left. - means turn right. Start Initial direction F-F-F-F means: Delta = 90 degrees

Branching L-Systems: Add two characters to alphabet: [ and ] Interpret [ to mean “start branch”. Interpret ] to mean “end branch”. F[+F][-F] means: Initial Direction Start Delta = 45 degrees

Turtles in 3D: + = left turn - = right turn & = pitch down Head Up + = left turn - = right turn & = pitch down ^ = pitch up / = roll right \ = roll left

Growth Functions: F(k) = length of the kth word in the derivation sequence. Example: a aa Axiom: a F(k) = 2k a abcc b bcc c c Axiom: a a abcc abccbcccc abccbccccbcccccc 1 4 9 16 F(k) = k2 F(

Growth Functions: G: a b b ab Axiom: b ak = number of a’s at iteration k. bk = number of b’s at iteration k. 0 1 1 1 ak bk ak+1 bk+1 = Theorem: Every growth function for an L-system is a linear combination of terms that are polynomials times exponential functions. Problem: Plants usually grow according to a logistic (or sigmoidal) function.

Parametric L-Systems: Axiom: A(3) A(x) : x<5 B(x+1)A(x*r) B(y) : * F(y)[+F(y/2)][-F(y/2)] Interpretation: F(x) means draw a segment of length x. +(x) means turn left x degrees.

Context Sensitive L-Systems Axiom: SFFFFA Production: SF FS SA B SFFFFA FSFFFA FFSFFA FFFSFA FFFFSA FFFFB Axiom: S[FA][FFA] S[FA][FFA] [FSA][FSFA] [FB][FFSA] [FB][FFB]

Developmental model using signals:

L-System Extensions: Gravity - pull on branches. Phyllotaxis - angle and position of branches. Phototropism - towards the light. Self-Organizing - branch into free spaces. Implementation: At each iteration, interpret the string and then decide based on the geometry and environment how to apply productions for the next iteration.

Colonization Algorithm: (Runions, Lane, and Prusinkiewicz 2007)

Colonization Algorithm:

Self-Organization Algorithm: (Palubicki 2009)

Self-Organization Algorithm:

Equivalence: G1: a bb b a Axiom: b b a bb aa bbbb G2: a b b aa Axiom: a a b aa bb aaaa L(G1) = L(G2) Is there an algorithm for determining if two L-Systems are equivalent?

Connection between Languages and Machines Recursively Enumerable Context Sensitive Context Free Regular L-Systems

Iterated Function System: