matrix handedness
This is more of a math question, so I''ll post it here:
How would you test the handedness of a matrix?
Can you tell if a 3x3 rotation matrix, for example, is left-handed or right-handed?
Negative. Matrices have no notion of "left-handed" or
"right-handed" associated with them.
~~~~
Kami no Itte ga ore ni zettai naru!
"right-handed" associated with them.
~~~~
Kami no Itte ga ore ni zettai naru!
神はサイコロを振らない!
Actually, I think there is a real answer here. If the matrix is a rotation matrix, there is an implicit "handedness" of the coordinate system represented by the matrix and you can determine it. Lets assume the following:
1) the matrix is a 3x3 rotation matrix; and
2) the columns of the matrix represent the basis vectors of the rotated coordinate system
Let the basis vectors be:
X = (X.x, X.y, X.z)
Y = (Y.x, Y.y, Y.z)
Z = (Z.x, Z.y, Z.z)
so the matrix is:
Then, you can determine the handedness of the coordinate system with the following pseudocode:
I will note, however, that tangentz is correct in saying "Matrices have no notion of left-handed or right-handed associated with them." It is only in the context of a rotation matrix that you can say the coordinate system represented by the matrix is left- or right-handed.
Graham Rhodes
Senior Scientist
Applied Research Associates, Inc.
[edited by - grhodes_at_work on July 19, 2002 12:11:55 PM]
1) the matrix is a 3x3 rotation matrix; and
2) the columns of the matrix represent the basis vectors of the rotated coordinate system
Let the basis vectors be:
X = (X.x, X.y, X.z)
Y = (Y.x, Y.y, Y.z)
Z = (Z.x, Z.y, Z.z)
so the matrix is:
[ X.x Y.x Z.x ]M = | X.y Y.y Z.y ] [ X.z Y.z Z.z ]
Then, you can determine the handedness of the coordinate system with the following pseudocode:
if (Z == (X cross Y) ) system is right-handedelse system is left-handedendif
I will note, however, that tangentz is correct in saying "Matrices have no notion of left-handed or right-handed associated with them." It is only in the context of a rotation matrix that you can say the coordinate system represented by the matrix is left- or right-handed.
Graham Rhodes
Senior Scientist
Applied Research Associates, Inc.
[edited by - grhodes_at_work on July 19, 2002 12:11:55 PM]
Graham Rhodes Moderator, Math & Physics forum @ gamedev.net
I agree that you can test the "handedness" of a coordinate
system given the basis {v1, v2, v3}.
if (v1 x v2) . v3 > 0, then it''s right-handed.
if (v1 x v2) . v3 < 0, then it''s left-handed.
However, the rotation matrix ITSELF has no notion of "handedness".
Since it is orthogonal (orthonormal), it preserves lengths
and angles, hence the coordinate system. That''s all.
The most you can say about a rotation matrix is whether it
is a reflection (determinant is -1) which reverses "handedness"
or a rotation (determinant is 1) which preserves "handedness".
Please feel free to correct any mistakes I made.
~~~~
Kami no Itte ga ore ni zettai naru!
system given the basis {v1, v2, v3}.
if (v1 x v2) . v3 > 0, then it''s right-handed.
if (v1 x v2) . v3 < 0, then it''s left-handed.
However, the rotation matrix ITSELF has no notion of "handedness".
Since it is orthogonal (orthonormal), it preserves lengths
and angles, hence the coordinate system. That''s all.
The most you can say about a rotation matrix is whether it
is a reflection (determinant is -1) which reverses "handedness"
or a rotation (determinant is 1) which preserves "handedness".
Please feel free to correct any mistakes I made.
~~~~
Kami no Itte ga ore ni zettai naru!
神はサイコロを振らない!
quote:
Original post by tangentz
I agree that you can test the "handedness" of a coordinate
system given the basis {v1, v2, v3}.
if (v1 x v2) . v3 > 0, then it''s right-handed.
if (v1 x v2) . v3 < 0, then it''s left-handed.
However, the rotation matrix ITSELF has no notion of "handedness".
Since it is orthogonal (orthonormal), it preserves lengths
and angles, hence the coordinate system. That''s all.
The most you can say about a rotation matrix is whether it
is a reflection (determinant is -1) which reverses "handedness"
or a rotation (determinant is 1) which preserves "handedness".
Please feel free to correct any mistakes I made.
~~~~
Kami no Itte ga ore ni zettai naru!
tangentz, you''re absolutely correct,

Graham Rhodes
Senior Scientist
Applied Research Associates, Inc.
Graham Rhodes Moderator, Math & Physics forum @ gamedev.net
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement