Fractals - PowerPoint PPT Presentation

1 / 55
About This Presentation
Title:

Fractals

Description:

These fractals are 'statistically self-similar' ... Statistically Self-Similar Fractals. Self-similar fractals in which random variations are made to the sub-parts ... – PowerPoint PPT presentation

Number of Views:125
Avg rating:3.0/5.0
Slides: 56
Provided by: pm5
Category:
Tags: fractals

less

Transcript and Presenter's Notes

Title: Fractals


1
Fractals Grammarsin GraphicsComp 575 - Fall
2008
2
Texturing with Images
  • Texture maps with images are good because images
    are (sometimes) easy to create.
  • In some cases, just taking a picture is easier
    than writing a program to generate the picture.
  • Images are hard to get for things that arent
    real.
  • Images consume space.
  • Images have finite precision.

3
Procedural Methods.
  • Write a program to generate the texture.
  • Save space.
  • In some cases, can zoom in forever and retain
    precision
  • Hard to write the right procedure.
  • However, ideas based on fractals go a long way.
  • Especially for objects in nature.

4
Euclidean vs. Fractal
  • Standard objects are represented in Euclidean
    geometry
  • Described by equations
  • This gives smooth, regular objects
  • Spheres
  • Polygons
  • B-spline surfaces
  • How do we model natural objects?
  • Clouds
  • Mountains
  • Plants
  • These kinds of objects are better represented
    with fractal geometry

5
What is a Fractal?
  • Benoit Mandelbrot, 1982,
  • clouds are not spheres, mountains are not
    cones, coastlines are not circles, and bark is
    not smooth, nor does lightning travel in a
    straight line.
  • Objects are represented as procedures rather than
    equations
  • Repeating the fractal procedure produces more and
    more detail

6
Properties of Fractals
  • Self-similarity between object parts and the
    overall object features
  • Fractional dimension
  • No specific size or scaling
  • Infinite detail looks good at every resolution
  • Generated by a function, so no data to store.
  • Some of them look like things you find in nature.

7
Fractal Mountain
The closer you get, the more detail you see
8
Fractal Generation
  • A fractal object is generated by repeatedly
    applying a specified transformation
  • Can apply the transformation to a point set, set
    of primitives (lines, curves, colors ,etc.), or
    anything else
  • Theoretically, the procedure is applied an
    infinite number of times
  • Practically, we only need to iterate a few times.

9
Fractal Dimension (Hausdorff variant)
Split into ¼ the size and multiply by
4 Build original by splitting into 4 parts
and multiplying by 4
Split into ¼ the size And multiply by 16
42 Build original by splitting into 4 parts
and multiplying by 42
Build original by splitting into 4 parts and
multiplying by 43
10
Fractal Dimension (Hausdorff variant)
Split into ¼ the size and multiply by
4 Build original by splitting into 4 parts
and multiplying by 4
Split into ¼ the size And multiply by 16
42 Build original by splitting into 4 parts
and multiplying by 42
Build original by splitting into 4 parts and
multiplying by 43
11
Fractal Dimension (Hausdorff variant)
12
Sierpinski Triangle
  • Take a triangle.
  • Reduce by ½
  • Make 3 copies and arrange them into a triangle
  • Repeat forever.

13
Sierpinski Triangle
14
Cantor Set
  • Lots of interesting and counter-intuitive
    properties
  • Uncountably infinite number of points.
  • Lebesgue measure of 0.
  • What is its fractal dimension?
  • Reduce by 1/3
  • Make 2 copies

15
A Few Examples
Penrose tiling 1.974 (a non-periodic tiling)
Cauliflower 2.33
Menger sponge 2.726
http//en.wikipedia.org/wiki/List_of_fractals_by_H
ausdorff_dimension
16
c. 13 branches each 1/3 smaller, D
log(13)/log(3) 2.33
17
Fractals in Nature
http//www.funpike.com/images/plant-bushes/2fracta
l_nature_1.jpg
http//www.treklens.com/gallery/Oceania/New_Zealan
d/photo22113.htm
18
Fractal Classification
  • Self-similar fractals
  • Parts are scaled-down versions of the initial
    object
  • Deterministic self-similar
  • Non-random
  • Statistically self-similar
  • Some randomness introduced
  • Self-affine
  • Different scaling parameters in each coordinate
    direction
  • Invariant Fractal Sets
  • Formed with nonlinear transformations
  • Sets in the complex plane (usually)

19
Self-Similar Fractals
  • Parts are scaled-down versions of the entire
    object
  • Start with the initial shape
  • Construct sub-parts by duplicating the initial
    shape and scaling it
  • Can apply different scaling factors for different
    parts
  • Example
  • The von Koch snowflake
  • Can also introduce random variations to the
    sub-parts
  • These fractals are statistically self-similar
  • Typically used to model trees, shrubs, and other
    plants

20
Von Koch Snowflake
  • Start with initiator
  • And generator
  • At each iteration, replace each piece of the
    initiator with the generator

21
Von Koch Snowflake
  • Iteration 0

22
Von Koch Snowflake
  • Iteration 1

23
Von Koch Snowflake
  • Iteration 2

24
Von Koch Snowflake
  • Iteration 3

25
Other Self-Similar Fractals
26
Peano Curve
  • Space-Filling Curve

1st Iteration
2nd Iteration
3rd Iteration
27
Statistically Self-Similar Fractals
  • Self-similar fractals in which random variations
    are made to the sub-parts
  • Typically used to model trees, shrubs, and other
    plants

Marco Bubkewww.xfrogdownloads.com
Bernd Lintermann www.xfrogdownloads.com
28
L-systems
  • Lindenmayer systems
  • Invented by a biologist
  • Used to describe plant growth
  • Formal Grammar
  • Rewrite a bunch of symbols in parallel.

29
Fibonacci Numbers as an L-system
  • variables  A B
  • start   A
  • rules   A ? B
  • B ? AB
  • This L-system produces the following sequence of
    strings
  • n 0  A
  • n 1  B
  • n 2  AB
  • n 3  BAB
  • n 4  ABBAB
  • n 5  BABABBAB
  • n 6  ABBABBABABBAB
  • n 7  BABABBABABBABBABABBAB
  • Count the length of each string 1,1, 2, 3, 5, 8,
    13, 21, 34,

30
Cube-Free
  • Is it possible to create a string of 0s and 1s
    where no substring repeats three times?
  • No substrings like 000, 010101, or 101101101
  • This is called the cube-free property.
  • Yes, the Thue-Morse Sequence.
  • Under some rules of chess, you can have an
    infinitely long game without a stalemate.

31
Thue-Morse Sequence
  • variables  0 1
  • start   0
  • rules   0 ? 01
  • 1 ? 10
  • n 0  0
  • n 1  01
  • n 2  0110
  • n 3  01101001
  • n 4  0110100110010110
  • n 5  0110100110010110 1001011001101001
  • n 6  0110100110010110 1001011001101001
  • 1001011001101001 0110100110010110

32
Von Koch Snowflake
  • Start with initiator
  • And generator
  • At each iteration, replace each piece of the
    initiator with the generator

33
L-systems Used to Model Plant Growth
34
Fractal Trees
35
Trees using L-systems
36
Modeling Venation Patterns
37
Split Grammars for Buildings
38
Results using Split Grammars
39
Midpoint Displacement
40
Midpoint Displacement
41
Midpoint Displacement
42
Invariant Fractal Sets
  • Formed with non-linear transformations
  • Includes the self-squaring fractals and the
    self-inverse fractals

43
Mandelbrot Set
  • Iterate over a complex function
  • Color the point in space based on how quickly the
    function diverges at that point
  • Points that do not diverge are in the set
  • The set is typically colored black, points that
    diverge at different speeds are colored
    accordingly

44
The Mandelbrot Set
45
Zooming into the Mandelbrot Set
http//www.softlab.ntua.gr/miscellaneous/mandel/ma
ndel.html
46
Computing the Mandelbrot Set
For each pixel on the screen do x x0
// x co-ordinate of pixel y y0 // y
co-ordinate of pixel x2 xx y2 yy
iteration 0 maxIteration 1000 while (
x2 y2 lt (22) iteration lt maxIteration )
y 2xy y0 // Complex
Multiplication x x2 - y2 x0 x2 xx
y2 yy iteration iteration 1
if ( iteration maxIteration ) color
black else color iteration
47
Fractal Mountains
  • Start with the basic shape of the mountain
  • Subdivide edges of the shape
  • Randomly perturb the new vertices
  • Repeat recursively
  • 2D for coastlines
  • 3D for mountains

48
Fractal Terrain Results
49
Terrain
50
Terrain
Other effects like erosion can be added.
51
Terrain
52
Other Uses of Fractals
  • Sierpinski Tetrahedron

53
Other Uses of Fractals
  • Fractal Brociflower

54
Other Uses of Fractals
  • Fractal Chandelier

55
Procedural Textures - Perlin Noise
  • Instead of perturbing the geometry perturb
    texture values.
  • http//www.noisemachine.com/talk1/20.html
  • http//blip.tv/file/760578/
Write a Comment
User Comments (0)
About PowerShow.com