cspice_axisar

 Abstract I/O Examples Particulars Required Reading Version Index_Entries

#### Abstract

```
CSPICE_AXISAR returns a 3x3 double rotation matrix that rotates
vectors by a specified angle about a specified axis.

```

#### I/O

```
Given:

axis    the vector defining a rotation axis.

[3,1] = size(axis); double = class(axis)

angle   the angle in radians defining the measure of rotation

[1,1] = size(angle); double = class(angle)

the call:

r = cspice_axisar( axis, angle)

returns:

r   the operator for the coordinate transformation determined by
'axis' and 'angle', i.e. the application of 'r' to a 3x1
array returns the result of rotating the vector about 'axis'

[3,3] = size(r); double = class(r)

Please note cspice_raxisa is not guaranteed to invert the
operation of cspice_axisar.

```

#### Examples

```
Any numerical results shown for this example may differ between
platforms as the results depend on the SPICE kernels used as input
and the machine specific arithmetic implementation.

Example:

%
% Define an axis and an angle for rotation.
%
axis = [ 1.; 2.; 3. ];
angle = .1 * cspice_twopi;

%
% Determine the rotation matrix.
%
rot_mat = cspice_axisar( axis, angle );

%
% Now calculate the rotation axis and angle based on the
% matrix as input.
%
[ axout, angout ] = cspice_raxisa( rot_mat);

%
% Now input the axout and angout to cspice_axisar to
% compare against the original rotation matrix rot_mat.
%
rot_out = cspice_axisar( axout, angout );
rot_mat - rot_out

MATLAB outputs:

1.0e-15 *

0  -0.11102230246252   0.05551115123126
0.11102230246252                  0                  0
-0.05551115123126   0.02775557561563                  0

The zero matrix accurate to round-off error. A numerical
demonstration of equality.

```

#### Particulars

```
None.

```

```
For important details concerning this module's function, please refer to
the CSPICE routine axisar_c.

MICE.REQ
ROTATION.REQ

```

#### Version

```
-Mice Version 1.0.1, 28-OCT-2014, EDW (JPL)

Edited I/O section to conform to NAIF standard for Mice documentation.

-Mice Version 1.0.0, 29-NOV-2005, EDW (JPL)

```

#### Index_Entries

```
axis and angle to rotation

```
`Wed Apr  5 18:00:29 2017`