axis_rotation_matrix

odl.tomo.util.utility.axis_rotation_matrix(axis, angle)[source]

Matrix of the rotation around an axis in 3d.

The matrix is computed according to Rodriguez' rotation formula.

Parameters:
axisarray-like, shape (3,)

Rotation axis, assumed to be a unit vector.

anglefloat or array-like

Angle(s) of counter-clockwise rotation.

Returns:
matnumpy.ndarray, shape (3, 3)

The axis rotation matrix.

References