Coordinates and Change of Basis

advertisement
Coordinates and Change of Basis
K. Behrend
February 29, 2008
Abstract
We discuss linear changes of coordinates.
1
Contents
Introduction
1 Vectors
1.1 How to convert between [~a]S
1.2 In Rn . . . . . . . . . . . .
1.3 An Application . . . . . . .
1.4 Exercises . . . . . . . . . .
3
.
.
.
.
4
6
8
9
11
2 Linear Operators
2.1 How to find [T ]B . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2.2 How to convert between [T ]B and [T ]S . . . . . . . . . . . . . . . . .
2.3 Exercises . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
13
15
17
19
and [~a]B
. . . . . .
. . . . . .
. . . . . .
2
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
.
Introduction
These notes are in somewhat preliminary form. The content is not yet stable. Watch
for updates.
3
1
Vectors
In Figure 1, two coordinate systems in the plane are displayed. We can use either
of the two coordinate systems to decribe vectors in the plane.
y'
y
u
x'
v
x
w
Figure 1: Three vectors
The vector ~u = 45 has standard coordinates x = 4 and y = 5. If we use
the blue coordinate system, whose coordinate axes are labelled x0 and y 0 , the blue
coordinates of ~u are x0 = 3 and y 0 = 2. The notation is as follows:
3
4
[~u]S =
[~u]B =
(1)
2
5
Similarely, we have
−4
[~v ]S =
1
2
[w]
~S=
−5
−1
[~v ]B =
2
−1
[~v ]B =
−4
Every coordinate system is defined by a basis. The standard coordinate system
is defined by the standard basis
1
0
S = (~e1 , ~e2 ) = (
,
)
0
1
4
The new (blue) coordinate system is defined by the basis
2
−1
B = (~u1 , ~u2 ) = (
,
)
1
1
y'
y
x'
e2
u2
u1
e1
x
Figure 2: The blue coordinate system is defined by the basis B = (~u1 , ~u2 ), the
standard coordinate system is defined by the basis S = (~e1 , ~e2 )
Referring back to Figure 1, we see that
~u = 3~u1 + 2~u2
and this is why the coordinates of ~u in the coordinate system defined by B = (~u1 , ~u2 )
are 3 an 2. Similarely,
−1
~v = −~u1 + 2~u2 therefore [~v ]B =
2
and
w
~ = −~u1 − 4~u2
therefore
[w]
~B=
−1
−4
In general,
To find the coordinate vecctor [~a]B of the vector ~a with respect to
the coordinate system defined by the basis B, express ~a asa linear
x0
0
0
combination ~a = x ~u1 + y ~u2 , and then read off: [~a]B =
y0
5
Of course every vector is equal to its coordinate vector in the standard basis:
4
4
~u =
so ~u = 4~e1 + 5~e2 so [~u]S =
= ~u
5
5
1.1
How to convert between [~a]S and [~a]B
Recall the above equation ~a = x0 ~u1 + y 0 ~u2 . We can rewrite this as a matrix equation
(recall that we can write linear combinations as matrix-vector products!)


|
| 0
x
~a = ~u1 ~u2  0
y
|
|
Remembering that ~a = [~a]S and
x0
y0
= [~a]B , we can rewrite this as


|
|
[~a]S = ~u1 ~u2  [~a]B
|
|
(2)
The matrix which appears in this equation:


|
|
P = ~u1 ~u2 
|
|
is called the change of basis matrix or transition matrix from the standard basis S
to the new basis B. This matrix P has the two basis vectors ~u1 and ~u2 as columns.
With this notation, we can rewrite (2) as
[~a]S = P [~a]B
If we multiply by P −1 on the left, we obtain:
P −1 [~a]S = P −1 P [~a]B = I2 [~a]B = [~a]B
(Here I2 is the 2 × 2 identity matrix.) So we get the other conversion formula
[~a]B = P −1 [~a]S
(3)
In our example, the matrix P is
2 −1
P =
1 1
and
P −1 =
1
3
1 1
−1 2
6
So, for example,
4
[
] =
5 B
1
3
1 1
4
[
] =
−1 2
5 S
1
3
1 1
−1 2
4
3
=
5
2
which is the same result (1), which we read off from the sketch. In general
0
x
1 1
1 1
x
x+y
1
1
1
[~a]S = 3
=3
= [~a]B = 3
−1 2
−1 2
y
−x + 2y
y0
Or
x0 = 13 x + 13 y
y 0 = − 13 x + 23 y
7
1.2
In Rn
If B = (~u1 , . . . , ~un ) is a basis of Rn , then for every vector ~v ∈ Rn ,
there exist unique numbers x1 , . . . , xn ∈ R, such that
~v = x1 ~u1 + . . . + xn ~un
These numbers are called the
of ~v with respect to the

 coordinates
x1
 
basis B, the column vector  ...  is called the coordinate vector
xn
of ~v with respect to the basis B, notation
 
x1
 .. 
[~v ]B =  . 
xn
Given that B = (~u1 , . . . , ~un ) is a basis of Rn , then the matrix


|
|
P = ~u1 · · · ~un 
|
|
with the basis vectors as columns is called the transition matrix
or change of basis matrix from the standard basis S to B.
Let us repeat our above calculation:
[~v ]S = ~v
standard coordinate vector is equal to vector
= x1 ~u1 + . . . + xn ~un
this is the defining equation in the box




x1
|
|


= ~u1 · · · ~un   ...  linear combination is a matrix vector product
|
|
xn
 
x1
 .. 
=P . 
definition of the change of basis matrix P
xn
= P [~v ]B
definition of coordinate vector from above box
We conclude
[~v ]S = P [~v ]B
[~v ]B = P −1 [~v ]S
8
1.3
An Application
Consider Figure 3.
y
y'
x'
x
Figure 3: An ellipse
The (x0 , y 0 )-coordinate system is well-suited for studying the ellipse. In fact, the
equation for the ellipse is
x 0 2
+ (y 0 )2 = 1
(4)
2
The transition matrix is
2 −1
P =
1 2
with inverse
P
And so
−1
0
x
=
y0
=
1
5
2 1
−1 2
1
5
2 1
−1 2
x
y
or
x0 = 52 x − 15 y
y 0 = 15 x + 25 y
Plugging this into the Equation (4), we get the standard equation for this ellipse
( 15 x −
2
1
10 y)
+ ( 15 x + 52 y)2 = 1
9
which is equivalent to
8x2 − 12xy + 17y 2 = 100
(5)
Thus, choosing a good coordinate system and then changing basis, can simplify the
study (in this case, finding the equation) of certain curves.
A central problem solved by linear algebra is the following: suppose an equation
such as (5) of a conic section in standard coordinates if given. How can we find the
(x0 , y 0 )-coordinate system, whose axes are the major and minor axis of the ellipse?
The method used is diagonalization of symmetric matrices.
10
1.4
Exercises
Exercise 1.1 In Figure 4, two vectors ~v1 and ~v2 are sketched, which form a basis
C = (~v1 , ~v2 ) of R2 .
(i) Find [~a]C , [~b]C and [~c]C , geometrically, without doing any calculations.
(ii) Skech (in Figure 4) the vectors ~u, ~v and w,
~ given that
2
2
3
[~u]C =
[~v ]C =
[w]
~C=
2
−3
−1
a
b
v2
v1
c
Figure 4: The figure for Exercise 1.1
Exercise 1.2 In Figure 5, two vectors ~v1 and ~v2 are sketched, which form a basis
C = (~v1 , ~v2 ) of R2 .
(i) Find [~a]C , [~b]C and [~c]C , geometrically, without doing any calculations.
(ii) Skech (in Figure 5) the vectors ~u, ~v and w,
~ given that
−1
3
2
[~u]C =
[~v ]C =
[w]
~C=
1
1
−3
Exercise 1.3 Given that B = (
[ 34 ]B
[
1
2
−4
]B
2
3
,
−2
), find
[
11
6
−1
]B
[
a
b
]B
a
b
v2
v1
c
Figure 5: The figure for Exercise 1.2
Exercise 1.4 Given that B = (
[
2
4 ]B
3
[
−2 3 ,
1
−1 3 ,
1
−2 −6 ]B
1
−2
3
2
−3
[~b]B =
3
−1
find
4 −1 ]B
3
[
Exercise 1.5 Consider the basis B = (
[~a]B =
1
2 ),
1
2
1
,
[
a
b ]B
c
) of R2 . Suppose that
[~c]B =
4
5
[~x]B =
s
t
Find [~a]S , [~b]S , [~c]S and [~x]S .
Exercise 1.6 Suppose the standard (x, y)-coordinate system of R2 is rotated coun0 0
terclockwise by an angle of 60◦ , to yield
the
−1
new (x
, y )-coordinate system. Find
2
0
the new coordinates of the points 3 , 1 and 1 .
Exercise 1.7 Suppose [
1
2
]B =
2
−1
and [
12
2
6
]B =
−2
3
. Find B.
2
Linear Operators
Consider the linear operator T : R2 → R2 wich is reflection across the line L :
x − 2y = 0, see Figure 6. The (x0 , y 0 )-coordinate system is defined by the basis
y
y'
v
x'
w
x
T(v)
L
T(w)
Figure 6: The reflection across the line x − 2y = 0. The original vectors are red,
their images under the reflection are light red.
2 is along the reflection mirror L, the
B = ( 21 , −1
).
The
first
basis
vector
1
2
is perpendicular to L.
second basis vector −1
2
The (x0 , y 0 )-coordinate system is well-adapted to this particular transformation
T . We can see that T preserves the x0 -coordinate, but changes the sign
on the
1 and the
y 0 -coordinate. For example, the vector ~v has coordinate vector
[~
v
]
=
B
1
1 . Similarely, [w]
reflected vector T (~v ) has coordinate vector [T (~v )]B = −1
~ =
B
−3/2
x0
−3/2
and
[T
(
w)]
~
=
.
More
generally,
if
a
vector
~
a
has
[~
a
]
=
B
B
y 0 , then
1
−1
x0
T (~a) has [T (~a)]B = −y0 .
0
x0
0 . This
The transformation xy0 7→ −y
is accomplished by the matrix 10 −1
0
is the matrix of T with respect to the basis B. Notation [T ]B .
1 0
[T ]B =
0 −1
The matrix [T ]B has the property that
[T ]B [~a]B = [T (~a)]B
13
(6)
for every vector ~a ∈ R2 .
For our two example vectors this equation reads
1 0
1
1
for ~v :
=
0 −1
1
−1
for w:
~
1 0
−3/2
−3/2
=
0 −1
1
−1
and in general
0
x
for
:
y0
0 0 1 0
x
x
=
0 −1
y0
−y 0
In words, we can reformulate Equation (6) as follows:
The matrix of T with respect to B transforms the B-coordinate
vector of a vector into the B-coordinate vector of the image vector.
or, put another way
The matrix of T with respect to B describes the effect of T on
B-coordinate vectors.
14
2.1
How to find [T ]B
Say the basis
is B = (~u1 , ~u2 ). Since ~u1 = 1~u1 +0~u2 , we have [~u1 ]B = 10 . Similarely,
[~u2 ]B = 01 . We can plug the vectors ~u1 and ~u2 into Formula (6). We get
[T ]B [~u1 ]B = [T (~u1 )]B
On the other hand,
[T ]B [~u1 ]B = [T ]B
1
0
which is the first column of [T ]B .
Similarely, we have
second column of [T ]B = [T ]B
0
1
= [T ]B [~u2 ]B = [T (~u2 )]B
So the two coluns of [T ]B are given by [T (~u1 )]B and [T (~u2 )]B .


|
|
[T ]B = [T (~u1 )]B [T (~u2 )]B 
|
|
In words:
To find the matrix of T in the basis B = (~u1 , ~u2 ), Find the images
of the basis vectors T (~u1 ) and T (~u2 ), and then express these in
the basis B, to find the coordinate vectors [T (~u1 )]B and [T (~u2 )]B ,
finally, but the resulting coordiate vectors as colunns of the matrix [T ]B .
In the example of Figure 6, the first basis vector ~u1 is on the reflection line, so
T (~u1 ) = ~u1 . The second basis vector ~u2 is perpendicular to the reflection line, so
T (~u2 ) = −~u2 . The corresponding
coordinate vectors are [T (~u1 )]B = [~u1 ]B = 10
0 , which give the matrix [T ] = 1 0 .
and [T (~u2 )]B = [−~u2 ]B = −1
B
0 −1
Of course, the same principle works in Rn :
If B = (~u1 , . . . , ~un ) is a basis of Rn , and T : Rn → Rn a linear
operator, then


|
|
[T ]B = [T (~u1 )]B · · · [T (~un )]B 
|
|
For another example, suppose E is a plane through the origin in R3 . Suppose
~u1 is a normal vector to E, and that ~u2 and ~u3 are two vectors spanning E. Then
B = (~u1 , ~u2 , ~u3 ) is a basis of R3 . Let T : R3 → R3 be the orthogonal projection onto
E. Then we have
0
T (~u1 ) = ~0
so
[T (~u1 )]B = 0
0
15
T (~u2 ) = ~u2
so
[T (~u2 )]B = [~u2 ]B =
0
1
0
T (~u3 ) = ~u3
so
[T (~u3 )]B = [~u3 ]B =
0
0
1
And therefore the matrix of T with respect

0
[T ]B = 0
0
16
to B is

0 0
1 0
0 1
(7)
2.2
How to convert between [T ]B and [T ]S
Let us combine Equation (6) with Equation (3) to obtain:
[T ]B P −1 [~a]S = P −1 [T (~a)]S
Multiplying through by P on the left gives
P [T ]B P −1 [~a]S = P P −1 [T (~a)]S = [T (~a)]S
(8)
On the other hand, the matrix which converts [~a]S into [T (~a)]S is [T ]S :
[T ]S [~a]S = [T (~a)]S
(9)
Comparing Equations (8) and (9), we see that the two matrices P [T ]B P −1 and
[T ]S have the same effect on all vectors [~a]S . Therefore, these two matrices have to
be equal:
[T ]S = P [T ]B P −1
Multiplying this equation by P −1 on the left and P on the right, we get the other
conversion formula
[T ]B = P −1 [T ]S P
Example 1 Returning to Figure 6, recall that ~u1 = 21 and ~u2 = −1
2 , so that
−1 = 1 2 1 . Thus, we
the transition matrix is P = 21 −1
,
whose
inverse
is
P
2
5 −1 2
have
1 0 1 2 1
4
2 −1
1 3
=
[T ]S = P [T ]B P −1 =
5 4 −3
0 −1 5 −1 2
1 2
This is the standard matrix of T . So we can deduce the formula for T in standard
coordinates:
4
x
x
1 3
1 3x + 4y
T
=5
=5
y
y
4 −3
4x − 3y
Example 2 Let us return to the Example leading to Equation 7. To be specific,
2 say that E has equation 2x + y − 3z = 0. Then we can take ~u1 = 1 as normal
−3
−1 0
vector. Two vectors which span the plane are ~u2 = 3 and ~u3 = 2 . This gives
1
0
the transition matrix


2 0 −1

1 3 2
P =
−3 1 0
with inverse

P −1

2
1 −3
1 
6
3 5
= 14
−10 2 −6
17
And hence

[T ]S = P [T ]B P −1

 

2 0 −1
0 0 0
2
1 −3
1 
6
3 5 =
=  1 3 2  0 1 0 14
−3 1 0
0 0 1
−10 2 −6
18


10 −2 6
1 
−2 13 3
14
6
3 5
2.3
Exercises
Exercise 2.1 Find the standard matrix of the reflection across the line 2x+5y = 0.
Exercise 2.2 Find the standard matrix of the orthogonal projection onto the line
x − 3y = 0.
Exercise 2.3 Find the standard matrix of the reflection acros the plane x+y+2z =
0.
19
Download