  The paper aims to adopt the complex octonion to formulate the angular
momentum, torque, and force etc in the electromagnetic and gravitational
fields. Applying the octonionic representation enables one single definition of
angular momentum (or torque, force) to combine some physics contents, which
were considered to be independent of each other in the past. J. C. Maxwell used
simultaneously two methods, the vector terminology and quaternion analysis, to
depict the electromagnetic theory. It motivates the paper to introduce the
quaternion space into the field theory, describing the physical feature of
electromagnetic and gravitational fields. The spaces of two fields can be
chosen as the quaternion spaces, while the coordinate component of quaternion
space is able to be the complex number. The quaternion space of electromagnetic
field is independent of that of gravitational field. These two quaternion
spaces may compose one octonion space. Contrarily, one octonion space can be
separated into two subspaces, the quaternion space and S-quaternion space. In
the quaternion space, it is able to infer the field potential, field strength,
field source, angular momentum, torque, and force etc in the gravitational
field. In the S-quaternion space, it is capable of deducing the field
potential, field strength, field source, current continuity equation, and
electric (or magnetic) dipolar moment etc in the electromagnetic field. The
results reveal that the quaternion space is appropriate to describe the
gravitational features, including the torque, force, and mass continuity
equation etc. The S-quaternion space is proper to depict the electromagnetic
features, including the dipolar moment and current continuity equation etc. In
case the field strength is weak enough, the force and the continuity equation
etc can be respectively reduced to that in the classical field theory.
