Graphics Reference
In-Depth Information
Therefore,
v
1
=
2
s
2
y
2
−
2
2
s
2
z
2
−
2
−
+
+
2
(yz
−
sx)
2
(yz
+
sx)
4
s
2
1
s
2
1
−
4
y
2
z
2
s
2
x
2
y
2
z
2
=
+
−
+
−
−
4
x
2
z
2
x
2
y
2
−
s
2
x
2
y
2
z
2
=
+
+
+
4
x
4
s
2
x
2
x
2
y
2
x
2
z
2
z
2
y
2
y
2
z
2
=
+
+
+
−
+
4
x
2
s
2
+
z
2
+
x
2
+
y
2
=
4
x
2
.
=
4
z
2
, which confirms that the eigenvector has compo-
nents associated with the quaternion's vector. The square terms should be no sur-
prise, as the triple
qpq
−
1
4
y
2
Similarly,
v
2
=
and
v
3
=
includes the product of two quaternions.
11.6 Rotating About an Off-Set Axis
Now that we have a matrix to represent a quaternion rotor, we can employ it to
resolve problems such as rotating a point about an off-set axis using the same tech-
niques associated with normal rotation transforms. For example, in Chap. 9 we used
the following notation
⎡
⎤
⎡
⎤
x
y
z
1
x
y
z
1
⎣
⎦
=
⎣
⎦
T
t
x
,
0
,t
z
R
β,y
T
−
t
x
,
0
,
−
t
z
to rotate a point about a fixed axis parallel with the
y
-axis. Therefore, by substituting
qpq
−
1
for
R
β,y
we have
⎡
⎤
⎡
⎤
x
y
z
1
x
y
z
1
⎣
⎦
=
⎣
⎦
T
t
x
,
0
,t
z
qpq
−
1
T
.
−
t
x
,
0
,
−
t
z
Let's test this by rotating our unit cube 90° about the vertical axis intersecting ver-
tices 4 and 6 as shown in Fig.
11.8
(a) and (b).
The quaternion to achieve this is
q
=
cos 45°
+
sin 45°
j
with the pure quaternion
=
+
u
and using (
11.3
) this creates the homogeneous matrix
p
0
⎡
⎣
⎤
⎦
⎡
⎣
⎤
⎦
0010
0100
−
x
u
y
u
z
u
1
qpq
−
1
=
.
1000
0001