Three-dimensional rotation operator

From HandWiki - Reading time: 6 min

This article derives the main properties of rotations in 3-dimensional space.

The three Euler rotations are one way to bring a rigid body to any desired orientation by sequentially making rotations about axis' fixed relative to the object. However, this can also be achieved with one single rotation (Euler's rotation theorem). Using the concepts of linear algebra it is shown how this single rotation can be performed.

Mathematical formulation

Let (ê1, ê2, ê3) be a coordinate system fixed in the body that through a change in orientation A is brought to the new directions 𝐀e^1,𝐀e^2,𝐀e^3.

Any vector x¯=x1e^1+x2e^2+x3e^3 rotating with the body is then brought to the new direction 𝐀x¯=x1𝐀e^1+x2𝐀e^2+x3𝐀e^3,

that is to say, this is a linear operator

The matrix of this operator relative to the coordinate system (ê1, ê2, ê3) is [A11A12A13A21A22A23A31A32A33]=[e^1|𝐀e^1e^1|𝐀e^2e^1|𝐀e^3e^2|𝐀e^1e^2|𝐀e^2e^2|𝐀e^3e^3|𝐀e^1e^3|𝐀e^2e^3|𝐀e^3].

As k=13AkiAkj=𝐀e^i|𝐀e^j={0,ij,1,i=j, or equivalently in matrix notation [A11A12A13A21A22A23A31A32A33]T[A11A12A13A21A22A23A31A32A33]=[100010001], the matrix is orthogonal and as a right-handed base vector system is reorientated into another right-handed system the determinant of this matrix has the value 1.

Rotation around an axis

Let (ê1, ê2, ê3) be an orthogonal positively oriented base vector system in R3. The linear operator "rotation by angle θ around the axis defined by ê3" has the matrix representation

[Y1Y2Y3]=[cosθsinθ0sinθcosθ0001][X1X2X3] relative to this basevector system. This then means that a vector x¯=[e^1e^2e^3][X1X2X3] is rotated to the vector y¯=[e^1e^2e^3][Y1Y2Y3] by the linear operator. The determinant of this matrix is det[cosθsinθ0sinθcosθ0001]=1, and the characteristic polynomial is |cosθλsinθ0sinθcosθλ0001λ|=((cosθλ)2+sin2θ)(1λ)=λ3+(2cosθ+1)λ2(2cosθ+1)λ+1.

The matrix is symmetric if and only if sin θ = 0, that is, for θ = 0 and θ = π. The case θ = 0 is the trivial case of an identity operator. For the case θ = π the characteristic polynomial is (λ1)(λ+1)2, so the rotation operator has the eigenvalues λ=1,λ=1.

The eigenspace corresponding to λ = 1 is all vectors on the rotation axis, namely all vectors x¯=αe^3,<α<.

The eigenspace corresponding to λ = −1 consists of all vectors orthogonal to the rotation axis, namely all vectors x¯=αe^1+βe^2,<α<,<β<.

For all other values of θ the matrix is not symmetric and as sin2 θ > 0 there is only the eigenvalue λ = 1 with the one-dimensional eigenspace of the vectors on the rotation axis: x¯=αe^3,<α<.

The rotation matrix by angle θ around a general axis of rotation k is given by Rodrigues' rotation formula. 𝐑=𝐈cosθ+[𝐤]×sinθ+(1cosθ)𝐤𝐤T, where I is the identity matrix and [k]× is the dual 2-form of k or cross product matrix, [𝐤]×=[0k3k2k30k1k2k10].

Note that [k]× satisfies [k]×v = k × v for all vectors v.

The general case

The operator "rotation by angle θ around a specified axis" discussed above is an orthogonal mapping and its matrix relative to any base vector system is therefore an orthogonal matrix. Furthermore its determinant has the value 1. A non-trivial fact is the opposite, that for any orthogonal linear mapping in R3 with determinant 1 there exist base vectors ê1, ê2, ê3 such that the matrix takes the "canonical form" [cosθsinθ0sinθcosθ0001] for some value of θ. In fact, if a linear operator has the orthogonal matrix [A11A12A13A21A22A23A31A32A33] relative to some base vector system (1, 2, 3), we can distinguish two cases.

Symmetric matrix case The "symmetric operator theorem" (Spectral theorem) valid in Rn (any dimension) applies saying that it has n orthogonal eigenvectors. This means for the 3-dimensional case that there exists a coordinate system ê1, ê2, ê3 such that the matrix takes the form [B11000B22000B33].

As it is an orthogonal matrix these diagonal elements Bii are either 1 or −1. As the determinant is 1 these elements are either all 1 or one of the elements is 1 and the other two are −1. In the first case it is the trivial identity operator corresponding to θ = 0. In the second case it has the form [100010001]

if the basevectors are numbered such that the one with eigenvalue 1 has index 3. This matrix is then of the desired form for θ = π.

Asymmetric matrix case If the matrix is asymmetric, the vector E¯=α1f^1+α2f^2+α3f^3, where α1=A32A232,α2=A13A312,α3=A21A122 is nonzero. This vector is an eigenvector with eigenvalue λ = 1. Setting e^3=E¯|E¯|

and selecting any two orthogonal unit vectors ê1 and ê2 in the plane orthogonal to ê3 such that ê1, ê2, ê3 form a positively oriented triple, the operator takes the desired form with cosθ=A11+A22+A3312,sinθ=|E¯|.

The expressions above are in fact valid also for the case of a symmetric rotation operator corresponding to a rotation with θ = 0 or θ = π. But the difference is that for θ = π the vector

E¯=α1f^1+α2f^2+α3f^3

is zero and of no use for finding the eigenspace of eigenvalue 1, and thence the rotation axis.

Defining E4 as cos θ the matrix for the rotation operator is 1E4E12+E22+E32[E1E1E1E2E1E3E2E1E2E2E2E3E3E1E3E2E3E3]+[E4E3E2E3E4E1E2E1E4],

provided that E12+E22+E32>0. That is, except for the cases θ = 0 (the identity operator) and θ = π.

Quaternions

Quaternions are defined similar to E1, E2, E3, E4 with the difference that the half angle θ/2 is used instead of the full angle θ. This means that the first 3 components q1, q2, q3 components of a vector defined from q1f^1+q2f^2+q3f^1=sinθ2,e^3=sinθ2sinθ,E¯, and that the fourth component is the scalar q4=cosθ2.

As the angle θ defined from the canonical form is in the interval 0θπ, one would normally have that q4 ≥ 0. But a "dual" representation of a rotation with quaternions is used, that is to say (q1, q2, q3, q4)}} and (−q1, −q2, −'q3, −q4) are two alternative representations of one and the same rotation.

The entities Ek are defined from the quaternions by E1=2q4q1,E2=2q4q2,E3=2q4q3,[8px]E4=q42(q12+q22+q32).

Using quaternions the matrix of the rotation operator is [2(q12+q42)12(q1q2q3q4)2(q1q3+q2q4)2(q1q2+q3q4)2(q22+q42)12(q2q3q1q4)2(q1q3q2q4)2(q2q3+q1q4)2(q32+q42)1].

Numerical example

Consider the reorientation corresponding to the Euler angles α = 10°, β = 20°, γ = 30° relative to a given base vector system (1, 2, 3). The corresponding matrix relative to this base vector system is (see Euler angles) [0.7712810.6337180.0593910.6130920.7146100.3368240.1710100.2961980.939693], and the quaternion is (0.171010,0.030154,0.336824,0.925417).

The canonical form of this operator [cosθsinθ0sinθcosθ0001] with θ = 44.537° is obtained with e^3=(0.451272,0.079571,0.888832).

The quaternion relative to this new system is then (0,0,0.378951,0.925417)=(0,0,sinθ2,cosθ2).

Instead of making the three Euler rotations 10°, 20°, 30° the same orientation can be reached with one single rotation of size 44.537° around ê3.

References

  • Shilov, Georgi (1961), An Introduction to the Theory of Linear Spaces, Prentice-Hall, Library of Congress 61-13845 .





Licensed under CC BY-SA 3.0 | Source: https://handwiki.org/wiki/Three-dimensional_rotation_operator
3 views | Status: cached on February 01 2026 14:54:56
↧ Download this article as ZWI file
Encyclosphere.org EncycloReader is supported by the EncyclosphereKSF