Game Development Reference
The final quantity is torque, which is the rotational equivalent to force. Ap-
plying force to an object at any place other than its center of mass will generate
torque. To compute the torque, we take a vector r from the center of mass to the
point where the force is applied and perform a cross product as follows:
τ = r
This will apply the torque counterclockwise around the vector direction, as per
the right-hand rule. We can sum all torques to determine the total torque on an
τ tot =
r j ×
F j .
As with force, we can use Newton's second law to find the relationship be-
tween torque and angular acceleration α :
τ = I α.
1.6.4 Numerical Integration for Orientation Using Matrices
To update our orientation, we ideally would want to do something like this:
R i +1 = R i + hω i .
However, as R i is a matrix and ω i is a vector, this is not possible. Instead, we do
R i +1 = R i + h [ ω ] × i R i ,
[ ω ] × =
To understand why, let us consider the basis vectors of the rotation matrix R and
how they change when an infinitesimal angular velocity is applied. For simplic-
ity's sake, let us assume that the angular velocity is applied along one of the basis
vectors; Figure 1.7 shows the other two. Recall that the derivative is a linear
quantity, whereas angular velocity is a rotational quantity. What we need to do is
change the rotational change of each axis to a linear change. We can do this by
computing the infinitesimal linear velocity at the tip of a given basic vector and
then adding this to get the new basis vector.
Recall that Equation (1.5) gives the linear velocity at a displacement r for
angular velocity ω . So for each basis vector r j , we could compute ω
r j and,