You are on page 1of 8

Lecture 4

Rotation matrix and Transformation matrix


and its application in Dead Reckoning Navigation

 A rotation matrix, usually denoted by R, is used to describe the rotation of an object in 2-


dimensional (2D) or 3-dimensional (3D) space.
 The rotation matrix transforms the set of coordinates representing a 2D/3D object, in an
orthogonal Cartesian coordinate frame without changing the length of any vector and the angle
between any pair of vectors. Such a matrix is called an orthonormal matrix.
 The rotation matrix is used in the rotation of vectors while the coordinate system remains fixed,
and the term transformation matrix (denoted by T) is used to describe the rotation of a
coordinate system while an object remains fixed.

Example in a 2-dimensional case


Consider a 2D Cartesian coordinate frame, A, as shown in Figure 1, in which a point P with coordinates
is represented by a vector , with length r and angle .

Figure 1. Representation of a point P as a vector.

From Figure 1,

Equation (1)

Now, the vector is rotated by an angle as shown in Figure 2. Due to the rotation, the point P is
changed to a new point with coordinates and its vector has the same length r with an angle

.
Figure 2. Rotation of vector by an angle .

From Figure 2,

Equation (2)

Expanding equation (2),

Now, from equation (1),

Similarly,

= =
=
Therefore, ,

In matrix form, Equation (3)

where, = rotation matrix, R.

Therefore, in vector form, the rotation from P to with respect to the fixed axes is represented

by: .
Now, for a 3D case, look at the rotation in Figure 2 from top view so that the rotation happens in a plane
where the axes are present, which means the rotation is about the vertical axis or -axis. By
doing so, the z-coordinate will not change.
Therefore, by including the third axis, the rotation matrix for rotating a vector about the z-axis is given by

Now, let us see how a point fixed P is represented with respect to two coordinate systems, that is, rotation
of the coordinate axes when an object is fixed.
Consider the geometry shown in Figure 3 for a 2D plane with a Cartesian coordinate frame A of axes
where a point PA is located with coordinates .
Now, the coordinate axes are rotated by an angle to form a new coordinate frame B with axes
with the point P remaining fixed. Now, the point P with respect to frame B is PB with coordinates
.

Figure 3. Location of a point P with respect to two coordinate systems A and B.

Note that, even though the point P is fixed, the coordinates and are not the same,

meaning that = is with respect to frame A, and = is with respect to frame B.

In vector form, and .

To find , create a geometry from Figure 3 as shown below.


From the above geometry, OE = .
From right angle triangle ODC, .
Also, DE = CF.
And, from right angle triangle CFP, .
Now, OE = = OD + DE = + .

Now, to find , create a geometry again from Figure 3 as shown below.

From the above geometry, OG = .


From right angle triangle OKL, .
Also, KG = LH.
And, from right angle triangle LPH, .
Now, OG = = OK – KG = – .

Therefore, = + ,

= .
In matrix form, Equation (4)

where, = transformation matrix, T.

Therefore, in vector form, the relation between the fixed point P with respect to coordinate systems A and
B is given by,
. Equation (5)

Equation (5) indicates that the coordinates is transformed into coordinates using the
transformation matrix, T. In other words, the coordinate system A is transformed into the coordinate
system B using the transformation matrix T.

Two important properties of Rotation matrix and Transformation matrix


Property 1: The transpose of a rotation matrix or transformation matrix is equivalent to its inverse and
vice versa.

Consider a rotation matrix, R = .

Now, multiply R and its transpose, =

= = identity matrix, I

And, we know that multiplying a matrix with its inverse will give an identity matrix.
Therefore, =I= . From that, we get = .

Property 2: The determinant of a rotation matrix or transformation matrix is always equal to 1.

The determinant (det) of a rotation matrix, R = is =

= = 1.
This means the area (or volume) bounded by the axes remains constant. By looking at the figure shown
below, in which the axes covering an area A1 is rotated by a rotation matrix R to get the axes
with area A2, which is the same as area A1.
Inference from Property 1
With reference to Figure 3, equation (5) describes the transformation of coordinate system A into
coordinate system B using the transformation matrix T.
Similar way, the transformation from coordinate system B to A is achieved by = .

Therefore, .

In other words, one coordinate system can be converted into another by multiplying its coordinates with
the transformation matrix.

Application of the transformation matrix in dead reckoning navigation


Dead reckoning navigation is a navigation method used in vehicles in which the vehicle’s present
position is determined from the previous position using the present information of sensor measurements
(velocity and/or acceleration), elapsed time, and direction of travel.
Let us consider an example of finding the position of a ground vehicle in 2-dimensional space, as shown
below.

In order to locate the position of the vehicle, we need to select a coordinate system. Here, the coordinate
system used is the North (N)-East (E) coordinate system. For simplicity, let us assume the starting point
of the vehicle is at the origin of the coordinate system O (0 m, 0 m). And, assume the vehicle is travelling
exactly towards the north direction with a constant velocity of 10 m/s.
At time 1 (t = 1 second), the velocity measurement is available from the velocity sensor in the vehicle,
and it is noted as 10 m/s. Therefore, from the velocity and the elapsed time of 1 second, the distance
travelled is 10 meters (position 1). Now, after another 1 second (at time 2), the sensor is providing a
measurement of 10 m/s. Therefore, again from the velocity value (10 m/s) and the time elapsed (1
second), the distance travelled is another 10 meters (position 2).
But, the total distance travelled with respect to the starting point is not 10 meters. So, in order to get that,
the present position (distance travelled) should be added with the previous position value (10 meters).
From that, the total distance travelled from the starting point is 10 + 10 = 20 meters. That is why, for dead
reckoning navigation, the previous position is required.
Even though we know the starting point and the distance travelled by the vehicle, we are still not getting a
clear picture of the vehicle’s position because it is not represented in the selected coordinate system.

Therefore, the proper way of representing the position of the vehicle is as follows:
20 meters North (x-axis), 0 meters East (y-axis) with respect to the starting point.
For this simple case, the vehicle does not take any turns, so there is no need for the transformation matrix
to be used. Now, consider the realistic case where the vehicle can travel in any direction.
Now, introducing a body-fixed coordinate system for the vehicle (shown in Figure 4) which is fixed with
the body of the vehicle, meaning that the coordinate system will move along with the vehicle’s motion.
The sensors that are mounted on the body of the vehicle will also give the measurements in the body
coordinate system.
With that, the position of the vehicle in the two coordinate frames is as follows:

In north-east coordinate frame: , and in body coordinate frame: .

Figure 4. Body coordinate system.

Let us assume the following case in which the vehicle is travelling at the same constant velocity of 10 m/s
in the direction indicated by the blue arrow mark (in between the north and east directions) as shown
below.

For understanding the concept, I have assumed the vehicle has travelled 20 m in its direction (after 2
seconds), and 16 m to the east. With trigonometry, the remaining values can be calculated and are shown
in the geometry. Now, the vehicle is at its current position, A. At that position, the angle between the true
north (N) and the vehicle’s forward direction (coarse) is called the heading angle, , which is available
from the attitude/heading sensor and is noted as 53.13 degrees.
Now, with a velocity value of 10 m/s and an elapsed time of 2 seconds, the distance travelled is 20
meters.
Therefore, in body coordinate system:

Velocity, = ,

Position (distance travelled), =

But, the required position should be in the N-E coordinate system. Therefore, the current values in the
body frame can be converted into the N-E frame through a counter-clockwise rotation by the angle as
follows:

= , where = transformation matrix

= =

= =

From this, the position expressed in the N-E coordinate system is 12 meters north (x-axis) and 16 meters
east (y-axis) with respect to the starting point.

Also, the position can be obtained after converting the velocity from the body frame to the N-E frame as
follows:

= =

= = m/s.

From that, using the elapsed time of 2 seconds, the position will be = meters.

Note:
Depending on the direction of rotation (clockwise or counter-clockwise), the sign of the sine term in the
rotation/transformation matrix will be interchanged.

For further clarifications on the content, feel free to send your queries to: senthil.avionics@gmail.com

You might also like