Get two vector rotations to obtain one vector direction

198 Views Asked by At

I do not know how to approach this math problem. Any hint would be much appreciated. Before I could solve such problem using Atan2 method to get two vector angles, when axes c and a are orthogonal.

Problem: there are two non orthogonal to each other vectors c and a. I need to rotate one time around vector c then around vector a to obtain vector v orientation.

Question: how can I get c and a vector rotations, when I only know vector v orientation?

In the image below, c and a vector rotations are both 0.

enter image description here

I was using atan2 for orthogonal system to get two rotations, but in this cases axis A is not perpendicular to C.

double RotationC = Math.Atan2(V_.X, V_.Y);
double RotationA = Math.Atan2(Math.Sqrt(V_.X * V_.X + V_.Y * V_.Y), V_.Z);
0

There are 0 best solutions below