MatheramaMatherama
← Matrices and Determinants
Matrices and Determinants·Section 10·10 min read

System of Linear Equations

System of Linear Equations§

A system of linear equations consists of multiple linear equations involving the same set of variables. In general, a system with mm equations and nn variables can be represented as:

{a11x1+a12x2+⋯+a1nxn=b1a21x1+a22x2+⋯+a2nxn=b2⋮am1x1+am2x2+⋯+amnxn=bm\begin{cases} a_{11}x_1 + a_{12}x_2 + \dots + a_{1n}x_n = b_1 \\ a_{21}x_1 + a_{22}x_2 + \dots + a_{2n}x_n = b_2 \\ \vdots \\ a_{m1}x_1 + a_{m2}x_2 + \dots + a_{mn}x_n = b_m \end{cases}

This is called a rectangular system if the number of equations (mm) is not equal to the number of variables (nn). However, we are particularly interested in square systems, where the number of equations equals the number of variables (m=nm = n).

In a square system, the equations can be represented as:

{a11x1+a12x2+⋯+a1nxn=b1a21x1+a22x2+⋯+a2nxn=b2⋮an1x1+an2x2+⋯+annxn=bn\begin{cases} a_{11}x_1 + a_{12}x_2 + \dots + a_{1n}x_n = b_1 \\ a_{21}x_1 + a_{22}x_2 + \dots + a_{2n}x_n = b_2 \\ \vdots \\ a_{n1}x_1 + a_{n2}x_2 + \dots + a_{nn}x_n = b_n \end{cases}

For example, you may recall from class 10 how to solve a system of two linear equations with two variables, such as:

{a1x+b1y=d1a2x+b2y=d2\begin{cases} a_1x + b_1y = d_1 \\ a_2x + b_2y = d_2 \end{cases}

where xx and yy are the variables, and a1a_1, b1b_1, d1d_1, etc., are constants.

In this section, we will primarily focus on solving square systems with three variables, which involves three linear equations of the form:

{a1x+b1y+c1z=d1a2x+b2y+c2z=d2a3x+b3y+c3z=d3\begin{cases} a_1x + b_1y + c_1z = d_1 \\ a_2x + b_2y + c_2z = d_2 \\ a_3x + b_3y + c_3z = d_3 \end{cases}

where xx, yy, and zz are the variables we aim to solve for, and the constants aia_i, bib_i, cic_i, and did_i are known values.

Solving a system of linear equations in three variables can be done using methods such as substitution, elimination, or matrix methods (like Cramer's Rule or Gaussian elimination (that we already discussed in the beginning)), which provide systematic approaches to find the values of xx, yy, and zz that satisfy all three equations simultaneously.'

Consistency§

A consistent system of linear equations is a system that has at least one solution. This means that there exists at least one set of values for the unknowns that satisfies all the equations simultaneously. Consistent systems can be further classified into:

  • Uniquely consistent: A system that has exactly one solution.
  • Infinitely consistent: A system that has infinitely many solutions.

For example:

x+y=2x + y = 2 2x+2y=42x + 2y = 4

This system is consistent with infinitely many solutions because the second equation is a multiple of the first, meaning the two equations represent the same line.

An inconsistent system of linear equations is a system that has no solution. In such a system, there are no values for the unknowns that can simultaneously satisfy all the equations. This typically occurs when the equations represent parallel lines or planes that do not intersect.

For example:

x+y=2x + y = 2 x+y=3x + y = 3

This system is inconsistent because the two equations represent parallel lines that never intersect. Therefore, there are no values of xx and yy that satisfy both equations simultaneously.

Cramer's Rule§

Let's write down the steps more mathematically. We start with the system:

{a1x+b1y+c1z=d1a2x+b2y+c2z=d2a3x+b3y+c3z=d3\begin{cases} a_1 x + b_1 y + c_1 z = d_1 \\ a_2 x + b_2 y + c_2 z = d_2 \\ a_3 x + b_3 y + c_3 z = d_3 \end{cases}

Let the determinant Δ=∣a1b1c1a2b2c2a3b3c3∣\Delta = \begin{vmatrix} a_1 & b_1 & c_1 \\ a_2 & b_2 & c_2 \\ a_3 & b_3 & c_3 \end{vmatrix}.

To proceed, we multiply each equation by the cofactor of the respective aia_i in Δ\Delta:

  1. Multiply the first equation by the cofactor C11C_{11} of a1a_1:

    C11(a1x+b1y+c1z)=C11d1C_{11} (a_1 x + b_1 y + c_1 z) = C_{11} d_1
  2. Multiply the second equation by the cofactor C21C_{21} of a2a_2:

    C21(a2x+b2y+c2z)=C21d2C_{21} (a_2 x + b_2 y + c_2 z) = C_{21} d_2
  3. Multiply the third equation by the cofactor C31C_{31} of a3a_3:

    C31(a3x+b3y+c3z)=C31d3C_{31} (a_3 x + b_3 y + c_3 z) = C_{31} d_3

Now, add these three equations:

C11(a1x+b1y+c1z)+C21(a2x+b2y+c2z)+C31(a3x+b3y+c3z)=C11d1+C21d2+C31d3C_{11} (a_1 x + b_1 y + c_1 z) + C_{21} (a_2 x + b_2 y + c_2 z) + C_{31} (a_3 x + b_3 y + c_3 z) = C_{11} d_1 + C_{21} d_2 + C_{31} d_3

Expanding the left-hand side:

(C11a1+C21a2+C31a3)x+(C11b1+C21b2+C31b3)y+(C11c1+C21c2+C31c3)z(C_{11} a_1 + C_{21} a_2 + C_{31} a_3) x + (C_{11} b_1 + C_{21} b_2 + C_{31} b_3) y + (C_{11} c_1 + C_{21} c_2 + C_{31} c_3) z

By properties of determinants:

  • (C11a1+C21a2+C31a3)=Δ(C_{11} a_1 + C_{21} a_2 + C_{31} a_3) = \Delta,
  • (C11b1+C21b2+C31b3)=0(C_{11} b_1 + C_{21} b_2 + C_{31} b_3) = 0,
  • (C11c1+C21c2+C31c3)=0(C_{11} c_1 + C_{21} c_2 + C_{31} c_3) = 0.

Thus, the equation reduces to:

Δx=C11d1+C21d2+C31d3\Delta x = C_{11} d_1 + C_{21} d_2 + C_{31} d_3

The right-hand side, C11d1+C21d2+C31d3C_{11} d_1 + C_{21} d_2 + C_{31} d_3, can be recognized as the determinant Δ1\Delta_1, obtained by replacing the first column of Δ\Delta with d1d_1, d2d_2, and d3d_3:

Δx=Δ1\Delta x = \Delta_1

Similarly, by replacing the second column with d1d_1, d2d_2, and d3d_3, we get Δy=Δ2\Delta y = \Delta_2, and by replacing the third column, we obtain Δz=Δ3\Delta z = \Delta_3.

Case 1: If Δ≠0\Delta \neq 0, then we can solve for xx, yy, and zz as follows:

x=Δ1Δ=∣d1b1c1d2b2c2d3b3c3∣∣a1b1c1a2b2c2a3b3c3∣x = \frac{\Delta_1}{\Delta} = \frac{\begin{vmatrix} d_1 & b_1 & c_1 \\ d_2 & b_2 & c_2 \\ d_3 & b_3 & c_3 \end{vmatrix}}{\begin{vmatrix} a_1 & b_1 & c_1 \\ a_2 & b_2 & c_2 \\ a_3 & b_3 & c_3 \end{vmatrix}}

Similarly, we have:

y=Δ2Δ=∣a1d1c1a2d2c2a3d3c3∣∣a1b1c1a2b2c2a3b3c3∣y = \frac{\Delta_2}{\Delta} = \frac{\begin{vmatrix} a_1 & d_1 & c_1 \\ a_2 & d_2 & c_2 \\ a_3 & d_3 & c_3 \end{vmatrix}}{\begin{vmatrix} a_1 & b_1 & c_1 \\ a_2 & b_2 & c_2 \\ a_3 & b_3 & c_3 \end{vmatrix}} z=Δ3Δ=∣a1b1d1a2b2d2a3b3d3∣∣a1b1c1a2b2c2a3b3c3∣z = \frac{\Delta_3}{\Delta} = \frac{\begin{vmatrix} a_1 & b_1 & d_1 \\ a_2 & b_2 & d_2 \\ a_3 & b_3 & d_3 \end{vmatrix}}{\begin{vmatrix} a_1 & b_1 & c_1 \\ a_2 & b_2 & c_2 \\ a_3 & b_3 & c_3 \end{vmatrix}}

Thus, when Δ≠0\Delta \neq 0, the system has a unique solution given by:

x=Δ1Δ,y=Δ2Δ,z=Δ3Δx = \frac{\Delta_1}{\Delta}, \quad y = \frac{\Delta_2}{\Delta}, \quad z = \frac{\Delta_3}{\Delta}

Case 2: If Δ=0\Delta = 0 but at least one of Δ1\Delta_1, Δ2\Delta_2, or Δ3\Delta_3 is not zero, the system has no solution. Here’s why:

Suppose Δ1≠0\Delta_1 \neq 0. Then, according to Cramer’s Rule:

Δ⋅x=Δ1\Delta \cdot x = \Delta_1

Since Δ=0\Delta = 0, this implies:

0⋅x=Δ10 \cdot x = \Delta_1

which simplifies to:

0=Δ10 = \Delta_1

However, this leads to a contradiction because we assumed Δ1≠0\Delta_1 \neq 0. This contradiction indicates that there are no values of xx, yy, and zz that satisfy all three equations. Thus, the system is inconsistent, and no solution exists.

The same reasoning applies if Δ2≠0\Delta_2 \neq 0 or Δ3≠0\Delta_3 \neq 0. In each case, we get a similar contradiction, confirming that the system cannot have a solution when Δ=0\Delta = 0 but any of Δ1\Delta_1, Δ2\Delta_2, or Δ3\Delta_3 is non-zero.

Case 3: If Δ=0\Delta = 0, Δ1=0\Delta_1 = 0, Δ2=0\Delta_2 = 0, and Δ3=0\Delta_3 = 0, then the system may have infinitely many solutions or no solution, depending on whether the equations are consistent or inconsistent.

To see this, let's start by considering that Cramer's Rule would give us:

Δ⋅x=Δ1,Δ⋅y=Δ2,Δ⋅z=Δ3\Delta \cdot x = \Delta_1, \quad \Delta \cdot y = \Delta_2, \quad \Delta \cdot z = \Delta_3

With Δ=0\Delta = 0, Δ1=0\Delta_1 = 0, Δ2=0\Delta_2 = 0, and Δ3=0\Delta_3 = 0, we get:

0⋅x=0,0⋅y=0,0⋅z=00 \cdot x = 0, \quad 0 \cdot y = 0, \quad 0 \cdot z = 0

These equations hold true for any values of xx, yy, and zz, meaning there could be infinitely many solutions. This situation suggests that the equations are dependent, allowing multiple values of xx, yy, and zz to satisfy the system.

However, this is not always the case. In some instances, even with Δ=0\Delta = 0, Δ1=0\Delta_1 = 0, Δ2=0\Delta_2 = 0, and Δ3=0\Delta_3 = 0, the system may still be inconsistent. For example, consider the system:

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

For this system, we calculate:

Δ=∣111111111∣=0,Δ1=0,Δ2=0,Δ3=0\Delta = \begin{vmatrix} 1 & 1 & 1 \\ 1 & 1 & 1 \\ 1 & 1 & 1 \end{vmatrix} = 0, \quad \Delta_1 = 0, \quad \Delta_2 = 0, \quad \Delta_3 = 0

At first glance, this might suggest infinite solutions. However, let’s examine the equations more closely. If (x0,y0,z0)(x_0, y_0, z_0) is a solution to this system, then:

x0+y0+z0=1x_0 + y_0 + z_0 = 1 x0+y0+z0=2x_0 + y_0 + z_0 = 2 x0+y0+z0=3x_0 + y_0 + z_0 = 3

These conditions imply that 1=2=31 = 2 = 3, which is a clear contradiction. This means that there are no values of xx, yy, and zz that can satisfy all three equations simultaneously. Therefore, in this example, the system has no solution.

Cramer's Rule for a Homogeneous System:§

For a homogeneous system of linear equations, such as:

a1x+b1y+c1z=0a_1 x + b_1 y + c_1 z = 0 a2x+b2y+c2z=0a_2 x + b_2 y + c_2 z = 0 a3x+b3y+c3z=0a_3 x + b_3 y + c_3 z = 0

the solution x=y=z=0x = y = z = 0 is always a solution. This is known as the trivial solution, and it can be easily verified. Thus, a homogeneous system is always consistent.

The behavior of the system depends on the value of Δ\Delta, the determinant of the coefficient matrix:

  1. Case 1: If Δ≠0\Delta \neq 0, then the only solution is the trivial solution (x=y=z=0x = y = z = 0), making it the unique solution.

  2. Case 2: If Δ=0\Delta = 0, the trivial solution still exists, but the system has infinitely many non-zero solutions (non-trivial solutions). This means there are infinitely many values of xx, yy, and zz that satisfy the system, in addition to the trivial solution.

Solving System of Linear Equations using Matrices§

Consider the system of linear equations:

a11x1+a12x2+⋯+a1nxn=b1a_{11} x_1 + a_{12} x_2 + \cdots + a_{1n} x_n = b_1 a21x1+a22x2+⋯+a2nxn=b2a_{21} x_1 + a_{22} x_2 + \cdots + a_{2n} x_n = b_2 ⋮\vdots an1x1+an2x2+⋯+annxn=bna_{n1} x_1 + a_{n2} x_2 + \cdots + a_{nn} x_n = b_n

This system can be written in matrix form as Ax=b\mathbf{A} \mathbf{x} = \mathbf{b}, where:

A=[a11a12⋯a1na21a22⋯a2n⋮⋮⋱⋮an1an2⋯ann],x=[x1x2⋮xn],b=[b1b2⋮bn]\mathbf{A} = \begin{bmatrix} a_{11} & a_{12} & \cdots & a_{1n} \\ a_{21} & a_{22} & \cdots & a_{2n} \\ \vdots & \vdots & \ddots & \vdots \\ a_{n1} & a_{n2} & \cdots & a_{nn} \end{bmatrix}, \quad \mathbf{x} = \begin{bmatrix} x_1 \\ x_2 \\ \vdots \\ x_n \end{bmatrix}, \quad \mathbf{b} = \begin{bmatrix} b_1 \\ b_2 \\ \vdots \\ b_n \end{bmatrix}

Since this is a system of nn equations in nn unknowns, A\mathbf{A} is a square matrix.

  1. If A\mathbf{A} is non-singular (∣A∣≠0|\mathbf{A}| \neq 0):

    • The inverse of A\mathbf{A} exists.

    • Multiply both sides of the equation Ax=b\mathbf{A} \mathbf{x} = \mathbf{b} by A−1\mathbf{A}^{-1} to get:

      x=A−1b\mathbf{x} = \mathbf{A}^{-1} \mathbf{b}
    • Thus, the solution is given by x=A−1b\mathbf{x} = \mathbf{A}^{-1} \mathbf{b}.

  2. If A\mathbf{A} is singular (∣A∣=0|\mathbf{A}| = 0):

    • Calculate adj⁡(A)\operatorname{adj}(\mathbf{A}), the adjugate of A\mathbf{A}.
    • Check the result of adj⁡(A)b\operatorname{adj}(\mathbf{A}) \mathbf{b}:
      • If adj⁡(A)b≠0\operatorname{adj}(\mathbf{A}) \mathbf{b} \neq \mathbf{0}: No solution exists, and the system is inconsistent.
      • If adj⁡(A)b=0\operatorname{adj}(\mathbf{A}) \mathbf{b} = \mathbf{0}: The system may have infinitely many solutions or no solution.
Section 10 of 10 · Matrices and Determinants

Mark this section complete when you have worked through its proofs.