Linear Transformations & Rotations Explained
Linear Transformations & Rotations Explained
Outline
Centre de la Imatge i la Tecnologia Multimèdia
4 Degrees of freedom in
Rotations
1 Attitude representation
5 Dualism with change of
2 Linear transformations basis
7 Homework
Outline
Centre de la Imatge i la Tecnologia Multimèdia
4 Degrees of freedom in
Rotations
1 Attitude representation
5 Dualism with change of
2 Linear transformations basis
7 Homework
Attitude
Centre de la Imatge i la Tecnologia Multimèdia
What is it?
Definition
Attitude is a term used in geometry that refers to the orientation of a
body in space.
Attitude
Centre de la Imatge i la Tecnologia Multimèdia
Intro
Outline
Centre de la Imatge i la Tecnologia Multimèdia
4 Degrees of freedom in
Rotations
1 Attitude representation
5 Dualism with change of
2 Linear transformations basis
7 Homework
Linear Transformation
Centre de la Imatge i la Tecnologia Multimèdia
What is?
Definition
A Linear Transformation is a Multivariate function that transforms the
space maintaining the origin,
T : Rn −→ Rm
Property
If a, b ∈ Rn , T is a Linear Transformation iff
T (a + b) = T (a) + T (b)
T (λ · a) = λ · T (a)
Example
x1 + 2x2
Is T (x) = T (x1 , x2 , x3 ) = 3x3 a linear transformation?
−x1 + x3
Linear Transformation
Centre de la Imatge i la Tecnologia Multimèdia
Some exercises
Linear Transformation
Centre de la Imatge i la Tecnologia Multimèdia
Some exercises
Exercise 2
x1 1
Find x subject to T (x) = T x2 = −1 if T (x) is a
x3 1
linear transformation and
1 3 1 0 −1 5
T 1 = 4 , T −1 = 0 , T
2 = −5
−1 2 0 3 3 0
Linear transformation
Centre de la Imatge i la Tecnologia Multimèdia
Matrix form
Proposition
A Transformation T (x) is Linear ⇐⇒ it is possible to find a matrix A
s.t. T (x) = Ax
.. .. ..
. . .
a 1
A= a2 ··· an
.. .. ..
. . .
T (x) = Ax = x1 a 1 + x2 a 2 + · · · + xn a n ∈ Rm
Linear transformation
Centre de la Imatge i la Tecnologia Multimèdia
Matrix form
Then
T (x) = x1 T (e 1 ) + x2 T (e 2 ) + · · · + xn T (e n ) ⇒
.. .. ..
. . .
T (x) = T (e 1 ) T (e 2) · · · x =: Ax
T (e n )
.. .. ..
. . .
Outline
Centre de la Imatge i la Tecnologia Multimèdia
4 Degrees of freedom in
Rotations
1 Attitude representation
5 Dualism with change of
2 Linear transformations basis
7 Homework
Rotation
Centre de la Imatge i la Tecnologia Multimèdia
What is?
Definition
A Rotation is a especial Linear Transformation in the same dimension n
R : Rn −→ Rn
that preserves
Distances (vector norm)
Angles (dot product)
Volumes (triple product)
Rotation
Centre de la Imatge i la Tecnologia Multimèdia
An aside
Definitions
Vector norm Length of a vector
√ √
kxk = x1 + x2 + · · · xn = xT x
x · y = x T y = x1 y1 + x2 y2 + · · · xn yn = kxkky k cos α
x T (y × z)
Outline
Centre de la Imatge i la Tecnologia Multimèdia
4 Degrees of freedom in
Rotations
1 Attitude representation
5 Dualism with change of
2 Linear transformations basis
7 Homework
DoFs in Rotations
Centre de la Imatge i la Tecnologia Multimèdia
In R3
leading to 3 DoF.
DoFs in Rotations
Centre de la Imatge i la Tecnologia Multimèdia
In R3
Equivalent restrictions
The 6 restrictions over matrix R about orthonormality are equivalent to
state that,
det(R) = 1, and
R| = R−1
DoFs in Rotations
Centre de la Imatge i la Tecnologia Multimèdia
An aside (II)
DoFs in Rotations
Centre de la Imatge i la Tecnologia Multimèdia
Three Exercises
Geometric meaning
Let R(v ) = Rv represent a rotation of 90 degs about the z
axis.
1 What are the elements in matrix R for this case? (Hint: z
remains, x goes to y and y goes to −x)
|
2 Which are the images for the vectors, v1 = (1, 0, 0) ,
| | |
v2 = (0, 1, 0) , v3 = (0, 0, 1) , and v4 = (−1, 2, 2) ?
3 Which rotation matrix R performs the inverse rotation?
Outline
Centre de la Imatge i la Tecnologia Multimèdia
4 Degrees of freedom in
Rotations
1 Attitude representation
5 Dualism with change of
2 Linear transformations basis
7 Homework
Change of basis
C
B2 −
→ B1
Exercise
Applying dualism, rotates vector x like in the previous
exercise, i.e. rotates 90 degs about the z axis.
Take care I
Centre de la Imatge i la Tecnologia Multimèdia
Rotations & change of basis
Take the rotation matrix
1 −1 0
1
R = √ 1 1 √0 ,
2 0 0 2
| √ |
and the vector p = (1, 0, 1) , then: p 0 = Rp = √1
2
1, 1, 2
Rotations
If we are talking about rotations, we meant
Take care II
Centre de la Imatge i la Tecnologia Multimèdia
Rotations & change of basis
Take the rotation matrix
1 −1 0
1
R= √ 1 1 √0 ,
2 0 0 2
| √ |
and the vector Ap = (1, 0, 1) , then: B
p = R Ap = √1 1, 1, 2
2
Change of basis
If we are talking about change of basis, we meant
Outline
Centre de la Imatge i la Tecnologia Multimèdia
4 Degrees of freedom in
Rotations
1 Attitude representation
5 Dualism with change of
2 Linear transformations basis
7 Homework
Concatenation
Centre de la Imatge i la Tecnologia Multimèdia
Linear transforms
Definition
Let T1 (x) = Ax and T2 (x) = Bx be linear transformations, then the
concatenation
T2 (T1 (x)) = BAx
is also a linear transformation.
Note the order!!!, BA 6= AB
The same definition applies to rotations.
Outline
Centre de la Imatge i la Tecnologia Multimèdia
4 Degrees of freedom in
Rotations
1 Attitude representation
5 Dualism with change of
2 Linear transformations basis
7 Homework
Exercise 1
Centre de la Imatge i la Tecnologia Multimèdia
Homework
Exercise 1
Given the next two transformations, find which of them are linear
transformations and which of them are rotations and argument why.
1 T1 (x) : R3 → R3
√
3
2 x1 + x2
T1 (x) = 3 − x3 + √13
x1
2 T2 (x) : R3 → R3
√
1 2
(x√1 + x3 ) − 2 x2
2
T2 (x) = 2
2 (x3 − x2 )
1 √1 x2
2 (x 1 + x 3 ) + 2
Exercise 2
Centre de la Imatge i la Tecnologia Multimèdia
Homework
Exercise 2
Two vectors v1 and v2 have known components on two orthonormal basis
{A} and {B}
| √ |
A
v 1 = (1, 0, 0) B
v 1 = 12 √3, 1, 0 √
A | |
v 2 = (1, 1, 0) B
v 2 = 12 3 − 1, 1 + 3, 0
Exercise 3
Centre de la Imatge i la Tecnologia Multimèdia
Homework
Exercise 3
The matrix
a1 −0.2655 −0.2113
R = a2 0.9640 −0.0726
a3 a4 0.9747
represents a rotation. Which are the values of a1 , a2 , a3 and a4 ?