Linear Systems
as Matrices
Learn to represent a system of linear equations as a single matrix equation, a foundational concept in linear algebra.
What Is a Matrix?
A matrix is a rectangular array of numbers arranged in rows and columns. We describe the size of a matrix as \( m \times n \), where \( m \) is the number of rows and \( n \) is the number of columns.
Three Key Pieces of the Puzzle
To write a system of equations as a matrix equation, we need three special matrices:
From Equations to One Equation
Consider this system of two linear equations:
We can rewrite the entire system as the single matrix equation \( A\vec{x} = \vec{b} \):
Why Does This Work?
When we multiply the coefficient matrix \( A \) by the variable vector \( \vec{x} \), each row of \( A \) gets multiplied by the vector. This produces one equation per row:
Each row of the matrix product \( A\vec{x} \) is the dot product of that row with the variable vector. Setting the result equal to \( \vec{b} \) recovers our original system.
The Core Rule: \( A\vec{x} = \vec{b} \)
Any system of \( m \) linear equations in \( n \) unknowns can be written as:
Dimensions Must Match
For the matrix multiplication \( A\vec{x} \) to be valid, the number of columns in \( A \) must equal the number of rows in \( \vec{x} \):
Equations vs Matrix Form
| System of Equations | Matrix Equation | |
|---|---|---|
| Format | Multiple separate equations | Single equation: \( A\vec{x} = \vec{b} \) |
| Variables | Written out in each equation | Collected in one vector \( \vec{x} \) |
| Coefficients | Mixed in with variables | Isolated in matrix \( A \) |
| Scalability | Cumbersome for large systems | Same compact form for any size |
| Best For | Small systems, by-hand solving | Computation, theory, proofs |
How to Convert: Step by Step
Example 1: A \( 2 \times 2 \) System
Example 2: A \( 3 \times 3 \) System
Step 1: All equations already have \( x, y, z \) in order with explicit coefficients.
Example 3: Missing Variables
Key step: Insert zero coefficients for missing variables. Rewrite as:
Visualizing the Mapping
Reverse: Matrix to System
You can also go backwards: given a matrix equation, recover the system of equations by multiplying out each row.
Common Mistakes to Avoid
Summary: Putting It All Together
| Component | Symbol | Size | Contains |
|---|---|---|---|
| Coefficient Matrix | \( A \) | \( m \times n \) | Coefficients of each variable |
| Variable Vector | \( \vec{x} \) | \( n \times 1 \) | Unknowns: \( x, y, z, \ldots \) |
| Constant Vector | \( \vec{b} \) | \( m \times 1 \) | Right-hand side constants |
| Matrix Equation | \( A\vec{x} = \vec{b} \) | --- | Entire system in one line |
Question 1 of 5
Which matrix equation represents the system
\( \begin{cases} 3x + y = 7 \\ 2x - 4y = -1 \end{cases} \)?
Question 2 of 5
For the system \( \begin{cases} x - 2y + z = 3 \\ 4y - z = 0 \\ 2x + y = 5 \end{cases} \), what is the coefficient matrix \( A \)?
Question 3 of 5
The matrix equation \( \begin{bmatrix} 2 & -1 \\ 0 & 5 \end{bmatrix} \begin{bmatrix} x \\ y \end{bmatrix} = \begin{bmatrix} 9 \\ 15 \end{bmatrix} \) represents which system?
Question 4 of 5
A system of \(4\) equations in \(3\) unknowns would produce a coefficient matrix \( A \) of what size?
Question 5 of 5
In the equation \( A\vec{x} = \vec{b} \), the number of columns of \( A \) must equal which of the following?