Matrices for simultaneous equations
Overview
Matrix methods give another way to solve simultaneous equations. Instead of eliminating $x$ or substituting for $y$, the two equations are organized into a matrix equation:
$$ AX=B $$
Here, $A$ is the coefficient matrix, $X$ is the column matrix of unknowns, and $B$ is the column matrix of constants.
For two equations in $x$ and $y$, the idea is:
$$ \begin{cases} ax+by=e \\ cx+dy=f \end{cases} \quad \Longrightarrow \quad \begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} e \\ f \end{pmatrix} $$
The conceptual bridge is simple: each row of the coefficient matrix stores one equation. The first row stores the coefficients in the first equation, and the second row stores the coefficients in the second equation. Solving by matrices means using the inverse of the coefficient matrix to isolate the unknown column.
+ Syllabus Alignment
- Subject: Mathematics
- Level: CSEE
- Form: Mathematics Form IV
- Competence: Use algebra and matrices in problem solving
- Source topic ID:
topic-matrices-for-simultaneous-equations - Hub: Algebra And Matrices
This page expands the official Form IV Mathematics syllabus topic Matrices for simultaneous equations. The syllabus remains the authority for topic identity and placement. Exam-frequency files and extracted question mappings are used only as unreviewed assessment signals until checked against original papers. The 2022 examination-format crosswalk is official but broad, so it is treated as a format signal rather than a solved-question source.
Prerequisites
- Linear simultaneous equations - Learners should already understand what it means for one pair $(x,y)$ to satisfy both equations.
- Two-by-two matrices: operations, determinant, inverse, and transformations - The inverse matrix method depends on determinants and inverse matrices.
- Algebraic expressions and equations - Matrix equations still require careful algebra and substitution checks.
- Graphical solution of simultaneous equations - A solution pair can also be interpreted as the intersection point of two straight lines.
- Coordinate geometry: gradient and straight-line equations - The equations being solved are straight-line equations in coordinate form.
Learning Scope
This chapter covers converting two linear equations into matrix form, identifying the coefficient matrix, unknown matrix, and constant matrix, deciding whether the inverse method is possible, solving by $X=A^{-1}B$, checking the solution in the original equations, and using matrix form for simple word problems.
This page does not reteach all matrix operations from the beginning. It also does not cover systems with three or more unknowns, row-reduction methods, determinants larger than two-by-two, or nonlinear simultaneous equations.
Subtopics
From Equations To Matrix Form
Start with a pair of simultaneous equations:
$$ \begin{cases} 2x-y=5 \\ 3x+2y=4 \end{cases} $$
The coefficients of $x$ and $y$ form the coefficient matrix:
$$ A= \begin{pmatrix} 2 & -1 \\ 3 & 2 \end{pmatrix} $$
The unknowns form the column matrix:
$$ X= \begin{pmatrix} x \\ y \end{pmatrix} $$
The constants form the column matrix:
$$ B= \begin{pmatrix} 5 \\ 4 \end{pmatrix} $$
So the matrix equation is:
$$ \begin{pmatrix} 2 & -1 \\ 3 & 2 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 5 \\ 4 \end{pmatrix} $$
Key insight: The coefficient matrix stores coefficients only. The constants go in a separate column.
Keeping The Variable Order Fixed
The variable column $X$ usually uses:
$$ \begin{pmatrix} x \\ y \end{pmatrix} $$
If this order is used, every row of the coefficient matrix must list the coefficient of $x$ first and the coefficient of $y$ second.
For:
$$ 5x+3y=9 $$
the coefficient row is:
$$ \begin{pmatrix} 5 & 3 \end{pmatrix} $$
For:
$$ 10x+7y=11 $$
the coefficient row is:
$$ \begin{pmatrix} 10 & 7 \end{pmatrix} $$
Warning sign: If a learner writes the unknown column as $\begin{pmatrix}y\\x\end{pmatrix}$ but still lists coefficients as $x,y$, the system has been scrambled.
Standard Form Before Matrix Form
Equations should first be arranged so the variables are on the left and the constant is on the right:
$$ ax+by=e $$
For example:
$$ 2x=5+y $$
should be rewritten as:
$$ 2x-y=5 $$
Only then should the row be written as:
$$ \begin{pmatrix} 2 & -1 \end{pmatrix} $$
This step prevents sign errors.
Solving By The Inverse Matrix Method
If:
$$ AX=B $$
and $A$ has an inverse, multiply both sides by $A^{-1}$:
$$ A^{-1}AX=A^{-1}B $$
Since $A^{-1}A=I$, this becomes:
$$ X=A^{-1}B $$
This is the matrix version of "undoing" multiplication. The inverse matrix undoes the coefficient matrix.
When The Method Works
For:
$$ A= \begin{pmatrix} a & b \\ c & d \end{pmatrix} $$
the inverse exists only if:
$$ ad-bc \ne 0 $$
If $ad-bc=0$, the coefficient matrix is singular and the inverse matrix method cannot be used in the usual way.
In a simultaneous-equations context, a zero determinant warns that the equations may not have one unique solution.
The Main Routine
To solve two simultaneous equations by matrices:
- Rewrite both equations in standard form: $ax+by=e$.
- Form $A$, $X$, and $B$.
- Find $\det(A)$.
- If $\det(A)\ne 0$, find $A^{-1}$.
- Calculate $X=A^{-1}B$.
- Read off $x$ and $y$.
- Check the values in the original equations.
The check is part of the method, not a decoration. It catches wrong coefficient order, sign errors, and arithmetic slips.
Reading A Word Problem Into Matrix Form
Some questions describe two unknown quantities in words. Define the variables first, then write two equations.
Example context:
In a test, a candidate answered $49$ questions. Correct answers score $2$ marks and wrong answers lose $1$ mark. The score is $62$. If $x$ is the number of correct answers and $y$ is the number of incorrect answers, then:
$$ x+y=49 $$
and:
$$ 2x-y=62 $$
The matrix form is:
$$ \begin{pmatrix} 1 & 1 \\ 2 & -1 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 49 \\ 62 \end{pmatrix} $$
Key insight: The matrix method begins after the equations are formed. The word-problem thinking still matters.
Checking The Solution
Suppose the matrix method gives $x=37$ and $y=12$ for the test problem above. Check both original equations:
$$ 37+12=49 $$
and:
$$ 2(37)-12=62 $$
Both statements are true, so the solution is consistent with the problem.
If one check fails, do not simply change the final answer. Go back to the matrix form and inspect the coefficient order and signs.
Key Terms
| Term | Meaning | | --- | --- | | Simultaneous equations | Equations that must be true at the same time. | | Matrix form | A way of writing simultaneous equations as $AX=B$. | | Coefficient matrix | The matrix containing the coefficients of the unknowns. | | Unknown matrix | The column matrix containing the unknowns, usually $\begin{pmatrix}x\\y\end{pmatrix}$. | | Constant matrix | The column matrix containing the numbers on the right side of the equations. | | Determinant | For a two-by-two coefficient matrix $\begin{pmatrix}a&b\\c&d\end{pmatrix}$, the value $ad-bc$. | | Inverse matrix | The matrix $A^{-1}$ used to undo multiplication by $A$. | | Singular matrix | A matrix whose determinant is $0$ and therefore has no inverse. | | Unique solution | One pair of values that satisfies both equations. | | Check | Substituting the answer back into the original equations. |
Worked Examples
Example 1: Write Equations In Matrix Form
Write the following system in matrix form:
$$ \begin{cases} 5x+3y=9 \\ 10x+7y=11 \end{cases} $$
The coefficient matrix is:
$$ A= \begin{pmatrix} 5 & 3 \\ 10 & 7 \end{pmatrix} $$
The unknown matrix is:
$$ X= \begin{pmatrix} x \\ y \end{pmatrix} $$
The constant matrix is:
$$ B= \begin{pmatrix} 9 \\ 11 \end{pmatrix} $$
Therefore:
$$ \begin{pmatrix} 5 & 3 \\ 10 & 7 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 9 \\ 11 \end{pmatrix} $$
Example 2: Solve By Matrix Method
Solve:
$$ \begin{cases} 2x-y=5 \\ 3x+2y=4 \end{cases} $$
Write:
$$ A= \begin{pmatrix} 2 & -1 \\ 3 & 2 \end{pmatrix}, \quad X= \begin{pmatrix} x \\ y \end{pmatrix}, \quad B= \begin{pmatrix} 5 \\ 4 \end{pmatrix} $$
Find the determinant:
$$ \det(A)=2(2)-(-1)(3)=4+3=7 $$
Since $7\ne 0$, the inverse exists:
$$ A^{-1}=\frac{1}{7} \begin{pmatrix} 2 & 1 \\ -3 & 2 \end{pmatrix} $$
Now:
$$ X=A^{-1}B $$
So:
$$ X=\frac{1}{7} \begin{pmatrix} 2 & 1 \\ -3 & 2 \end{pmatrix} \begin{pmatrix} 5 \\ 4 \end{pmatrix} $$
Multiply:
$$ X=\frac{1}{7} \begin{pmatrix} 2(5)+1(4) \\ -3(5)+2(4) \end{pmatrix} = \frac{1}{7} \begin{pmatrix} 14 \\ -7 \end{pmatrix} = \begin{pmatrix} 2 \\ -1 \end{pmatrix} $$
Therefore:
$$ x=2,\qquad y=-1 $$
Check:
$$ 2(2)-(-1)=5 $$
and:
$$ 3(2)+2(-1)=4 $$
Both are true.
Example 3: Solve A System With Fractions
Solve:
$$ \begin{cases} 5x+3y=9 \\ 10x+7y=11 \end{cases} $$
The coefficient matrix is:
$$ A= \begin{pmatrix} 5 & 3 \\ 10 & 7 \end{pmatrix} $$
The determinant is:
$$ \det(A)=5(7)-3(10)=35-30=5 $$
So:
$$ A^{-1}=\frac{1}{5} \begin{pmatrix} 7 & -3 \\ -10 & 5 \end{pmatrix} $$
Then:
$$ X=A^{-1}B = \frac{1}{5} \begin{pmatrix} 7 & -3 \\ -10 & 5 \end{pmatrix} \begin{pmatrix} 9 \\ 11 \end{pmatrix} $$
Calculate:
$$ X= \frac{1}{5} \begin{pmatrix} 7(9)-3(11) \\ -10(9)+5(11) \end{pmatrix} = \frac{1}{5} \begin{pmatrix} 30 \\ -35 \end{pmatrix} = \begin{pmatrix} 6 \\ -7 \end{pmatrix} $$
Therefore:
$$ x=6,\qquad y=-7 $$
Check:
$$ 5(6)+3(-7)=9 $$
and:
$$ 10(6)+7(-7)=11 $$
Both are true.
Example 4: Word Problem In Matrix Form
A candidate answered $49$ questions in a test. A correct answer gives $2$ marks and a wrong answer gives $-1$ mark. The total score is $62$. Find the number of correct and wrong answers, assuming every answered question is either correct or wrong.
Let:
$$ x=\text{number of correct answers} $$
and:
$$ y=\text{number of wrong answers} $$
The number of answered questions gives:
$$ x+y=49 $$
The score gives:
$$ 2x-y=62 $$
Matrix form:
$$ \begin{pmatrix} 1 & 1 \\ 2 & -1 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 49 \\ 62 \end{pmatrix} $$
The determinant is:
$$ 1(-1)-1(2)=-3 $$
The inverse is:
$$ \frac{1}{-3} \begin{pmatrix} -1 & -1 \\ -2 & 1 \end{pmatrix} $$
Then:
$$ X= \frac{1}{-3} \begin{pmatrix} -1 & -1 \\ -2 & 1 \end{pmatrix} \begin{pmatrix} 49 \\ 62 \end{pmatrix} = \frac{1}{-3} \begin{pmatrix} -111 \\ -36 \end{pmatrix} = \begin{pmatrix} 37 \\ 12 \end{pmatrix} $$
So the candidate had $37$ correct answers and $12$ wrong answers.
Example 5: When The Inverse Method Fails
Consider:
$$ \begin{cases} 2x+4y=10 \\ x+2y=5 \end{cases} $$
The coefficient matrix is:
$$ A= \begin{pmatrix} 2 & 4 \\ 1 & 2 \end{pmatrix} $$
Its determinant is:
$$ 2(2)-4(1)=0 $$
The matrix is singular, so $A^{-1}$ does not exist.
Notice that the first equation is just twice the second equation. The system does not give two independent facts, so the usual inverse matrix method cannot produce one unique solution.
Common Mistakes
- Putting constants inside the coefficient matrix. Correction: coefficients go in $A$ and constants go in $B$.
- Forgetting to rewrite equations in standard form before making the matrix.
- Losing the sign of a negative coefficient, especially from equations such as $2x-y=5$.
- Changing the variable order halfway through the solution.
- Writing $AX=B$ correctly but then calculating $X=BA^{-1}$. Correction: use $X=A^{-1}B$.
- Using the inverse formula when $\det(A)=0$.
- Finding $A^{-1}$ correctly but multiplying it by $B$ entry-by-entry instead of row-by-column.
- Giving $x$ and $y$ without checking them in the original equations.
- Treating a word problem as a matrix problem before defining the variables and forming the two equations.
Practice Tasks
Foundation
- Write $\begin{cases}x+y=7\\2x-y=5\end{cases}$ in matrix form.
- Identify $A$, $X$, and $B$ in $\begin{pmatrix}3&2\\1&-4\end{pmatrix}\begin{pmatrix}x\\y\end{pmatrix}=\begin{pmatrix}8\\-6\end{pmatrix}$.
- Rewrite $3x=2y+7$ in standard form.
- For $4x-5y=9$, write the coefficient row if $X=\begin{pmatrix}x\\y\end{pmatrix}$.
- Find the determinant of $\begin{pmatrix}2&-1\\3&2\end{pmatrix}$.
Skill-Building
- Solve by matrix method: $x+y=9$ and $x-y=1$.
- Solve by matrix method: $2x+y=11$ and $x+3y=18$.
- Solve by matrix method: $3x+2y=13$ and $x-y=1$.
- Solve by matrix method: $5x+3y=9$ and $10x+7y=11$.
- Show that the inverse method cannot be used directly for $2x+4y=10$ and $x+2y=5$.
Exam-Style
- By using the matrix method, solve $2x-y=5$ and $3x+2y=4$.
- By using the matrix method, solve $5x+3y=9$ and $10x+7y=11$.
- A test has correct answers worth $2$ marks and wrong answers worth $-1$ mark. A learner answered $49$ questions and scored $62$ marks. Write the information in matrix form and solve.
- Two types of tickets were sold. Adult tickets cost Tsh $5,000$ and student tickets cost Tsh $3,000$. A total of $40$ tickets brought Tsh $164,000$. Form two equations and solve by the matrix method.
Challenge
- Create a pair of simultaneous equations whose coefficient matrix has determinant $1$, then solve it by the matrix method.
- Create a pair of simultaneous equations whose coefficient matrix has determinant $0$, then explain what goes wrong with the inverse method.
- Solve one system by elimination and by matrix method. Compare the checking steps.
- Explain why the order of $A^{-1}B$ matters even though $B$ is only a column matrix.
Generated Question Layer
Original generated practice for this topic should include:
- Direct conversion of two linear equations into $AX=B$.
- Identification of coefficient, unknown, and constant matrices from a given matrix equation.
- Standard-form correction tasks where signs must be fixed before matrix form is written.
- Inverse-method solution questions with small determinants, negative determinants, and fractional intermediate values.
- Singular coefficient matrix questions that ask why the inverse method is unavailable.
- Word-problem questions involving marks, prices, tickets, ages, and two quantities.
- Check-the-answer prompts that require substitution into both original equations.
- Error-analysis prompts where a learner used $BA^{-1}$, swapped coefficient order, or placed constants in the coefficient matrix.
- Include tutor-style prompts that ask learners to build $A$, $X$, and $B$ separately before any inverse calculation is shown.
These generated questions are not official past-paper questions. They are a learner-practice layer aligned to the syllabus topic and should be reviewed before high-stakes use.
Learner Aid Opportunities
- diagram: Map each equation row to the matching row of the coefficient matrix.
- chart: Step checklist for $AX=B$, $\det(A)$, $A^{-1}$, $X=A^{-1}B$, and checking.
- animation: Show $A^{-1}A$ becoming the identity matrix so that $X$ is isolated.
- interactive: Matrix-form builder where learners drag coefficients and constants into $A$, $X$, and $B$.
- interactive: Inverse-method solver with feedback on determinant, inverse formula, multiplication, and final check.
- video: Word-problem walkthrough from variables to equations to matrix solution.
- LLM tutor: Guided questioning that asks, "What are the two unknowns?", "What is the coefficient matrix?", and "Does the determinant allow an inverse?"
Exam-Derived Signals
The table below separates official format evidence from unreviewed extracted question mappings.
| Source | Status | Signal For This Topic | Use With Learners | | --- | --- | --- | --- | | data/exam_format_topic_crosswalk_2022.jsonl record format-041-spec-13 | official format crosswalk | The group Matrices and transformations is mapped to this topic and Two-by-two matrices: operations, determinant, inverse, and transformations, with 1 item and 7.14 percent weight in the format record. | Safe as a broad assessment-format signal, not as a claim about a specific past-paper question. | | data/topic_frequency_2021_2025.json | unreviewed extraction | This exact topic is listed in the topic registry but does not appear as a separately counted primary topic in the frequency totals consulted. Matrix-method records are counted under the broader two-by-two matrices topic. | Use only to guide review priority; absence of a separate count is not evidence of absence from assessment. | | data/question_map_2021_2025.jsonl | unreviewed extraction | Matrix-method simultaneous-equation records appear as primary matches for topic-two-by-two-matrices-operations-determinant-inverse-and-transformations with simultaneous-equation secondary signals. | Do not present as audited past-question links until manually reviewed and assigned to this page if appropriate. |
Selected unreviewed extracted records relevant to this page:
| Year | Question ID | Extracted Signal | Review Note | | ---: | --- | --- | --- | | 2021 | csee_041_2021_p1_q13_a | Solve simultaneous equations by matrix method. | Primary mapped to two-by-two matrices; secondary simultaneous-equations signal. | | 2023 | csee_041_2023_p1_q13_b_i | Write word-problem information in matrix form. | Direct matrix wording, unreviewed. | | 2023 | csee_041_2023_p1_q13_b_ii | Use inverse matrix method in the same word context. | Needs review because inverse wording may overlap other topics. | | 2025 | csee_041_2025_p1_q13_b | Solve simultaneous equations by matrix method. | Multi-topic candidate and missing-marks review flag. |
Source And Review Notes
- Official syllabus status: The topic identity, Form IV placement, competence, source topic ID, and hub come from the 2023 CSEE Mathematics syllabus through
data/curriculum_map.json. - Official source reference: The cited syllabus file is
raw/syllabuses/csee/2023/csee_mathematics_syllabus_2023.pdf. - Registry detail:
data/curriculum_map.jsonlists this as Form IV, sequence35, underalgebra-and-matrices. - Exam format status:
data/exam_format_topic_crosswalk_2022.jsonlmaps Matrices and transformations to this page and Two-by-two matrices: operations, determinant, inverse, and transformations as an official format crosswalk. - Exam signal status:
data/topic_frequency_2021_2025.jsonanddata/question_map_2021_2025.jsonlare unreviewed extraction sources and should not be treated as audited past-question references. - Review caution: Some matrix-method simultaneous-equation questions are currently mapped primarily to the broader two-by-two matrices page. A reviewer should decide whether to duplicate, split, or cross-link those records.
- Content authorship status: Explanations, worked examples, checking routines, mistake notes, and practice tasks are original learner-facing prose written from the syllabus topic and local assessment signals.
- Renderer QA: This page uses
$...$and$$...$$math notation for compatibility with Obsidian, KaTeX, and MathJax. Some plain Markdown viewers may show raw delimiters.
+ Related Pages
- Mathematics Form IV
- Algebra And Matrices
- Two-by-two matrices: operations, determinant, inverse, and transformations
- Linear simultaneous equations
- Graphical solution of simultaneous equations
- Coordinate geometry: gradient and straight-line equations
- Algebraic expressions and equations
- CSEE Mathematics Syllabus 2023