This issue came up at work today, I thought ya /prog/ peeps might have some info.
So what do ya'll know about the numerical stability of rotations with, matrices, euler angles, and quaterions.
Also what do you know about the methods for interpolating rotations, and which method maintains numerical stability across the interpolation operation.
Name:
Anonymous2007-11-14 2:57
I was hoping there was some smart channer out there that could help me understand this quaternion problem but I see this is gonna have to end up being a tutorial for you braindead zombies.
A good example of numerical stability issues shows up in matrix inversion. When you calculate the inverse of a matrix the naive method, that those of us that made it out of remedial math classes in highschool learned was gaussian elimination. In this algorithm you use multiples of the ith row of an mxn matrix to reduce the leftmost non-zero coeeficient of rows i+1 to m of the matrix to 0. The problem that arises is that floating point representations in computers end up having little non-zero components floating off in the least significant digits(ie a result of a multiplication ends up 1.0000004 instead of 0.0000000) To reduce these little fuckers to 0 requires ever more complex and esoteric row multipliers as the algorithm continues, to the point where this simple algorithm ends up essentially intractable on modern computers for matrices of reasonably large dimensions(>10x10).
Each step in this algorithm compounds this error because the multipliers used in previous steps to get the coefficient exactly to zero are not independent of subsequent steps.
So since gaussian elimination is numerically unstable most matrix inversion packages try to use other more complex methods of calculating the matrix inverse.