
Relative Transformation at the Joint The main task in the joint kinematics is to compute the relative orientation angles of the segments to their respective proximallylinked segments at the joints. This is done based on the local reference frames of the segments defined. The segmental reference frames can be obtained from the coordinates of the markers and joint centers. For example, the unit coordinate vectors of the pelvis and the right thigh shown in Figure 1 can be obtained as follows:
and
where i, j & k = the unit coordinate vectors. Describing the unit coordinate vectors as row matrices:
See Transformation Matrix in the Axis Transformation section for the details. The unit coordinate vectors of the segmental reference frames form the transformation matrices from the global frame, respectively:
where P = the proximal segment, D = the distal segment, and G = the global inertial reference frame. The transformation matrix from the proximal reference frame (frame P) to the distal reference frame (frame D) can be computed from the transformation matrices shown in [4]:
where J stands for the joint involved. See the Transformation Matrix page for the details of computation of the transformation matrix from one local frame to another. From [5] of Orientation Angles in the Axis Transformation section:
where f, q & y = the relative orientation angles of the distal segment to the proximal segment forming the joint, c(x) = cos x, and s(x) = sin x. In [7], q_{J} is the first angle to compute. The general solutions of angle q_{J} are
where n = integer number which is quite likely to be 0 for angle q_{J}. As shown in [7], two possible solutions can be obtained as q_{J}. The return value of the inverse sine function (sin^{1}) ranges
Since angle q is the orientation angle about the Y axis, it generally stays within the range shown in [8] with one exception: the shoulder. In the shoulder, angle q_{J} can be outside the range shown in [8]. Let's use the shoulder abduction from the anatomical reference frame as an example. The abduction angle in fact coincides with angle q_{J} in this case and the abduction angle can obviously exceed p/2 (90°) as shown in Figure 2. The red arrow in the figure shows the motion of the upperarm from position 1 to position 2, passing the 90° position.
The more direct and useful solutions for angle q_{J} would be
The solutions shown in [9] are in the range of
In Figure 3, the purple arrows represent case 1 shown in [9]. In order to bring the upperarm reference frame to position 2 in this case, one must first flex the shoulder (f_{J}) by p. Therefore, one will observe discontinuity in f_{J} between positions 1 and 2 while q_{J} remains smaller than p/2. On the other hand, the blue arrow represents case 2 shown in [9]. Angle f_{J} stays (= 0) while angle q_{J} passes and becomes larger than p/2. One can only find the true solution by considering the continuous motion of the upperarm.
Computation of f_{J} and y_{J} Once q_{J} is known, f_{J} and y_{J} can be computed. In both cases, the sine and cosine of the angle are given and one can use the inverse tangent (tan^{1}) function for this job. The general solution are
where n = integer number which is not necessarily 0, especially in the shoulder joint. In addition, n may not be zero when one computes the relative orientation of a particular segment to the global frame if the motion involves multiple somersaults and/or twists. n must be figured out considering the continuity in the angle. Although the return value of the inverse tangent function ranges
one can compute the true angle since both the sine and cosine of the angle are given. The angle range shown in [12] coincides with that of positive cosine. The more specific solution would be
and
In [13] and [14]:
In the case of the gimbal lock, [6] reduces to
[13] & [14] can be then modified to
Again, [13], [14] & [17] provide the orientation angles in the range of
There are two obstacles in computing the orientation angles of the distal reference frame to the proximal reference frame. Firstly, [9], [13], [14] & [17] provide two sets of orientation angles due to two possible q_{J}'s. Secondly, the arbitrary integer n in [13], [14] & [17] needs to be determined. But these obstacles have a common root: continuity in the angles. In other words, the true solution and n must be determined based on the continuous relative motion of the distal reference frame to the proximal frame. Determination of n can be taken care using the procedure explained in the Continuous Angle page in the UserAngle Issues section. Therefore the only real problem is to choose the true orientation angle set from the two sets computed. The key to solution for this problem is the fact that one must observe discontinuity in f_{J} and y_{J} if wrong q_{J} is chosen. Thus, the angle set that shows smaller
with the previous frame is the final solution. 
© YoungHoo Kwon, 1998 