# Calculated Pitch, Yaw, Roll of vectors in a plane

1. ### nschaefe

12
Hello, I'm sorry if this is a dumb question but I am extremely confused and could use some guidance.

So consider a cartesian coordinate system with a plane which passes through the origin, and there are vectors of known X,Y,Z components which lie within this plane. The plane(and vectors) are then rotated about the X,Y, and Z axes by some unknown angles wrt the origin. Assume that the plane is initially parrallel with the XY plane and has a rotation about Z of 0

Given the new coordinates of the vectors after rotation, is there a way to algebraically determine the angles of rotation Rx, Ry, and Rz that were applied?

My original approach was based on finding the planes unit normal vector (N), then calculating Rx = atan(Ny/Nz) and Ry = atan(Nx/Nz), and using one of the vectors (V) to calculate Rz = atan(Vy/Vx), but I am realizing this is incorrect. Is this even possible? Thanks for taking a look.

2. ### tiny-tim

26,016
hello nschaefe! welcome to pf!

i think it's easiest if you imagine everything on a sphere, with north along the z-axis and longitude 0 along the x-axis

let the first plane cut the sphere along the equator, and the second plane along a great circle that intersects the equator at longitudes φ and 180°+φ, and with an angle θ between it and the equator

then the transformation would be a rotation of φ about the z-axis, followed by a rotation of θ about the x-axis

3. ### nmf77

13
This link may help ....

http://en.wikipedia.org/wiki/Euler_angles

I'm sure the PF contributors can cover this topic perfectly well, but you may also want to look further afield. This question crops up all the time in the field of navigation, so resources related to that area may also shed some light. The link above will set you off down that route. The order of the rotations is important, and there are some conventions discussed here ....

http://mathworld.wolfram.com/EulerAngles.html

4. ### nschaefe

12
Thank you both for your responses. I think my part of my confusion is because I want the transformations to occur about the original coordinate system.

Looking at the image from the wolfram site:

The final transformation appears to be taken about the rotated coordinate systems z axis (the angle $ψ$), also appearing in this text below:
What I want are rotations about the original coordinate system (xyz), i.e. $\theta$x, $\theta$y,$\theta$z which yield the rotated points.

I am wondering if this is due to the definition of rotation being a coordinate system transformation vs. a transformation of the points themselves. From what I have gathered from the wikipedia article on rotation matrices, switching the sign of the sin terms in the rotation matrix yields a point transformation vs. a coordinate system transformation. However, isn't this irrelavent as it is really just the idea of rotation by a negative angle vs. a positive one? (i.e. -20 degrees coordinate system transformation is equivalent to +20 degrees point transformation)

Of particular interest however were equations 71-77 of the wolfram math page, and funny enough was an solution I originally conceived but then disregarded.

Essentially given X as an original point and X' as the rotated counterpart due to applied rotation transformation A, (i.e. X' = AX), you can use a nonlinear iterative solution method to solve the applied rotations.

So if A = R_x*R_y*R_z (where R_x is the rotation matrix of some angle about X, then the Jacobian of A with respect to $\theta$x, $\theta$y,$\theta$z can be used to solve the rotations that occurred.

Thus my question is this: Using the iterative solution outlined above (see the wolfram math page at this link, and using the rotation matrices outlined in this wikipedia article, will the solution give me rotations $\theta$x, $\theta$y,$\theta$z about the original coordinate system xyz?

Worded another way, if I were to take some points and apply a three transformations (R_x,R_y,R_z), all of these rotations should be occuring about the "same" coordinate system, i.e. coordinate systems with identical orientation, correct?

I hope this makes sense, thanks for all your help and let me know if you need any clarification.

Know someone interested in this topic? Share this thead via email, Google+, Twitter, or Facebook

Have something to add?
Draft saved Draft deleted