
J Math Imaging Vis (2009) 35: 155–164 DOI 10.1007/s10851-009-0161-2 Metrics for 3D Rotations: Comparison and Analysis Du Q. Huynh Published online: 18 June 2009 © Springer Science+Business Media, LLC 2009 Abstract 3D rotations arise in many computer vision, com- efficiently represent 3D rotations and how to correctly eval- puter graphics, and robotics problems and evaluation of the uate the distance between them. If one of the 3D rotation distance between two 3D rotations is often an essential task. matrices is a true or reference rotation while the other is an This paper presents a detailed analysis of six functions for estimated one, then it is useful also to identify regions where measuring distance between 3D rotations that have been identical error measures occur. A few functions for distance proposed in the literature. Based on the well-developed the- measures between 3D rotations have been proposed in the ory behind 3D rotations, we demonstrate that five of them computer vision literature; however, there has neither been are bi-invariant metrics on SO(3) but that only four of them detailed analysis provided to these functions nor a compari- are boundedly equivalent to each other. We conclude that son of them in the context of the group SO(3) to which 3D it is both spatially and computationally more efficient to use rotations belong. The contributions of this paper are: (1) to quaternions for 3D rotations. Lastly, by treating the two rota- provide this missing information; (2) to analyze and illus- tions as a true and an estimated rotation matrix, we illustrate trate the iso-error contours of a given reference rotation. the geometry associated with iso-error measures. Rotations in 3D space can be represented in various forms. Euler angles are commonly used in robotics appli- Keywords Matrix Lie group · Lie algebra · Quaternions · cations where, because of constraints in the design of the 3D rotations · Distance functions joints of robot arms, rotations often have to be carried out in a certain order (e.g., [1];seealso[19]). For other ap- plications where such a constraint is absent, Euler angles 1 Introduction are less favoured, precisely because the values of these an- gles are dependent on the order of rotations about the three principal axes. For research in computer vision and com- 3D rotations are common entities in many computer vision, puter graphics, 3D rotations are commonly represented as computer graphics, and robotics problems that need to deal unit quaternions (e.g., [5, 15, 17, 18]), rotation axes and an- with the 3D world. Typical applications that involve 3D ro- gles (e.g., [8, 21]), or even as the 3 × 3 rotation matrices tations include the interpolation of trajectory of 3D orienta- themselves (e.g., [3, 4, 6]). The number of computer vision tions, robot kinematics, flight simulation, structure from mo- research papers that involve 3D rotations of any form is far tion, 3D pose recovery of objects, and motion capture. The too many to permit a complete list of citations. The refer- common issues that arise in these applications are how to ences given here are only a very small subset of papers in the literature. In terms of storage, each 3 × 3 rotation matrix requires This research was in part supported by a UWA study leave grant. the space of 9 floating point numbers, whereas in reality the D.Q. Huynh () special orthogonal group is a 3 dimensional object embed- School of Computer Science and Software Engineering, dable in R4. Another concern of the matrix representation The University of Western Australia, Nedlands, WA 6009, Australia is that after several matrix multiplications, round-off errors e-mail: [email protected] within computers can result in “rotation” matrices that are 156 J Math Imaging Vis (2009) 35: 155–164 no longer orthogonal. In that regard, the unit quaternions and noting that√ exp(tA) = I whenever t is an integer mul- are preferred as an alternative way of representing 3D ro- tiple of 2π/ 3. This example, however, suggests at least tations. Although round-off errors may also cause any unit some of the degree of non-uniqueness in the exponential quaternion to have a non-unit magnitude, it is more straight- parametrization. Indeed, the exponential parametrization of forward to renormalize it to unity in comparison with re- SO(3) corresponds exactly to the rotation axis and rota- orthogonalizing a distorted matrix. tion angle formulation. Given a rotation with rotation axis In the following sections, we will first give a brief u = (u1,u2,u3) of unit magnitude and rotation angle θ, overview of the special orthogonal group and the unit the 3 × 3 rotation matrix R can be obtained by the exponen- quaternions. This is then followed by the formal definition tial mapping exp([θu]×), where [ a ]× is chosen to be the of a distance function or metric. Six different functions for matrix defined by [a]×b = a × b. For example, the matrix in 3D rotations will then be studied in turn; their computation (4) corresponds to [(−1, 1, −1)]×. The group SO(3) is cov- complexity will be briefly analyzed. In Sect. 5, a geometrical ered by one-parameter groups (in fact circles) of the form interpretation of one of the functions will be studied further, {exp([θu]×) : θ ∈[−π,π)} and this representation is almost this leads to the discussion on iso-error contours. Finally in unique, since a rotation uniquely specifies its (unit vector) Sect. 6, we conclude the paper. rotation axis up to a multiplication by ±1, and once this is fixed, the angle is specified up to a multiple of 2π. It is straightforward to show that the Rodrigues formula 2 SO(3) and Unit Quaternions: An Overview (see, e.g., [11]) for a rotation matrix R as defined below 3D rotations form the so-called Special Orthogonal Group R = cos θ I + sin θ [u]× + (1 − cos θ)uu , (5) SO(3) of orthogonal matrices with determinant 1. SO(3) is a compact Lie group having the skew-symmetric matrices as is just a simplification of the exponential map given in (3) [ ] × its Lie algebra, so(3). This Lie algebra is a non-associative being applied to θu ×.Givena3 3 rotation matrix R, vector space equipped with a binary operation: the inverse of the exponential map provides a rotation an- gle/axis description of the rotation. Thus, log(R) is the [·, ·]:so(3) × so(3) → so(3), skew-symmetric matrix containing information about the ro- (1) tation axis and angle. Although the inverse process requires [A, B]=AB − BA a choice of rotation axis between the two alternatives, it is which can easily be seen to be a closed operation in so(3). a straightforward procedure to retrieve the rotation axis and The Lie algebra so(3) is the tangent space at the identity ele- angle (see Appendix A). ment of SO(3). The binary operation defined above is known As a unit quaternion, the same 3D rotation matrix [ ] ∈ ≡ ≡ Lie bracket exp( θu ×) SO(3) can be written as q (q0,q1,q2,q3) as the , which satisfies the following properties: (q0, q˜) [ ]=−[ ] =± θ θ A, B B, A , (cos 2 , u sin 2 ) . The unit quaternions are a one-to- (2) one parametrization of the Special Unitary group SU(2) and [A, [B, C]] + [C, [A, B]] + [B, [C, A]] = 0, the q above can be written as a 2 × 2 unitary matrix: for all A, B, C ∈ so(3). It follows immediately from the first q + iq q + iq property that [A, A]=0. 0 1 2 3 . (6) −q + iq q − iq In the theory of Lie groups, the exponential map is a map- 2 3 0 1 ping from the Lie algebra of a Lie group to the group itself. SU(2) provides a double-covering of SO(3); that is, each Such a mapping allows one to recapture the group structure rotation matrix in SO(3) corresponds to two members of from its Lie algebra. As in the general case of matrix Lie SU(2). The group homomorphism from SU(2) to SO(3) : → groups, the exponential map exp so(3) SO(3) is simply: has a two element kernel and this corresponds to the am- biguity in the choice of rotation axis in the logarithmic A2 A3 exp(A) = I + A + + +··· . (3) map. In this regard, we note that SU(2) and SO(3) have 2! 3! the same Lie algebra. The Lie algebra su(2), which con- For the special orthogonal group SO(3), the exponential map sists of the 2×2 skew-hermitian matrices, is isomorphic as a is surjective but not injective. The failure of injectivity is Lie algebra to so(3). Consider representing the rotation axis easily seen by considering a skew-symmetric matrix such as u = (u1,u2,u3) of unit magnitude and the rotation angle ⎡ ⎤ θ as a 2 × 2 skew-hermitian matrix, A, as follows: 011 A = ⎣−101⎦ (4) iθu θu + iθu A = 1 2 3 1 −10 −θu2 + iθu3 −iθu1 J Math Imaging Vis (2009) 35: 155–164 157 iu1 u2 + iu3 ˜ = θ ≡ θA. (7) = −u2 + iu3 −iu1 resp. Φ(R2R1, R3R1) Φ(R2, R3) (12) By applying the exponential mapping to A and noting that for R1, R2, R3 ∈ SO(3). A distance function is bi-invariant A2 =−θ 2I, we obtain a different version of the Rodrigues if it is both left and right invariant. formula: Two distance functions Φ and Ψ are said to be boundedly equivalent if there are positive real numbers a and b such exp : su(2) → SU(2), that sin θ exp(A) = cos θ I + A (8) aΦ(R , R ) ≤ Ψ(R , R ) ≤ bΦ(R , R ) (13) θ 1 2 1 2 1 2 ˜ = cos θ I + sin θ A.
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages10 Page
-
File Size-