$LastChangedDate: 27-Juil-2011 $

# CL_rot_eul2quat

Euler '123' angles to quaternion - DEPRECATED

## Calling Sequence

       [q] = CL_rot_eul2quat(phi,theta,psi)

## Description

- Computes the quaternion that corresponds to the combination of 3 successive rotations of respective angles phi, theta, psi around axes number 1 (x-axis), 2 (y-axis), 3 (z-axis) respectively.

- Notes:

  - See Conventions or CL_rot_defQuat for more details on quaternions.

## Parameters

phi :

  Rotation angle around the first (X) axis [rad] (1xN)

theta :

  Rotation angle around the second (Y) axis [rad] (1xN)

psi :

  Rotation angle around the third (Z) axis [rad] (1xN)

q :

  Quaternion (dim N)

## Authors

- CNES - DCT/SB

## Bibliography

- 1) Mecanique spatiale - CNES Cepadues 1995, Tome I, 7.2.2.3 Les quaternions

## See also

- CL_rot_quat2eul

- CL_rot_defQuat

## Examples

    // Example 1
    phi = 0.2; // radians
    theta = 0.3;
    psi = 0.4;
    q = CL_rot_eul2quat(phi,theta,psi)

    // Same computation with matrix:
    M = CL_rot_angles2matrix([1,2,3], [phi;theta;psi]);
    q = CL_rot_matrix2quat(M)