quaternion-conventions
quaternion-conventions copied to clipboard
An overview of different quaternion implementations and their chosen order: x-y-z-w or w-x-y-z?
Quaternion Order Conventions
Quaternions are expressions of the form w + x i + y j + z k, with x i + y j + z k being the vector/imaginary part and w the scalar/real part. Math libraries differ in the way they order the vector and real part of a quaternion. This can lead to bothersome debugging sessions.
The following table shows quaternion implementations and their chosen order:
X-Y-Z-W
(scalar-last format) vs. W-X-Y-Z 