Escher's infinity trick gets a mathematical upgrade
M.C. Escher’s 1956 print, Gallery of Prints, has always been a head-scratcher – a visual paradox that seems to defy logic. Now, thanks to a Hungarian programmer named Laszlo Korte, the mind-bending artwork has been transformed into an interactive educational tool, revealing the surprisingly elegant mathematics underpinning its illusion.

Unraveling the recursive loop
The print depicts a man observing a gallery filled with prints. As the eye follows the scene, it seems to endlessly loop, the gallery within a gallery within a gallery – an infinite regression. It’s a masterclass in the Droste effect, but rendered with Escher’s signature surrealist flair. Korte, captivated by both the print and a detailed video explanation by 3Blue1Brown, decided to translate this visual puzzle into an interactive shader for educational purposes.
What appears to be magic is, in fact, a clever manipulation of coordinates. The trick lies in transforming a seemingly chaotic image into a continuous spiral by breaking down the separation between copies. Instead of simply repeating the image, Korte’s interactive tool allows users to zoom in and out, revealing the mathematical underpinnings: polar coordinates, complex logarithms, exponentials, and conformal transformations – mathematical tools that preserve the local shape of small squares as the image transforms.
The secret? A shift from Cartesian coordinates to a logarithmic space. This seemingly simple change reframes the zooming process, turning it into a straightforward lateral shift. The periodic angularity, which appears as a vertical repetition of 2π in Cartesian coordinates, becomes strikingly clear. What was once a complicated calculation becomes elegantly streamlined: logarithm, rotation, scaling, and exponential transformation. Escher’s print isn’t just a visual marvel; it’s a surprisingly neat solution to a puzzle that appeared, at first glance, to be unsolvable.
The original print features a self-similarity reduction of 256 times, while a simpler version employed only 16 levels of self-similarity, a 16-fold reduction. Korte's interactive tool unlocks a deeper understanding of the spatial relationships at play, demonstrating how Escher intuitively grasped concepts that modern mathematicians now articulate with precision.
Ultimately, Korte’s work doesn't just recreate Escher's effect; it illuminates the ingenious mathematical framework that makes it possible. And it proves that even the most visually complex illusions can be rooted in a surprising simplicity.