Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

My google foo seems to be failing me on this one, so here goes.

I have a matrix that represents the rotation of an object, and another that represents the rotational velocity of the object for an object in 3d space for a simulation. I'm trying to figure out how to calculate the amount of change of rotation to apply. If I was only doing 1 render per frame then I could just multiple the velocity by the current rotation and it would be fine, but I'm rendering as fast as the machine can handle.

For translation, I can just scale the velocity vector and add that to the current one, I just can't seem to figure out how to do it for the rotational velocity (and acceleration when I get that far).

My understanding of mathematical notation for matrix maths is fairly limited, so simple terms would be great, pseudo code would be even better :)


share|improve this question
Rotational velocity is typically represented by a vector, not a matrix. It sounds like you have a matrix that, when multiplied with the current orientation, gives you the orientation at the next time step, is that correct? If so, what you can do is convert the matrix to an axis-angle representation, scale the angle, and then convert back to a matrix. –  Rahul Jul 13 '11 at 23:36
By the way, it's spelt Google-fu (by analogy with kung-fu). –  Rahul Jul 13 '11 at 23:37
Thank you, you are correct regarding what my matrix represents. I tried converting to Quaternions but hit the problem of them wrapping around. The maths library I am using doesn't have axis-angles so I had assumed they were not needed. I will investigate the maths required for converting from a 3x3 matrix to an axis-angle. –  Endolf Jul 14 '11 at 6:10
After finding that converting a rotation matrix in to an axis angle has the same wrapping issues as quaternions, I investigated using a vector as per the first of your links @Rahul. Everything finally works now. Thank you :) –  Endolf Jul 15 '11 at 20:41

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.