In mathematics, a Hurwitz quaternion (or Hurwitz integer) is a quaternion whose components are either all integers or all half-integers (halves of an odd integer; a mixture of integers and half-integers is excluded). The set of all Hurwitz quaternions is
That is, either a, b, c, d are all integers, or they are all half-integers. H is closed under quaternion multiplication and addition, which makes it a subring of the ring of all quaternions H. Hurwitz quaternions were introduced by Adolf Hurwitz (1919).
A Lipschitz quaternion (or Lipschitz integer) is a quaternion whose components are all integers. The set of all Lipschitz quaternions
forms a subring of the Hurwitz quaternions H. Hurwitz integers have the advantage over Lipschitz integers that it is possible to perform Euclidean division on them, obtaining a small remainder.
The Hurwitz quaternions form an order (in the sense of ring theory) in the division ring of quaternions with rational components. It is in fact a maximal order; this accounts for its importance. The Lipschitz quaternions, which are the more obvious candidate for the idea of an integral quaternion, also form an order. However, this latter order is not a maximal one, and therefore (as it turns out) less suitable for developing a theory of left ideals comparable to that of algebraic number theory. What Adolf Hurwitz realised, therefore, was that this definition of Hurwitz integral quaternion is the better one to operate with. For a non-commutative ring such as H, maximal orders need not be unique, so one needs to fix a maximal order, in carrying over the concept of an algebraic integer.
The (arithmetic, or field) norm of a Hurwitz quaternion a + bi + cj + dk, given by a2 + b2 + c2 + d2, is always an integer. By a theorem of Lagrange every nonnegative integer can be written as a sum of at most four squares. Thus, every nonnegative integer is the norm of some Lipschitz (or Hurwitz) quaternion. More precisely, the number c(n) of Hurwitz quaternions of given positive norm n is 24 times the sum of the odd divisors of n. The generating function of the numbers c(n) is given by the level 2 weight 2 modular form
is the weight 2 level 1 Eisenstein series (which is a quasimodular form) and σ1(n) is the sum of the divisors of n.
A Hurwitz integer is called irreducible if it is not 0 or a unit and is not a product of non-units. A Hurwitz integer is irreducible if and only if its norm is a prime number. The irreducible quaternions are sometimes called prime quaternions, but this can be misleading as they are not primes in the usual sense of commutative algebra: it is possible for an irreducible quaternion to divide a product ab without dividing either a or b. Every Hurwitz quaternion can be factored as a product of irreducible quaternions. This factorization is not in general unique, even up to units and order, because a positive odd prime p can be written in 24(p+1) ways as a product of two irreducible Hurwitz quaternions of norm p, and for large p these cannot all be equivalent under left and right multiplication by units as there are only 24 units. However, if one excludes this case then there is a version of unique factorization. More precisely, every Hurwitz quaternion can be written uniquely as the product of a positive integer and a primitive quaternion (a Hurwitz quaternion not divisible by any integer greater than 1). The factorization of a primitive quaternion into irreducibles is unique up to order and units in the following sense: if
are two factorizations of some primitive Hurwitz quaternion into irreducible quaternions where pk has the same norm as qk for all k, then
The ordinary real integers and the Gaussian integers allow a division with remainder or Euclidean division. For positive integers N and D, there is always a quotient Q and a nonnegative remainder R such that
For complex or Gaussian integers N = a + ib and D = c + id, with the norm N(D) > 0, there always exist Q = p + iq and R = r + is such that
However, for Lipschitz integers N = (a, b, c, d) and D = (e, f, g, h) it can happen that N(R) = N(D). This motivated a switch to Hurwitz integers, for which the condition N(R) < N(D) is guaranteed.
Many algorithms depend on division with remainder, for example, Euclid's algorithm for the greatest common divisor.