Difference between revisions of "Dcm2euler.m"
(Normalise sequential blank lines) |
(sync with Spinach main f053e432: nearest proper rotation via Davenport matrix note added) |
||
| (4 intermediate revisions by the same user not shown) | |||
| Line 10: | Line 10: | ||
angles=dcm2euler(dcm) | angles=dcm2euler(dcm) | ||
| − | == | + | ==Parameters== |
dcm - directional cosine matrix | dcm - directional cosine matrix | ||
| Line 25: | Line 25: | ||
==Notes== | ==Notes== | ||
The problem of recovering Euler angles from a DCM is, in general, ill-posed. This function is a product of considerable work, it has passed rigorous testing: it either returns a correct answer or gives an informative error. See the notes on [[rotation conventions]] for the basic definitions of rotations in ''Spinach''. | The problem of recovering Euler angles from a DCM is, in general, ill-posed. This function is a product of considerable work, it has passed rigorous testing: it either returns a correct answer or gives an informative error. See the notes on [[rotation conventions]] for the basic definitions of rotations in ''Spinach''. | ||
| + | |||
| + | The angles returned are those of the proper rotation that is nearest to the input in the Frobenius norm; that rotation is found in closed form through the dominant eigenvector of the Davenport matrix (I.Y. Bar-Itzhack, J. Guidance Control Dyn. 23 (2000) 1085), and the angles are extracted from the corresponding quaternion. | ||
==See also== | ==See also== | ||
| − | [[euler2dcm.m]], [[ | + | [[euler2dcm.m]], [[wigner.m]], [[dcm2wigner.m]], [[anax2dcm.m]], [[anax2quat.m]], [[axis_tsymm.m]], [[euler_sup.m]], [[quat2anax.m]], [[rotmat_align.m]], [[rotor_stack.m]], [[xyz2sph.m]], [[Kernel_utilities]] |
''Version 2.3, authors: [[Ilya Kuprov]]'' | ''Version 2.3, authors: [[Ilya Kuprov]]'' | ||
Latest revision as of 06:42, 30 August 2026
Converts directional cosine matrix into Euler angles, ZYZ active convention (rotating the object rather than the axes).
Syntax
[alpha,beta,gamma]=dcm2euler(dcm)
OR
angles=dcm2euler(dcm)
Parameters
dcm - directional cosine matrix
Outputs
alpha, beta, gamma - Euler angles in ZYZ active con-
vention, radians
angles - a row vector of Euler angles in
ZYZ active convention, ordered
as alpha, beta, gamma, in radians
Notes
The problem of recovering Euler angles from a DCM is, in general, ill-posed. This function is a product of considerable work, it has passed rigorous testing: it either returns a correct answer or gives an informative error. See the notes on rotation conventions for the basic definitions of rotations in Spinach.
The angles returned are those of the proper rotation that is nearest to the input in the Frobenius norm; that rotation is found in closed form through the dominant eigenvector of the Davenport matrix (I.Y. Bar-Itzhack, J. Guidance Control Dyn. 23 (2000) 1085), and the angles are extracted from the corresponding quaternion.
See also
euler2dcm.m, wigner.m, dcm2wigner.m, anax2dcm.m, anax2quat.m, axis_tsymm.m, euler_sup.m, quat2anax.m, rotmat_align.m, rotor_stack.m, xyz2sph.m, Kernel_utilities
Version 2.3, authors: Ilya Kuprov