quat2eul is giving me a strange result
12 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Adam Levschuk
le 31 Mar 2021
Réponse apportée : James Tursa
le 2 Avr 2021
Hello All,
I am using the quat2eul function to convert quaternions to euler Angles, However, after i do that i get a strange result. It appears that whenever ever my angle gets greater than pi it switches to a negative angel. Does anyone know how to fix this? i have attached a photo so you can see what I'm talking about.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/569004/image.png)
2 commentaires
James Tursa
le 2 Avr 2021
Modifié(e) : James Tursa
le 2 Avr 2021
Please post a small subset of your quaternion data that encompasses one of these pos/neg switches, and also the code you are using for the conversion. Maybe all you have to do is add 2*pi to all results that are less than -pi to get things how you want.
Réponse acceptée
James Tursa
le 2 Avr 2021
Maybe all you have to do is add 2*pi to all results that are less than -pi to get things how you want.
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Calendar dans Help Center et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!