Documentation for jbiu/

Generated by IDLdoc

single page | use frames     summary     class     fields     routine details     file attributes

math/

quat2rotaxis.pro


top source quat2rotaxis

Math

result = quat2rotaxis(quat)

Returns the net axis and angle of the rotation specified by the input quaternion.

Return value

The function returns a 4-element vector. The first 3 elements are the axis of the rotation and the 4th element is the magnitude of the rotation in radians.

Parameters

quat in

A quaternion specifying a rotation.

Examples

IDL> theta=!PI/3. IDL> rm = [[COS(theta),0,-SIN(theta)],[0,1,0],[SIN(theta),0,COS(theta)]] IDL> quat = MATRIX2QUATERNION(rm) IDL> rotation = QUAT2ROTAXIS(quat) IDL> PRINT, rotation 0.00000 -1.000000 0.00000 1.04720

Author information

History:

Written by: Jeremy Bailin 27 Nov 2008 Released in JBIU

File attributes

Modification date: Wed Apr 15 16:08:04 2009
Lines: 44