Posts tagged: IFS

Recursive Drawing

Drawing programs don’t always have a “point”, even if they are fun. Recursive Drawing, however, aims to use a simple and addictive user-interface to explore how drawings could be translated into programming.

On the surface, it’s a purely fun tool (which you can, and should, play with!) to draw crazy-awesome things like Fibonacci trees (like in the video). But deep down, it’s an experiment in translating visual objects into programming commands. That’s called a spatial or visual programming environment, and it’s a way to disconnect the syntax of programming from the logic and math.

Environments like these also let non-English speakers and young people get introduced to programming skills without having to master the language itself. But if you don’t want to pay attention to all that, it’s just really FUN!

Previously: A dangerously addictive online fluid dynamics simulator and a particle/gravity simulator that really looks more like fireworks.

Mathematica code:

P[t_] := (1 + 0.9 Cos[8 t]) (1 + 0.1 Cos[24 t]) (0.9 + 0.05 Cos[200 t]) (1 + Sin[t])T[t_] :=  If[0 < t < 17, .01 t,   If[16 < t < 25, .2 + .1 (t - 16)/2,    If[24 < t < 35, 0 + (t - 24)/2,     If[34 < t < 45, -3 + 20*(t - 34)/2, 0]]]]ListAnimate[ Table[  Show[   PolarPlot[    Evaluate[     Table[      (T[Mod[s, 45]]*1/.85^n)*P[t],      {n, 0, 20, 1}],    {t, -Pi, Pi}],    PlotRange -> {{-7.5, 7.5}, {-4.3, 15.7}},    Background -> Black, Axes -> False, ImageSize -> 500],   PolarPlot[    Evaluate[     Table[      (T[Mod[s + 5, 45]]*1/.85^n)*P[t],      {n, 0, 20, 1}],    {t, -Pi, Pi}],   PlotRange -> {{-7.5, 7.5}, {-4.3, 15.7}},   Background -> Black]],{s, 1, 45, 2}]]
Filed under: #420  #GIF  #Mathematica  #IFS
Connecting the dots in the complex plane

This will be an attempt at describing the algorithmic procedure used to generate some of the graphics posted here.

• Start with a line segment of any length L.

• Now pick any angle A in the range 0° to 180°.

• Connect another line segment of the same length as the first at the end of the first line so that two create an angle of A between them.

• Repeat this procedure connecting additional lines of length L at the same angle A to the endpoints of the previous lines.

This shows the procedure repeated several times using an angle of about 20°.

And this shows the pattern that results some 150 lines into the procedure with the same angle of 20°:

Instead, if each additional line segment were to be made slightly smaller than the previous, say 99% of the length of the previous line, then the lines would look something like this where they begin to spiral in towards the center:

Its interesting to observe how these patterns change as the value for the angle A is varied. The closer the values for two different angles are the closer the two patterns will resemble one another. However, for each distinct angle A the resulting pattern is unique.

Here are some animations that show the angle vary through some range while keeping the number of lines in the iteration fixed. Note how relatively small the range is that the angle varies through.

With all lines the same length varying through angles of about 10.7° to 10.4° :

and with each line 99% the length of the previous with an angle variation from 20° to 16° :

This algorithm can be equivalently thought of as taking a certain ordered sequence of points in the plane and then joining them with straight lines—playing connect the dots basically. Different arrangements and sequences of points in the plane would produce different patterns when connected with lines.

Perhaps the most elegant and concise way to mathematically describe this algorithm is by making use of the complex numbers. Due to the way complex numbers multiply, this algorithm can be specified by picking a complex number z and then successively multiplying it by itself to get a sequence of points given by zn, where the resulting complex numbers zn represent the nth point in the sequence. Then the connect the dots routine is performed with this sequence of points.

For instance, the configuration for the first 100 dots corresponding to a particular choice of complex number may look something like this:

Then once all the dots are connected with lines it would look like this:

Performing this procedure with each different point in the complex plane generates a different pattern.

This kind of procedure where a certain transformation is repeated on some elements is considered an iterated function system, which is a class of fractals.

You could imagine all the different possibilities which would result from using different functions.

In fact, all of these images here were generated using similar procedures.

Download an interactive CDF file here where you can control the parameters, view the graphics, and also create numbered dot sequences.

Filed under: #CTD  #GIF  #IFS  #Mathematica  #math  #CDF

For more GIFs of dragon curve variants see here and here.

(via secxtanx)

Filed under: #dragon curve  #fractal  #math  #GIF  #L-system  #IFS

In this iterated function system, a Möbius transformation is applied in succession to the white circle yielding the blue and yellow circles. The characteristic constant of the transformation remains fixed, but the radius of the white circle is decreased in each frame of the animation.

More IFS here

GIF source: Java app

(via anniesboobs)

Source: psykzz
Filed under: #GIF  #IFS  #Sierpinksi  #fractal  #psykzz

In this iterated function system, a Möbius transformation is applied in succession to the white circle yielding the blue and yellow circles. Varying the characteristic constant of the transformation gives the different arrangements seen in each frame of the animation.

The particular dynamics shown here can be conceived by using a stereographic projection and oscillating the Riemann sphere about the point at infinity.

More IFS here

GIF source: Java app

In this iterated function system, a Möbius transformation is applied in succession to the white circle yielding the blue and yellow circles. Varying the characteristic constant of the transformation gives the different arrangements seen in each frame of the animation.

More IFS here

GIF source: Java app

In this iterated function system, a Möbius transformation is applied in succession to the white circle yielding the blue and yellow circles. Varying the characteristic constant of the transformation gives the different arrangements seen in each frame of the animation.

More IFS here

GIF source: Java app

(via drunkjew)

Filed under: #IFS  #Pythagorean tree  #fractal  #math  #2^N

Here’s an animation of the dragon curve with increasing angles I did in a similar vein to my Koch curve animation; also, the final result at 90° deserves some close looking at too, unlike in the Koch curve case where it’s just a triangle.

Filed under: #math  #fractal  #gif  #animation  #IFS  #L-system

Here’s an animation going through the various forms of the Koch curve, from the degenerate case of a line to the degenerate case of every point in the triangle.  The frame I picked is very close to the usual one with fractal dimension log(4)/log(3).

Filed under: #math  #fractal  #gif  #animation  #IFS  #L-system

A tree of Pythagoras (a fractal):

Filed under: #IFS  #fractal  #2^N
Filed under: #GIF  #fractal  #animation  #L-system  #IFS