Skip to content

03. System of Linear Equations

Dated: 11-03-2025

Linear Equations

The equation of a straight line1 in \(\mathbb R^2\) (the plane2) can be written as

\[a_1x + a_2y = b\]

Similarly, for \(\mathbb R^3\) (the space), the equation can be written as

\[a_1x + a_2y + a_3z= b\]

Similarly, for a hyper plane \(\mathbb R^n\)

\[a_1x_1 + a_2x_2 + \cdots + a_nx_n = b\]

where \(a_1, a_2, \ldots, b\) are constants and at least one of the \(a\) is not zero.

Homogeneous Linear Equation

If \(b = 0\) then the previous equation is called homogeneous linear equation.

\[a_1x_1 + a_2x_2 + \cdots + a_nx_n = 0\]

A linear equation contains following characteristics

  • They do not involve product of variables, such as \(xy\) terms.
  • The maximum power of the variables involved, do not exceed \(1\), (e.g. \(x^1\) is the maximum). Otherwise the equation is not linear.
  • The variables are not passed as arguments to functions3 like
    • Trigonometric functions
    • Exponential functions
    • Logarithmic functions4

System of Linear Equations

A finite set5 of linear equations is called a linear system or a system of linear equations.
The variables involved are called the unknowns.

General System of Linear Equations

A general linear system of \(m\) equations in \(n\) unknowns \(x_1, x_2, \ldots, x_n\) can be written as

\[ \begin{array}{cccccc} a_{11}x_1 &+& a_{12}x_2 &+& \cdots &+& a_{1n}x_n &= b_1 \\ a_{21}x_1 &+& a_{22}x_2 &+& \cdots &+& a_{2n}x_n &= b_2 \\ \vdots & & \vdots & & & & \vdots &\vdots \\ a_{m1}x_1 &+& a_{m2}x_2 &+& \cdots &+& a_{mn}x_n &= b_m \end{array} \]

Solution of a System of Linear Equations

A solution of a system of linear equations in \(n\) unknowns \(x_1, x_2, \ldots, x_n\) is a sequence of \(n\) numbers6 \(s_1, s_2, \ldots, s_n\) such that when substituted for \(x_1, x_2, \ldots, x_n\), respectively, makes every linear equation as true statements.
The set5 \(\{s_1, s_2, \ldots, s_n\}\) is called the solution set.5

Linear System in 2 Unknowns

Imagine a linear system in \(\mathbb R^2\).

\[a_1x + b_1y = c_1\]
\[a_2x + b_2y = c_2\]

There are 3 possibilities.

  1. The lines1 are parallel and distinct. Hence they don't intersect and there is no solution.
  2. The lines1 are not parallel and intersect at only one point, which is the solution.
  3. The lines1 are parallel and coincide. Hence there are infinite solutions.

Consistent

If the linear system has at least one solution then it is called consistent.

Inconsistent

If the linear system has no solutions then it is called inconsistent.

Linear System in 3 Unknowns

Imagine a linear system in \(\mathbb R^3\).

\[a_1x + b_1y + c_1z = d_1\]
\[a_2x + b_2y + c_2z = d_2\]
\[a_3x + b_3y + c_3z = d_3\]

In this case, graph of each equation is a plane.2
The solutions can be

  • Non existent
  • A single point
  • A line1
  • A plane2

Theorem 1

A linear system has

  • zero
  • one
  • infinite

solutions.

Example 1

\[x - y = 1\]
\[2x + y = 6\]

Adding both equations, we get \(x = \frac 7 3\).
Plugging \(x\) in either of the equations, we get \(y = \frac 4 3\).
Therefore, this system has a unique solution which is the point \(\left(\frac 7 3, \frac 4 3\right)\).

Example 2

\[x + y = 4\]
\[3x + 3y = 6\]

After multiplying the first equation by \(3\) and subtracting it from second equation, we get

\[0 = 6\]

Geometrically, this means there is no intersection between the lines due to them being parallel and distinct. Hence no solution.

Example 3

\[4x - 2y = 1\]
\[16x - 8y = 4\]

Multiplying the first equation by \(-4\) and then adding it to second equation, we get

\[0 = 0\]

This means that all the points which satisfy either the first or second equation are the solution. Geometrically, this means that these lines are parallel and coincide with each other.

Parametric Representation

Imagine

\[4x - 2y = 1\]

Now let \(y = t\)

\[4x - 2t = 1\]
\[\implies x(t) = \frac 1 4 + \frac 1 2 t, \quad y = t\]

In this case, selecting any \(t\) can possibly yield \(x(t)\).
Hence the solution(s) are \((x(t), t)\).

Example

\[x - y + 2z - 5= 0\]
\[2x - 2y + 4z - 10 = 0\]
\[3x - 3y + 6z - 15 = 0\]

Notice how if you multiply first equation by \(2\), you get the second equation and if you multiply by \(3\), you get the 3rd equation.
This means that any point satisfying any equation, will satisfy the whole system because these all planes coincide.

Matrix Notation

Imagine that

\[ \begin{align} x_1 - &2x_2 + x_3 &= 0 \\ &2x_2 - 8x_3 &= 8 \\ -4x_1 + &5x_2 + 9x_3 &= -9 \\ \end{align} \]
\[\Big\downarrow\]
\[ \begin{bmatrix} 1 & -2 & 1\\ 0 & 2 & -8\\ -4 & 5 & 9 \end{bmatrix} \]

This matrix7 is called the coefficient matrix.
The augmented matrix is obtained by appending the right side of the linear system.

\[ A_b = \begin{bmatrix} 1 & -2 & 1 & 0\\ 0 & 2 & -8 & 8\\ -4 & 5 & 9 & -9 \end{bmatrix} \]

Solving a Linear System

Successive Elimination Method

In this method the \(x_1\) term of first equation is used to eliminate \(x_1\) terms from the other systems. Then \(x_2\) term of second equation is used in similar way and so on.
Lets take the linear system from previous example

\[ A_b = \begin{bmatrix} 1 & -2 & 1 & 0\\ 0 & 2 & -8 & 8\\ -4 & 5 & 9 & -9 \end{bmatrix} \]
\[\Big\downarrow \text{eq}_3 = 4 \text{ eq}_1 + \text{eq}_3\]
\[ = \begin{bmatrix} 1 & -2 & 1 & 0\\ 0 & 2 & -8 & 8\\ 0 & -3 & 13 & -9 \end{bmatrix} \]
\[\Big\downarrow \text{eq}_2 = \frac 1 2 \text{ eq}_2\]
\[ = \begin{bmatrix} 1 & -2 & 1 & 0\\ 0 & 1 & -4 & 4\\ 0 & -3 & 13 & -9 \end{bmatrix} \]
\[\Big\downarrow \text{eq}_3 = 3 \text{ eq}_2 + \text{eq}_3\]
\[ = \begin{bmatrix} 1 & -2 & 1 & 0\\ 0 & 1 & -4 & 4\\ 0 & 0 & 1 & 3 \end{bmatrix} \]
\[\Big\downarrow \text{eq}_2 = 4 \text{ eq}_3 + \text{eq}_2\]
\[ = \begin{bmatrix} 1 & -2 & 0 & -3\\ 0 & 1 & 0 & 16\\ 0 & 0 & 1 & 3 \end{bmatrix} \]
\[\Big\downarrow \text{eq}_1 = 2 \text{ eq}_2 + \text{eq}_1\]
\[ = \begin{bmatrix} 1 & 0 & 0 & 29\\ 0 & 1 & 0 & 16\\ 0 & 0 & 1 & 3 \end{bmatrix} \]
\[ = \begin{cases} x_1 = 29 \\ x_2 = 16 \\ x_3 = 3 \end{cases} \]

Elementary Row Operations

  1. Replacement. Replace a row by adding a nonzero multiple of any row to it.
  2. Interchange. Interchange two rows.
  3. Scaling. Multiply all entries7 in the row by a nonzero value.

Row Equivalent Matrices

If \(A\) and \(B\) are two matrices7 such that \(B\) can be obtained by performing finite amount of elementary row operations on \(A\) and vise versa then they are said to be row equivalent matrices.

\[A \sim B\]

If \(A\) and \(B\) are augmented matrices of two linear systems and \(A \sim B\) then they both have same solution set.

Two Fundamental Questions

  1. Is the system consistent; that is, does at least one solution exist?
  2. If a solution exists is it the only one; that is, is the solution unique?

References

Read more about notations and symbols.


  1. Read more about lines

  2. Read more about planes

  3. Read more about functions

  4. Read more about logarithms

  5. Read more about sets

  6. Read more about numbers

  7. Read more about matrices