Description
1. Exercise 3.11 from the text:
Construct quaternions for the null rotation, and for rotations of π and π
2
about each coordinate axis.
2. Exercise 3.13 from the text:
For the rotation described by the matrix below, produce the rotation axis and angle, the unit quaternion,
and the Euler angles.
−2/3 −2/3 1/3
2/3 −1/3 2/3
−1/3 2/3 2/3
3. Exercise 3.16 from the text:
For this question you will conduct an experiment to answer the question: What is the average angle
of rotations in E
3
?
(a) Write code to generate uniformly distributed unit quaternions.
(b) Write code to produce the smallest rotation angle for a given quaternion, in the range from zero
to π.
(c) Write code to generate a lot of unit quaternions, uniformly distributed, and take the mean angle.
For additional insight plot a histogram.
How does one produce a uniform distribution on the surface of a sphere in E
4
? One easy way is to
generate four real numbers uniformly in the interval [−1,1]. That defines a uniform distribution in a
cube. If we discard every quadruple with magnitude greater than 1, we will have a uniform distribution
in the interior of the sphere. Normalize to get a uniform distribution on the surface of the sphere.
1