Overview
Introduction
The pentaflake is one of the more visually striking members of the "n-flake" family of fractals, a central polygon surrounded by smaller copies of itself, built here from regular pentagons.
Unlike some of the other constructions in this category, the pentaflake is a real, well-documented fractal with a precise, golden-ratio-derived scale factor, not an invented variant.
What Is Generate a Sierpinski Pentagon?
A fractal made of a central regular pentagon with 5 more pentagons arranged around its edges, each one scaled down by 1/(1+phi), where phi is the golden ratio. The same pattern then repeats inside each of the 6 pentagons.
It belongs to the same family as the hexaflake (built from hexagons) and the classic Sierpinski triangle, all are n-flake constructions that combine a central copy with n copies arranged around it.
How Generate a Sierpinski Pentagon Works
The tool starts with one regular pentagon. At the first recursive step, it places 5 smaller pentagons around the original's edges, each scaled by 1/(1+phi), plus one more copy at the exact same scale sitting on the original's center.
That gives 6 total sub-pentagons per level, 5 arranged around the perimeter and 1 in the center, each one eligible for the same subdivision at the next level.
This repeats down to the chosen Depth, with every one of the 6^depth resulting pentagons drawn as a filled polygon.
When To Use Generate a Sierpinski Pentagon
Use it whenever you want an accurate, textbook pentaflake for math visualizations, generative art, or educational material about n-flake fractals and the golden ratio.
If you want a similarly structured fractal built on a different base polygon, see the hexagon-based Sierpinski Hexagon Generator or the octagon-based Sierpinski Polyflake Generator.
Often used alongside Generate a Sierpinski Hexagon, Generate a Sierpinski Polyflake and Generate a Sierpinski Square.
Features
Advantages
- Implements the real, mathematically precise pentaflake construction rather than an approximation.
- The golden-ratio scale factor gives the pentagons a naturally tight, non-overlapping fit at every level.
- Filled-polygon rendering makes the 5-fold symmetry easy to see even at low depth.
Limitations
- Depth is capped at 4, since the pentagon count grows by a factor of 6 per level and quickly produces a very large number of tiny shapes.
- Only the standard 1/(1+phi) scale factor is offered, there's no option to use a different packing ratio.
Examples
Best Practices & Notes
Best Practices
- Start at Depth 2 to see the 5-fold symmetry and the golden-ratio spacing clearly before increasing further.
- Use the SVG export for print or further vector editing, since the polygon points stay exact at any zoom level.
Developer Notes
Generated by the shared `nFlake(sides, scale, depth, radius, cx, cy, level, out)` helper with `sides = 5` and `scale = 1 / (1 + GOLDEN_RATIO)`, where `GOLDEN_RATIO = (1 + Math.sqrt(5)) / 2`. At each level the helper places `sides` child copies around the perimeter at `distance = radius * (1 - scale)` plus one more child copy centered on the same point, giving the standard 6-copies-per-level pentaflake recursion. Depth is bounded to 0-4 by `boundsCheck`.
Generate a Sierpinski Pentagon Use Cases
- Math and geometry visualizations demonstrating the golden ratio and n-flake fractals
- Generative art with natural 5-fold rotational symmetry
- Educational material comparing pentaflake, hexaflake, and other n-flake constructions side by side
Common Mistakes
- Expecting the scale factor to be a round number like 1/3, it's derived from the golden ratio and works out to roughly 0.382, not an even fraction.
- Pushing Depth to the maximum immediately, at depth 4 the pentagon count is large enough that individual shapes become very small on screen.
Tips
- Compare this tool with Sierpinski Hexagon Generator to see how changing the base polygon and scale factor changes the fractal's density and symmetry.
- Zoom into the exported SVG to inspect the self-similar center-plus-5 structure at each level individually.