Skip to main content
Logo image

Section 3.2 Bases and coordinate systems

Standard Cartesian coordinates are commonly used to describe points in the plane. If we mention the point (4,3), we know that we arrive at this point from the origin by moving four units to the right and three units up.
Sometimes, however, it is more natural to work in a different coordinate system. Suppose that you live in the city whose map is shown in Figure 3.2.1 and that you would like to give a guest directions for getting from your house to the store. You would probably say something like, "Go four blocks up Maple. Then turn left on Main for three blocks." The grid of streets in the city gives a more natural coordinate system than standard north-south, east-west coordinates.
Figure 3.2.1. A city map.
In this section, we will develop the concept of a basis through which we will create new coordinate systems in Rm. We will see that the right choice of a coordinate system provides a more natural way to approach some problems.

Preview Activity 3.2.1.

Consider the vectors
v1=[21],v2=[12]
in R2, which are shown in Figure 3.2.2.
Figure 3.2.2. Linear combinations of v1 and v2.
  1. Indicate the linear combination v1āˆ’2v2 on the figure.
  2. Express the vector [āˆ’30] as a linear combination of v1 and v2.
  3. Find the linear combination 10v1āˆ’13v2.
  4. Express the vector [16āˆ’4] as a linear combination of v1 and v2.
  5. Explain why every vector in R2 can be written as a linear combination of v1 and v2 in exactly one way.
In the preview activity, we worked with a set of two vectors in R2 and found that we could express any vector in R2 in two different ways: in the usual way where the components of the vector describe horizontal and vertical changes, and in a new way as a linear combination of v1 and v2. We could also translate between these two descriptions. This example illustrates the central idea of this section.

Subsection 3.2.1 Bases

In the preview activity, we created a new coordinate system for R2 using linear combinations of a set of two vectors. More generally, the following definition will guide us.

Definition 3.2.3.

A set of vectors v1,v2,…,vn in Rm is called a basis for Rm if the set of vectors spans Rm and is linearly independent.

Activity 3.2.2.

We will look at some examples of bases in this activity.
  1. In the preview activity, we worked with the set of vectors in R2:
    v1=[21],v2=[12].
    Explain why these vectors form a basis for R2.
  2. Consider the set of vectors in R3
    v1=[111],v2=[01āˆ’1],v3=[10āˆ’1]
    and determine whether they form a basis for R3.
  3. Do the vectors
    v1=[āˆ’213],v2=[30āˆ’1],v3=[110],v4=[03āˆ’2]
    form a basis for R3?
  4. Explain why the vectors e1,e2,e3 form a basis for R3.
  5. If a set of vectors v1,v2,…,vn forms a basis for Rm, what can you guarantee about the pivot positions of the matrix
    [v1v2…vn]?
  6. If the set of vectors v1,v2,…,vn is a basis for R10, how many vectors must be in the set?
We can develop a test to determine if a set of vectors v1,v2,…,vn forms a basis for Rm by considering the matrix
A=[v1v2…vn].
To be a basis, this set of vectors must span Rm and be linearly independent.
We know that the span of the set of vectors is Rm if and only if A has a pivot position in every row. We also know that the set of vectors is linearly independent if and only if A has a pivot position in every column. This means that a set of vectors forms a basis if and only if A has a pivot in every row and every column. Therefore, A must be row equivalent to the identity matrix I:
A∼[10⋯001⋯0⋮⋮⋱⋮00⋯1]=I.
In addition to helping identify bases, this fact tells us something important about the number of vectors in a basis. Since the matrix A has a pivot position in every row and every column, it must have the same number of rows as columns. Therefore, the number of vectors in a basis for Rm must be m. For example, a basis for R23 must have exactly 23 vectors.

Example 3.2.5.

Notice that the vectors
e1=[100],e2=[010],e3=[001]
form the columns of the 3Ɨ3 identity matrix, which implies that this set forms a basis for R3. More generally, the set of vectors e1,e2,…,em forms a basis for Rm, which we call the standard basis for Rm.

Subsection 3.2.2 Coordinate systems

A basis for Rm forms a coordinate system for Rm, as we will describe. Rather than continuing to write a list of vectors, we will find it convenient to denote a basis using a single symbol, such as
B={v1,v2,…,vm}

Example 3.2.6.

In this section’s preview activity, we considered the vectors
v1=[21],v2=[12],
which form a basis B={v1,v2} for R2.
In the standard coordinate system, the point (2,āˆ’3) is found by moving 2 units to the right and 3 units down. We would like to define a new coordinate system where we interpret (2,āˆ’3) to mean we move two times along v1 and 3 times along āˆ’v2. As we see in the figure, doing so leaves us at the point (1,āˆ’4), expressed in the usual coordinate system.
We have seen that
x=[1āˆ’4]=2v1āˆ’3v2.
The coordinates of the vector x in the new coordinate system are the weights that we use to create x as a linear combination of v1 and v2.
Since we now have two descriptions of the vector x, we need some notation to keep track of which coordinate system we are using. Because [1āˆ’4]=2v1āˆ’3v2, we will write
{[1āˆ’4]}B=[2āˆ’3].
More generally, {x}B will denote the coordinates of x in the basis B; that is, {x}B is the vector [c1c2] of weights such that
x=c1v1+c2v2.
For example, if the coordinates of x in the basis B are
{x}B=[5āˆ’2],
x=5v1āˆ’2v2=5[21]āˆ’2[12]=[83],
and we conclude that
{[83]}B=[5āˆ’2].
This demonstrates how we can translate coordinates in the basis B into standard coordinates.
Suppose we know the expression of a vector x in standard coordinates. How can we find its coordinates in the basis B? For instance, suppose x=[āˆ’82] and that we would like to find {x}B. We can write
{[āˆ’82]}B=[c1c2],
which means that
[āˆ’82]=c1v1+c2v2
c1[21]+c2[12]=[āˆ’82].
This linear system for the weights defines an augmented matrix
[21āˆ’8122]∼[10āˆ’6014],.
which means that
{[āˆ’82]}B=[āˆ’64].
This example illustrates how a basis in R2 provides a new coordinate system for R2 and shows how we may translate between this coordinate system and the standard one.
More generally, suppose that B={v1,v2,…,vm} is a basis for Rm. We know that the span of the vectors is Rm, which implies that any vector x in Rm can be written as a linear combination of the vectors. In addition, we know that the vectors are linearly independent, which means that we can write x as a linear combination of the vectors in exactly one way. Therefore, we have
x=c1v1+c2v2+…+cmvm
where the weights c1,c2,…,cm are unique. In this case, we write the coordinate description of x in the basis B as
{x}B=[c1c2ā‹®cm].

Activity 3.2.3.

Let’s begin with the basis B={v1,v2} of R2 where
v1=[3āˆ’2],v2=[21].
  1. If the coordinates of x in the basis B are {x}B=[āˆ’24], what is the vector x?
  2. If x=[35], find the coordinates of x in the basis B; that is, find {x}B.
  3. Find a matrix A such that, for any vector x, we have x=A{x}B. Explain why this matrix is invertible.
  4. Using what you found in the previous part, find a matrix B such that, for any vector x, we have {x}B=Bx. What is the relationship between the two matrices A and B? Explain why this relationship holds.
  5. Suppose we consider the standard basis
    E={e1,e2}.
    What is the relationship between x and {x}E?
  6. Suppose we also consider the basis
    C={[12],[āˆ’21]}.
    Find a matrix C that converts coordinates in the basis C into coordinates in the basis B; that is,
    {x}B=C{x}C.
    You may wish to think about converting coordinates from the basis C into the standard coordinate system and then into the basis B.
This activity demonstrates how we can efficiently convert between coordinate systems defined by different bases. Let’s consider a basis B={v1,v2,…,vm} and a vector x. We know that
x=c1v1+c2v2+…+cmvm=[v1v2⋯vm][c1c2ā‹®cm]=[v1v2⋯vm]{x}B.
If we use PB to denote the matrix whose columns are the basis vectors, then we find that
x=PB{x}B
where PB=[v1v2⋯vm]. This means that the matrix PB converts coordinates in the basis B into standard coordinates.
Since the columns of PB are the basis vectors v1,v2,…,vm, we know that PB∼Im, and PB is therefore invertible. Since we have
x=PB{x}B,
we must also have
PBāˆ’1x={x}B.
If we have another basis C, we find, in the same way, that x=PC{x}C for the conversion between coordinates in the basis C into standard coordinates. We then have
{x}B=PBāˆ’1x=PBāˆ’1(PC{x}C)=(PBāˆ’1PC){x}C.
Therefore, PBāˆ’1PC is the matrix that converts C-coordinates into B-coordinates.

Subsection 3.2.3 Examples of bases

We will now look at some examples of bases that illustrate how it can be useful to study a problem using a different coordinate system.

Example 3.2.8.

Let’s consider the basis of R3:
B={[10āˆ’2],[āˆ’210],[112]}.
It is relatively straightforward to convert a vector’s representation in this basis into to the standard basis using the matrix whose columns are the basis vectors:
PB=[1āˆ’21011āˆ’202].
For example, suppose that the vector x is described in the coordinate system defined by the basis as {x}B=[2āˆ’21]. We then have
x=PB{x}B=[1āˆ’21011āˆ’202][2āˆ’21]=[7āˆ’1āˆ’2].
Consider now the vector x=[31āˆ’2]. If we would like to express x in the coordinate system defined by B, then we compute
{x}B=PBāˆ’1x=[1412āˆ’38āˆ’1412āˆ’18141218][31āˆ’2]=[201].

Example 3.2.9.

Suppose we work for a company that records its quarterly revenue, in millions of dollars, as:
Table 3.2.10. A company’s quarterly revenue
Quarter Revenue
1 10.3
2 13.1
3 7.5
4 8.2
Rather than using a table to record the data, we could display it in a graph or write it as a vector in R4:
x=[10.313.17.58.2].
Let’s consider a new basis B for R4 using vectors
v1=[1111],   v2=[11āˆ’1āˆ’1],   v3=[1āˆ’100],   v4=[001āˆ’1].
We may view these basis elements graphically, as in Figure 3.2.11
Figure 3.2.11. A representation of the basis elements of B.
To convert our revenue vectors into the coordinates given by B, we form the matrices:
PB=[111011āˆ’101āˆ’1011āˆ’10āˆ’1],   PBāˆ’1=[141414141414āˆ’14āˆ’1412āˆ’12000012āˆ’12].
In particular, if the revenue vector is x=[x1x2x3x4], then
{x}B=[14x1+14x2+14x3+14x414x1+14x2āˆ’14x3āˆ’14x412x1āˆ’12x212x3āˆ’12x4].
Notice that the first component of {x}B is the average of the components of x.
For our particular revenue vector x=[10.313.17.58.2], we have
{x}B=PBāˆ’1x=PBāˆ’1[10.313.17.58.2]=[9.7751.925āˆ’1.400āˆ’0.350].
This means that our revenue vector is
x=9.775v1+1.925v2āˆ’1.400v3āˆ’0.350v4.
We will think about what these terms mean by adding them together one at a time.
The first term,
9.775v1=[9.7759.7759.7759.775],
gives us the average revenue over the year.
The average revenue for the first two quarters is 11.7, which is 1.925 million dollars above the yearly average. Similarly, the average revenue for the last two quarters is 1.925 million dollars below the yearly average. This is recorded by the second term
1.925v2=[1.9251.925āˆ’1.925āˆ’1.925].
Finally, the first quarter’s revenue is 1.400 million dollars below the average over the first two quarters and the second quarter’s revenue is 1.400 million dollars above that average. This, and the corresponding data for the last two quarters, is captured by the last two terms:
āˆ’1.400v3āˆ’0.350v4=[āˆ’1.4001.400āˆ’0.3500.350],
If we write {x}B=[c1c2c3c4], we see that the coefficient c1 measures the average revenue over the year, c2 measures the deviation from the annual average in the first and second halves of the year, and c3 measures how the revenue in the first and second quarter differs from the average in the first half of the year. In this way, the coefficients provide a view of the revenue over different time scales, from an annual summary to a finer view of quarterly behavior.
This basis is sometimes called a Haar wavelet basis, and the change of basis is known as a Haar wavelet transform. In the next section, we will see how this basis provides a useful way to store digital images.

Activity 3.2.4. Edge detection.

An important problem in the field of computer vision is to detect edges in a digital photograph, as is shown in Figure 3.2.12. Edge detection algorithms are useful when, say, we want a robot to locate an object in its field of view. Graphic designers also use these algorithms to create artistic effects.
Figure 3.2.12. A canyon wall in Capitol Reef National Park and the result of an edge detection algorithm.
We will consider a very simple version of an edge detection algorithm to give a sense of how this works. Rather than considering a two-dimensional photograph, we will think about a one-dimensional row of pixels in a photograph. The grayscale values of a pixel measure the brightness of a pixel; a grayscale value of 0 corresponds to black, and a value of 255 corresponds to white.
Suppose, for simplicity, that the grayscale values for a row of six pixels are represented by a vector x in R6:
x=[25343045190200].
We can easily see that there is a jump in brightness between pixels 4 and 5, but how can we detect it computationally? We will introduce a new basis B for R6 with vectors:
v1=[100000],v2=[110000],v3=[111000],v4=[111100],v5=[111110],v6=[111111].
  1. Construct the matrix PB that relates the standard coordinate system with the coordinates in the basis B.
  2. Determine the matrix PBāˆ’1 that converts the representation of x in standard coordinates into the coordinate system defined by B.
  3. Suppose the vectors are expressed in general terms as
    x=[x1x2x3x4x5x6],   {x}B=[c1c2c3c4c5c6].
    Using the relationship {x}B=PBāˆ’1x, determine an expression for the coefficient c2 in terms of x1,x2,…,x6. What does c2 measure in terms of the grayscale values of the pixels? What does c4 measure in terms of the grayscale values of the pixels?
  4. Now for the specific vector
    x=[25343045190200],
    determine the representation of x in the B-coordinate system.
  5. Explain how the coefficients in {x}B determine the location of the jump in brightness in the grayscale values represented by the vector x.
Readers who are familiar with calculus may recognize that this change of basis converts a vector x into {x}B, the set of changes in x. This process is similar to differentiation in calculus. Similarly, the process of converting {x}B into the vector x adds together the changes in a process similar to integration. As a result, this change of basis represents a linear algebraic version of the Fundamental Theorem of Calculus.

Subsection 3.2.4 Summary

We defined a basis to be a set of vectors B={v1,v2,…,vn} that is linearly independent and whose span is Rm.
  • A set of vectors forms a basis for Rm if and only if the matrix
    A=[v1v2⋯vn]∼I.
    This means there must be m vectors in a basis for Rm.
  • If v1,v2,…,vm forms a basis for Rm, then any vector in Rm can be written as a linear combination of the vectors in exactly one way.
  • We used the basis B to define a coordinate system in which {x}B=[c1c2ā‹®cn], the coordinates of x in the basis B, are defined by
    x=c1v1+c2v2+⋯+cnvm.
  • Forming the matrix PB whose columns are the basis vectors, we can convert between coordinate systems:
    x=PB{x}B,PBāˆ’1x={x}B..

Exercises 3.2.5 Exercises

1.

Shown in Figure 3.2.13 are two vectors v1 and v2 in the plane R2.
Figure 3.2.13. Vectors v1 and v2 in R2.
  1. Explain why B={v1,v2} is a basis for R2.
  2. Using Figure 3.2.13, indicate the vectors x such that
    1. {x}B=[2āˆ’1]
    2. {x}B=[āˆ’1āˆ’2]
    3. {x}B=[03]
  3. Using Figure 3.2.13, find the representation {x}B if
    1. x=[āˆ’2āˆ’1].
    2. x=[24].
    3. x=[2āˆ’5].
  4. Find {x}B if x=[6090].

2.

Consider vectors
v1=[12],v2=[1āˆ’3]w1=[23],w2=[āˆ’1āˆ’2].
and let B={v1,v2} and C={w1,w2}.
  1. Explain why B and C are both bases of R2.
  2. If x=[5āˆ’3], find {x}B and {x}C.
  3. If {x}B=[2āˆ’4], find x and {x}C.
  4. If {x}C=[āˆ’32], find x and {x}B.
  5. Find a matrix Q such that {x}B=Q{x}C.

3.

Consider the following vectors in R4:
v1=[1111],v2=[0111],v3=[0011],v4=[0001].
  1. Explain why B={v1,v2,v3,v4} forms a basis for R4.
  2. Explain how to convert {x}B, the representation of a vector x in the coordinates defined by B, into x, its representation in the standard coordinate system.
  3. Explain how to convert the vector x into {x}B, its representation in the coordinate system defined by B.
  4. If x=[23121019], find {x}B.
  5. If {x}B=[31āˆ’3āˆ’4], find x.

4.

Consider the following vectors in R3:
v1=[132],v2=[014],v3=[āˆ’2āˆ’50],v4=[āˆ’2āˆ’1āˆ’1],v5=[1āˆ’2āˆ’1].
  1. Do these vectors form a basis for R3? Explain your thinking.
  2. Find a subset of these vectors that forms a basis of R3.
  3. Suppose you have a set of vectors v1,v2,…,v6 in R4 such that
    [v1v2…v6]∼[10āˆ’20100130āˆ’40000120000001].
    Find a subset of the vectors that forms a basis for R4.

5.

This exercise involves a simple Fourier transform, which will play an important role in the next section.
Suppose that we have the vectors
v1=[111],v2=[cos⁔(Ļ€6)cos⁔(3Ļ€6)cos⁔(5Ļ€6)]v3=[cos⁔(2Ļ€6)cos⁔(6Ļ€6)cos⁔(10Ļ€6)].
  1. Explain why B={v1,v2,v3} is a basis for R3. Notice that you may enter cos⁔(Ļ€6) into Sage as cos(pi/6).
  2. If x=[151515], find {x}B.
  3. Find the matrices PB and PBāˆ’1. If x=[x1x2x3] and {x}B=[c1c2c3], explain why c1 is the average of x1, x2, and x3.

6.

Determine whether the following statements are true or false and provide a justification for your response.
  1. If the columns of a matrix A form a basis for Rm, then A is invertible.
  2. There must be 125 vectors in a basis for R125.
  3. If B={v1,v2,…,vn} is a basis of Rm, then every vector in Rm can be expressed as a linear combination of basis vectors.
  4. The coordinates {x}B are the weights that form x as a linear combination of basis vectors.
  5. If the basis vectors form the columns of the matrix PB, then {x}B=PBx.

7.

Provide a justification for your response to each of the following questions.
  1. Suppose you have m linearly independent vectors in Rm. Can you guarantee that they form a basis of Rm?
  2. If A is an invertible mƗm matrix, do the columns necessarily form a basis of Rm?
  3. Suppose we have an invertible mƗm matrix A, and we perform a sequence of row operations on A to form a matrix B. Can you guarantee that the columns of B form a basis for Rm?
  4. Suppose you have a set of 10 vectors in R10 and that every vector in R10 can be written as a linear combination of these vectors. Can you guarantee that this set of vectors is a basis for R10?

8.

Crystallographers find it convenient to use coordinate systems that are adapted to the specific geometry of a crystal. As a two-dimensional example, consider a layer of graphite in which carbon atoms are arranged in regular hexagons to form the crystalline structure shown in Figure 3.2.14.
Figure 3.2.14. A layer of carbon atoms in a graphite crystal.
The origin of the coordinate system is at the carbon atom labeled by ā€œ0ā€. It is convenient to choose the basis B defined by the vectors v1 and v2 and the coordinate system it defines.
  1. Locate the points x for which
    1. {x}B=[10],
    2. {x}B=[01],
    3. {x}B=[21].
  2. Find the coordinates {x}B for all the carbon atoms in the hexagon whose lower left vertex is labeled ā€œ0ā€.
  3. What are the coordinates {x}B of the center of that hexagon, which is labeled ā€œCā€?
  4. How do the coordinates of the atoms in the hexagon whose lower left corner is labeled ā€œ1ā€ compare to the coordinates in the hexagon whose lower left corner is labeled "0"?
  5. Does the point x whose coordinates are {x}B=[164] correspond to a carbon atom or the center of a hexagon?

9.

Suppose that A=[2112] and
v1=[11],   v2=[1āˆ’1].
  1. Explain why B={v1,v2} is a basis for R2.
  2. Find Av1 and Av2.
  3. Use what you found in the previous part of this problem to find {Av1}B and {Av2}B.
  4. If {x}B=[1āˆ’5], find {Ax}B.
  5. Find a matrix D such that {Ax}B=D{x}B.
You should find that the matrix D is a very simple matrix, which means that this basis B is well suited to study the effect of multiplication by A. This observation is the central idea of the next chapter.
You have attempted 1 of 1 activities on this page.