2.2 LINEAR TRANSFORMATIONS IN GEOMETRY

2.2 Linear Transformations in Geometry
2.2
55
LINEAR TRANSFORMATIONS IN GEOMETRY
0 −1
In Example 2.1.5 we saw that the matrix
represents a counterclockwise
1
0
◦
rotation through 90 in the coordinate plane. Many other 2 × 2 matrices define
simple geometrical transformations as well; this section is dedicated to a discussion
of some of those transformations.
EXAMPLE 1
Consider the matrices
2 0
1 0
−1 0
, B=
, C=
,
0 2
0 0
0 1
0 1
1 0.5
1 −1
D=
, E=
, and F =
.
−1 0
0
1
1
1
A=
Show the effect of each of these matrices on our standard letter L,3 and describe
each transformation in words.
a.
0
4
0
2
A=
2 0
0 2
1
0
2
0
The L gets enlarged by a factor of 2; we will call this transformation a scaling by
2.
b.
0
2
B=
1
0
1 0
0 0
1
0
The L gets smashed into the horizontal axis. We will call this transformation the
projection onto the horizontal axis.
3
See Example 2.1.5. Recall that vector
0
1
is its back.
is the foot of our standard L, and
2
0
56 CHAPTER 2 Linear Transformations
c.
0
2
0
2
C=
−1 0
0 1
−1
0
1
0
The L gets flipped over the vertical axis. We will call this the reflection about
the vertical axis.
d.
0
2
D=
0 1
−1 0
2
0
1
0
0
−1
The L is rotated through 90◦ , in the clockwise direction (this amounts to a rotation through −90◦ ). The result is the opposite of what we got in Example 2.1.5.
e.
0
2
1
2
E=
1 0.5
0 1
1
0
1
0
The foot of the L remains unchanged, while the back is shifted horizontally to
the right; the L is italicized, becoming L. We will call this transformation a horizontal shear.
f.
−2
2
0
2
F=
1 −1
1 1
1
1
1
0
There are two things going on here: The L is rotated through 45◦ and also en-
57
2.2 Linear Transformations in Geometry
√
larged (scaled) by a factor of 2. This is a rotation combined with a scaling
(you may perform the two transformations in either order). Among all the possible composites of the transformations considered in parts (a) through (e), this one is
particularly important in applications as well as in pure mathematics (see Fact 7.5.3,
■
for example).
We will now take a closer look at the six types of transformations we encountered
in Example 1.
Scalings
k 0
defines a scaling by k, since
0 k
k 0
k 0
x1
kx1
x
x =
=
= k 1 = k x.
0 k
0 k
x2
kx2
x2
For any positive constant k, the matrix
This is a dilation (or enlargement) if k exceeds 1, and it is a contraction (or shrinking) for values of k between 0 and 1.
Projections
Consider a line L in the plane, running through the origin. Any vector x in R2 can
be written uniquely as
x = x + x⊥ ,
where x is parallel to line L, and x⊥ is perpendicular to L. See Figure 1.
x
x⊥ (translated)
x
L⊥
L
L
x⊥
xll
xll
O
O
Figure 1
Figure 2
The transformation T (
x ) = x from R2 to R2 is called the projection of x onto
L, often denoted by proj L (
x ):
x ) = x .
proj L (
You can think of proj L (
x ) as the shadow vector x casts on L if you shine a light
straight down on L.
Let L ⊥ be the line through the origin perpendicular to L. Note that x⊥ is parallel
to L ⊥ , and we can interpret x⊥ as the projection of x onto L ⊥ , as illustrated in
Figure 2.
We can use the dot product to write a formula for a projection. Before proceeding,
you may want to review the section “Dot Product, Length, Orthogonality” in the
Appendix.
To find a formula for x , let u be a unit vector parallel to L. Since x is parallel
to u, we can write
x = k u,
58 CHAPTER 2 Linear Transformations
for some scalar k about to be determined. Now x⊥ = x − x = x − k u is perpendicular to line L, that is, perpendicular to u, meaning that
(
x − k u) · u = 0.
It follows that
x · u − k(
u · u) = x · u − k = 0,
or,
k = x · u.
We have used the fact that u · u = u = 1, since u is a unit vector. We can
conclude that
x ) = x = k u = (
x · u)
u.
proj L (
2
x⊥ = x − xll (translated)
x
L
xll = projL(x) = (x · u)u
O
u
Figure 3
What is the matrix of this projection (if it is linear at all)? If we write
x1
u
x =
and u = 1 ,
x2
u2
then
x1
u
u1
· 1
x2
u2
u2
u
= (x1 u 1 + x2 u 2 ) 1
u2
2
u x + u 1 u 2 x2
= 1 1
u 1 u 2 x1 + u 22 x2
2
u1 u1u2
x1
=
2
u1u2 u2
x2
2
u1 u1u2
=
x.
u 1 u 2 u 22
proj L (
x ) = (
x · u)
u=
EXAMPLE 2
Find the matrix A of the projection onto the line L spanned by v =
4
.
3
Solution
First we need a unit vector u parallel to L. We can let
1
1
0.8
u =
v = v =
.
0.6
v
5
Now we can use the formula just derived, with u 1 = 0.8 and u 2 = 0.6:
2
u1 u1u2
0.64 0.48
A=
=
.
u 1 u 2 u 22
0.48 0.36
■
2.2 Linear Transformations in Geometry
59
Let us summarize our findings.
Projections4
Definition 2.2.1
Consider a line L in the coordinate plane, running through the origin. Any vector
x in R2 can be written uniquely as
x = x + x⊥ ,
where x is parallel to line L, and x⊥ is perpendicular to L.
2
2
The transformation T (
x ) = x from
R to R is called the projection of x onto
u
x ). If u = 1 is a unit vector parallel to L, then
L, often denoted by proj L (
u2
proj L (
x ) = (
x · u)
u.
u 21 u 1 u 2
The transformation T (
x ) = proj L (
x ) is linear, with matrix
.
u 1 u 2 u 22
Reflections
Again, consider a line L in the coordinate plane, running through the origin, and let
x ) of x about L is shown in Figure 4: We
x be a vector in R2 . The reflection ref L (
are flipping vector x over the line L. In previous math courses you have surely seen
examples of reflections about the horizontal and vertical axes [when comparing the
graphs of y = f (x), y = − f (x), and y = f (−x), for example].
x
L
O
refL(x)
Figure 4
We can use the representation x = x + x⊥ to write a formula for ref L (
x ): See
Figure 5.
We can see that
x ) = x − x⊥ .
ref L (
Alternatively, we can express ref L (
x ) in terms of x⊥ alone or in terms of x alone:
x ) = x − x⊥ = (
x − x⊥ ) − x⊥ = x − 2
x⊥
ref L (
(use Figure 5 to explain this formula geometrically) and
x ) = x − x⊥ = x − (
x − x ) = 2
x − x
ref L (
x ) − x = 2(
x · u)
u − x.
= 2proj L (
4
More precisely, we are defining an orthogonal projection here (orthogonal means “perpendicular”).
A more general definition of a projection is presented in Exercise 33. Convention: All projections
discussed in this text are assumed to be orthogonal, unless stated otherwise.
60 CHAPTER 2 Linear Transformations
x⊥ (translated)
L
x
xll
−x⊥ (translated)
O
refL(x)
Figure 5
The formula ref(
x ) = 2(
x · u)
u − x allows
us to
find the matrix of a reflection. It
a
b
turns out that this matrix is of the form
, where a 2 + b2 = 1 (see Exercise
b −a
13), and that, conversely, any 2 × 2 matrix of this form represents a reflection about
a line (see Exercise 17).
Definition 2.2.2
Reflections
Consider a line L in the coordinate plane, running through the origin, and let
x ) = x − x⊥ is
x = x + x⊥ be a vector in R2 . The linear transformation T (
x ):
called the reflection of x about L, often denoted by ref L (
x ) = x − x⊥ .
ref L (
x ) to proj L (
x ):
We have a formula relating ref L (
x ) = 2proj L (
x ) − x = 2(
x · u)
u − x.
ref L (
a
b
The matrix of T is of the form
, where a 2 + b2 = 1.
b −a
Use Figure 6 to explain the formula ref L (
x ) = 2proj L (
x ) − x geometrically.
L
x
projL(x)
O
refL(x)
Figure 6
Projections and Reflections in Space
Although this section is mostly concerned with linear transformations from R2 to
R2 , we will take a quick look at projections and reflections in space, since this theory
is analogous to the case of two dimensions.
Let L be a line in coordinate space, running through the origin. Any vector x in
R3 can be written uniquely as x = x + x⊥ , where x is parallel to L, and x⊥ is
2.2 Linear Transformations in Geometry
61
perpendicular to L. We define
x ) = x ,
proj L (
and we have the formula
x ) = x = (
x · u)
u,
proj L (
where u is a unit vector parallel to L. See Definition 2.2.1.
Let L ⊥ = V be the plane through the origin perpendicular to L; note that the
vector x⊥ will be parallel to L ⊥ = V . We can give formulas for the orthogonal
projection onto V , as well as for the reflections about V and L, in terms of the
projection onto L:
x ) = x − proj L (
x ) = x − (
x · u)
u,
projV (
ref L (
x ) = proj L (
x ) − projV (
x ) = 2proj L (
x ) − x = 2(
x · u)
u − x,
and
x ) = projV (
x ) − proj L (
x ) = − ref L (
x ) = x − 2(
x · u)
u.
refV (
See Figure 7, and compare with Definition 2.2.2.
x
projL(x)
O
projV(x)
V = L⊥
L
Figure 7

5
Let V be the plane defined by 2x1 + x2 − 2x3 = 0, and let x =  4 . Find
−2
refV (
x ).

EXAMPLE 3

2
Note that the vector v =  1  is perpendicular to plane V (the components of v
−2
are the coefficients of the variables in the given equation of the plane: 2, 1, and −2).
Thus


2
1
1
u =
v =  1 
v
3
−2
Solution

62 CHAPTER 2 Linear Transformations
is a unit vector perpendicular to V , and we can use the formula we derived earlier:

 

 


2
2
5
5
2
refV (
x ) = x − 2(
x · u)
u =  4  −  4  ·  1   1 
9
−2
−2
−2
−2




2
5
=  4 − 4  1
−2
−2

 

8
5
=  4 −  4
−8
−2


−3
=  0 .
■
6
Rotations
Consider the linear transformation T from R2 to R2 that rotates any vector x through
a fixed angle θ in the counterclockwise direction,5 as shown in Figure 8. Recall
Example 2.1.5, where we studied a rotation through θ = π/2.
T (x)
T (x)
y
x
q
Figure 8
q
x
Figure 9
Now consider Figure 9, where we introduce the auxiliary vector y, obtained
by
x1
, then
rotating x through π/2. From Example 2.1.5 we know that if x =
x2
−x2
y =
. Using basic trigonometry, we find that
x1
x
−x2
T (
x ) = (cos θ )
x + (sin θ )y = (cos θ ) 1 + (sin θ )
x2
x1
(cos θ )x1 − (sin θ )x2
=
(sin θ )x1 + (cos θ )x2
cos θ − sin θ
x1
=
sin θ
cos θ
x2
cos θ − sin θ
=
x.
sin θ
cos θ
We can define a rotation more formally in terms of the polar coordinates of x. The length of T (
x ) equals
the length of x, and the polar angle (or argument) of T (
x ) exceeds the polar angle of x by θ.
5
2.2 Linear Transformations in Geometry
63
This computation shows that a rotation through θ is indeed a linear transformation,
with the matrix
cos θ − sin θ
.
sin θ
cos θ
Fact 2.2.3
Rotations
The matrix of a counterclockwise rotation in R2 through an angle θ is
cos θ − sin θ
.
sin θ
cos θ
a −b
Note that this matrix is of the form
, where a 2 + b2 = 1.
b
a
EXAMPLE 4
The matrix of a counterclockwise rotation through π/6 (or 30◦ ) is
√
1
3 √
−1
cos(π/6) − sin(π/6)
.
=
sin(π/6)
cos(π/6)
1
3
2
■
Rotations Combined with a Scaling
EXAMPLE 5
Examine how the linear transformation
a −b
T (
x) =
x
b
a
affects our standard letter L. Here a and b are arbitrary constants.
Solution
Figure 10 suggests that T represents a rotation combined with a scaling.
Think
a
polar coordinates: This is a rotation through the phase angle θ of vector
, comb
√
a
bined with a scaling by the magnitude r = a 2 + b2 of vector
. To verify this
b
0
2
a −b
b a
−2b
2a
a
b
θ
1
0
Figure 10
64 CHAPTER 2 Linear Transformations
a
claim algebraically, we can write the vector
in polar coordinates, as
b
a
r cos θ
=
,
b
r sin θ
a
b
r
q
r sin q
r cos q
Figure 11
as illustrated in Figure 11. Then
a −b
r cos θ −r sin θ
cos θ − sin θ
=
=r
.
b
a
r sin θ
r cos θ
sin θ
cos θ
a −b
It turns out that matrix
is a scalar multiple of a rotation matrix, as claimed.
b
a
■
Fact 2.2.4
Rotations combined with a scaling
a −b
A matrix of the form
represents a rotation combined with a scaling.
b
a
a
More precisely, if r and θ are the polar coordinates of vector
, then
b
a −b
represents a rotation through θ combined with a scaling by r .
b
a
Shears
We will introduce shears by means of some simple experiments involving a ruler
and a deck of cards.6
In the first experiment, we place the deck of cards on the ruler, as shown in Figure
12. Note that the 2 of diamonds is placed on one of the short edges of the ruler. That
edge will stay in place throughout the experiment. Now we lift the other short edge
of the ruler up, keeping the cards in vertical position at all times. The cards will
slide up, being “fanned out,” without any horizontal displacement.
2
2
Ruler
Figure 12
Figure 13 shows a side view of this transformation. The origin represents the
ruler’s short edge that is staying in place.
Such a transformation T is called a vertical shear. If we focus on the side view
only, we have a vertical shear in R2 (although in reality the experiment takes place
in space).
6
Two hints for instructors:
• Use several decks of cards for dramatic effect.
• Hold the decks together with a rubber band to avoid embarrassing accidents.
2.2 Linear Transformations in Geometry
65
T
O
O
Ruler
Figure 13
x1
Now let’s draw a vector x =
on the side of our deck of cards, and let’s find
x2
a formula for the sheared vector T (
x ), using Figure 14 as a guide. Here, k denotes
the slope of the ruler after the transformation:
x1
x1
1 0
x1
1 0
T (
x) = T
=
=
=
x.
k 1
k 1
x2
kx1 + x2
x2
Deck of Cards
T(x)
x
x2
x2
T
Slope k
O
x1
Ruler
O
x1
kx1
Figure 14
1 0
We find that the matrix of a vertical shear is of the form
, where k is an
k 1
arbitrary constant.
Horizontal shears are defined analogously; consider Figure 15.
Ruler
Deck of
Cards
O
O
Figure 15
We leave it as anexercise
to the reader to verify that the matrix of a horizontal
1 k
shear is of the form
. Take another look at part (e) of Example 1.
0 1
Oblique shears are far less important in applications, and we will not consider
them in this introductory text.
Fact 2.2.5
Horizontal and vertical shears
1 k
The matrix of a horizontal shear is of the form
, and the matrix of a
0 1
1 0
vertical shear is of the form
, where k is an arbitrary constant.
k 1
66 CHAPTER 2 Linear Transformations
The Scottish scholar d’Arcy Thompson showed how the shapes of related species
of plants and animals can often be transformed into one another, using linear as well
as nonlinear transformations.7 In Figure 16 he uses a horizontal shear to transform
the shape of one species of fish into another.
Argyropelecus olfersi.
Sternoptyx diaphana.
Figure 16
EXERCISES
2.2
GOAL Check whether a transformation is linear. Use the
matrices of projections, reflections, and rotations. Apply the
definitions of shears, projections, and reflections.
1. Sketch the image of the standard L under the linear transformation
3 1
x.
T (
x) =
1 2
(See Example 1.)
2. Find the matrix of a rotation through an angle of 60◦ in
the counterclockwise direction.
3. Consider a linear transformation T from R2 to R3 . Use
T (e1 ) and T (e2 ) to describe the image of the unit square
geometrically.
4. Interpret the following linear transformation geometrically:
1 1
T (
x) =
x.
−1 1
5. The matrix
−0.8 −0.6
0.6 −0.8
represents a rotation. Find the angle of rotation (in radians).
6. Let L be the line
in R3 that consists of all scalar multiples
 
2
of the vector  1 . Find the orthogonal projection of the
2
 
1
vector  1  onto L.
1
7
3
7. LetL be
 the line in R that consists of all scalar
  multiples
1
2
of  1 . Find the reflection of the vector  1  about the
1
2
line L.
8. Interpret the following linear transformation geometrically:
0
T (
x) =
−1
−1
x.
0
9. Interpret the following linear transformation geometrically:
T (
x) =
1
1
0
x.
1
10. Find the matrix of the projection onto the line L in R2
shown in the accompanying figure:
L
4
3
Thompson, d’Arcy W.: On Growth and Form, Cambridge University Press, 1917. P. B. Medawar calls this “the finest work of literature in all the
annals of science that have been recorded in the English tongue.”