graeco-latin squares

mathematical precision meets
visual harmony through orthogonal
latin square solutions

graeco-latin squares.

graeco-latin squares transforms complex mathematical solutions into striking visual art.

This project solves mutually orthogonal latin squares (MOLS) of any dimension and depth, then renders them as concentric colored squares—creating mesmerizing patterns that blend mathematical precision with aesthetic beauty.

concept.

graeco-latin squares emerged from the intersection of classical combinatorial mathematics and digital art. The project solves mutually orthogonal latin squares—a mathematical puzzle dating back to Euler—then transforms these abstract solutions into visual compositions through color mapping and geometric manipulation.

By solving MOLS problems up to 25×25 dimensions with 25 levels of depth, the application handles mathematical complexity beyond what's typically visualized. When perfect solutions don't exist, it approximates the closest possible arrangement, ensuring aesthetic coherence is maintained.

The true innovation lies in the rendering system, which transforms these mathematical structures into concentric squares where each number corresponds to a unique color. Users can manipulate hue, saturation, lightness, adjust corner roundness for organic shapes, and even animate the patterns with customizable movement parameters.

The result is a seamless fusion where rigorous mathematical solutions become captivating visual art—allowing viewers to appreciate the hidden beauty in abstract mathematical structures through direct sensory experience.

technical details.

the visualization engine uses D3.js for data-driven document manipulation and webGL for high-performance rendering of complex mathematical patterns.


        technologies = {
                visuals: 'D3.js, webGL';
                JS: 'javascript';
                algorithm: 'mathematical solutions for MOLs';
                }

Key mathematical concepts implemented include:

  • latin square generation using finite field operations
  • euler's construction for pairs of orthogonal latin squares
  • macneish's theorem for constructing MOLS
  • connections to projective planes and error-correcting codes

gallery.

visualization of an order-4 latin square with color mapping.
each color represents a unique mathematical property.

algorithmic music generation based on latin square patterns.
mapping mathematical structures to sound parameters.

visualization of mutually orthogonal latin squares (MOLS).
euler's construction for pairs of orthogonal latin squares.

connection between latin squares and projective planes.
visualizing finite field geometry through color mapping.