4

I am trying to convert euler rotation order from existing xyz to zxy. Could anyone please help me in doing this? Thanks.

Edit: I found this really useful article, thinking it may help others on the same path - http://knol.google.com/k/matrices-for-3d-applications-translation-rotation#Rotation_matrices_for_Euler_angles(C2)(A0)_(28)rotation_round_X(2C)Y_and_Z_axis(29)

AakashM
  • 62,551
  • 17
  • 151
  • 186
i4n
  • 210
  • 1
  • 3
  • 8

2 Answers2

2

See this link: http://en.wikipedia.org/wiki/Euler_angles#Matrix_orientation. Make 9 equations from xyz to zxy matrix and solve them.

Ghostoy
  • 2,689
  • 19
  • 18
1

In your particular case, there's an easy way to do it. that's because you are changing the x->z, the y->x and z->y, so in a circular way that mantains the right hand order of axis. So if the matrix is:

m[0] m[3] m[6]
m[1] m[4] m[7]
m[2] m[5] m[8]

you have to rotate the columns so the 3rd becomes 1st,

m[6] m[0] m[3]
m[7] m[1] m[4]
m[8] m[2] m[5]

and after exchange the coords in the rows:

m[8] m[2] m[5]
m[6] m[0] m[3]
m[7] m[1] m[4]

so the correspondence is between first and third matrix, for example:

m[0] --> m[8]
m[4] --> m[0]
m[8] --> m[4]

and so on.

substitute the matrix elements in your formulas and that's all, folks!

AndrewBloom
  • 2,171
  • 20
  • 30