Originally Posted by

**HallsofIvy** Then presumably you know that a rotation about the x-axis though angle rx is given by the matrix with rows [1 0 0], [0 cos(rx) -sin(rx)], [0 sin(rx) cos(rx)], that a rotation about the y-axis through angle ry is given by the matrix [cos(ry) 0 -sin(ry)], [0 1 0], [sin(ry), 0 cos(ry)], and that the rotation around the z-axis through an angle rz is given by the matrix [cos(rz) -sin(rz) 0], [sin(rz) cos(rz) 0], [0 0 1].

And the rotation matrix R is the product of those matrics.

Go ahead and multiply the matrices above by the Vbefore vector, and set the result equal to the Vafter vector. That gives you three equations to solve for vx, vy, and vz. (I presume you meant {rx,ry,rz}, not {rx,ry,rx}.)