by gizmo686 · 9y ago · 0 comments
No you don't. You might notice this by simply working with imaginary numbers. You might invent imaginary numbers for rotation [0].
Alternatively, consider the multiplication (x + yi)(a + bi), as the value (a + bi) performing a transformation on (x + yi). We want (x + yi)(a + bi) = xy - by + ayi + bxi. If we consider (x + yi) to be a 2 dimensional matrix (with basis 1 and i), we can write the above equation as a matrix multiplication:
[ x y ] [ a b ] = [ ax-by ; ay + bx]
-b a
Notice that [ a b ]
-b a
is just a rotation matrix multiplied by the scalar (a^2 + b^2).[0] That is, define a group (in the group-theory sense) of functions of rotations, denoted as xi for real numbers x, and a group of group of functions for sliding, denoted x for real numbers x. You might then notice that you can combine these groups in a field structure, that happens to have 1i * 1i = -1, and that the subfield of elements with no i component happens to be isomorphic the the reals.
Topologically, unit complex numbers are the unit circle which is connected, and 1 is part of this circle so all of these transformations must have determinant 1: these are rotations.
No Euler formula.
It's also fun to introduce e as a matrix operator for 3d rotations.
It's useful for kinematics and having compact representations for axis angle notations. It's a little far in my head but at some point it felt like a ha-ha moment with the Euler identity, in the "2d version".
(At least if you’re ever needing to compose rotations; to apply a quaternion to a big array of 3-vectors, go ahead and convert it to a 3x3 matrix first, which should end up slightly more efficient.)
3x3 rotation matrices are really hard to keep normalized properly, whereas quaternions are trivial to normalize (just divide by the norm).
If you need to compress a unit quaternion down to 3 numbers, instead of taking the logarithm (which is computationally expensive and a pain to deal with) use the stereographic projection.
Imaginary numbers can be represented with a 2x2 skew symmetric matrix with no stretch of the imagination at all. And 3x3 skew symmetric matrixes represent rotations most compactly with only 3 actual variables. Instead of 4 for quaternions, 9 for "classic rotation matrixes", or the need to tell which is the order of the angles if you're given 3 euler angles.
There are interesting applications of Lie Algebra on SO(3) [1], notably in computer vision where a global energy is minimized across two successive rgb-d "shots" in order to recover the infinitesimal rotation [2]. It's going to be easier to minimize energy on something that is most compactly defined, and always amounts to a valid rotation.
[1] https://en.wikipedia.org/wiki/Rotation_group_SO(3)#Lie_algeb... [2] https://vision.in.tum.de/_media/spezial/bib/kerl13icra.pdf