The familiar proof of Fermat’s two-square theorem through Gaussian integers has a very satisfying shape. For a prime , one first finds a solution of
. This produces the Gaussian ideal
The fact that has class number one, or more concretely that it is a principal ideal domain, turns this ideal into one generated by a single Gaussian integer
. Taking norms then gives
.
Hurwitz’s proof of the four-square theorem is the same strategy in a richer ring. The Gaussian integers are replaced by a ring of integral quaternions; the binary norm is replaced by the quaternary norm
; and a commutative ideal is replaced by a left ideal. The point is not merely that quaternions provide Euler’s four-square identity. They provide an arithmetic setting in which a prime
can be forced to factor, and that factorization produces a quaternion of norm
.
The theorem we want is:
Every positive integer is a sum of four integer squares.
As with the two-square theorem, it is enough to prove the result for primes. Indeed, if and
are norms of integral quaternions, then
is also such a norm. This is the four-square identity in structural form.
Quaternions
Let be Hamilton’s quaternion algebra. Its elements are expressions
where , and where the symbols
satisfy
Multiplication is associative but not commutative. The basic involution is quaternionic conjugation:
The norm is defined by
Although multiplication in is noncommutative, the norm is multiplicative. Indeed, because
,
Here is a real number and hence commutes with every quaternion. This immediately explains Euler’s four-square identity. If
have integer coordinates, then also has integer coordinates. Therefore
is another sum of four integer squares, while multiplicativity says that
Thus the product of two sums of four squares is again a sum of four squares. The problem is therefore reduced to showing that every prime occurs as the norm of some quaternion with integer coordinates.
Hurwitz Quaternions
The most obvious integral quaternions are the Lipschitz quaternions
They are closed under multiplication, and their norm is exactly the form that we want. But this ring is slightly too sparse for a Euclidean algorithm.
Geometrically, is the usual integer lattice
inside
. Given a point of
, one can round each coordinate to a nearest integer. The resulting lattice point is at distance at most
, but equality occurs at the centres of the unit four-dimensional cubes. Thus ordinary integral quaternions come very close to being Euclidean, but fail exactly at those cube centres.
Hurwitz’s insight was to add those missing centres. Let The ring of Hurwitz quaternions is
Equivalently, its elements are precisely the quaternions whose four coordinates are either all integers or all half-integers. Thus
inside . The second collection consists exactly of the centres of the unit cubes of
. This one enlargement repairs the Euclidean algorithm.
The norm of every Hurwitz quaternion is an integer. This is obvious for integral coordinates. If the coordinates are half-integral, write where
are odd integers. Then
Each odd square is congruent to
, so the numerator is divisible by
. Hence
.
The elements of norm are the units of
. There are twenty-four of them: the eight integral units
together with the sixteen half-integral units
These extra units will eventually allow us to convert a half-integral norm representation into an ordinary representation by four integer squares.
The crucial fact about is the following nearest-point statement:
To see this, round the four coordinates of to nearest integers. The resulting integral quaternion
satisfies
. Equality could occur only if every coordinate of
lies exactly halfway between two consecutive integers. But then all four coordinates of
are half-integers, so
itself belongs to
. In that exceptional case we choose
, obtaining distance
. Thus strict inequality is always possible.
This geometric fact gives division with remainder. Let , with
. Apply the nearest-point statement to the real quaternion
. Choose
such that
Define Then
, and
By multiplicativity of the norm,
Thus
This is a left-sided Euclidean division algorithm. The order matters: the quotient occurs on the left of
. It follows that every left ideal of
is principal. Indeed, let
be a nonzero left ideal, and choose a nonzero element
of smallest norm. For any
, divide
by
:
Because is a left ideal,
, and hence
. By the minimality of
, we must have
. Therefore every
belongs to
, and so
This is the precise quaternionic analogue of class number one. Since is noncommutative, one does not speak of the ordinary ideal class group of a quadratic ring. Instead, one says that the Hurwitz order has one-sided class number one: every left ideal is principal.
The Ideal
Let be an odd prime. The first ingredient is the same elementary congruence argument that appeared in Lagrange’s descent proof. There exist integers
such that
Indeed, consider the sets and
modulo
. Each has
distinct elements, so the two sets must intersect.
Choose with
and
Now define the quaternion
Its norm is Thus
. Moreover, our size restriction on
and
gives
This quaternion is the four-dimensional analogue of the Gaussian integer . In the two-square proof one has
Here one has instead
The additional coordinate is exactly what removes the congruence obstruction. In the Gaussian setting, must be a square modulo
, which happens only for
. In the quaternionic setting,
is always a sum of two squares modulo an odd prime. Now form the left ideal
This is the direct analogue of the Gaussian ideal The ideal
lies strictly between
and
. First,
strictly contains
, because
but
. Indeed, if
for some
, then
which would force , contradicting
. Second,
is proper. Suppose instead that
. Then there are
such that
Modulo
, this becomes
Multiply on the right by
. Since
we obtain
But , by exactly the same norm argument used for
. This contradiction proves that
This is the ideal-theoretic heart of the argument. Modulo , the class of
is nonzero, but its product with
vanishes. Thus
behaves like a nonzero zero divisor modulo
. In the Gaussian proof, the congruence
shows that
and
multiply to
modulo
; here the same role is played by
and
.
Because every left ideal of is principal, there exists a Hurwitz quaternion
such that
Since
, there is some
for which
Neither factor can be a unit. If
were a unit, then
, contradicting that
is proper. If
were a unit, then
and therefore
contradicting that
properly contains
.
Taking norms gives Both factors on the right are integers greater than
. Since
is an ordinary prime, the only possibility is
Thus is the norm of a Hurwitz quaternion.
At this point, the essential factorization argument is complete. The constructed ideal has produced a generator of norm , just as a principal Gaussian ideal produces a Gaussian integer of norm
. There remains one final issue. A Hurwitz quaternion of norm
might have half-integral coordinates, whereas the four-square theorem asks for integer coordinates.
Integer Coordinates
Let satisfy
with
odd. If
already has integer coordinates, then
gives immediately
Suppose instead that
has half-integral coordinates. Then we may write
where are odd integers. Choose signs
satisfying
The quaternion
is a Hurwitz unit, so
. Direct multiplication gives
The chosen congruences imply that every coefficient on the right is divisible by . For example,
For the coefficient of
, one gets
and the other two coordinates cancel similarly.
Therefore has integer coordinates:
for some
. Since
is a unit,
Thus every odd prime is a sum of four integer squares. The prime is already represented by
Finally, every positive integer factors into primes, and the product of norms of integral quaternions is again the norm of an integral quaternion. Hence every positive integer is a sum of four squares.
For the two-square theorem, one works in , whose norm is
For a prime
, one chooses
with
forms the ideal
uses the fact that
is a principal ideal domain, obtains a generator
, and concludes that
. For the four-square theorem, one works in the Hurwitz order
, whose norm is
For every odd prime
, one chooses
with
forms the left ideal
uses the fact that
is a left principal ideal ring, obtains a generator
, and concludes that
.
So the passage from two squares to four squares is not accidental. The Gaussian integers and the Hurwitz quaternions are both normed arithmetic rings. In each case, the norm is the quadratic form one wants to study; the congruence produces a nontrivial ideal above ; and class number one turns that ideal into a single element whose norm is
.
The difference is that the quaternionic setting has enough room for every odd prime. The equation has a solution only when
, whereas
has a solution for every odd prime. The extra square is exactly what makes the four-square theorem universal.
Finally, this proof also explains the relation with Lagrange’s descent proof. In the descent proof, one explicitly reduces coordinates modulo a multiplier and finds a smaller norm representative. In the Hurwitz proof, the same minimization principle is absorbed into the Euclidean algorithm for the Hurwitz lattice. The statement that every left ideal is principal is, in this sense, a global and structural form of descent.