These matrices ( A & B ) both qualify as being orthogonal.

\[ \left [ \begin{matrix} 1 &0 &0 \\ 0 &1 &0 \\ 0 &0 &1 \end{matrix} \right ] \]

\[ \left [ \begin{matrix} -1 &0 &0 \\ 0 &1 &0 \\ 0 &0 &1 \end{matrix} \right ] \]

Furthermore, my code says their quaternion representation is actually the same ( both the identity quaternion). glm gives me { 1/sqrt(2), 0, 0, 0 } for B curiously.

Also I know that det(A) = 1 and det(B) = -1

So I guess that orthogonal matrices have some sort of "sign" property to them, that gives the handedness of the basis? And how this work with quaternions? I suspect it might have some relation to the famous 'double cover' property of quaternions that people always mention. Basically the fact that Q and -Q correspond to the same rotation. I also wonder if this works for complex numbers as well as they're the 2d equivalent of quaternions.

Are there any other properties involving this 'sign'? I have a vague feeling it had something to do with the diagonal as well.

Maybe someone here has some deeper insights or facts to share about this