Consider an aerospace application where the world reference coordinate frame {W} and a body-fixed coordinate frame {B}. The origins of {W} and {B} are coincident. The orientation of {B} is described in terms of roll-pitch-yaw angles defined as a sequence of rotations where yaw is about the Z, pitch is about the Y axis and roll is about the X axis.
Given an SO(3) rotation matrix describing the orientation of {B} with respect to {W} determine the roll-pitch-yaw angles.
Solution Stats
Problem Comments
Solution Comments
Show commentsProblem Recent Solvers8
Suggested Problems
-
Find the sum of the elements in the "second" diagonal
1204 Solvers
-
Convert hex color specification to MATLAB RGB
254 Solvers
-
Getting the indices from a vector
11803 Solvers
-
Create a Cell array of month-end date strings within a date range
78 Solvers
-
Calculate distance travelled when given radius and rotations
241 Solvers
More from this Author16
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
There is a flaw in the test suite. It tests the values in rpy2r rather than the results rpy from the solver's function. Also, the tolerance needs to be widened a bit.
Actually that's not a flaw, William. Since it is not always possible to determine the exact three original angles. In the second test case for instance, there are infinite solutions due to a singularity. Therefore, he tests the rotation matrix since it will be equal for all possible solutions.