I understand how to solve systems of linear equations when they have the same number of variables as equations. But what about when there are only three equations and 4 variables? For example, when i was looking through an exam paper, i came across this question-

w + x + y + z = 1 
2w + x + 3y + z =7
2w + 2x + y + 2z =7

The question does not implicitly ask for us to solve using matrices, but it is in a question about matrices...

Any help would be appreciated!

  • 1
    $\begingroup$ Here is great video explaining this topic. $\endgroup$
    – Jakov Gl.
    Commented Jan 15, 2023 at 22:48

3 Answers 3


when you have $n$ equations and $m$ variables that $n<m$ you must consider $m-n$ variables free and fixed (they can take arbitrary value) then you try to solve your equation with $n$ equations and $n$ variables

as at this problem you can do it:




consider $z$ fixed:




with substract $2$ from $1$ we will have :$w+2y=6$

with substract $3$ from $-2(2)$ we will have : $-2w-5y=-7$

and so $w=16$ and $y=-5$

and with attention to (1) we will have


that $z$ is free variable (can take any value)


You can use Gaussian elimination on non-square matrix (similar to square matrix).

Actually, you already know that.

Hint: $0w + 0x + 0y + 0z = 0$

  • $\begingroup$ how is it possible to get upper triangular form on a non square matrix? $\endgroup$
    – Ryman
    Commented May 6, 2013 at 9:57
  • $\begingroup$ The important thing when trying to solve a system of linear equations is to make row echelon form. $\endgroup$
    – JiminP
    Commented May 6, 2013 at 10:03
  • $\begingroup$ And there can be some 0s on the diagonal of a triangular matrix. You might encountered some system of linear equations which has no solutions or infinite solutions. $\endgroup$
    – JiminP
    Commented May 6, 2013 at 10:03

There are a couple of things you have to pay attention to when solving a system of equations.

The first thing you want to pay attention to is the rank of the corresponding matrix, defined as the number of pivot rows in the Reduced Row Echelon form of your matrix (that you get at via Gaussian elimination). You can think of the rank as the number of independent equations. For example, if you have

$a + b = 3$


$2a + 2b = 6$,

those equations are not independent. The second one does not tell you anything that the first one doesn't tell you already.

So instead of characterizing a system as "m equations with n unknowns", treat it as "m independent equations with n unkowns".

The next thing you have to know is how to identify the solution space. Linear algebra tells you that if you have a matrix of rank r and n columns (unkowns), you will have n - r free variables that can take any value. Linear algebra also tells you that the complete solution space consists of any particular solution plus the null space of the matrix. To find both a particular solution and a basis for the null space, you will want to use the Reduced Row Echelon form.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .