The Story
On October 16, 1843, the Irish mathematician William Rowan Hamilton was walking along the Royal Canal in Dublin with his wife when an equation hit him so hard he carved it into the stone of Brougham Bridge with a knife. The equation: i² = j² = k² = ijk = -1. He'd just invented the quaternions, a number system with four dimensions instead of two. The original carving is long gone, but a plaque marks the spot, and mathematicians retrace his walk every year on the anniversary.
What Hamilton figured out that day was that you could extend complex numbers (which have one real and one imaginary part) into four dimensions by adding two more imaginary axes. The cost: multiplication stops being commutative. i × j = k, but j × i = -k. Order matters.
A regular Julia set takes 2D complex numbers and iterates z → z² + c. Quaternion Julia sets do the same thing, but with these 4D numbers instead.
The Problem With Four Dimensions
You can't see a 4D object. So what you're actually looking at when you see a "quaternion Julia set" is a 3D slice through a 4D shape. Think of it like this: if you had a 3D sculpture and could only see 2D cross-sections of it (like an MRI scan), each slice would show a different contour. Same idea here, but one dimension up.
Change which 3D hyperplane you slice along, and the same fractal looks completely different. A bulging, organic mass at one slice angle becomes a spiky lattice at another. The object hasn't changed. Your cut through it has.
This is genuinely strange. Every frame you see is a shadow of something you can never see whole.
What They Look Like
Quaternion Julia sets tend to produce rounded, blobby shapes with fractal surface detail. At certain c values they look like bones or coral. At others, like crumpled fabric or sea creatures. The non-commutative multiplication gives them a handedness that regular Julia sets lack, so you get spiral structures that twist preferentially left or right depending on the parameters.
Tweak the four components of c by small amounts and the shape can shift from a smooth connected blob to a shattered dust of disconnected fragments. Just like the 2D Julia set, the boundary between connected and disconnected is where things get wild.
Exploring It
Circles the fractal so you can see the full 3D shape of the current slice.
Flies the camera through the geometry. Good for seeing how the surface folds inward.
Sweeps through different c values, so the 4D shape itself deforms in real time. This is the one that really shows what's going on in parameter space.
Pushes into the fractal surface to find self-similar detail at smaller scales.
Full manual control. WASD to move, QE for up/down, mouse or touch to rotate.
Why Quaternions Matter Outside Fractals
Hamilton's quaternions spent decades as a mathematical curiosity. Then 3D computer graphics happened. It turns out quaternions are the cleanest way to represent rotations in three-dimensional space. They avoid gimbal lock (the nasty singularity that Euler angles hit), they interpolate smoothly, and they compose efficiently. Every modern game engine, every robot arm controller, every spacecraft attitude system uses them.
So the same algebraic structure that produces these fractals also keeps your phone's screen orientation working and stops fighter jets from tumbling. Hamilton would have been pleased.
Tips
Start with c values near the origin, something like (0.3, 0.3, 0.1, 0.0). Connected shapes live close to zero. Push the values past about 0.5 in any component and the set usually shatters into dust.
The C Parameter Morphing animation is the best way to build intuition for how the 4D parameter space works. Watch how the shape inflates, pinches, and breaks apart as c moves. It's the closest thing to "seeing" the fourth dimension.
Use the orbital view to understand the full 3D structure before zooming in. These aren't flat. The surface folds and pockets only become visible when you rotate around them.
Further Reading
- Paul Bourke - Quaternion Julia Fractals - thorough mathematical treatment with images of different c values
- Keenan Crane - Ray Tracing Quaternion Julia Sets on the GPU - the paper behind modern real-time rendering of these fractals
- Wikipedia - Broom Bridge - the bridge where Hamilton carved the quaternion formula