Image89

Sierpiński triangle

The Sierpiński triangle

Take a filled equilateral triangle, join the midpoints of its sides and remove the interior of the middle triangle. Three smaller triangles remain, each half as wide. Do the same with each of them, and again, forever. After n steps there are

Nn=3n triangles, with the area An= (34)n A0 →0

The area left in the end is zero, but the shape is not empty: the sides of all the triangles remain. Doubling it gives three copies of itself, so its fractal dimension lies between a line and a surface:

D= log⁡3log⁡2 ≈1.585

History

The Polish mathematician Wacław Sierpiński described the triangle in 1915 as a curve in which every point is a branching point. A year later he described a square version, now called the Sierpiński carpet. The pattern itself is much older. The Cosmati family of stone workers laid it into the floors of Italian churches in the 12th and 13th centuries, for example in the cathedral of Anagni.

Interesting facts

How Image89 draws it

Image89 builds the exact triangles and fills them with dark blue on white; the gaps are the background. The preset depth is 7, which gives 37 = 2187 triangles. Details smaller than a few pixels would only blur, so the depth drops for small images until the smallest triangles are at least 4 pixels wide:

d=min⁡(7, ⌊log2⁡(s/4)⌋)

where s is the side of the triangle in pixels; a 32×32 image shows depth 2. The triangle is fitted into the image without distortion, with a margin of 5% of the shorter side. The preset is in the [types.sierpinski] section of the config.

Examples