Transformation Matrices

# Introduction

Transformation matrices are used to describe the position and orientation of one coordinate frame with respect to another. The matrix is made of a position vector and a rotation matrix.

# Position Vector

A position vector is simply the coordinates of one frame compared to another. In robotics cartesian coordinates are generally used to describe position as follows:

(1)
\begin{align} o_{1}^{0} = \left[ { \begin{array}{ccc} \Delta x \\ \Delta y \\ \Delta z \end{array} } \right] \end{align}

# Rotations

It is not possible to represent a rotation of coordinate systems with a vector, because the comutativity rule will not hold. This is illustrated by the book in Fig. 1 [1]. The same rotations are made for each case, just in a different order.

Figure 1 [1]

## Rotation Matrix

The rotation matrix is used to describe rotations of coordinate systems. The formulation assumes right-handed angle measurements. The rotation matrix describing the projection of coordinate $o_{1}x_{1}y_{1}z_{1}$ onto $o_{0}x_{0}y_{0}z_{0}$ is given by:

(2)
\begin{align} R_{1}^{0} = \left[ { \begin{array}{ccc} x_{1} \cdot x_{0} & y_{1} \cdot x_{0} & z_{1} \cdot x_{0} \\ x_{1} \cdot y_{0} & y_{1} \cdot y_{0} & z_{1} \cdot y_{0} \\ x_{1} \cdot z_{0} & y_{1} \cdot z_{0} & z_{1} \cdot z_{0} \end{array} } \right] \end{align}

Because of its form it has the following special properties:

• $\mid R \mid = 1$
• $R^{T} = R^{-1}$
• Rows and Columns are orthogonal

### Basic Rotation Matrices

Basic rotation matrices describe the rotation around one axis. The three basic rotation matrices are:

(3)
\begin{align} R_{x, \theta} = \left[ { \begin{array}{ccc} 1 & 0 & 0 & 0 & cos\theta & -sin \theta \\ 0 & sin\theta & cos \theta \\ \end{array} } \right] \end{align}
(4)
\begin{align} R_{y, \theta} = \left[ { \begin{array}{ccc} cos\theta & 0 & sin \theta \\ 0& 1 & 0\\ -sin \theta & 0 & cos\theta \end{array} } \right] \end{align}
(5)
\begin{align} R_{z, \theta} = \left[ { \begin{array}{ccc} cos\theta & -sin \theta & 0 \\ sin \theta& cos\theta & 0\\ 0 & 0 & 1 & \end{array} } \right] \end{align}

### Composition of Basic Rotation Matrices

Any complex rotation can be decomposed into a number of simple one axis rotations which can be combined through multiplication. Post multiplication is used to combine rotation matrices relative to the current frame [2] :

(6)
$$p^{0} = R_{1}^{0}p^{1}$$
(7)
$$p^{1} = R_{2}^{1}p^{2}$$
(8)
$$p^{0} = R_{2}^{0}p^{2}$$
(9)
$$p^{0} = R_{1}^{0} R_{2}^{1}p^{2}$$

Athough less common, rotations are also possible about fixed axes, in which premultiplication is used.

# Transformation Matrix

The transformation matrix is a way to express the position and pose of a body in one matrix. Once $o_{1}^{0}$ and $R_{1}^{0}$ are know transformation matrix $T_{1}^{0}$ can be written as:

(10)
\begin{align} T_{1}^{0} = \left[ { \begin{array}{cccc} R_{11} & R_{12} & R_{13} & o_{1} \\ R_{21} & R_{22} & R_{23} & o_{2} \\ R_{31} & R_{32} & R_{33} & o_{3} \\ 0 & 0 & 0 & 1 \end{array} } \right] \end{align}

Transformation matrices can be combined through post multiplication like rotation matrices.

Bibliography
1. Baruh, H. (1999). Analytical Dynamics. McGraw-Hill.
2. Spong, M. W., et.al. (2006). Robot Modeling and Control. Hoboken: John Wiley & Sons, Inc.
page revision: 11, last edited: 22 Dec 2010 20:57