difference between euler angles and rotation vector
30 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
YunYuan XIONG
il 25 Gen 2021
Modificato: James Tursa
il 2 Feb 2021
When transform a quaternion to 3 angles, I have a confusion about 'eulerd' and 'rotvecd'. Where the difference between them ? For example:
quat = quaternion(randn(1,4));
rotationVectorDegrees = rotvecd(quat); % rotation vector (degrees)
eulerAnglesDegrees = eulerd(quat,'XYZ','frame'); % euler angles (degrees)
Why they got different results ?
0 Commenti
Risposta accettata
James Tursa
il 2 Feb 2021
Modificato: James Tursa
il 2 Feb 2021
The rotvecd( ) function gives a scaled rotation axis. I.e., what it would take to do a single rotation of an object on all three axes simultaneously to get from one orientation to another. The direction of the vector gives the rotation axis, and the magnitude of the vector gives the total rotation angle.
The eulerd( ) function gives the angles for performing three separate sequential rotations (not simultaneous) to get from one orientation to another. E.g., rotate about the X-axis by some amount first, then from that resulting position rotate about the Y-axis by some amount, then from that resulting position rotate about the Z-axis by some amount to get to the final orientation.
In general, anytime you deal with Euler Angles you are dealing with separate rotations that are chained together sequentially.
0 Commenti
Più risposte (0)
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!