2.2 Day 2 Reflections and Rotations combined with Scaling
The concept of transformations inspired art by M.C. Escher
Reflections
Consider a line L through the origin. We saw yesterday that and vector in R2 can be written as the sum of components perpendicular and parallel that line
If we consider the parallel component minus two times the perpendicular component, The result if a resultant vector that is the a reflection of the original vector over line L
You will need this formula in your notes
Problem 7
Solution to problem 7
Formula
Reflections over a vector (line)
The matrix of transformation is given by the formula:
Where
Please note that this matrix has the following form:
Note u1 and u2 are components of a unit vector pointing in the direction of line of reflection. (will prove as next problem)
Note: this only works for vectors in R2 while other formula works for in Rn
Problem 13
Solution to Problem 13
Reflections
Find the matrix of projection through
Use the matrix
Find the matrix of reflection over
For reflections in 3 D space Reflecting a Vector over a plane
Formula for reflection over a plane:
Note: u is a unit vector perpendicular (normal) to the plane
Add this formula to your notes
Example 3
Note: we are reflecting the vector x about a plane
Solution to example 3Formula:
Recall: Rotations
Note: We proved this in 2.1
The matrix of counterclockwise rotation in real 2 dimensional space through angle theta is
Note this is a matrix of the form
The matrix below represents a rotation. Find the angle of rotation
(in radians)
The matrix below represents a rotation. Find the angle of rotation
(in radians)
Answer: invcos(3/5)Or invsin (4/5)
Use the formula:
Rotations combined with Scaling
This is the same as the proof we did in 2.1 but now we don’t requirea2 + b2 = 1
Why does removing this requirement result in a rotation plus a scaling?
What matrices should we have in our library of basic matrices?
Identity Matrix
Projection Matrices
Projection onto x-axis
Projection onto y-axis
Rotation MatrixReflection Matrix
Rotation with ScalingOne directional ScalingMixed ScalingHorizontal ShearVertical Shear
How do you identify an unknown matrix?
1) Check your library of basic matrices.
2) Use your knowledge of matrix multiplication.
3) Plug in values. To be efficient use the elementary matrices.
Identify the following matrices
5 00 2
5/13 12/13-12/13 5/13
2 0 0 0
3/5 4/5
4/5 -3/5
1 0
2 1
1 -2
2 1
25/169 60/169
60/169 144/169
Identify the following matrices
An non-symmetricalProjection onto y=x
5 00 2
5/13 12/13-12/13 5/13
rotationCombined scaling
2 0 0 0
ProjectionOnto x-axis with scaling
3/5 4/5
4/5 -3/5
reflection
1 0
2 1
Vertical shear
1 -2
2 1
Rotation with scaling
25/169 60/169
60/169 144/169
projection
Homework
P. 65 7,11, 25,26 (d, e only) 27,28,32,34,37,38,39,
Rotations in R3
For more information on rotations visit:http://www.songho.ca/opengl/gl_projectionmatrix.html