I would like to find out how to rotate a vector in 3D from one orientation to another with a series of rotations (around x, around y, around z — or any other order) so it ends up forming pre-defined angles with the coord. system axes.
Details:
Let us consider a fixed coordinate system xyz: see attached image Image of the system. In this coordinate system, there is vector U (unit length), forming angle a with the x axis, angle b with the y axis and angle c with the z axis. a,b,c are known. Let us rotate the same vector (now called U1) to form angles a1, b1, c1 with the same axes x, y and z. a1, b1, c1 are known. Correct me if I am wrong, but I think a,b,c are not Euler angles ( Euler angles )– right?
Usually the rotation matrix (R, rotating U to U1 from starting orientation to final orientation as defined above) is composed by a series of 3 rotations around the axes x, y and z by angles alpha, beta, gamma (respectively). The order can vary. This is clear on Wikipedia ( Rotation matrix ).
Question:
What are the angles alpha, beta, gamma that make up the rotation matrix (how can they be expressed in function of a, b, c, a1, b1, c1 vector to axes angles), in case of (i) x-y-z and (ii) z-y-x rotation orders? Correct me if I am wrong, but I think alpha, beta, gamma will be Euler angels — in contrast to a, b, c.
Matlab code examples would be appreciated, just as tips regarding eul2rotm() function's angle definitions(drawing?).
Thank you!
Best Answer