  In this paper we introduce a new algebraic device, which enables us to treat
the quaternions as though they were a commutative field. This is of interest
both for its own sake, and because it can be applied to develop an "algebraic
geometry" of noncompact hypercomplex manifolds.
  The basic building blocks of the theory are AH modules, which should be
thought of "vector spaces" over the quaternions. An AH-module is a left module
over the quaternions H, together with a real vector subspace. There are natural
concepts of linear map and tensor product of AH-modules, which have many of the
properties of linear maps and tensor products of vector spaces. However, the
definition of tensor product of AH-modules is strange and has some unexpected
properties.
  Let M be a hypercomplex manifold. Then there is a natural class of H-valued
"q-holomorphic functions" on M, satisfying a quaternionic analogue of the
Cauchy-Riemann equations, which are analogues of holomorphic functions on
complex manifolds. The vector space of q-holomorphic functions A on M is an
AH-module.
  Now some pairs of q-holomorphic functions can be multiplied together to get
another q-holomorphic function, but other pairs cannot. So A has a kind of
partial algebra structure. It turns out that this structure can be very neatly
described using the quaternionic tensor product and AH-morphisms, and that A
has the structure of an "H-algebra", a quaternionic analogue of commutative
algebra.
