Function rotate3dh

rotate3dh(theta, v) returns a 3D rotation by a given angle $\theta$ around a unit axis $v$. This transformation is encoded as a $4 \times 4$ matrix in homogeneous coordinates.

  • Parameters

    • theta: Num

      angle of rotation (in radians)

    • v: VecN

      axis of rotation (unit vector)

    Returns Num[][]

    3D rotation matrix in homogeneous coordinates