On a Monday in October 1843, an Irish mathematician stopped on a Dublin bridge and, by his own account, scratched a formula into the stone with a pocket knife.
A problem that had blocked him for years
William Rowan Hamilton knew that complex numbers can be read as points on a flat plane. He wanted the same trick for points in space, which need three numbers instead of two.
Adding and subtracting those triples was easy. Multiplying and dividing them had stumped him for years.
The walk along the Royal Canal
On 16 October 1843, Hamilton was walking the towpath of the Royal Canal with his wife, headed to a council meeting at the Royal Irish Academy, where he was due to preside. Somewhere along the way, the answer arrived.
The fix was to stop using three numbers and use four. He called the new objects quaternions, and their rules fit in one line: i squared, j squared and k squared all equal minus one, and so does i times j times k.
He could not resist. According to his own telling, he carved that line into the stone of what he called Brougham Bridge.
The letter that explains the spark
The next day he wrote to his friend John T. Graves. He admitted that, to calculate with triples, we must accept a fourth dimension of space.
His description of the moment became famous: “An electric circuit seemed to close, and a spark flashed forth.”
The price of the idea
Quaternions broke a rule that mathematicians treated as sacred. Multiplication order mattered. Swap the two numbers and the answer changes, something that never happens with ordinary numbers or with complex numbers.
Hamilton spent the rest of his life on them. He founded a school of “quaternionists” and wrote his last and longest book, Elements of Quaternions, in the final six years of his life. His son published it in 1866, after Hamilton died in 1865 at the age of 60.
The idea had company. Olinde Rodrigues had described rotations with four parameters in 1840. Gauss had found quaternions in 1819 but his work was not published until 1900. In 1877, Ferdinand Frobenius proved that a three-dimensional version, the thing Hamilton first sought, cannot exist.
Dublin made them an exam topic
After his death, the Scottish physicist Peter Tait championed the cause. Quaternions became a mandatory exam subject in Dublin, and Maxwell’s equations were written in them. There was even a professional Quaternion Association.
Then came a rival. From the mid-1880s, the vector analysis of Gibbs, Heaviside and Helmholtz did the same job with simpler notation, and quaternions faded. Vector analysis borrowed a lot from them, including Hamilton’s dot and cross products.
The comeback nobody planned
Since the late 20th century, quaternions have been winning back ground, because they describe spatial rotations beautifully. They are more compact and quicker to compute than rotation matrices, and they avoid a glitch called gimbal lock that affects the older method of Euler angles.
That is why they now sit inside computer graphics, robotics, computer vision and MRI imaging. The attitude control systems of spacecraft are commonly commanded in quaternions.
Where the bridge stands today
The carving is gone, and no trace of it remains. A stone plaque unveiled in 1958 by Taoiseach Éamon de Valera marks the spot instead, now mounted higher under the railing after vandals and visitors damaged it.
Every year since 1989, mathematicians walk from Dunsink Observatory, where Hamilton lived, to the bridge. Past walkers include Andrew Wiles, Roger Penrose and Ingrid Daubechies. Some call 16 October “Broomsday”, a wink at Bloomsday on 16 June.
A formula scratched into a bridge faded in stone but survived in the code that points a spacecraft. It is a fair reminder that an idea judged too strange can simply be waiting for the right machine to need it.

