PDA

Click to See Complete Forum and Search --> : 3D Rotation


SteveS
Feb 21st, 2002, 03:35 AM
I have used the idea that the end of a vector is a point on a sphere and the other end is the origin of the XYZ Axis of roation. I want to move the X-Axis DegX and the Y-Axis DegY and the Z-Axis DegZ.

How do I do the rotation calculation. I just can't get the new values of XYZ.

PS: Converting from 3D to 2D, I already have working, for plotting the vector, but the new XYZ coordinates of the Vector????????

/\/\isanThr0p
Feb 21st, 2002, 10:07 AM
as far as I understand you you just have to go like
sin(degx) to get the y component to add
and sin(degy) to get the x component to add
than you would have to do it for all 3 dimensions.
(every dimension can be seen as a 2 dimensional vector for itself)

I hope I made some sense

Zaei
Feb 21st, 2002, 01:35 PM
Look up spherical coordinates, and conversion from spherical to rectangular coordinates. This should be what you are looking for(though a 3d vector can be described with only 2 angles, and a radius).

Z.

SteveS
Feb 25th, 2002, 04:24 AM
Thanks, I'll try that.