top of page

Freaky Fractals

Strange attractors, or as I like to call them, freaky fractals, are fractal patterns which show up in chaotic systems in mathematics. They are fractal pictures, often very beautiful, which show up in unexpected places such as chaotic systems or in randomness.


The first, and most popular, example of this is the chaos game. The chaos game is a simple game where a point (known as the tracepoint) is plotted inside of three corners making up a triangle. A dice is randomly rolled, and depending on its output, a new tracepoint is plotted midway between the current tracepoint and a corner of the triangle. After repeating this a large number of times, what do you think is most likely to occur?



Interestingly, and almost spookily, a familiar, yet completely unexpected, shape emerges: the Sierpinski Triangle.





Despite the complete randomness of the dice roll, a very non-random shape emerges from the hundreds of tracepoints plotted. Not only this, but this procedure works for any number of corners, producing similar fractal shapes. The code for this animation has not been specially written to produce this shape - it appeared entirely of its own accord. So how did this happen? Where does it come from?


When the distance between the tracepoint and a corner is halved, the tracepoint falls inside of a smaller iteration of a Sierpinski triangle. A Sierpinski triangle has been overlayed in the animation below to show more clearly how this works. Eventually, the size of the dot becomes bigger than the size of the triangle iteration in which it lands. This means that, after many iterations and with a small enough dot size, the dot appears to plot the point of an entire smaller iteration of a Sierpinski triangle. Since this is done over hundreds of randomly selected points, eventually it covers the entire fractal structure, albeit with a rather low resolution.




A common trope in popular culture which originates from chaos theory is that of the butterfly effect - that a butterfly flapping its wings in the Amazon can cause a tornado in Texas. This encapsulates the idea of chaos theory - that a small change in initial conditions, such as a butterfly flapping its wings, can create completely different behaviour in the long run. A non-chaotic system could be the differential equations describing the motion of a spring, which was covered in a previous post. Changing the initial parameters of the amplitude of the spring or its extension do change the output, but not in any drastic way, and it can almost always be predicted and calculated.


With chaotic systems, however, even changes as small as 0.00001 can cause vastly different behaviour within the span of 30-40 seconds. These systems are completely deterministic - knowing the exact initial values will always allow us to predict future states of the system. However, even slight inaccuracies will cause completely incorrect predictions over a short period of time. One such system of equations is the Lorenz System - it describes the velocities of fluid particles which are heated uniformly from the bottom and cooled from the top. These have been subject to no fewer than a hundred separate studies, and it is close to impossible to represent them analytically. However, using numerical methods and approximations, we have been able to represent their behaviour.


We do this using phase space, an idea which 3blue1brown goes into in great depth on his first video about differential equations. We represent the x, y, and z coordinates of the air particle using the coordinate system, and use the derivatives to find the velocities which we then use to plot their new positions. An example of a frictionless pendulum's phase space can be seen below, as an example. One important thing to be gleaned from this is that the lines in the phase space of different initial conditions which aren't on the same phase space curve never cross. This intuitively makes sense; particles having different initial conditions have different energies, so it is impossible for something with more or less energy to spontaneously gain or lose some in a frictionless environment to land on a different phase space.




Now, we can use the same idea of phase space to plot the x, y, and z coordinates of three air particles which differ in distance by 0.001 and are subject to the Lorenz System. What pattern do they produce?






Although the paths which the particles take completely diverges over a very short period of time, they seem to travel across two major spirals, which (aside from creating a beautiful picture) also tells us that despite the extreme sensitivity to random conditions, they all seem to follow a general pattern consisting of a double swirl - two stable attractors. Not only is this a beautiful example of order out of chaos, it is also a fractal. As stated before, since the particles cannot have the same energy due to different starting velocities and positions, the lines which they trace cannot intersect and follow the same path, as this would imply them having the same speed and position and therefore energy. The only way for this to be true for the infinite number of possible starting positions is for the attractor to be a fractal, as this allows it to be self-repeating to an infinite number of smaller and smaller pieces, allowing an infinite number of starting states to occupy these spaces.


Another strange attractor is the Chua attractor. This attractor rose independently, from a chaotic circuit known as the Chua circuit. This circuit is governed by a different set of equations. The ones used in the animation below are not exactly the same, but work to a similar effect. The Chua circuit uses Chua's diode, which is a nonlinear, negative resistance diode. This means the sum of two signals passed through the resistor does not equal the sum of the signals passed through the resistor individually and increasing the voltage across the diode actually decreases the current through it. These two properties are what allows Chua's circuit to oscillate chaotically, and produce an even more beautiful strange attractor:


Incredibly, and almost poetically, an obsession with the butterfly effect allowed us to use the power of chaotic electrical circuits to produce a strange attractor which resembles both the wings of a butterfly and the swirling of a tornado.



Comments


Post: Blog2_Post
bottom of page