# Arotation: Rotation axis and angle of rotation given a rotation matrix In Directional: A Collection of Functions for Directional Data Analysis

## Description

Given a 3 x 3 rotation matrix, the angle and the axis of rotation are calcualted.

## Usage

 `1` ```Arotation(A) ```

## Arguments

 `A` A 3 x 3 rotation matrix.

## Details

If the user does not supply a rotation matrix a message will appear.

## Value

A list including:

 `angle` The angle of rotation expressed in degrees. `axis` The axis of rotation. A vector of two components, latitude and longitude, expressed in degrees.

## Author(s)

Michail Tsagris R implementation and documentation: Michail Tsagris mtsagris@uoc.gr and Giorgos Athineou <gioathineou@gmail.com>

## References

Course webpage of Howard E. Haber. http://scipp.ucsc.edu/~haber/ph216/rotation_12.pdf

Ted Chang (1986). Spherical Regression. Annals of Statistics, 14(3): 907-924.

```rot.matrix, rotation, rsop ```

## Examples

 ```1 2 3 4 5``` ```ksi <- c(25.31, 24.29) theta <- 2.38 A <- rot.matrix(ksi, theta, rads = FALSE) A Arotation(A) ```

### Example output

```sh: 1: wc: Permission denied
Warning messages:
1: In rgl.init(initValue, onlyNULL) : RGL: unable to open X11 display
2: 'rgl.init' failed, running with 'rgl.useNULL = TRUE'.
[,1]        [,2]        [,3]
[1,]  0.99972305 -0.01748908  0.01574641
[2,]  0.01801771  0.99925667 -0.03408022
[3,] -0.01513867  0.03435450  0.99929505
\$angle
[1] 2.38

\$axis
latitude longitude
25.31     24.29
```

Directional documentation built on Nov. 8, 2021, 1:07 a.m.