Decomposing a Transformation Matrix
Mostrar comentarios más antiguos
Hi!
I have been trying to look for a function that will "undo" a transformation matrix.
I saw in Matlab that there's a function "makehgtform" to create a transformation matrix. Now, I'm looking for something that is the exact opposite of this.
Example:
M = makehgtform('xrotate',30*pi/180);
It would result to a 4x4 matrix. But I want to actually extract the X, Y, Z translation and X,Y,Z rotation.
Can anyone help me or just give me an idea? I would really appreciate it! :(
Thanks in advance!
Respuesta aceptada
Más respuestas (1)
Bruno Luong
el 28 de Nov. de 2018
0 votos
Translation vector is T(1:3,4);
Rotation matrix is T(1:3,1:3).
If you want to decompose in rotation on axis, there are many conventions (intrinsic, extrinsic, Euler's angle, Tait–Bryan angles, etc...) see https://en.wikipedia.org/wiki/Euler_angles and pick your choice.
Categorías
Más información sobre Coordinate Transformations en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!