aa_from_rotmat Subroutine

public subroutine aa_from_rotmat(rotmat, axis, angle)

Extracts axis and angle from a rotation matrix.

Arguments

Type IntentOptional Attributes Name
real(kind=rp), intent(in), dimension(3,3) :: rotmat

Rotation matrix (must be orthonormal).

real(kind=rp), intent(out), dimension(3) :: axis

Unit vector along the axis.

real(kind=rp), intent(out) :: angle

Angle of rotation in radian.