Chapter 3 Exercises — Systems of Linear Equations

Work these with both pictures in mind: every "how many solutions?" question can be answered from the row picture (where do the surfaces meet?), the column picture (is $\mathbf{b}$ a combination of the columns?), and the rank test ($\operatorname{rank}(A)$ vs. $\operatorname{rank}([A\mid\mathbf{b}])$ vs. $n$). You are not expected to use row reduction — that algorithm is Chapter 4. Here, reason geometrically and verify with numpy. Tiers: ⭐ conceptual · ⭐⭐ hand computation · ⭐⭐⭐ proof (A) / coding (C) · ⭐⭐⭐⭐ application. Selected answers appear in the appendix.

⭐ Conceptual

3.1 State, in one sentence each, what the row picture and the column picture of a linear system are. Which one asks "where do lines/planes intersect?" and which asks "is $\mathbf{b}$ a linear combination of the columns?"

3.2 A linear system can have how many solutions? List every possibility and explain in one sentence why "exactly two" is impossible.

3.3 Classify each equation as linear or not, and say why: (a) $3x - 2y + z = 4$; (b) $xy + z = 1$; (c) $x_1 + 5x_2 - x_3 = 0$; (d) $\sqrt{x} + y = 2$; (e) $2x = 7$.

3.4 True or false, with a one-line reason: "A system with more equations than unknowns must be inconsistent." Give a small counterexample or confirmation.

3.5 Explain why a homogeneous system $A\mathbf{x} = \mathbf{0}$ can never be inconsistent. What is the one question that remains for a homogeneous system?

3.6 In three unknowns, describe a geometric arrangement of three planes that gives (a) exactly one solution, (b) no solution with no two planes parallel, and (c) infinitely many solutions.

3.7 What does it mean for a square matrix $A$ to be singular, and what does np.linalg.solve(A, b) do when $A$ is singular?

⭐⭐ Hand computation

3.8 For the system $\;x + y = 4,\; x - y = 2\;$: (a) find the solution by inspection; (b) write it in column-picture form $x\,\mathbf{a}_1 + y\,\mathbf{a}_2 = \mathbf{b}$ and state the two column vectors and the target; (c) confirm the weights you found rebuild $\mathbf{b}$.

3.9 Sketch (by hand) the two lines for $\;2x + 4y = 8,\; x + 2y = 6\;$. Are they crossing, parallel-distinct, or coincident? How many solutions does the system have?

3.10 Sketch the two lines for $\;x - 3y = 1,\; -2x + 6y = -2\;$. How many solutions, and why? Describe the solution set with a free variable.

3.11 Write the augmented matrix $[A\mid\mathbf{b}]$ for $\;3x + y - z = 2,\; x + 2z = 5,\; -y + 4z = 0\;$. Identify which column is the constants and which entry is $a_{23}$ (row 2, column 3) in the coefficient matrix.

3.12 Without solving, decide how many solutions $\;x + 2y + 3z = 6,\; 2x + 4y + 6z = 11\;$ has. (Hint: compare the two equations' coefficients and constants.)

3.13 Express the solution set of $\;x + y + z = 3\;$ (a single equation in three unknowns) using two free variables. What is the dimension of the solution set?

3.14 For the homogeneous system $\;x + 2y = 0,\; 3x + 6y = 0\;$, find all solutions and describe them as a line through the origin in $\mathbb{R}^2$, giving a direction vector.

⭐⭐⭐ Proof (A) / Coding (C)

3.15 (Proof, A) Prove that if $\mathbf{x}_0$ and $\mathbf{x}_1$ are both solutions of $A\mathbf{x} = \mathbf{b}$, then $\mathbf{x}_1 - \mathbf{x}_0$ is a solution of the homogeneous system $A\mathbf{x} = \mathbf{0}$. (This is the engine behind the "particular + homogeneous" structure.)

3.16 (Proof, A) Using Exercise 3.15, prove that a consistent system has either exactly one solution or infinitely many — never some finite number greater than one. (Hint: if a nonzero homogeneous solution $\mathbf{h}$ exists, what are $\mathbf{x}_0 + t\mathbf{h}$ for all real $t$?)

3.17 (Proof, A) Show that $A\mathbf{x} = \mathbf{b}$ is consistent if and only if $\mathbf{b}$ is a linear combination of the columns of $A$. (Use the definition $A\mathbf{x} = x_1\mathbf{a}_1 + \cdots + x_n\mathbf{a}_n$ from Chapter 1.)

3.18 (Coding, C) Write a function classify(A, b) that returns the string "none", "one", or "infinitely many" using only np.linalg.matrix_rank. Apply the rank criterion: unequal ranks → none; equal ranks with rank = number of unknowns → one; equal ranks with rank < unknowns → infinitely many. Test it on the four systems from the chapter's Build Your Toolkit callout.

3.19 (Coding, C) For the system $\;2x + y = 5,\; x - y = 1\;$, use np.linalg.solve to find the solution, then verify by computing A @ x and checking it equals b with np.allclose. Why is np.allclose preferable to == here?

3.20 (Coding, C) Construct a $3\times 3$ singular coefficient matrix (make the third row the sum of the first two). Pick a right-hand side that makes the system (a) inconsistent and (b) consistent, and in each case print np.linalg.matrix_rank(A) and np.linalg.matrix_rank(np.column_stack([A, b])). Explain how the two cases differ in the printout.

3.21 (Coding, C) Use np.linalg.lstsq(A, b, rcond=None) on a dependent (infinitely-many-solutions) system and print the returned solution and the returned rank. Explain why the single vector it returns is not "the" solution, and describe the full solution set.

⭐⭐⭐⭐ Application

3.22 (Mixture / chemistry) A lab needs $100$ mL of a solution that is $38\%$ acid, mixing a $20\%$ stock and a $50\%$ stock. Let $x, y$ be the millilitres of each stock. Set up the linear system ($x + y = 100$ and $0.2x + 0.5y = 38$), predict the number of solutions from the geometry, then solve with np.linalg.solve. (Expected: $x = 40,\ y = 60$.)

3.23 (Network flow / engineering) At a road junction, traffic conservation gives the node equations $\;f_1 + f_2 = 800,\; f_2 + f_3 = 600,\; f_1 - f_3 = 200\;$ (cars/hour on three road segments). (a) Show the third equation is dependent on the first two. (b) Conclude how many solutions exist and describe the one-parameter family of feasible flows. (c) What additional real-world constraint (e.g. a sensor reading $f_3$) would pin down a unique flow?

3.24 (Economics — input–output, ties to the case study) A two-sector economy satisfies $\;(I - A)\mathbf{x} = \mathbf{d}\;$ where $A = \begin{bmatrix}0.2 & 0.3\\ 0.4 & 0.1\end{bmatrix}$ is the consumption matrix and $\mathbf{d} = (90, 80)^{\mathsf{T}}$ is final demand. (a) Form the coefficient matrix $I - A$. (b) Argue from the column picture why a unique production vector $\mathbf{x}$ should exist (the columns of $I - A$ are independent). (c) Solve with np.linalg.solve and interpret $\mathbf{x}$ as the total output each sector must produce.

3.25 (PageRank seed — the anchor) A tiny three-page web has page 1 linking to pages 2 and 3; page 2 linking to page 3; page 3 linking to page 1. (a) Explain in words why "page $i$'s importance is a share of the importances of pages linking to it" is a linear system in the unknown importances. (b) Why is the natural form $(\,M - I\,)\mathbf{r} = \mathbf{0}$ a homogeneous system, and what does the trivial solution $\mathbf{r} = \mathbf{0}$ mean (and why do we reject it)? (c) Without solving, name the Chapter (and the concept — eigenvector) where this system is actually computed for the real web.

3.26 (Synthesis) Invent one linear system in two unknowns for each of the three outcomes (none / one / infinitely many). For each, give the two equations, draw or describe the row picture, state the column picture, and predict the output of np.linalg.solve (a vector, or a LinAlgError). Then verify all three predictions in numpy.