Quaternions and Rotations

For my second year maths project I wrote an essay on representing rotations in 3D, largely focusing on quaternions.

It discusses a few ways in which rotations (more correctly, orientations) can be represented, how quaternions can be used, and their limitations.

The essay is provided here for anyone who might find it useful; most likely a programmer like myself.

Note that this article doesn't cover all representations; another I know of is the Gibbs-Rodrigues.

More on rotations

As discussed in my quaternions article, quaternions are more apt to represent an orientation than a rotation. Axis-angle representions can be used for rotations or angular velocity/spin, however, these are difficult to combine. Thus for a while I have been trying to solve the problem of how to represent the spin of an object, in such a way that it allows rotations of more than 2pi (360 degrees) and allows the angle of rotation to be scaled easily. If I find a suitible solution I intend to post it here.

Update: Well, I just used the quaternion operations (conversions to and from, multiplication) to make an operator combining axis-angle represented rotations. I didn't do this before because of the limitations (such as a maximum angle of rotation of 2pi), but it seems to work (although it's not exactly a fast operation and you need to check the value passed to the arccos function is in the range [-1,1] if you don't want bad things to happen). I also tried using quaternions to represent the spin, scaling them by raising to the power of a scalar, as described here (under Quaternion SLERP). Both methods seem to work OK, except that when trying to adjust spinning thrusts to the objects current orientation things didn't work very well for the quaternion method. I didn't test the quaternion method very much because of this. On testing the axis-angle combining method, I've found that spinning an object too fast causes the direction to flip when the spinning speed reaches 2pi radians per second. I'm sure changing the units to something like radians per 1/10th of a second will help though.

btw let me know if anyone actually finds this useful (besides myself), or if you want a bit clearer explanations or something.