rotation-matrix3 ( axis theta -- matrix )


Vocabulary
math.matrices

Inputs and outputs
axisan object
thetaan object
matrixan object


Definition


:: rotation-matrix3 ( axis theta -- matrix )
theta cos :> c theta sin :> s axis first3 :> ( x y z ) x sq
1.0 x sq - c * + x y * 1.0 c - * z s * - x z * 1.0 c - *
y s * + 3array x y * 1.0 c - * z s * + y sq 1.0 y sq - c * +
y z * 1.0 c - * x s * - 3array x z * 1.0 c - * y s * - y z *
1.0 c - * x s * + z sq 1.0 z ~7 more~ ;