Sign in to follow this  
glSmurf

Angular velocity

Recommended Posts

How do I compute the angular velocity of an rigid body given only its rotation matrix in the current and previous frame? Thanks in advance

Share this post


Link to post
Share on other sites
If M0 and M1 are your rotation matrices in the previous and the current frame, then they are related by:

R*M0 = M1 (1)

where R is a rotation matrix.
From (1), you get that

R = M1*transpose(M0)

From http://en.wikipedia.org/wiki/Rotation_matrix:

R(0,0) + R(1,1) + R(2,2) = 1+2*cos(w) (3)

where w is the angle of the rotation, divide it by your delta, you get the angular velocity.

There is one problem though, the number of solutions to (3) is infinite, which means that strictly speaking, it's impossible to do what you are trying to do. In practice, I guess you can assume that abs(w) is small, so you can choose the smallest solution.

Share this post


Link to post
Share on other sites
Thanks for the reply

That did help me alot with what im trying to do, but to completely solve my problem I also need the axis of this rotation (this is in 3D btw)

Share this post


Link to post
Share on other sites
I just found another article on wikipedia which will help you, see section "Log map from SO(3) to so(3)".

The formula is:
w = 1/2sin(theta) * [R(3,2)-R(2,3); R(1,3)-R(3,1); R(2,1)-R(1,1)]

I have not checked the it, but I suspect an error in their formula. It's surprisingly almost symmetrical, but not quite... I wonder if the last R(1,1) should read R(1,2)?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this