Square Routes Re-Revisited

This is a very simple fractal:


It has four orientations:


Any orientation can be turned into any other by a rotation of 90°, 180° or 270°, either clockwise or anticlockwise. If you mix orientations and rotations, you can create much more complex fractals. Here’s a selection of them:

Animated fractal

Static fractal


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Animated fractal

Static


Elsewhere other-posted:

Square Routes
Square Routes Revisited

Square on a Three String

222 A.D. was the year in which the Emperor Heliogabalus was assassinated by his own soldiers. Exactly 1666 years later, the Anglo-Dutch classicist Sir Lawrence Alma-Tadema exhibited his painting The Roses of Heliogabalus (1888). I suggested in “Roses Are Golden” that Alma-Tadema must have chosen the year as deliberately as he chose the dimensions of his canvas, which, at 52″ x 84 1/8“, is an excellent approximation to the golden ratio.

But did Alma-Tadema know that lines at 0º and 222º divide a circle in the golden ratio? He could easily have done, just as he could easily have known that 222 precedes the 48th prime, 223. But it is highly unlikely that he knew that 223 yields a magic square whose columns, rows and diagonals all sum to 222. To create the square, simply list the 222 multiples of the reciprocal 1/223 in base 3, or ternary. The digits of the reciprocal repeat after exactly 222 digits and its multiples begin and end like this:

001/223 = 0.00001002102101021212111012022211122022... in base 3
002/223 = 0.00002011211202120201222101122200021121...
003/223 = 0.00010021021010212121110120222111220221...
004/223 = 0.00011100200112011110221210022100120020...
005/223 = 0.00012110002220110100102222122012012120...

[...]

218/223 = 0.22210112220002112122120000100210210102... in base 3
219/223 = 0.22211122022110211112001012200122102202...
220/223 = 0.22212201201212010101112102000111002001...
221/223 = 0.22220211011020102021000121100022201101...
222/223 = 0.22221220120121201010111210200011100200...

Each column, row and diagonal of ternary digits sums to 222. Here is the full n/223 square represented with 0s in grey, 1s in white and 2s in red:

(Click for larger)


It isn’t difficult to see that the white squares are mirror-symmetrical on a horizontal axis. Here is the symmetrical pattern rotated by 90º:

(Click for larger)


But why should the 1s be symmetrical? This isn’t something special to 1/223, because it happens with prime reciprocals like 1/7 too:

1/7 = 0.010212... in base 3
2/7 = 0.021201...
3/7 = 0.102120...
4/7 = 0.120102...
5/7 = 0.201021...
6/7 = 0.212010...

And you can notice something else: 0s mirror 2s and 2s mirror 0s. A related pattern appears in base 10:

1/7 = 0.142857...
2/7 = 0.285714...
3/7 = 0.428571...
4/7 = 0.571428...
5/7 = 0.714285...
6/7 = 0.857142...

The digit 1 in the decimal digits of n/7 corresponds to the digit 8 in the decimal digits of (7-n)/7; 4 corresponds to 5; 2 corresponds to 7; 8 corresponds to 1; 5 corresponds to 4; and 7 corresponds to 2. In short, if you’re given the digits d1 of n/7, you know the digits d2 of (n-7)/7 by the rule d2 = 9-d1.

Why does that happen? Examine these sums:

 1/7 = 0.142857142857142857142857142857142857142857...
+6/7 = 0.857142857142857142857142857142857142857142...
 7/7 = 0.999999999999999999999999999999999999999999... = 1.0

 2/7 = 0.285714285714285714285714285714285714285714...
+5/7 = 0.714285714285714285714285714285714285714285...
 7/7 = 0.999999999999999999999999999999999999999999... = 1.0

 3/7 = 0.428571428571428571428571428571428571428571...
+4/7 = 0.571428571428571428571428571428571428571428...
 7/7 = 0.999999999999999999999999999999999999999999... = 1.0

And here are the same sums in ternary (where the first seven integers are 1, 2, 10, 11, 12, 20, 21):

  1/21 = 0.010212010212010212010212010212010212010212...
+20/21 = 0.212010212010212010212010212010212010212010...
 21/21 = 0.222222222222222222222222222222222222222222... = 1.0

  2/21 = 0.021201021201021201021201021201021201021201...
+12/21 = 0.201021201021201021201021201021201021201021...
 21/21 = 0.222222222222222222222222222222222222222222... = 1.0

 10/21 = 0.102120102120102120102120102120102120102120...
+11/21 = 0.120102120102120102120102120102120102120102...
 21/21 = 0.222222222222222222222222222222222222222222... = 1.0

Accordingly, in base b with the prime p, the digits d1 of n/p correspond to the digits (p-n)/p by the rule d2 = (b-1)-d1. This explains why the 1s mirror themselves in ternary: 1 = 2-1 = (3-1)-1. In base 5, the 2s mirror themselves by the rule 2 = 4-2 = (5-1) – 2. In all odd bases, some digit will mirror itself; in all even bases, no digit will. The mirror-digit will be equal to (b-1)/2, which is always an integer when b is odd, but never an integer when b is even.

Here are some more examples of the symmetrical patterns found in odd bases:

Patterns of 1s in 1/19 in base 3


Patterns of 6s in 1/19 in base 13


Patterns of 7s in 1/19 in base 15


Elsewhere other-posted:

Roses Are Golden — more on The Roses of Heliogabalus (1888)
Three Is The Key — more on the 1/223 square

Living Culler

When you replace a square with four smaller squares, each a quarter the size of the original, the smaller squares occupy the same area, because 4 * ¼ = 1. If you discard one sub-square, then divide each of the three remaining sub-squares into four sub-sub-square, discard one sub-sub-quare and repeat, you create fractals like those I looked at in Squaring and Paring. The fractals stay within a fixed boundary.

Square replaced with four smaller squares, each ¼th the size of the original


Animated fractal


Static fractal


This time I want to look at a slightly different process. Replace a square with nine smaller squares each a quarter the size of the original. Now the sub-squares occupy a larger area than the original, because 9 * ¼ = 2¼. If you discard — or cull — sub-squares and repeat, the resultant fractal grows beyond the original boundary. Indeed, sub-squares start to overlap, so you can use colours to represent how often a particular pixel has been covered with a square. Here is an example of this process in action:

Square replaced with nine smaller squares, each ¼th the size of the original


Animated fractal


Static fractal #1


Static fractal #2


Here are the individual stages of a more complex fractal that uses the second process:

Stage 1


Stage 2


Stage 3


Stage 4


Stage 5


Stage 6


Stage 7


Stage 8


Stage 9 (compare Fingering the Frigit and Performativizing the Polygonic)


Stage 10


Animated version


Static version #1


Static version #2


And here are some more of the fractals you can create in a similar way:


Static version #1

Static version #2


Static version #2

Static version #2

Static version #3





Various fractals in an animated gif


Squaring and Paring

Squares are often thought to be the most boring of all shapes. Yet every square holds a stunning secret – something that in legend prompted a mathematical cult to murder a traitor. If each side of a square is one unit long, how long is the square’s diagonal, that is, the line from one corner to the opposite corner?

By Pythagoras’ theorem, the answer is this:

• x^2 = 1^2 + 1^2
• x^2 = 2
• x = √2

But what is √2? Pythagoras and his followers thought that all numbers could be represented as either whole numbers or ratios of whole numbers. To their dismay, so it’s said, they discovered that they were wrong. √2 is an irrational number – it can’t be represented as a ratio. In modern notation, it’s an infinitely decimal that never repeats:

• √2 = 1·414213562373095048801688724209698…

A modern story, unattested in ancient records, says that the irrationality of √2 was a closely guarded secret in the Pythagorean cult. When Hippasus of Metapontum betrayed the secret, he was drowned at sea by enraged fellow cultists. Apocryphal or not, the story shows that squares aren’t so boring after all.

Nor are they boring when they’re caught in the fract. Divide one square into nine smaller copies of itself:


Discard three of the copies like this:

Stage 1
Retain squares 1, 2, 4, 6, 8, 9 (reading left-to-right, bottom-to-top)


Then do the same to each of the sub-squares:

Stage 1


And repeat:

Stage 3


Stage 4


Stage 5


Stage 6


The result is a fractal of endlessly subdividing contingent hexagons:

Animated vesion


Retain squares 1, 2, 4, 6, 8, 9 (reading left-to-right, bottom-to-top)


Here are a few more of the fractals you can create by squaring and paring:

Retain squares 1, 3, 5, 7, 9 (reading left-to-right, bottom-to-top)


Retain squares 2, 4, 5, 6, 8


Retain squares 1, 2, 4, 5, 6, 8, 9


Retain squares 1, 4, 6, 7, 10, 11, 13, 16


Retain squares 1, 3, 6, 7, 8, 9, 10, 11, 14, 16


Retain squares 2, 3, 5, 6, 8, 9, 11, 12, 14, 15


Retain squares 1, 3, 5, 7, 9, 11, 15, 17, 19, 21, 23, 25


Retain squares 1, 3, 7, 8, 11, 12, 14, 15, 18, 19, 23, 25


Retain squares 1, 5, 7, 8, 9, 12, 14, 17, 18, 19, 21, 25


Retain squares 2, 3, 4, 6, 7, 9, 10, 11, 15, 16, 17, 19, 20, 22, 23, 24


Retain squares 1, 2, 5, 6, 7, 9, 13, 17, 19, 20, 21, 24, 25


Previously pre-posted (please peruse):

M.i.P. Trip

Pedal to the Medal

“Once, in a contest with a rival, he painted a blue curve on a huge sheet of paper. Then he dipped the feet of a chicken in red paint and persuaded the bird to walk all over the paper. The resulting image, he said, represented the Tatsuta river with red maple leaves floating in it. The judge gave him the prize.” — The Japanese artist Katsushika Hokusai (c. 1760-1849) described in Thomas W. Hodgkinson’s and Hubert van den Bergh’s How to Sound Cultured (2015)

He Say, He Sigh, He Sow #44

H. Rider Haggard describes fractals:

Out of the vast main aisle there opened here and there smaller caves, exactly, Sir Henry said, as chapels open out of great cathedrals. Some were large, but one or two — and this is a wonderful instance of how nature carries out her handiwork by the same unvarying laws, utterly irrespective of size — were tiny. One little nook, for instance, was no larger than an unusually big doll’s house, and yet it might have been a model for the whole place, for the water dropped, tiny icicles hung, and spar columns were forming in just the same way. — King Solomon’s Mines, 1885, ch. XVI, “The Place of Death”

Phrallic Frolics

It’s a classic of low literature:

There was a young man of Devizes
Whose balls were of different sizes:
     The one was so small
     ’Twas no use at all;
But t’other won several prizes.

But what if he had been a young man with balls of different colours? This is a core question I want to interrogate issues around in terms of the narrative trajectory of this blog-post. Siriusly. But it’s not the keyliest core question. More corely keyly still, I want to ask what a fractal phallus might look like. Or a phrallus, for short. The narrative trajectory initializes with this fractal, which is known as a pentaflake (so-named from its resemblance to a snowflake):

Pentaflake — a pentagon-based fractal


It’s created by repeatedly replacing pentagons with six smaller pentagons, like this:

Pentaflake stage 0


Pentaflake stage 1


Pentaflake stage 2


Pentaflake stage 3


Pentaflake stage 3


Pentaflake stage 4


Pentaflake (animated)


Pentaflake (static)


This is another version of the pentaflake, missing the central pentagon of the six used in the standard pentaflake:

No-Center Pentaflake stage 0


No-Center Pentaflake stage 1


Stage 2


Stage 3


Stage 4


No-Center Pentaflake (animated)


No-Center Pentaflake (static #1)


No-Center Pentaflake (static #2)


The phrallus, or fractal phallus, begins with an incomplete version of the first stage of the pentaflake (note balls of different colours):

Phrallus stage 1


Phrallus stage 1 (monochrome)


Phrallus stage 2


Phrallus stage 3


Stage 4


Stage 5


Stage 6


Stage 7


Stage 8


And there you have it: a fractal phallus, or phrallus. Here is an animated version:

Phrallus (animated)


Phrallus (static)


But the narrative trajectory is not over. The center of the phrallus can be rotated to yield mutant phralloi. Stage #1 of the mutants looks like this:

Phrallus (mutation #1)


Phrallus (mutation #2)


Phrallus (mutation #3)


Phrallus (mutation #4)


Phrallus (mutation #5)


Mutant phralloi (rotating)


Here are some animations of the mutant phralloi:

Phrallus (mutation #3) (animated)


Phrallus (mutation #5) (animated)


This mutation doesn’t position the pentagons in the usual way:

Phrallus (another upright version) (animated)


The static mutant phralloi look like this:

Phrallus (mutation #2)


Phrallus (mutation #3)


Phrallus (upright #2)


And if the mutant phralloi are combined in a single image, they rotate like this:

Mutant phralloi (rotating)


Coloured mutant rotating phralloi #1


Coloured mutant rotating phralloi #2


Square Routes Revisited

Take a square, divide it into four smaller squares, and discard the smaller square on the top right. Do the same to each of the subsquares, dividing it into four sub-subsquares, then discarding the one on the top right. And repeat with the sub-subsquares. And the sub-sub-squares. And the sub-sub-sub-squares. And so on. The result is a fractal like this:

sq2x2_123_1

Stage 1


sq2x2_123_2

Stage 2


sq2x2_123_3

Stage 3


sq2x2_123_4

Stage 4


sq2x2_123

Animated fractal


sq2x2_123_static

Final fractal (static)


It looks as though this procedure isn’t very fertile. But you can enrich it by rotating each of the subsquares in a different way, so that the discarded sub-subsquare is different. Here’s an example:

Stage 1


Stage 2


Stage 3


Stage 4


Stage 5


Stage 6


Stage 7


Animated fractal


Final fractal (static)


Here are more examples of how rotating the subsquares in different ways produces different fractals:

Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Animated fractal

Static fractal


Previously pre-posted:

Square Routes — first look at this kind of fractal

He Say, He Sigh, He Sow #43

Me dijo que su libro se llamaba el Libro de Arena, porque ni el libro ni la arena tienen ni principio ni fin. — Jorge Luis Borges, “El Libro de Arena” (1975)

   He told me that his book was called the Book of Sand, because neither book nor sand has beginning or end. — Borges, “The Book of Sand

Corralling Chaos

“Down through the aether I saw the accursed earth turning, ever turning, with angry and tempestuous seas gnawing at wild desolate shores and dashing foam against the tottering towers of deserted cities.” — “The Crawling Chaos” (1921), Winifred Jackson and H. P. Lovecraft.


All the best people brood incessantly on the fact that a point inside a square jumping half-way towards a randomly chosen vertex will not create a fractal. Inside a triangle, yes: a fractal appears. Inside a pentagon too. But not inside a square:

Point jumping half-way towards a randomly chosen vertex


Instead, the interior of the square fills with random points: it crawls with chaos, you might say. However, fractals appear inside a square if the point is restricted in some way: banned from jumping towards a vertex twice in a row; banned from jumping towards the second-nearest vertex; and so on. Those restrictions are what might be called soft, because they take place in software (or in the brain of someone following the rule as a game or piece of performance art). Here’s what might be called a hard restriction that creates a fractal: the point cannot jump towards a randomly vertex if its jump passes over any part of the red upright cross:

Point cannot pass over red lines


I call this a barrier fractal. It’s obvious that the point cannot jump from one corner of the square towards the opposite corner, which creates bare space stretching from each vertex towards the tips of the upright cross. Less obvious is the way in which this bare space “cascades” into other parts of the square, creating a repeatedly branching and shrinking pattern.



When the barrier is a circle, a similar fractal appears:


If the point can also jump towards the center of the circle, this is what happens:


Now here’s an upright cross with a gap in the middle:


Here’s an upright cross when the point can also jump towards the center of the cross:


A slanted cross with a central attractor:


And a single horizontal stroke:


A slanted stroke — note pentagons:


Even if the barrier is small and set on an edge of the square, it affects the rest of the square:


A more attractive example of edge-affects-whole:


Circles away from the edges


Detail of previous image






Here the point can also jump towards the center of the square’s edges:


A more subtle barrier fractal uses the previous jumps of the point to restrict its next jump. For example, if the point cannot jump across the line created by its previous-but-one jump, it moves like this:

Jump can’t cross track of last-but-one jump (animated gif)


The fractal itself looks like this:


Rule: on jump #3, cannot jump across the line created by jump #1; on jump #4, cannot cross the line created by jump #2; and so on.



And this is the fractal if the point cannot jump across the line created by its previous-but-two jump:

Rule: on jump #4, cannot jump across the line created by jump #2; on jump #5, cannot cross the line created by jump #3; and so on