Skip to main content

Section 13 The Null Space and Column Space of a Matrix

Subsection Application: The Lights Out Game

Lights Out (LO) is a commercial game released by Tiger Toys in 1995 (later bought out by Hasbro). The game consists of a 5Γ—5 grid in which each square is either lit or unlit. Pressing a square changes the status of the square itself and all the squares to the left, right, up, or down. The player's job is to turn all the lights out. You can play a sample game at geogebra.org/m/wcmctahp. There is a method to solve any solvable Lights Out game that can be uncovered through linear algebra that we will uncover later in this section. Column spaces and null spaces play important roles in this method.

Subsection Introduction

Recall that a subspace of Rn is a subset of Rn which is a vector space in itself. More specifically, a subset W or Rn is a subspace of Rn if

  1. whenever u and v are in W it is also true that u+v is in W (that is, W is closed under addition),

  2. whenever u is in W and a is a scalar it is also true that au is in W (that is, W is closed under scalar multiplication),

  3. 0 is in W.

Given a matrix A, there are several subspaces that are connected to A. Two specific such subspaces are the null space of A and the column space of A. We will see that these subspaces provide answers to the big questions we have been considering since the beginning of the semester, such as β€œDo columns of A span Rm?” β€œAre the columns of A linearly independent?” β€œIs the transformation T defined by matrix multiplication by A one-to-one?” β€œIs the transformation T onto?”

In this preview activity, we start examining the null space.

Preview Activity 13.1.

(a)

Let A=[213114].

(i)

Find the general solution to the homogeneous equation Ax=0. Write your solutions in parametric vector form. (Recall that the parametric vector form expresses the solutions to an equation as linear combinations of vectors with free variables as the weights. An example would be x3[10βˆ’10]+x4[βˆ’2101].)

(ii)

Find two specific solutions x1 and x2 to the homogeneous equation Ax=0. Is x1+x2 a solution to Ax=0? Explain.

(iii)

Is 3x1 a solution to Ax=0? Explain.

(v)

What does the above seem to indicate about the set of solutions to the homogeneous system Ax=0?

(b)

Let A be an mΓ—n matrix. As problem 1 implies, the set of solutions to a homogeneous matrix-vector equation Ax=0 appears to be a subspace. We give a special name to this set.

Definition 13.1.

The null space of an mΓ—n matrix A is the set of all solutions to Ax=0.

We denote the null space of a matrix A as Nul A. In set notation we write

Nul A={x:Ax=0}.

Note that since Ax=0 corresponds to a homogeneous system of linear equations, Nul A also represents the solution set of a homogeneous system. Let A=[21301141]. Find all vectors in Nul A.

(c)

So far we considered specific examples of null spaces. But what are the properties of a null space in general? Let A be an arbitrary mΓ—n matrix.

(i)

The null space of an mΓ—n matrix is a subset of Rk for some integer k. What is k?

(ii)

Now suppose u and v are two vectors in Nul A. By definition, that means Au=0, Av=0. Use properties of the matrix-vector product to show that u+v is also in Nul A.

(iii)

Now suppose u is a vector in Nul A and a is a scalar. Explain why au is also in Nul A.

(iv)

Explain why Nul A is a subspace of Rn.

Subsection The Null Space of a Matrix and the Kernel of a Matrix Transformation

In this section we explore the null space and see how the null space of a matrix is related to the matrix transformation defined by the matrix.

Let A be an mΓ—n matrix. In Preview Activity 13.1 we defined the null space of a matrix A (see Definition 13.1) as the set of solutions to the matrix equation Ax=0. Note that the null space of an mΓ—n matrix is a subset of Rn. We saw that the null space of A is closed under addition and scalar multiplication β€” that is, if u and v are in Nul A and a and b are any scalars, then u+v and au are also in Nul A. Since the zero vector is always in Nul A, we can conclude that the null space of A is a subspace of Rn.

There is a connection between the null space of a matrix and the matrix transformation it defines. Recall that any mΓ—n matrix A defines a matrix transformation T from Rn to Rm by T(x)=Ax. The null space of A is then the collection of vectors x in Rn so that T(x)=0. So if T is a matrix transformation from Rn to Rm, then the set

{x in Rn:T(x)=0}

is a subspace of Rn equal to the null space of A. This set is is given a special name.

Definition 13.2.

Let T:Rn→Rn be a matrix transformation. The kernel of T is the set

Ker(T)={x∈Rn:T(x)=0}.

Activity 13.2.

If T is a matrix transformation defined by a matrix A, then there is a convenient way to determine if T is one-to-one.

(a)

Let T be the matrix transformation defined by T(x)=Ax, where

A=[12βˆ’1014].

Find all of the vectors in Nul A. If Nul A contains more than one vector, can T be one-to-one? Why?

(b)

Let T be the matrix transformation defined by T(x)=Ax, where

A=[1021βˆ’14].

Find all of the vectors in Nul A. Is T one-to-one? Why?

(c)

To find the vectors in the null space of a matrix A we solve the system Ax=0. Since a homogeneous system is always consistent, there are two possibilities for Nul A: either Nul A={0} or Nul A contains infinitely many vectors.

(i)

Under what conditions on A is Nul A={0}? What does that mean about T being one-to-one or not? Explain.

(ii)

Under what conditions is Nul A infinite? What does that mean about T being one-to-one or not? Explain.

(iii)

Is is possible for Nul A to be the whole space Rn? If so, give an example. If not, explain why not.

Recall that for a function to be one-to-one, each output must come from exactly one input. Since a matrix transformation T defined by T(x)=Ax always maps the zero vector to the zero vector, for T to be one-to-one it must be the case that the zero vector is the only vector that T maps to the zero vector. This means that the null space of A must be {0}. Activity 13.2 demonstrates that if the matrix A that defines the transformation T has a pivot in every column, then T(x)=b will have exactly one solution for each b in the range of T. So a trivial null space is enough to characterize a one-to-one matrix transformation.

Subsection The Column Space of a Matrix and the Range of a Matrix Transformation

Given an mΓ—n matrix A, we have seen that the matrix-vector product Ax is a linear combination of the columns of A with weights from x. It follows that the equation Ax=b has a solution if and only if b is a linear combination of the columns of A. So the span of the columns of A tells us for which vectors the equation Ax=b is consistent. We give the span of the columns of a matrix A a special name.

Definition 13.4.

The column space of an mΓ—n matrix A is the span of the columns of A.

We denote the column space of A as Col A. Given that Ax is a linear combination of the columns of A, we can also write the column space of an mΓ—n matrix A as

Col A={Ax:x is in Rn}.

For the matrix transformation T defined by T(x)=Ax, the set of all vectors of the form Ax is also the range of the transformation T. So for a matrix transformation T with matrix A we have Range(T)=Col A.

Activity 13.3.

As a span of a set of vectors, we know that Col A is a subspace of Rk for an appropriate value of k.

(a)

Let M=[11102010111011βˆ’101011]. The space Col M is a subspace of Rk for some positive integer k. What is k in this case?

(b)

If A is an mΓ—n matrix, then Col A is a subspace of Rk for some positive integer k. What is k in this case?

(c)

Recall that a matrix transformation T given by T(x)=Ax where A is an mΓ—n matrix is onto if for every b in Rm there exists a x in Rn for which T(x)=b. How does T being onto relate to the Col A?

As you saw in Activity 13.3, a matrix transformation T defined by T(x)=Ax is onto if the column space of A, which consists of the image vectors under the transformation T, is equal to Rm. In other words, we want the Range(T) to equal Rm.

Subsection The Row Space of a Matrix

As you might expect, if there is a column space for a matrix then there is also a row space for a matrix. The row space is defined just as the column space as the span of the rows of a matrix.

Definition 13.6.

The row space of an mΓ—n matrix A is the span of the row of A.

There is really nothing new here, though. Since the rows of A are the columns of AT, it follows that Row A=Col AT. So if we want to learn anything about the row space of A, we can just translate all of our questions to the column space of AT.

Subsection Bases for Nul A and Col A

When confronted with a subspace of Rn, we will usually want to find a minimal spanning set β€” a smallest spanning set β€” for the space. Recall that a minimal spanning set is also called a basis for the space. So a basis for a space must span that space, and to be a minimal spanning set we have seen that a basis must also be linearly independent. So to prove that a set is a basis for a subspace of Rn we need to demonstrate two things: that the set is linearly independent, and that the set spans the subspace.

Activity 13.4.

In this activity we see how to find a basis for Col A and Nul A for a specific matrix A. Let

A=[11102010111011βˆ’101011].

Assume that the reduced row echelon form of A is

R=[10100010020001βˆ’100000].
(a)

First we examine Col A. Recall that to find a minimal spanning set of a set of vectors {v1,v2,…,vk} in Rn we just select the pivot columns of the matrix [v1 v2 β‹― vk].

(i)

Find a basis for Col A.

(ii)

Does Col A equal Col R? Explain.

(b)

Now we look at Nul A.

(i)

Write the general solution to the homogeneous system Ax=0 in vector form.

(ii)

Find a spanning set for Nul A.

(iii)

Find a basis for Nul A. Explain how you know you have a basis.

You should have noticed that Activity 13.4 (a) provides a process for finding a basis for Col A β€” the pivot columns of A form a basis for Col A. Similarly, Activity 13.4 (b) shows us that we can find a basis for Nul A by writing the general solution to the homogeneous equation Ax=0 as a linear combination of vectors whose weights are the variables corresponding to the non-pivot columns of A β€” and these vectors form a basis for Nul A. As we will argue next, these process always give us bases for Col A and Nul A.

Let A be an mΓ—n matrix, and let R be the reduced row echelon form of A. Suppose R has k non-pivot columns and nβˆ’k pivot columns. We can rearrange the columns so that the non-pivot columns of R are the last k columns (this just amounts to relabeling the unknowns in the system).

Basis for Nul A.

Here we argue that the method described following Activity 13.4 to find a spanning set for the null space always yields a basis for the null space. First note that Nul R=Nul A, since the system Ax=0 has the same solution set as Rx=0. So it is enough to find a basis for Nul R. If every column of R is a pivot column, then Rx=0 has only the trivial solution and the null space of R is {0}. Let us now consider the case where R contains non-pivot columns. If we let x=[x1 x2 β€¦ xn]T, and if Rx=0 then we can write x1, x2, …, xnβˆ’k in terms of xnβˆ’k+1, xnβˆ’k+2, …, and xn. From these equations we can write x as a linear combination of some vectors v1, v2, …, vk with xnβˆ’k+1, xnβˆ’2+2, …, xn as weights. By construction, each of the vectors v1, v2, …, vk has a component that is 1 with the corresponding component as 0 in all the other vi. Therefore, the vectors v1, v2, …, vk are linearly independent and span Nul R (and Nul A). In other words, the method we have developed to find the general solution to Ax=0 always produces a basis for Nul A.

Basis for Col A.

Here we explain why the pivot columns of A form a basis for Col A. Recall that the product Ax expresses a linear combination of the columns of A with weights from x, and every such linear combination is matched with a product Rx giving a linear combination of the columns of R using the same weights. So if a set of columns of R is linearly independent (or dependent), then the set of corresponding columns in A is linearly independent (or dependent) and vice versa. Since each pivot column of R is a vector with 1 in one entry (a different entry for different pivot columns) and zeros elsewhere, the pivot columns of R are clearly linearly independent. It follows that the pivot columns of A are linearly independent. All that remains is to explain why the pivot columns of A span Col A. Let r1, r2, …, rn be the columns of R so that R = [r1  r2  β‹―  rn], and let a1, a2, …, an be the columns of A so that A = [a1  a2  β‹―  an]. Suppose ai is a non-pivot column for A and ri the corresponding non-pivot column in R. Each pivot column is composed of a single 1 with the rest of its entries 0. Also, if a non-pivot column contains a nonzero entry, then there is a corresponding pivot column that contains a 1 in the corresponding position. So ri is a linear combination of r1, r2, …, rnβˆ’k β€” the pivot columns of R. Thus,

ri=c1r1+c2r2+β‹―+cnβˆ’krnβˆ’k

for some scalars c1, c2, …, cnβˆ’k. Let x=[c1 c2 β‹― cnβˆ’k 0 β‹―0 βˆ’1 0 β‹― 0]T, where the βˆ’1 is in position i. Then Rx=0 and so Ax=0. Thus,

ai=c1a1+c2a2+β‹―+cnβˆ’kanβˆ’k

and ai is a linear combination of the pivot columns of A. So every non-pivot column of A is in the span of A and we conclude that the pivot columns of A form a basis for Col A.

IMPORTANT POINT.

It is the pivot columns of A that form a basis for Col A, not the pivot columns of the reduced row echelon form R of A. In general, Col Rβ‰ Col A.

We can incorporate the ideas of this section to expand the Invertible Matrix Theorem.

Subsection Examples

What follows are worked examples that use the concepts from this section.

Example 13.8.

(a)

Let A=[10βˆ’23βˆ’2βˆ’40βˆ’141319].

(i)

Find a basis for Col A.

Technology shows that the reduced row echelon form of A is

[10βˆ’2301120000].

The first two columns of A are the pivot columns of A. Since the pivot columns of A form a basis for Col A, a basis for Col A is

{[1βˆ’21],[0βˆ’43]}.
Solution.

We use A=[10βˆ’23βˆ’2βˆ’40βˆ’141319].

Let v1=[1βˆ’21] and v2=[0βˆ’43]. Since neither v1 nor v2 is a scalar multiple of the other, we see that Col A is the span of two linearly independent vectors in R3. Thus, we conclude that Col A is the plane in R3 through the origin and the points (1,βˆ’2,1) and (0,βˆ’4,3).

(ii)

Describe Col A geometrically (e.g., as a line, a plane, a union of lines, etc.) in the appropriate larger space.

Solution.

(b)

Let B=[0βˆ’21βˆ’1016βˆ’10βˆ’11βˆ’41].

(i)

Find a basis for Nul B.

Solution.

We use B=[0βˆ’21βˆ’1016βˆ’10βˆ’11βˆ’41].

Technology shows that the reduced row echelon form of B is

[10βˆ’101βˆ’12000000].

To find a basis for Nul B, we must solve the homogeneous equation Bx=0. If x=[x1x2x3] and Bx=0, the reduced row echelon form of B shows that x3 is free, x2=12x3, and x1=x3. So

x=[x1x2x3]=[x312x3x3]=x3[11211].

Thus, a basis for Nul B is

{[212]}.
(ii)

Describe Nul B geometrically (e.g., as a line, a plane, a union of lines, etc.) in the appropriate larger space.

Solution.

We use B=[0βˆ’21βˆ’1016βˆ’10βˆ’11βˆ’41].

Since Nul B=Span{[212]} is the span of one nonzero vector in R3, we conclude that Nul B is the line in R3 through the origin and the point (2,1,2).

Example 13.9.

Let A=[13βˆ’120βˆ’256], and let T be the matrix transformation defined by T(x)=Ax.

(a)

What are the domain and codomain of T? Why?

Solution.

Recall that Ax is a linear combination of the columns of A with weights from x. So Ax is defined only when the number of components of x is equal to the number of columns of A. This explains why the domain of T is R2. Also, since each output of T is a linear combination of the columns of A, the codomain of T is R4.

(b)

Find all vectors x such that T(x)=0. How is this set of vectors related to Nul A? Explain.

Solution.

The set of vectors x such that 0=T(x)=Ax is the same as Nul A. The reduced row echelon form of A is

[10010000].

Since both columns of A are pivot columns, the columns of A are linearly independent. This implies that Ax=0 has only the trivial solution. Therefore, the only vector x such that T(x)=0 is the zero vector in R2.

(c)

Is T one-to-one? Explain.

Solution.

The previous part shows that Ker(T)={0}. This means that T is one-to-one by Theorem 13.3.

(d)

Is T onto? If yes, explain why. If no, find a basis for the range of T.

Solution.

Recall that the range of T is the same as Col A. The reduced row echelon form of A has a row of zeros, so Ax=b is not consistent for every b in R4. We conclude that T is not onto. To find a basis for the range of T, we just need to find a basis for Col A. The pivot columns of A form such a basis, so a basis for the range of T is

{[1βˆ’105],[32βˆ’26]}.

Subsection Summary

  • The null space of an mΓ—n matrix A is the set of vectors x in Rn so that Ax=0. In set notation

    Nul A={x:Ax=0}.
  • The column space of a matrix A is the span of the columns of A.

  • A subset W of Rn is a subspace of Rn if

    1. u+v is in W whenever u and v are in W (when this property is satisfied we say that W is closed under addition),

    2. au is in W whenever a is a scalar and u is in W (when this property is satisfied we say that W is closed under multiplication by scalars),

    3. 0 is in W.

  • The null space of an mΓ—n matrix is a subspace of Rn while the column space of A is a subspace of Rm.

  • The span of any set of vectors in Rn is a subspace of Rn.

  • The kernel of a matrix transformation T:Rnβ†’Rm is the set

    Ker(T)={x∈Rn:T(x)=0}.
  • The kernel of a matrix transformation T defined by T(x)=Ax is the same set as Nul A.

  • The range of a matrix transformation T:Rnβ†’Rm is the set

    Range(T)={T(x):x∈Rn}.
  • The range of a matrix transformation T defined by T(x)=Ax is the same set as Col A.

  • A basis for the null space of a matrix A can be found by writing the general solution to the homogeneous equation Ax=0 as a linear combination of vectors whose weights are the variables corresponding to the non-pivot columns of A. The number of vectors in a basis for Nul A is the number of non-pivot columns of A.

  • The pivot columns of a matrix A form a basis for the column space of A.

Exercises Exercises

1.

Find a basis for the null space and column space of the matrix

A=[1234002βˆ’21252].

Of which spaces are the null and column spaces of A subspaces?

2.

If the column space of [12βˆ’111112c] has basis {[111],[212]}, what must c be?

3.

If the null space of [21a12b] has basis {[2βˆ’11]}, what must a and b be?

4.

Find a matrix with at least four non-zero and distinct columns for which the column space has basis {[111],[223]}.

5.

Find a matrix with at least two rows whose null space has basis {[11βˆ’1]}.

6.

Find a matrix whose column space has basis {[111],[223]} and whose null space has basis {[21βˆ’1]}.

7.

If possible, find a 4Γ—4 matrix whose column space does not equal R4 but whose null space equals {0}. Explain your answer. If not possible, explain why not.

8.

Label each of the following statements as True or False. Provide justification for your response.

(a) True/False.

For a 3Γ—4 matrix, the null space contains vectors other than the zero vector.

(b) True/False.

For a 4Γ—3 matrix, the null space contains vectors other than the zero vector.

(c) True/False.

If Nul A is not the zero subspace, then the transformation x↦Ax is not one-to-one.

(d) True/False.

If the transformation x↦Ax is onto where A is an mΓ—n matrix, then Col A=Rm.

(e) True/False.

For a 4Γ—3 matrix A, Col A cannot equal R4.

(f) True/False.

For a 3Γ—4 matrix A, Col A cannot equal R3.

(g) True/False.

The null space of the matrix [111111111] consists of the two vectors [βˆ’1 0 1]T and [0 βˆ’1 1]T.

(h) True/False.

A basis for the null space of the matrix [111111111] consists of the two vectors [βˆ’1 0 1]T and [0 βˆ’1 1]T.

(i) True/False.

There does not exist a matrix whose null space equals its column space.

(j) True/False.

The column space of every 4Γ—4 matrix is R4 and its null space is {0}.

Subsection Project: Solving the Lights Out Game

The Lights Out game starts with a 5Γ—5 grid on which some of the squares are lit (on) and some are not lit (off). We will call such a state a configuration. Pressing a square that is on turns it off and changes the state of all adjacent (vertically and horizontally) squares, and pressing a square that is off turns it on and changes the state of all adjacent (vertically and horizontally) squares. To model this situation, we consider the number system Z2={0,1} consisting only of 0 and 1, where 0 represents the off state and 1 the on state. We can also think of 1 as the act of pressing a square and 0 as the act of not pressing β€” that is,

  • 0+0=0 (not pressing an off square leaves it off),

  • 0+1=1=1+0 (pressing an off square turns it on or not pressing a lit square leaves it lit),

  • 1+1=0 (pressing a lit square turns it off).

The numbers 0 and 1 in Z2 will be the only numbers we use when playing the Lights Out game, so all of our matrix entries will be in Z2 and all of our calculations are done in Z2.

There are two ways we can view a Lights Out game.

  • We can view each configuration as a 5Γ—5 matrix. In this situation, we label the entries in the grid as shown in Figure 13.10. Each entry in the grid will be assigned a 0 or 1 according to whether the light in that entry is off or on.

  • For our purposes a better way to visualize a Lights Out configuration is as a 25Γ—1 vector. The components in this vector correspond to the entries in the 5Γ—5 grid with the correspondence given by the numbering demonstrated in Figure 13.10 (for the sake of space, this array is shown in a row instead of a column). Again, each component is assigned a 0 or 1 according to whether the light for that entry is off or on. In this view, each configuration is a vector with 25 components in Z2.

Figure 13.10. Two representations of the Lights Out game.

We will take the latter perspective and view the Lights Out game as if it is played on a 25Γ—1 board with entries in Z2. The space of all of these Lights Out configurations is denoted as Z225 (similar to R25, but with entries in Z2 rather than R). Since Z2 is a field, the space Z225 is a vector space just as R25 is. This is the environment in which we will play the Lights Out game.

If we think about the game as played on a 25Γ—1 board, then pressing a square correlates to selecting one of the 25 components of a configuration vector. Each time we press a square, we make a move that changes the status of that square and all the squares vertically or horizontally adjacent to it from the 5Γ—5 board. Recalling that adding 1 to a square has the effect of changing its status (from on to off or off to on), and each move that we make in the game can be represented as a 25Γ—1 vector that is added to a configuration. For example, the move of pressing the first square is given by adding the vector

m1=[1 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]T

to a configuration vector and the move of pressing the second square is represented by adding the vector

m2=[1 1 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]T.

Project Activity 13.5.

Let mi be the move of pressing the ith square for i from 1 to 25.

(a)

Find vector representations for m9 and m22.

(b)

Let M=[mij]=[m1|m2|β‹―|m25]. Explain why mij=mji for each i and j. In other words, explain why MT=M. (Such a matrix is called a symmetric matrix.)

The goal of the Lights Out game is to begin with an initial configuration c (a vector in Z225) and determine if we can apply a sequence of moves to obtain the configuration in which all the entries are 0 (or all the lights are off). The vector in Z225 of all 0s is the zero vector in Z225 and we will denote it as 0. Some basic algebra of vector addition in Z2 (or mod 2) will help us understand the strategy.

Start with a configuration c. If we press the ith square, then we obtain the new configuration c1=mi+c (where each move mi is also in Z225).

Project Activity 13.6.

(a)

What happens if we press the ith square twice in a row? Explain in terms of the action and the game and verify using vector addition.

(b)

Explain why applying move mi then move mj is the same as applying move mj, then mi.

(c)

Explain how the answers to the previous two questions show that to play the game we only need to determine which buttons to press (and only once each) without worrying about the order in which the buttons are pressed.

What we have seen is that to play the game we are really looking for scalars x1, x2, …, x25 in Z2 (in other words, either 0 or 1) so that

(13.1)x1m1+x2m2+β‹―+x25m25+c=0.

Project Activity 13.7.

Explain why (13.1) has the equivalent matrix equation

(13.2)Mx=c,

where M=[m1|m2|β‹―|m25], or

M=[1100010000000000000000000111000100000000000000000001110001000000000000000000011100010000000000000000000110000100000000000000010000110001000000000000000100011100010000000000000001000111000100000000000000010001110001000000000000000100011000010000000000000001000011000100000000000000010001110001000000000000000100011100010000000000000001000111000100000000000000010001100001000000000000000100001100010000000000000001000111000100000000000000010001110001000000000000000100011100010000000000000001000110000100000000000000010000110000000000000000000100011100000000000000000001000111000000000000000000010001110000000000000000000100011].

Explicitly identify the vector x. Also, explain why c is on the right side of this equation.

To solve a Lights Out game now, all we need do is determine a solution, if one exists, to the matrix equation (13.2).

Project Activity 13.8.

For this activity you may use the fact that the reduced row echelon form of the matrix M (using algebra in Z2) is as shown below.

(a)

Find a basis for the column space of M.

(b)

Explain why not every Lights Out puzzle can be solved. That is, explain why there are some initial configurations of lights on and off for which it is not possible to turn out all the lights (without turning off the game). Relate this to the column space of M.

The reduced row echelon form of the matrix M (using algebra in Z2):

[1000000000000000000000001010000000000000000000001000100000000000000000000110001000000000000000000010000010000000000000000000100000100000000000000000110000001000000000000000000000000010000000000000001100000000100000000000000000000000001000000000000011000000000010000000000001000000000000100000000000100000000000001000000000000000000000000010000000001000000000000000100000000100000000000000001000000011000000000000000010000000000000000000000000100000110000000000000000001000000000000000000000000010001100000000000000000000100010000000000000000000001010000000000000000000000011100000000000000000000000000000000000000000000000000].

To find conditions under which a Lights Out game is not solvable, we will demonstrate that if A is an nΓ—n matrix, then the scalar product of any vector in Nul AT with any column of A is 0. Let A=[aij] be an nΓ—n matrix with columns a1, a2, …, an. Represent the entries in the ith column as ai=[a1i a2i β€¦ ani]T for each i between 1 and n. Note that ai is also the ith row of AT. Also, let x=[x1 x2 β€¦ xn]T be a vector in Nul AT. Then ATx=0. Using the row-column method of multiplying a matrix by a vector, when we multiply the ith row of AT with x we obtain

(13.3)a1ix1+a2ix2+β‹―+anixn=0.

This equation is valid for each i between 1 and n. Recall that the sum in (13.3) is the scalar product of ai and x and is denoted aiβ‹…x. That is,

aiβ‹…x=ai1x1+ai2x2+β‹―+ainxn.

The fact that x is in Nul AT means aiβ‹…x=0 for every i between 1 and n. In other words, the scalar product of any vector in Nul AT with any column of A is 0. (When the scalar product of two vectors is 0, we call the vectors orthogonal β€” a fancy word for β€œperpendicular”.) Since scalar products are linear, we can extend this result to the following.

With Theorem 13.11 in mind we can return to our analysis of the Lights Out game, applying this result to the matrix M.

Project Activity 13.9.

(a)

Find a basis for the null space of MT. (Recall that MT=M, so you can use the reduced row echelon form of M (using algebra in Z2) given earlier.)

(b)

Use Theorem 13.11 to show that if c=[c1 c2 β€¦ c25]T is an initial Lights Out configuration that is solvable, then c must be orthogonal to each of the vectors in a basis for Nul MT. Then show that if c is a solvable initial Lights Out configuration, c must satisfy

c2+c3+c4+c6+c8+c10+c11+c12+c14+c15+c16+c18+c20+c22+c23+c24=0

and

c1+c3+c5+c6+c8+c10+c16+c18+c20+c21+c23+c25=0.

Be very specific in your explanation.

Project Activity 13.10.

Now that we know which Lights Out games can be solved, let c be an initial configuration to a solvable Lights Out game. Explain how to find a solution to this game. Will the solution be unique? Explain.

Now that we have a strategy for solving the Lights Out game, use it to solve random puzzles at geogebra.org/m/wcmctahp, or create your own game to solve.