All four modes here are genuine algorithms, not decorative randomness:
- Flow field — a 2D Perlin gradient-noise field assigns a direction to every point in the plane; thousands of particles are pushed step by step along that direction, and their overlapping trails form the linework. Classic Perlin implementation: permutation table, fade curve
6t⁵-15t⁴+10t³, gradient dot products, bilinear interpolation.
- Voronoi mosaic — N random seed points partition the plane into cells; every pixel block is coloured by whichever seed is nearest to it (Euclidean distance), which is the literal definition of a Voronoi diagram.
- Recursive subdivision — starts from one rectangle and recursively splits it in half (alternating horizontal/vertical) with a probability that decays by depth, exactly like Piet Mondrian's compositional method and the k-d tree/BSP algorithm used in computational geometry.
- Spirograph — traces the true hypotrochoid curve of a small circle of radius
r rolling inside a fixed circle of radius R with a pen offset d: x=(R-r)cos t + d·cos((R-r)/r·t), y=(R-r)sin t − d·sin((R-r)/r·t).