Calculate the individual rotations - Printable Version +- LDraw.org Discussion Forums ( https://forums.ldraw.org)+-- Forum: Off Topic ( https://forums.ldraw.org/forum-28.html)+--- Forum: Off-Topic ( https://forums.ldraw.org/forum-27.html)+--- Thread: Calculate the individual rotations ( /thread-28204.html) |

Calculate the individual rotations - Manfred Schaefer - 2024-04-08
Hello, I am trying to calculate the individual rotations (Euler angles) around the three axes from the rotation matrix. I have also tried it with quaternions, but somehow it doesn't work. Has anyone tried something like this before and can give me a solution or tips? Thank you. Manfred RE: Calculate the individual rotations - Travis Cobbs - 2024-04-08
(2024-04-08, 20:18)Manfred Schaefer Wrote: Hello, The LDraw transformation matrix is a general transformation matrix, so it is possible that what you want is not possible for some arbitrary one. Having said that, the matrix applied to parts should always contain only rotations and translations, so hopefully this StackOverflow answer helps: https://stackoverflow.com/questions/15022630/how-to-calculate-the-angle-from-rotation-matrix#15029416 RE: Calculate the individual rotations - N. W. Perry - 2024-04-09
Not sure if you're seeking the method or just the answer, but I use this tool: https://www.andre-gaschler.com/rotationconverter/ It's open source, so you could presumably figure out how it works. RE: Calculate the individual rotations - Manfred Schaefer - 2024-04-18
Thank you for answers. Sorry for the long delay. I couldn't solve the issue to calculate the Euler angles. There are some points which make this item hard to solve for me. One point is that some sets of Euler angles lead to one rotation matrix. Another point is one entry of the rotation matrix represent the sin angle of one axis. But the value for 45° and 135° is the same for example. I don't give up, may be I will found a solution in the future. Greetings Manfred |