derivations

Module: derivations.angle_axes

Derivations for rotations of angle around axis

angle_axis2mat(theta, vector)

Rotation matrix of angle theta around vector

angle_axis2quat(theta, vector)

Quaternion for rotation of angle theta around vector Notes —– Formula from http://mathworld.wolfram.com/EulerParameters.html

orig_aa2mat(angle, direction)

quat2angle_axis(quat)

Convert quaternion to rotation of angle around axis

Module: derivations.decompositions

Derivations for extracting rotations, zooms, shears

Module: derivations.eulerangles

These give the derivations for Euler angles to rotation matrix and Euler angles to quaternion. We use the rotation matrix derivation only in the tests. The quaternion derivation is in the tests, and, in more compact form, in the euler2quat code.

The rotation matrices operate on column vectors, thus, if R is the 3x3 rotation matrix, v is the 3 x N set of N vectors to be rotated, and vdash is the matrix of rotated vectors:

vdash = np.dot(R, v)

x_rotation(theta)

Rotation angle theta around x-axis http://en.wikipedia.org/wiki/Rotation_matrix#Dimension_three

y_rotation(theta)

Rotation angle theta around y-axis http://en.wikipedia.org/wiki/Rotation_matrix#Dimension_three

z_rotation(theta)

Rotation angle theta around z-axis http://en.wikipedia.org/wiki/Rotation_matrix#Dimension_three

Module: derivations.quaternions

Symbolic formulae for quaternions

qmult(q1, q2)

Multiply two quaternions

quat2mat(quat)

Symbolic conversion from quaternion to rotation matrix

quat_around_axis(theta, axis)

Quaternion for rotation of angle theta around axis axis

Module: derivations.utils

Utilities for derivations

make_matrix(name_prefix, N, M)

matrices_equal(M1, M2)

matrix_simplify(M)

angle_axis2mat

transforms3d.derivations.angle_axes.angle_axis2mat(theta, vector)

Rotation matrix of angle theta around vector

Parameters
thetascalar

angle of rotation

vector3 element sequence

vector specifying axis for rotation.

is_normalizedbool, optional

True if vector is already normalized (has norm of 1). Default False

Returns
matarray shape (3,3)

rotation matrix specified rotation

Notes

From: http://en.wikipedia.org/wiki/Rotation_matrix#Axis_and_angle

angle_axis2quat

transforms3d.derivations.angle_axes.angle_axis2quat(theta, vector)

Quaternion for rotation of angle theta around vector Notes —– Formula from http://mathworld.wolfram.com/EulerParameters.html

orig_aa2mat

transforms3d.derivations.angle_axes.orig_aa2mat(angle, direction)

quat2angle_axis

transforms3d.derivations.angle_axes.quat2angle_axis(quat)

Convert quaternion to rotation of angle around axis

x_rotation

transforms3d.derivations.eulerangles.x_rotation(theta)

Rotation angle theta around x-axis http://en.wikipedia.org/wiki/Rotation_matrix#Dimension_three

y_rotation

transforms3d.derivations.eulerangles.y_rotation(theta)

Rotation angle theta around y-axis http://en.wikipedia.org/wiki/Rotation_matrix#Dimension_three

z_rotation

transforms3d.derivations.eulerangles.z_rotation(theta)

Rotation angle theta around z-axis http://en.wikipedia.org/wiki/Rotation_matrix#Dimension_three

qmult

transforms3d.derivations.quaternions.qmult(q1, q2)

Multiply two quaternions

Parameters
q14 element sequence
q24 element sequence
Returns
q12shape (4,) array

Notes

See : http://en.wikipedia.org/wiki/Quaternions#Hamilton_product

quat2mat

transforms3d.derivations.quaternions.quat2mat(quat)

Symbolic conversion from quaternion to rotation matrix

For a unit quaternion

From: http://en.wikipedia.org/wiki/Rotation_matrix#Quaternion

quat_around_axis

transforms3d.derivations.quaternions.quat_around_axis(theta, axis)

Quaternion for rotation of angle theta around axis axis

Parameters
thetasymbol

angle of rotation

axis3 element sequence

vector (assumed normalized) specifying axis for rotation

Returns
quat4 element sequence of symbols

quaternion giving specified rotation

Notes

Formula from http://mathworld.wolfram.com/EulerParameters.html

make_matrix

transforms3d.derivations.utils.make_matrix(name_prefix, N, M)

matrices_equal

transforms3d.derivations.utils.matrices_equal(M1, M2)

matrix_simplify

transforms3d.derivations.utils.matrix_simplify(M)