Barnsley fern: Difference between revisions

From testwiki
Jump to navigation Jump to search
rv nonsense
 
(No difference)

Latest revision as of 15:19, 10 November 2024

Template:Short description

Barnsley fern

The Barnsley fern is a fractal named after the British mathematician Michael Barnsley who first described it in his book Fractals Everywhere.[1] He made it to resemble the black spleenwort, Asplenium adiantum-nigrum.

History

Asplenium adiantum-nigrum, after which the fractal was modelled

The fern is one of the basic examples of self-similar sets, i.e. it is a mathematically generated pattern that can be reproducible at any magnification or reduction. Like the Sierpinski triangle, the Barnsley fern shows how graphically beautiful structures can be built from repetitive uses of mathematical formulas with computers. Barnsley's 1988 book Fractals Everywhere is based on the course which he taught for undergraduate and graduate students in the School of Mathematics, Georgia Institute of Technology, called Fractal Geometry. After publishing the book, a second course was developed, called Fractal Measure Theory.[1] Barnsley's work has been a source of inspiration to graphic artists attempting to imitate nature with mathematical models.

The fern code developed by Barnsley is an example of an iterated function system (IFS) to create a fractal. This follows from the collage theorem. He has used fractals to model a diverse range of phenomena in science and technology, but most specifically plant structures.

Template:Quote—Michael Barnsley et al.[2]

Construction

Barnsley's fern uses four affine transformations. The formula for one transformation is the following:

fw(x,y)=[abcd][xy]+[ef]

Barnsley shows the IFS code for his Black Spleenwort fern fractal as a matrix of values shown in a table.[3] In the table, the columns "Template:Mvar" through "Template:Mvar" are the coefficients of the equation, and "Template:Mvar" represents the probability factor.

Template:Mvar Template:Mvar Template:Mvar Template:Mvar Template:Mvar Template:Mvar Template:Mvar Template:Mvar Portion generated
Template:Math 0 0 0 0.16 0 0 0.01 Stem
Template:Math 0.85 0.04 −0.04 0.85 0 1.60 0.85 Successively smaller leaflets
Template:Math 0.20 −0.26 0.23 0.22 0 1.60 0.07 Largest left-hand leaflet
Template:Math −0.15 0.28 0.26 0.24 0 0.44 0.07 Largest right-hand leaflet

These correspond to the following transformations:

f1(x,y)=[0.000.000.000.16][xy][6px]f2(x,y)=[0.850.040.040.85][xy]+[0.001.60][6px]f3(x,y)=[0.200.260.230.22][xy]+[0.001.60][6px]f4(x,y)=[0.150.280.260.24][xy]+[0.000.44]

Computer generation

Fractal fern in four states of construction. Highlighted triangles show how the half of one leaflet is transformed to half of one whole leaf or frond.

Though Barnsley's fern could in theory be plotted by hand with a pen and graph paper, the number of iterations necessary runs into the tens of thousands, which makes use of a computer practically mandatory. Many different computer models of Barnsley's fern are popular with contemporary mathematicians. As long as math is programmed correctly using Barnsley's matrix of constants, the same fern shape will be produced.

The first point drawn is at the origin (Template:Math) and then the new points are iteratively computed by randomly applying one of the following four coordinate transformations:[4][5]

Template:Math
Template:Math
Template:Math

This coordinate transformation is chosen 1% of the time and just maps any point to a point in the first line segment at the base of the stem. In the iterative generation, it acts as a reset to the base of the stem. Crucially it does not reset exactly to (0,0) which allows it to fill in the base stem which is translated and serves as a kind of "kernel" from which all other sections of the fern are generated via transformations Template:Math, Template:Math, Template:Math.

Template:Math
Template:Math
Template:Math

This transformation encodes the self-similarity relationship of the entire fern with the sub-structure which consists of the fern with the removal of the section which includes the bottom two leaves. In the matrix representation, it can be seen to be a slight clockwise rotation, scaled to be slightly smaller and translated in the positive Template:Mvar direction. In the iterative generation, this transformation is applied with probability 85% and is intuitively responsible for the generation of the main stem, and the successive vertical generation of the leaves on either side of the stem from their "original" leaves at the base.

Template:Math
Template:Math
Template:Math

This transformation encodes the self-similarity of the entire fern with the bottom left leaf. In the matrix representation, it is seen to be a near-90° counterclockwise rotation, scaled down to approximately 30% size with a translation in the positive Template:Mvar direction. In the iterative generation, it is applied with probability 7% and is intuitively responsible for the generation of the lower-left leaf.

Template:Math
Template:Math
Template:Math

Similarly, this transformation encodes the self-similarity of the entire fern with the bottom right leaf. From its determinant it is easily seen to include a reflection and can be seen as a similar transformation as Template:Math albeit with a reflection about the Template:Mvar-axis. In the iterative-generation, it is applied with probability 7% and is responsible for the generation of the bottom right leaf.

Mutant varieties

Barnsley fern mutated into a Thelypteridaceae fern.
Barnsley fern mutated into a leptosporangiate fern.

By playing with the coefficients, it is possible to create mutant fern varieties. In his paper on V-variable fractals, Barnsley calls this trait a superfractal.[2]

One experimenter has come up with a table of coefficients to produce another remarkably naturally looking fern however, resembling the Cyclosorus or Thelypteridaceae fern. These are:[6][7]

Template:Mvar Template:Mvar Template:Mvar Template:Mvar Template:Mvar Template:Mvar Template:Mvar Template:Mvar
Template:Math 0 0 0 0.25 0 −0.4 0.02
Template:Math 0.95 0.005 −0.005 0.93 −0.002 0.5 0.84
Template:Math 0.035 −0.2 0.16 0.04 −0.09 0.02 0.07
Template:Math −0.04 0.2 0.16 0.04 0.083 0.12 0.07

Pseudocode

Template:Syntaxhighlight

References

Template:Reflist

Template:Fractals Template:Digital art

  1. 1.0 1.1 Fractals Everywhere, Boston, MA: Academic Press, 1993, Template:ISBN
  2. 2.0 2.1 Michael Barnsley, et al.,Template:Cite web Template:Small
  3. Fractals Everywhere, table III.3, IFS code for a fern.
  4. Template:Cite book
  5. Template:Cite web
  6. Other fern varieties with supplied coefficients
  7. A Barnsley fern generator