Systems of linear equations — exam-style exercises with the shake, a parameter that changes everything, the equations of a subspace and a 20-question quiz (and the row of zeros that scared me)

In the Campus quiz on systems, row reducing gave me a whole row of zeros, I wrote “inconsistent” and got the question wrong. The row was (0  0  0∣0)(0 \; 0 \; 0 \mid 0): an equation saying 0=00 = 0, which always holds and was simply redundant. The system had infinitely many solutions. That confusion, the row of zeros versus the impossible row, is the first fragment of “What’s wrong here?”, and it is in the quiz too.

How to use this article

In the AG exam, EX=(T+P)/2EX = (T + P)/2: T is the 20-question quiz drawn from the Campus quizzes and P, the written exercises on paper. You can see how it combines with the quizzes and the MATLAB assignments in the AG grade calculator.

In recent years’ exams there is no exercise only about systems, but solving a system is the first step of almost every other one: the bases of a subspace come from a homogeneous system, so do the eigenvectors, and intersections of lines and planes are systems. So the exercises here are in the format of an exam question (points and marking criteria), and the last one is exactly the homogeneous system that appears in the subspaces exercise. And for part T, at the end, a 20-question quiz like the Campus one.

  1. Do each exercise on paper: write the augmented matrix, classify with Rouché and then solve.
  2. Compare with the expected result and, if it does not match, open the hint before looking at the solution.
  3. In “What’s wrong here?”, look for the mistake yourself before reading the explanation.
  4. Take the quiz and check the exercises in MATLAB or in the Gauss-Jordan step-by-step simulator, which classifies with Rouché and row reduces with exact fractions.

If some method gets stuck in your throat, go back to the guided practice.

Exercise 1 (basic level): another shake

Exercise 1. [3 points] With oats (xx), milk (yy) and banana (zz), and the usual data per serving (oats 4, 18, 2; milk 6, 10, 3; banana 1, 24, 0 grams of protein, carbs and fat), I want a shake with 17 g of protein, 62 g of carbs and 8 g of fat. a) (0.5 points) Write the system and its augmented matrix. b) (1.5 points) Classify it and solve it by Gaussian elimination. c) (1 point) Check the value of yy with Cramer’s rule, knowing that ∣A∣=34|A| = 34.

Expected result: unique solution; x=1x = 1, y=2y = 2, z=1z = 1.

Start with the fat equation and halve the carbs one. They are the same operations as in the theory: only the last column changes.

Exercise 2 (intermediate level): discussing a parameter

Exercise 2. [4 points] Consider the system mx−y+z=1mx – y + z = 1, my−z=1my – z = 1, 2x−y+z=12x – y + z = 1, with m∈Rm \in \mathbb{R}. a) (2 points) Discuss it for the values of mm. b) (1 point) Solve it when it has a unique solution. c) (1 point) Solve it when it has infinitely many.

Expected result: ∣A∣=(m−1)(m−2)|A| = (m – 1)(m – 2); unique solution if m≠1m \neq 1 and m≠2m \neq 2, with x=0x = 0, y=2m−1y = \frac{2}{m – 1}, z=m+1m−1z = \frac{m + 1}{m – 1}; inconsistent if m=1m = 1; infinitely many with one parameter if m=2m = 2.

Before row reducing, subtract the third equation from the first: you get (m−2)x=0(m – 2)x = 0. That already tells you a lot about xx.

Exercise 3 (challenge): how it appears in the exam

In the subspaces exercise of the exam you are given a subspace by its implicit equations and asked for a basis. The first step is always the same: solve the homogeneous system those equations form. Bases belong to topic 3, but the system is today’s.

Exercise 3. [3 points] Consider the homogeneous system x+y+z+t=0x + y + z + t = 0, x−y+2z=0x – y + 2z = 0, 2x+3z+t=02x + 3z + t = 0. a) (1 point) Find the rank of the coefficient matrix and classify the system. b) (1.5 points) Solve it by Gauss-Jordan. c) (0.5 points) Write the solution as a combination of fixed vectors, choosing the parameters so that there are no fractions.

Expected result: rank 2, infinitely many solutions with 2 parameters; (x,y,z,t)=α(−3,1,2,0)+β(−1,−1,0,2)(x, y, z, t) = \alpha(-3, 1, 2, 0) + \beta(-1, -1, 0, 2).

Check whether the third equation is the sum of the other two. If it is, the system really has two equations.

What’s wrong here?

Three solutions, each with one mistake. Read, look for the error and then read the explanation.

Fragment 1: the row of zeros

 x + 2y -  z = 3          | 1  2 -1 | 3 |              | 1  2 -1 |  3 |
2x + 4y - 2z = 6    -->   | 2  4 -2 | 6 |  f2-2f1      | 0  0  0 |  0 |
 x -  y +  z = 0          | 1 -1  1 | 0 |  f3-f1  -->  | 0 -3  2 | -3 |

A row of zeros has appeared: the system is INCONSISTENT.

Predict: how many solutions does it have?

The row (0  0  0∣0)(0 \; 0 \; 0 \mid 0) is 0=00 = 0: it imposes nothing, it only says the second equation was twice the first. Two useful equations in three unknowns remain: rg(A)=rg(A∣B)=2<3rg(A) = rg(A \mid B) = 2 < 3, infinitely many solutions with one parameter. With z=λz = \lambda: from the third row, −3y+2λ=−3⇒y=1+23λ-3y + 2\lambda = -3 \Rightarrow y = 1 + \tfrac23 \lambda; from the first, x=3−2y+λ=1−13λx = 3 – 2y + \lambda = 1 – \tfrac13 \lambda.

The redundant row and the impossible rowLeft: a row of zeros with constant term 0, which is the equation 0 = 0 and is redundant. Right: a row of zeros with constant term 5, which is the impossible equation 0 = 5 and makes the system inconsistent.0000(0 0 0 | 0)0 = 0always true: redundantchanges nothing0005(0 0 0 | 5)0 = 5impossibleincompatible
It all comes down to the last number in the row.

Confusing (0  0  0∣0)(0 \; 0 \; 0 \mid 0) with (0  0  0∣c)(0 \; 0 \; 0 \mid c). The first is redundant; the second is impossible. The last number is what counts.

Fragment 2: Cramer with a zero determinant

 x +  y = 2
2x + 2y = 4

|A| = 1·2 - 1·2 = 0   ->   x = |A1| / 0   ->   cannot divide by 0
CONCLUSION: the system has no solution.

Predict: is it true that it has no solution?

No. ∣A∣=0|A| = 0 only says that Cramer cannot be applied, not that there is no solution. The second equation is the first times 2 (constant term included), so it is the same line: infinitely many solutions, x=2−λx = 2 – \lambda, y=λy = \lambda. With ∣A∣=0|A| = 0 you have to look at the ranks: here rg(A)=rg(A∣B)=1rg(A) = rg(A \mid B) = 1.

Reading “∣A∣=0|A| = 0” as “inconsistent”. With ∣A∣=0|A| = 0 the system may be inconsistent or have infinitely many solutions, and only the ranks of AA and (A∣B)(A \mid B) decide.

Fragment 3: too many equations

 x +  y = 3
 x -  y = 1
2x +  y = 5

There are 3 equations and only 2 unknowns, so the system is inconsistent.

Predict: does it have a solution?

Yes: the first two give x=2x = 2, y=1y = 1, and the third holds, 2⋅2+1=52 \cdot 2 + 1 = 5. It has a unique solution. The number of equations decides nothing; the ranks do: rg(A)=2rg(A) = 2 and rg(A∣B)=2rg(A \mid B) = 2 (the determinant of the 3×33 \times 3 augmented matrix is 0), with n=2n = 2.

Classifying by size. It is the trick question from the Campus quiz (“with more equations than unknowns, always inconsistent”: false).

Solutions

Exercise 1

a) Each nutrient is an equation and each ingredient, a column:

4x+6y+z=1718x+10y+24z=622x+3y=8(A∣B)=(46117181024622308) \begin{array}{rcl} 4x + 6y + z & = & 17 \\ 18x + 10y + 24z & = & 62 \\ 2x + 3y & = & 8 \end{array} \qquad (A \mid B) = \left(\begin{array}{ccc|c} 4 & 6 & 1 & 17 \\ 18 & 10 & 24 & 62 \\ 2 & 3 & 0 & 8 \end{array}\right)

Before touching the matrix, the plan. Classifying and solving come out of the same row reduction: you count the steps of A A and of (A∣B) (A \mid B) and, if there is a unique solution, you substitute from the bottom up. The only thing to decide is how to row reduce with the least arithmetic.

The obvious move would be to leave the equations as they come and use the 4 of the protein as the pivot. It works, but f2→f2−184f1 f_2 \to f_2 – \frac{18}{4} f_1 gives (0,−17,392,−292) (0, -17, \frac{39}{2}, -\frac{29}{2}) : fractions from the very first step. That is why the order changes:

  • Fat goes on top because its pivot is a 2 and it has a 0 in the banana column: when you subtract it, the z z column does not change.
  • The carbs are halved because all their numbers are even: (9,5,12,31) (9, 5, 12, 31) has the same solutions and is lighter.

Changing the order of the equations does not change the solutions: they are the same conditions, read in a different order.

b) With fat on top and the carbs halved:

(230846117951231)→f3→2f3−9f1f2→f2−2f1(230800110−1724−10)→f2↔f3(23080−1724−100011) \left(\begin{array}{ccc|c} 2 & 3 & 0 & 8 \\ 4 & 6 & 1 & 17 \\ 9 & 5 & 12 & 31 \end{array}\right) \xrightarrow[f_3 \to 2f_3 – 9f_1]{f_2 \to f_2 – 2f_1} \left(\begin{array}{ccc|c} 2 & 3 & 0 & 8 \\ 0 & 0 & 1 & 1 \\ 0 & -17 & 24 & -10 \end{array}\right) \xrightarrow{f_2 \leftrightarrow f_3} \left(\begin{array}{ccc|c} 2 & 3 & 0 & 8 \\ 0 & -17 & 24 & -10 \\ 0 & 0 & 1 & 1 \end{array}\right)

The row 3 arithmetic: 2⋅31−9⋅8=62−72=−102 \cdot 31 – 9 \cdot 8 = 62 – 72 = -10. Three steps in AA and in (A∣B)(A \mid B): p=q=n=3p = q = n = 3, unique solution. From the bottom up: z=1z = 1; −17y+24=−10⇒y=2-17y + 24 = -10 \Rightarrow y = 2; 2x+6=8⇒x=12x + 6 = 8 \Rightarrow x = 1.

For c), the plan. Cramer gives each unknown as a quotient of two determinants, and the bottom one, ∣A∣=34 |A| = 34 , is given in the statement. So there is only one to work out: the top one for y y . You do not need x x or z z : here Cramer is a check on b).

Which column do you replace? The one for the unknown you are after: y y is the milk, the second column.

Replacing the second row instead of the second column. The columns are the ingredients; the rows, the nutrients. You are after an ingredient, so you replace a column.

And the 0 of the fat is still in the third row: two of the six Sarrus products are 0 for free.

c) For yy, the milk column replaced by (17,62,8)(17, 62, 8):

y=∣4171186224280∣34=0+816+144−124−0−76834=6834=2 y = \frac{\begin{vmatrix} 4 & 17 & 1 \\ 18 & 62 & 24 \\ 2 & 8 & 0 \end{vmatrix}}{34} = \frac{0 + 816 + 144 – 124 – 0 – 768}{34} = \frac{68}{34} = 2

Why it is done this way: the order of the equations is chosen to get a small pivot and a 0 that saves arithmetic. And the final check, in the original system: 4+12+1=174 + 12 + 1 = 17, 18+20+24=6218 + 20 + 24 = 62, 2+6=82 + 6 = 8.

How it is marked (indicative, my own): a) 0.5; b) 0.5 for the classification with Rouché and 1 for solving it; c) 1 (0.5 for the determinant and 0.5 for the ratio).

Exercise 2

Before working anything out, the plan. The temptation is to row reduce with the m m inside, but to make zeros you end up dividing by things like m−1 m – 1 , which can be 0: cases pop up halfway through and it is easy to forget one. Since A A is square, there is a tidier route:

  1. Work out ∣A∣ |A| in terms of m m . Wherever it is not zero, rg(A)=3 rg(A) = 3 : unique solution without row reducing anything.
  2. Find the roots of ∣A∣=0 |A| = 0 . They are the only awkward values.
  3. For each root, substitute and look at the ranks of A A and of (A∣B) (A \mid B) , now with no letters.

Step 3 needs the augmented matrix: with m=1 m = 1 and with m=2 m = 2 you get rg(A)=2 rg(A) = 2 in both cases, and the only thing that tells them apart is the rank of (A∣B) (A \mid B) .

a) By Sarrus:

∣A∣=∣m−110m−12−11∣=m2+2+0−2m−0−m=m2−3m+2=(m−1)(m−2) |A| = \begin{vmatrix} m & -1 & 1 \\ 0 & m & -1 \\ 2 & -1 & 1 \end{vmatrix} = m^2 + 2 + 0 – 2m – 0 – m = m^2 – 3m + 2 = (m – 1)(m – 2)

Check the six products: m⋅m⋅1=m2m \cdot m \cdot 1 = m^2, (−1)(−1)(2)=2(-1)(-1)(2) = 2, 1⋅0⋅(−1)=01 \cdot 0 \cdot (-1) = 0; and subtracting 1⋅m⋅2=2m1 \cdot m \cdot 2 = 2m, (−1)⋅0⋅1=0(-1) \cdot 0 \cdot 1 = 0 and m⋅(−1)(−1)=mm \cdot (-1)(-1) = m.

  • If m≠1m \neq 1 and m≠2m \neq 2: ∣A∣≠0|A| \neq 0, rg(A)=rg(A∣B)=3=nrg(A) = rg(A \mid B) = 3 = n: unique solution.
  • If m=1m = 1: the augmented matrix is
(1−11101−112−111)→f3→f3−2f1(1−11101−1101−1−1)→f3→f3−f2(1−11101−11000−2) \left(\begin{array}{ccc|c} 1 & -1 & 1 & 1 \\ 0 & 1 & -1 & 1 \\ 2 & -1 & 1 & 1 \end{array}\right) \xrightarrow{f_3 \to f_3 – 2f_1} \left(\begin{array}{ccc|c} 1 & -1 & 1 & 1 \\ 0 & 1 & -1 & 1 \\ 0 & 1 & -1 & -1 \end{array}\right) \xrightarrow{f_3 \to f_3 – f_2} \left(\begin{array}{ccc|c} 1 & -1 & 1 & 1 \\ 0 & 1 & -1 & 1 \\ 0 & 0 & 0 & -2 \end{array}\right)

The last row is 0=−20 = -2: rg(A)=2<rg(A∣B)=3rg(A) = 2 < rg(A \mid B) = 3, inconsistent.

  • If m=2m = 2: the first and third equations coincide (2x−y+z=12x – y + z = 1), so two independent equations remain: rg(A)=rg(A∣B)=2<3rg(A) = rg(A \mid B) = 2 < 3, infinitely many solutions with one parameter.

For b), the obvious move would be Cramer with the m m inside: three more determinants. It gives the same thing (the one for y y comes out as 2(m−2) 2(m – 2) , and dividing by (m−1)(m−2) (m – 1)(m – 2) leaves 2m−1 \frac{2}{m – 1} ), but it is a lot of arithmetic for something you can see sooner: the first and third equations only differ in the coefficient of x x . When you subtract them, y y and z z disappear, and since m≠2 m \neq 2 you can divide by m−2 m – 2 . With x=0 x = 0 , two equations in two unknowns remain.

Check you’ve got it: is m = 0 a special case?

No: with m=0 m = 0 there is a unique solution, with x=0 x = 0 , y=−2 y = -2 and z=−1 z = -1 .

Step by step: ∣A∣=(0−1)(0−2)=2≠0 |A| = (0 – 1)(0 – 2) = 2 \neq 0 . A term disappearing when m=0 m = 0 does not make 0 special: the only special values are the ones that make ∣A∣ |A| zero. Check it: 2−1=1 2 – 1 = 1 , 0+1=1 0 + 1 = 1 and 0+2−1=1 0 + 2 – 1 = 1 .

b) Subtracting the third equation from the first: (m−2)x=0(m – 2)x = 0, and since m≠2m \neq 2, x=0x = 0. That leaves −y+z=1-y + z = 1 and my−z=1my – z = 1; adding them, (m−1)y=2(m – 1)y = 2:

x=0,y=2m−1,z=1+y=m+1m−1 x = 0, \qquad y = \frac{2}{m – 1}, \qquad z = 1 + y = \frac{m + 1}{m – 1}

With m=3m = 3, for example: x=0x = 0, y=1y = 1, z=2z = 2. Check in the second equation: 3⋅1−2=13 \cdot 1 – 2 = 1.

c) With m=2m = 2: 2x−y+z=12x – y + z = 1 and 2y−z=12y – z = 1. I take y=λy = \lambda as the parameter: z=2λ−1z = 2\lambda – 1 and 2x−λ+2λ−1=1⇒x=1−λ22x – \lambda + 2\lambda – 1 = 1 \Rightarrow x = 1 – \tfrac{\lambda}{2}.

x=1−λ2,y=λ,z=2λ−1,λ∈R x = 1 – \frac{\lambda}{2}, \qquad y = \lambda, \qquad z = 2\lambda – 1, \qquad \lambda \in \mathbb{R}

Why it is done this way: the trick of subtracting equations before row reducing is not compulsory, but in a system with a parameter any combination that leaves a simple equation saves cases. In c), yy is chosen as the parameter so that zz comes out without fractions; taking xx as the parameter also works, it just looks different.

How it is marked (indicative):

PartWhat earns the marksPoints
a)Determinant and its roots0.75
a)General case, unique, with Rouché0.25
a)m=1m = 1: inconsistent, with the impossible row or the ranks0.5
a)m=2m = 2: infinitely many, with the ranks0.5
b)Solution in terms of mm1
c)Solution with one parameter1

Exercise 3

a) The third equation is the sum of the first two: (1+1)x+(1−1)y+(1+2)z+(1+0)t=2x+3z+t(1 + 1) x + (1 – 1) y + (1 + 2) z + (1 + 0) t = 2x + 3z + t. So the rank is at most 2, and the minor ∣111−1∣=−2≠0\begin{vmatrix} 1 & 1 \\ 1 & -1 \end{vmatrix} = -2 \neq 0 says it is exactly 2. Homogeneous with rg(A)=2<4rg(A) = 2 < 4: infinitely many solutions with 4−2=24 – 2 = 2 parameters.

For b), the plan: you are after the reduced form, a 1 on each step and zeros above and below, because from there the unknowns come out without substituting backwards. The arithmetic below, with the reason for each step:

StepOperationResulting rowWhy
1f2→f2−f1 f_2 \to f_2 – f_1 (0,−2,1,−1) (0, -2, 1, -1) Zero below the 1 of x x
2f3→f3−2f1 f_3 \to f_3 – 2f_1 (0,−2,1,−1) (0, -2, 1, -1) The same in the third row
3f3→f3−f2 f_3 \to f_3 – f_2 (0,0,0,0) (0, 0, 0, 0) It is what you saw in a): one equation was redundant
4f2→−12f2 f_2 \to -\frac12 f_2 (0,1,−12,12) (0, 1, -\frac12, \frac12) A 1 on the step
5f1→f1−f2 f_1 \to f_1 – f_2 (1,0,32,12) (1, 0, \frac32, \frac12) Zero above the 1 of y y

Why are z z and t t the parameters? The steps have ended up in the columns of x x and y y , so each of them is solved from its own row. The columns without a step have no row of their own: those are the free ones. Two others would also work, but you would have to solve again.

b) Gauss-Jordan on the coefficient matrix (in a homogeneous system, the column of zeros never changes and can be left out):

(11111−1202031)→f3→f3−2f1f2→f2−f1(11110−21−10−21−1)→f3→f3−f2(11110−21−10000) \begin{pmatrix} 1 & 1 & 1 & 1 \\ 1 & -1 & 2 & 0 \\ 2 & 0 & 3 & 1 \end{pmatrix} \xrightarrow[f_3 \to f_3 – 2f_1]{f_2 \to f_2 – f_1} \begin{pmatrix} 1 & 1 & 1 & 1 \\ 0 & -2 & 1 & -1 \\ 0 & -2 & 1 & -1 \end{pmatrix} \xrightarrow{f_3 \to f_3 – f_2} \begin{pmatrix} 1 & 1 & 1 & 1 \\ 0 & -2 & 1 & -1 \\ 0 & 0 & 0 & 0 \end{pmatrix}
→f2→−12f2(111101−12120000)→f1→f1−f2(10321201−12120000) \xrightarrow{f_2 \to -\frac12 f_2} \begin{pmatrix} 1 & 1 & 1 & 1 \\ 0 & 1 & -\frac12 & \frac12 \\ 0 & 0 & 0 & 0 \end{pmatrix} \xrightarrow{f_1 \to f_1 – f_2} \begin{pmatrix} 1 & 0 & \frac32 & \frac12 \\ 0 & 1 & -\frac12 & \frac12 \\ 0 & 0 & 0 & 0 \end{pmatrix}

The free unknowns are zz and tt: x=−32z−12tx = -\tfrac32 z – \tfrac12 t, y=12z−12ty = \tfrac12 z – \tfrac12 t.

c) To get rid of the halves, z=2αz = 2\alpha and t=2βt = 2\beta: x=−3α−βx = -3\alpha – \beta, y=α−βy = \alpha – \beta. Separating what goes with α\alpha and what goes with β\beta:

(xyzt)=α(−3120)+β(−1−102),α,β∈R \begin{pmatrix} x \\ y \\ z \\ t \end{pmatrix} = \alpha \begin{pmatrix} -3 \\ 1 \\ 2 \\ 0 \end{pmatrix} + \beta \begin{pmatrix} -1 \\ -1 \\ 0 \\ 2 \end{pmatrix}, \qquad \alpha, \beta \in \mathbb{R}

Check the first vector in the three equations: −3+1+2+0=0-3 + 1 + 2 + 0 = 0, −3−1+4=0-3 – 1 + 4 = 0, −6+6+0=0-6 + 6 + 0 = 0. In topic 3 those two vectors will be a basis of the subspace, and their number, 2, its dimension: today’s degrees of freedom. The diagram shows it.

The solution as a combination of vectorsThe solutions of the homogeneous system written as alpha times the vector (−3, 1, 2, 0) plus beta times the vector (−1, −1, 0, 2): two parameters, two vectors.(x, y, z, t) = α · v₁ + β · v₂-3120-1-102v₁ (z = 2, t = 0)v₂ (z = 0, t = 2)2 parameters= 2 vectors(topic 3: basis and dimension 2)
Each parameter brings one vector; in topic 3 they will be called a basis.

How it is marked (indicative): a) 0.5 for the justified rank and 0.5 for the classification; b) 1.5 for the reduced form and the unknowns solved; c) 0.5 for the two vectors.

Check it in MATLAB

format rat
%% Exercise 1
A = [4 6 1; 18 10 24; 2 3 0];
rref([A [17; 62; 8]])
A2 = A;  A2(:, 2) = [17; 62; 8];  det(A2)/det(A)   % Cramer for y
%% Exercise 2
syms m
Am = [m -1 1; 0 m -1; 2 -1 1];  Bm = [1; 1; 1];
d = det(Am)
rank(subs(Am, m, 1)), rank(subs([Am Bm], m, 1))   % 2 and 3: inconsistent
rank(subs(Am, m, 2)), rank(subs([Am Bm], m, 2))   % 2 and 2: infinitely many
inv(subs(Am, m, 3))*Bm                             % m = 3: (0, 1, 2)
%% Exercise 3
H = [1 1 1 1; 1 -1 2 0; 2 0 3 1];
rank(H)
rref(H)
null(H, 'r')

Output:

ans =

       1              0              0              1       
       0              1              0              2       
       0              0              1              1       

ans =

       2       

 
d =
 
m^2 - 3*m + 2
 

ans =

       2       

ans =

       3       

ans =

       2       

ans =

       2       

 
ans =
 
0
1
2
 

ans =

       2       

ans =

       1              0              3/2            1/2     
       0              1             -1/2            1/2     
       0              0              0              0       

ans =

      -3/2           -1/2     
       1/2           -1/2     
       1              0       
       0              1       

null(H, 'r') gives two columns: the solutions with z=1,t=0z = 1, t = 0 and with z=0,t=1z = 0, t = 1. They are half our vectors (MATLAB does not clear the fractions), but they describe the same set of solutions.

Campus-style quiz

These 20 questions are like the ones in the Campus quiz on systems of linear equations: matching, true or false, single answer, several correct answers, fill in the gaps, ordering and a few short calculations. They are original and belong to the question bank of the AG mock exam. The rules are those of the exam: no negative marking, except in the several correct answers questions, where each wrongly ticked option cancels a correctly ticked one. About 15 minutes; repeat it whenever you like.

Question 1Match

Match each condition on the ranks (with nn unknowns) with the classification of the system:

rg(A) = rg(A|B) = n
rg(A) = rg(A|B) < n
rg(A) < rg(A|B)

Definitions:

  • Homogeneous
  • Infinitely many solutions
  • Inconsistent
  • Unique solution
Solution
  • rg(A) = rg(A|B) = n → Unique solution
  • rg(A) = rg(A|B) < n → Infinitely many solutions
  • rg(A) < rg(A|B) → Inconsistent

This is the Rouché-Frobenius theorem. “Homogeneous” is not a classification by solutions: it means the constant terms are 0.

Question 2True or false

Say whether each statement is true or false:

  1. A system with more equations than unknowns is always inconsistent.
  2. A system with fewer equations than unknowns never has a unique solution.
  3. A homogeneous system always has at least one solution.
  4. A linear system can have exactly two solutions.
Solution
  • F — A system with more equations than unknowns is always inconsistent.
  • T — A system with fewer equations than unknowns never has a unique solution.
  • T — A homogeneous system always has at least one solution.
  • F — A linear system can have exactly two solutions.

With more equations than unknowns it is usually inconsistent, but if the extra ones are combinations of the others it can be consistent. With fewer equations, there are at most as many pivots as equations and some unknowns are left free. And if there are two different solutions, there are infinitely many.

Question 3Single choice

When row reducing the augmented matrix of a system in 3 unknowns, the row (0    0    0∣0)(0 \;\; 0 \;\; 0 \mid 0) appears. What can you be sure of?

  1. Nothing yet: that row only says one equation was redundant
  2. The system is inconsistent
  3. The system has a unique solution
  4. The system has exactly one parameter
Solution

Answer: Nothing yet: that row only says one equation was redundant

The row (0  0  0∣0)(0 \; 0 \; 0 \mid 0) is the equation 0=00 = 0, which always holds. What is inconsistent is (0  0  0∣c)(0 \; 0 \; 0 \mid c) with c≠0c \neq 0. To classify, compare rg(A)rg(A), rg(A∣B)rg(A \mid B) and nn.

Question 4Short answer

A consistent system has 5 unknowns and its coefficient matrix has rank 3. How many parameters (degrees of freedom) does its solution have? Write only the number.

Solution

Answer: 2

Degrees of freedom = n−rg(A)=5−3=2n – rg(A) = 5 – 3 = 2.

Question 5Multiple · wrong ticks subtract

What is needed to apply Cramer’s rule to a system?

  1. As many equations as unknowns
  2. A non-zero determinant of the coefficient matrix
  3. It must be homogeneous
  4. All coefficients must be non-zero
Solution

Answer: As many equations as unknowns · A non-zero determinant of the coefficient matrix

Cramer needs a square system with ∣A∣≠0|A| \neq 0: then it has a unique solution and xi=∣Ai∣/∣A∣x_i = |A_i| / |A|.

Question 6Single choice

The system x+2y=3x + 2y = 3, 2x+4y=52x + 4y = 5 is:

  1. Inconsistent
  2. Consistent with a unique solution
  3. Consistent with infinitely many solutions
  4. You cannot tell without solving it
Solution

Answer: Inconsistent

The second equation has the coefficients of the first times 2, but 2⋅3=6≠52 \cdot 3 = 6 \neq 5. They are two parallel lines: f2−2f1f_2 – 2f_1 gives 0=−10 = -1.

Question 7Single choice

The system x−y=1x – y = 1, −3x+3y=−3-3x + 3y = -3 is:

  1. Consistent with infinitely many solutions
  2. Consistent with a unique solution
  3. Inconsistent
  4. Homogeneous
Solution

Answer: Consistent with infinitely many solutions

The second equation is the first times −3-3, constant term included: it is the same line. rg(A)=rg(A∣B)=1<2rg(A) = rg(A \mid B) = 1 < 2.

Question 8True or false

About Gaussian and Gauss-Jordan elimination:

  1. Gaussian elimination brings the augmented matrix to echelon form and then you substitute from the bottom up.
  2. Gauss-Jordan reaches the reduced row echelon form, with zeros above and below each pivot.
  3. Multiplying an equation by 2 changes the solutions of the system.
  4. Swapping two equations does not change the solutions.
Solution
  • T — Gaussian elimination brings the augmented matrix to echelon form and then you substitute from the bottom up.
  • T — Gauss-Jordan reaches the reduced row echelon form, with zeros above and below each pivot.
  • F — Multiplying an equation by 2 changes the solutions of the system.
  • T — Swapping two equations does not change the solutions.

The three elementary operations give equivalent systems (with the same solutions). Multiplying a row by 2 does change the determinant, but that does not affect the solutions.

Question 9Fill in the gaps

Complete the sentence:

In an echelon matrix, the unknowns whose column has a pivot are called ____ unknowns, and the rest are called ____ unknowns or parameters; their number equals the ____ of the system.

Words:

  • free
  • trivial
  • independent
  • pivot
  • equations
  • degrees of freedom
Solution

In an echelon matrix, the unknowns whose column has a pivot are called pivot unknowns, and the rest are called free unknowns or parameters; their number equals the degrees of freedom of the system.

The unknowns without a pivot are chosen freely and the pivot unknowns are written in terms of them.

Question 10Single choice

A square homogeneous system with ∣A∣≠0|A| \neq 0:

  1. Only has the trivial solution
  2. Has infinitely many solutions
  3. Is inconsistent
  4. Has exactly two solutions
Solution

Answer: Only has the trivial solution

With ∣A∣≠0|A| \neq 0, rg(A)=nrg(A) = n and the solution is unique; since X=0X = 0 is a solution, it is the only one.

Question 11Single choice

The reduced row echelon form of an augmented matrix is (102301−11)\left(\begin{array}{ccc|c} 1 & 0 & 2 & 3 \\ 0 & 1 & -1 & 1 \end{array}\right). The solution of the system is:

  1. x=3−2λx = 3 – 2\lambda, y=1+λy = 1 + \lambda, z=λz = \lambda
  2. x=3x = 3, y=1y = 1, z=0z = 0
  3. x=3+2λx = 3 + 2\lambda, y=1−λy = 1 – \lambda, z=λz = \lambda
  4. It has no solution
Solution

Answer: x=3−2λx = 3 – 2\lambda, y=1+λy = 1 + \lambda, z=λz = \lambda

The zz column has no pivot: z=λz = \lambda. Each row is read by moving zz to the right: x+2λ=3x + 2\lambda = 3 and y−λ=1y – \lambda = 1.

Question 12Short answer

Solve x+y=5x + y = 5, x−y=1x – y = 1 and write the value of xx.

Solution

Answer: 3

Adding the two equations: 2x=62x = 6, x=3x = 3; then y=2y = 2.

Question 13Multiple · wrong ticks subtract

What does the number of parameters of a consistent system with infinitely many solutions depend on?

  1. The rank of the coefficient matrix
  2. The number of unknowns
  3. The number of equations
  4. The constant terms
Solution

Answer: The rank of the coefficient matrix · The number of unknowns

Parameters =n−rg(A)= n – rg(A). The number of equations does not count by itself: an equation that is a combination of others does not change the rank.

Question 14Single choice

In Cramer’s rule, to compute yy in a 3×33 \times 3 system, the numerator is the determinant of:

  1. The coefficient matrix with its second column replaced by the constant terms
  2. The coefficient matrix with its second row replaced by the constant terms
  3. The augmented matrix
  4. The coefficient matrix without its second column
Solution

Answer: The coefficient matrix with its second column replaced by the constant terms

y=∣A2∣/∣A∣y = |A_2| / |A|, where A2A_2 is AA with the column of yy (the second) replaced by the column of constant terms.

Question 15True or false

About the solutions of AX=BAX = B and of the homogeneous system AX=0AX = 0:

  1. If X1X_1 and X2X_2 solve AX=BAX = B, then X1−X2X_1 – X_2 solves AX=0AX = 0.
  2. The general solution of a consistent system is one particular solution plus those of the homogeneous system.
  3. If X1X_1 and X2X_2 solve AX=BAX = B (with B≠0B \neq 0), so does X1+X2X_1 + X_2.
Solution
  • T — If X1X_1 and X2X_2 solve AX=BAX = B, then X1−X2X_1 – X_2 solves AX=0AX = 0.
  • T — The general solution of a consistent system is one particular solution plus those of the homogeneous system.
  • F — If X1X_1 and X2X_2 solve AX=BAX = B (with B≠0B \neq 0), so does X1+X2X_1 + X_2.

A(X1−X2)=B−B=0A(X_1 – X_2) = B – B = 0. On the other hand A(X1+X2)=2B≠BA(X_1 + X_2) = 2B \neq B if B≠0B \neq 0.

Question 16Single choice

The system x+y=2x + y = 2, x−y=0x – y = 0, 3x+y=43x + y = 4 (three equations, two unknowns) is:

  1. Consistent with a unique solution
  2. Inconsistent because there are more equations than unknowns
  3. Consistent with infinitely many solutions
  4. It is not a linear system
Solution

Answer: Consistent with a unique solution

The first two give x=y=1x = y = 1, and the third holds: 3+1=43 + 1 = 4. rg(A)=rg(A∣B)=2=nrg(A) = rg(A \mid B) = 2 = n.

Question 17Order

Put the steps for discussing a square system with a parameter aa in order:

  1. Substitute each special value and compare the ranks of A and of the augmented matrix
  2. Find the values of aa that make it zero
  3. For all other values, conclude that the solution is unique
  4. Compute the determinant of the coefficient matrix in terms of aa
Solution

Correct order:

  1. Compute the determinant of the coefficient matrix in terms of aa
  2. Find the values of aa that make it zero
  3. For all other values, conclude that the solution is unique
  4. Substitute each special value and compare the ranks of A and of the augmented matrix

The determinant separates the general case (unique solution) from the special values, which are studied one by one.

Question 18Single choice

In a system of 4 equations in 3 unknowns, rg(A)=3rg(A) = 3 and rg(A∣B)=4rg(A \mid B) = 4. The system is:

  1. Inconsistent
  2. Consistent with a unique solution because rg(A) = n
  3. Consistent with 1 parameter
  4. You cannot tell without the constant terms
Solution

Answer: Inconsistent

rg(A)<rg(A∣B)rg(A) < rg(A \mid B): inconsistent. Row reducing produces a row (0  0  0∣c)(0 \; 0 \; 0 \mid c) with c≠0c \neq 0.

Question 19True or false

With two equations in two unknowns, each equation is a line in the plane:

  1. If the lines meet at one point, the system has a unique solution.
  2. If they are parallel and distinct, it is inconsistent.
  3. If they are the same line, it is inconsistent.
Solution
  • T — If the lines meet at one point, the system has a unique solution.
  • T — If they are parallel and distinct, it is inconsistent.
  • F — If they are the same line, it is inconsistent.

The solutions are the common points: one (they meet), none (parallel) or infinitely many (the same line).

Question 20Short answer

For which value of kk does the system x+2y=1x + 2y = 1, 3x+ky=23x + ky = 2 NOT have a unique solution? Write only the number.

Solution

Answer: 6

∣A∣=k−6|A| = k – 6, which vanishes at k=6k = 6. With k=6k = 6, f2−3f1f_2 – 3f_1 gives 0=−10 = -1: inconsistent.

What next?

With this topic you close the foundations of AG: matrices, determinants and systems. In topic 3, vector spaces and subspaces, today’s exercise 3 becomes “find a basis and the dimension”, and the rank takes center stage again to tell whether some vectors are independent. If you want to practice the mechanics, the Gauss-Jordan step-by-step simulator solves any system with you, and if your matrices are rusty, go over the matrices and determinants exercises. Start with the vector spaces theory.

AG exam coming up?The test and practical packs with new solved questions and exercises, their cheat sheets, a blank test and practical exam and MATLAB functions, for free.See the pack

Cheat sheet: systems of linear equations

The essentials in 30 seconds: write the augmented matrix, row reduce and compare p=rg(A)p = rg(A), q=rg(A∣B)q = rg(A \mid B) and nn. p=q=np = q = n: one solution; p=q<np = q < n: infinitely many with n−pn – p parameters; p<qp < q: none. (0⋯0∣0)(0 \cdots 0 \mid 0) is redundant; (0⋯0∣c≠0)(0 \cdots 0 \mid c \neq 0) is impossible.

I want to…By handMATLAB
ClassifyRow reduce and compare pp, qq, nn (or ranks with minors)rank(A), rank([A B]), size(A,2)
Solve a unique-solution systemGaussian elimination and substitute, or Gauss-Jordan and readrref([A B])
Solve an infinitely-many systemGauss-Jordan; unknowns without a pivot = parametersrref([A B])
Get one unknown of a 3×33 \times 3Cramer: xi=∣Ai∣/∣A∣x_i = \lvert A_i \rvert / \lvert A \rvert if ∣A∣≠0\lvert A \rvert \neq 0A2 = A; A2(:,i) = B; det(A2)/det(A)
Get the solutions of a homogeneous systemGauss-Jordan and split by parametersnull(A, 'r')
Discuss a parameterDeterminant, roots, general case unique, each root separatelysyms a, det, subs, rank

Templates for the exercises:

  • System with numbers: augmented matrix → row reduce → Rouché → solve → check in the original.
  • System with a parameter: ∣A∣|A| in terms of the parameter → roots → for the rest, unique and its solution → each root: substitute, row reduce and compare ranks.
  • Homogeneous: rank → parameters =n−rg(A)= n – rg(A) → reduced form → solution as a combination of vectors (without fractions if possible).
SymptomLikely cause
You get a row (0⋯0∣0)(0 \cdots 0 \mid 0) and write “inconsistent”You are confusing the redundant row with the impossible one
You have parameters to spareAn equation not copied, or a pivot you missed
The solution does not satisfy the original systemAn arithmetic slip while row reducing (check in the original, not in the echelon form)
Cramer “has no solution”∣A∣=0\lvert A \rvert = 0: Cramer does not apply, look at the ranks
You write “inconsistent” because there are more equationsClassifying by size instead of by ranks

Before handing in, ask yourself:

  1. Did I classify with the ranks (not the number of equations) before solving?
  2. If there are infinitely many solutions, did I give the general solution with the parameters?
  3. If there was a parameter, did I study separately each value that makes the determinant zero?
  4. Did I check the solution in the original system?
Keep goingAll Linear algebra articles

Did this article help you? Here is how you can support SergioLearns →

Ready for the exam?AG theory mock exam — the 20-question test with the Campus rules, no negative marking (and the catch in the several-correct ones)