Three-dimensional rotation operator

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.

## Contents

* 1 Mathematical formulation
* 1.1 Rotation around an axis
* 1.2 The general case
* 2 Quaternions
* 3 Numerical example
* 4 References

## 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^1⟩⟨e^1|𝐀e^2⟩⟨e^1|𝐀e^3⟩⟨e^2|𝐀e^1⟩⟨e^2|𝐀e^2⟩⟨e^2|𝐀e^3⟩⟨e^3|𝐀e^1⟩⟨e^3|𝐀e^2⟩⟨e^3|𝐀e^3⟩].

As ∑k=13AkiAkj=⟨𝐀e^i|𝐀e^j⟩={0,i≠j,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⁡θ+(1−cos⁡θ)𝐤𝐤T, where I is the identity matrix and [k]× is the dual 2-form of k or cross product matrix, [𝐤]×=[0−k3k2k30−k1−k2k10].

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 (f̂1, f̂2, f̂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 [−1000−10001]

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=A32−A232,α2=A13−A312,α3=A21−A122 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+A33−12,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 1−E4E12+E22+E32[E1E1E1E2E1E3E2E1E2E2E2E3E3E1E3E2E3E3]+[E4−E3E2E3E4−E1−E2E1E4],

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

## Quaternions

Main article: Quaternions and spatial rotation

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(q1q2−q3q4)2(q1q3+q2q4)2(q1q2+q3q4)2(q22+q42)−12(q2q3−q1q4)2(q1q3−q2q4)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 (f̂1, f̂2, f̂3). The corresponding matrix relative to this base vector system is (see Euler angles) [0.771281−0.6337180.0593910.6130920.714610−0.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 .

0.00

(0 votes)

|

Retrieved from "https://handwiki.org/wiki/index.php?title=Three-dimensional_rotation_operator&oldid=196661"