1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Quaternion local rotation

  1. Nov 27, 2013 #1

    Once again, I got a question about quaternions.
    Say I have an initial rotation Q1. I now want to rotate Q1 on the X and then on the Y axis. BUT: The Y rotation should apply to the local Y axis which was given in Q1.

    The problem is:
    If i rotate Q1 by the X-rotation Q2, then the Y axis changes for Q1*Q2. So, since quaternion multiplication is noncommutativ, if I then apply the Y-rotation Q3, I don't rotate about the original Y axis of Q1.

    How can I rotate quaternions this way?

  2. jcsd
  3. Dec 1, 2013 #2
    I assume that the rotations around X and Y will be achieved by applying by two separate quaternion increments, call them QX and QY. Assuming this is the case I think you need to proceed as follows;

    1. apply the QX rotation to Q1, call the result R1.
    2. apply the QX rotation to the QY rotation increment - this transforms the Y axis rotation from the original frame of reference to the frame that exists after you've done the X rotation. Call the modified QY increment QY'
    3. apply QY' to R1
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook