You can edit almost every page by Creating an account and confirming your email.

Ana's fractal

From EverybodyWiki Bios & Wiki


Ana's fractal. The center of the region: z = 0.129 − 122.569i

Ana's fractal is a fractal in the complex plane, which is obtained by applying the operation discussed below to complex variables, and by representing the results as colors.

This fractal is obtained by taking a point z in the complex plane, applying hyperbolic tangent to it, then multiplying the result by z, applying hyperbolic tangent again and repeating these instructions again and again. After some time the results behave much like repeating decimals, meaning that they repeat themselves after every n iterations. After this point z is painted with color number n (one can number colors arbitrarily).

Definition

Let us define a sequence for each point z inside the complex plane: f0(z)=1 and fn+1(z)=tanh(zfn(z)). For large values of n, fn(z) will be either chaotic (with respect to n), or it will tend to some limit or limits. By the sequence tending to several limits we mean that for large values of n, fn takes only several specific values, and repeats those values in the same order forever. The sets of these values are called attractors.

We can say that the point z, for which fn(z) is chaotic (with respect to n), has an infinitely long attractor. Thus, every complex point z has an attractor, with some length.

Let us now define sets, labeled from 1 to infinity. Each set contains all the points whose attractors have the same length as the label of this set. The set of these sets is called Ana's fractal.

If we paint each point of a complex plane, according to the length of its attractor (i.e. paint each element in Ana's fractal with a separate color), we will obtain the images shown here.

Fractal images and animations

Images and animations were generated using C++ code.

საზღვარი
Region borders:

min = -2.1457 - 46.8507 i

max = -2.1433 - 46.8483 i

Region borders:

min = 2.812-154.592 i

max = 2.818-154.586 i

Region borders:

min = 1.046673850 -153.902519604 i

max = 1.046673857 -153.902519597 i

საზღვარი საზღვარი

Code for Wolfram Mathematica

This code generates Ana's fractal. (Keep in mind that this code is not optimal)

   (* Definition of the function *)
   topLimit = 10^10; (* If series gets larger than topLimit, we color it with 0 *)   
   
   f[z_, 0] = z;
   f[z_, n_] := f[z, n] = z Tanh[ f[z, n - 1]] // N;
   
   (* Parameters for convergence check *)
   colorQuantity = 20; (* Maximal length of attractor *)
   iter = 200; (* Number of iterations needed to come close to attractor *)
   error = 0.01; (* Allowed error during searching for the attractor *)
   checkPairs = 10; (* Pairs to check, before claiming an attractor *)
   
   (* Image borders *)
   reMin = -2;
   reMax = 2;
   imMin = -2;
   imMax = 2;
   dotsPerUnit = 20;
   
   (* Calculation of the attractor length *)
   limits[zIn_] := Module[{tbl},
      (* Save colorQuantity+checkPairs terms in tbl *)
      tbl = Table[f[zIn, n], {n, iter, iter + colorQuantity + checkPairs}];
      (* Check if f is finite *)
      If[AnyTrue[Abs[tbl], # > topLimit &],
       Return[0]; (* Paint as 0 if not *)
       ];
      
      (* Vary the length of attractor *)
      For[i = 1, i < colorQuantity, i++,
       (* Check if the attractor length is correct *)
       If[AllTrue[Table[Abs[tblj - tblj + i], {j, 1, checkPairs}], # <= error & ],
         Return[i];
         ];
       ];
      Return[0]; (* attractor is longer than colorQuantity. Paint it as 0 *)
      ];
   
   (* Plot the image *)
   ArrayPlot[Table[limits[x + I y], {y, imMin, imMax, 1/dotsPerUnit}, {x, reMin, reMax, 1/dotsPerUnit}]]

References


This article "Ana's fractal" is from Wikipedia. The list of its authors can be seen in its historical. Articles copied from Draft Namespace on Wikipedia could be seen on the Draft Namespace of Wikipedia and not main one.