pytransform3d.rotations.concatenate_mrp#

pytransform3d.rotations.concatenate_mrp(mrp1, mrp2)[source]#

Concatenate two rotations defined by modified Rodrigues parameters.

Suppose we want to apply two extrinsic rotations given by modified Rodrigues parameters mrp1 and mrp2 to a vector v. We can either apply mrp2 to v and then mrp1 to the result or we can concatenate mrp1 and mrp2 and apply the result to v.

The solution for concatenation of two rotations \(\boldsymbol{\psi}_1,\boldsymbol{\psi}_2\) is given by Shuster [1]:

\[\boldsymbol{\psi} = \frac{ (1 - ||\boldsymbol{\psi}_1||^2) \boldsymbol{\psi}_2 + (1 - ||\boldsymbol{\psi}_2||^2) \boldsymbol{\psi}_1 - 2 \boldsymbol{\psi}_2 \times \boldsymbol{\psi}_1} {1 + ||\boldsymbol{\psi}_2||^2 ||\boldsymbol{\psi}_1||^2 - 2 \boldsymbol{\psi}_2 \cdot \boldsymbol{\psi}_1}.\]
Parameters:
mrp1array-like, shape (3,)

Modified Rodrigues parameters.

mrp2array-like, shape (3,)

Modified Rodrigues parameters.

Returns:
mrp12array, shape (3,)

Modified Rodrigues parameters that represent the concatenated rotation of mrp1 and mrp2.

References

[1]

Shuster, M. D. (1993). A Survey of Attitude Representations. Journal of the Astronautical Sciences, 41, 439-517. http://malcolmdshuster.com/Pub_1993h_J_Repsurv_scan.pdf