- #1
jstluise
- 58
- 0
I've been trying to wrap my head around 3D rotations and specifically, Euler angles. I thought I had a good understanding of performing multiple rotations, but after writing a Matlab script that graphically shows my rotations, I am not so sure right now.
My biggest hang up is whether or not a rotation is ALWAYS taken about the original frame or if it taken about a intermediate frame. For example, the ZXZ Euler rotation from the original frame ##\vec{X}## to the final frame ##\vec{x}## is described as:
1. Rotation about ##Z## by angle ##\phi## to get intermediate frame ##\vec{x}_1##
##\vec{x}_1 = R_Z(\phi)\vec{X}##
2. Rotation about ##x_1## by angle ##\theta## to get intermediate frame ##\vec{x}_2##
##\vec{x}_2 = {R_x}_1(\theta)\vec{x}_1##
3. Rotation about ##z_1## by angle ##\psi## to get final frame ##\vec{x}##
##\vec{x} = {R_x}_2(\psi)\vec{x}_2##Making substitutions, the final rotation matrix is ##\vec{x} = {R_x}_2(\psi){R_x}_1(\theta)R_Z(\phi)\vec{X} = R\vec{X}##That makes sense with those equations, but then when I go to plot it to see each individual step, it doesn't make sense. It seems like each rotation is always taken about the original frame.
A better example is from a paper I went through:
The rotation is described by: "first a rotation about ##z## (the original frame) by an angle ##\alpha##, then a rotation about the rotated-intermediate frame y-axis by an angle ##\beta##"
This makes sense looking at the picture. So I go through the math just like above in the ZXZ Euler angles and get:
##\vec{x}_1 = R_z(\alpha)\vec{x}##
##\vec{x}_2 = {R_y}_1(\beta)\vec{x}_1##
##\vec{x}_2 = {R_y}_1(\beta)R_z(\alpha)\vec{x} = R\vec{x}##
If I compute this rotation matrix ##R## and perform the rotation, it doesn't come out right. However, if I reverse the order of rotation by 1) rotate by ##\beta## about original y axis, then 2) rotate by ##\alpha## about original z axis, I get:
##\vec{x}_2 = R_z(\alpha)R_y(\beta)\vec{x} = R\vec{x}##
This resulting rotation matrix works correctly when I plot it and is the same rotation matrix given in the paper. But, it all boils down to that I always considered rotating about the original frame.
Can someone help me with this madness! My brain hurts.
My biggest hang up is whether or not a rotation is ALWAYS taken about the original frame or if it taken about a intermediate frame. For example, the ZXZ Euler rotation from the original frame ##\vec{X}## to the final frame ##\vec{x}## is described as:
1. Rotation about ##Z## by angle ##\phi## to get intermediate frame ##\vec{x}_1##
##\vec{x}_1 = R_Z(\phi)\vec{X}##
2. Rotation about ##x_1## by angle ##\theta## to get intermediate frame ##\vec{x}_2##
##\vec{x}_2 = {R_x}_1(\theta)\vec{x}_1##
3. Rotation about ##z_1## by angle ##\psi## to get final frame ##\vec{x}##
##\vec{x} = {R_x}_2(\psi)\vec{x}_2##Making substitutions, the final rotation matrix is ##\vec{x} = {R_x}_2(\psi){R_x}_1(\theta)R_Z(\phi)\vec{X} = R\vec{X}##That makes sense with those equations, but then when I go to plot it to see each individual step, it doesn't make sense. It seems like each rotation is always taken about the original frame.
A better example is from a paper I went through:
The rotation is described by: "first a rotation about ##z## (the original frame) by an angle ##\alpha##, then a rotation about the rotated-intermediate frame y-axis by an angle ##\beta##"
This makes sense looking at the picture. So I go through the math just like above in the ZXZ Euler angles and get:
##\vec{x}_1 = R_z(\alpha)\vec{x}##
##\vec{x}_2 = {R_y}_1(\beta)\vec{x}_1##
##\vec{x}_2 = {R_y}_1(\beta)R_z(\alpha)\vec{x} = R\vec{x}##
If I compute this rotation matrix ##R## and perform the rotation, it doesn't come out right. However, if I reverse the order of rotation by 1) rotate by ##\beta## about original y axis, then 2) rotate by ##\alpha## about original z axis, I get:
##\vec{x}_2 = R_z(\alpha)R_y(\beta)\vec{x} = R\vec{x}##
This resulting rotation matrix works correctly when I plot it and is the same rotation matrix given in the paper. But, it all boils down to that I always considered rotating about the original frame.
Can someone help me with this madness! My brain hurts.