Using Matrices to Perform Geometric Transformations Kendalyn Paulin.
-
Upload
aileen-irma-lyons -
Category
Documents
-
view
226 -
download
1
Transcript of Using Matrices to Perform Geometric Transformations Kendalyn Paulin.
Using Matrices to Perform Geometric Transformations
Kendalyn Paulin
Review of Basic Transformations
Translation Reflection Rotation Dilation
How do Matrices apply to Transformations?
Remember we can translate a figure up, down, left and right.
When we do that we are changing the x and y coordinates of the original figure
Translating a Figure
Say we have a triangle with coordinates: A(0,0), B(2,5) and C(7,-1) shown below. The Matrix form would look like this:
17
52
00
CC
BB
AA
yx
yx
yx
Translate
Say you want to translate the figure 4 units to the left and 3 units up. You can do this by adding the translation matrix to the original matrix. The result is the final coordinates of the new figure.
23
82
34
34
34
34
17
52
00
What is a Matrix?
A matrix is a 2D array of numbers which can have any width and height. The one below had a height and width of 2. So it is called a 2x2 matrix (said “two-by-two”).
dc
ba
cont
They are usually stated by their height first, then their width. The one below would be a 4x3 matrix.
lkj
ihg
fed
cba
Translation Matrices
Add these matrices to translate figure….
x
x
x
0
0
0
x
x
x
0
0
0Up x units Down x units
Right x units Left x units
0
0
0
x
x
x
0
0
0
x
x
x
Adding Matrices
Add the values of the corresponding positions to each other.
zdyc
xbwa
zy
xw
dc
ba
12
23
13
21
21
02Ex:
Adding Matrices
Can you add two matrices that are different sizes?
32
01
25
12
40+ = ?
Subtracting Matrices
How do you think we can subtract two matrices?
Is it the same process as addition? Why or why not?
Subtracting Matrices
Same as addition, but subtracting instead. Once again, matrices must be of the same size.
zdyc
xbwa
zy
xw
dc
ba
34
21
13
21
21
02Ex:
Original Triangle Dilated by a Factor of 2
Dilate a figure
In order to dilate a figure, scalar multiplication is used. To dilate the triangle by a factor of 2, just multiply the matrix by 2.
214
104
00
17
52
00
*2
Scalar Multiplication
In the scalar multiplication, every entry is multiplied by a number, called a scalar. In this example the number being multiplied by is 2.
dc
ba
dc
ba
*2*2
*2*2*2
02
44
01
22*2Ex:
Other Dilations
You can also dilate the figure by a fraction, this will make the triangle smaller. If you dilate by a factor ½, the triangle will be half as big as it originally was. You can investigate this on your own.
Multiplying Matrices
Multiplying matrices will be investigated in a later course. This lesson will only briefly show multiplication.
Here is what a resulting matrix looks like. We will use excel to do our multiplication matrices.
Example
)*()*()*(
)*()*()*(*
yfxewd
ycxbwa
y
x
w
fed
cba
(2X3) (3X1) (2X1)
*Don’t worry about being able to do this procedure. We will use excel!
Reflection and Rotation
These transformations will be investigated using Microsoft Excel.
We will review our findings in the next slides.
What transformation matrices to you multiply to do what?
Image stays the same
Reflect over x axis
Reflect over the y axis
10
01
10
01
10
01
What transformations?
Image dilates by 2
Rotates image 90 degrees clockwise
Dilates the image by a factor of 2 then rotates the image 90 degrees clockwise
01
10
02
20
20
02