System of Equations using Matrices

Consider the following system of in linear equations in n unknowns:

a11 x1 + a12 x2 + … + a1n xn = b1

a21 x1 + a22 x2 + … + a2n xn = b2

…        …        …        …

…        …        …        …

am1 x1 + am2 x2 + … + amn xn = bm

This system of equations can be written in matrix from as $$\left[\begin{matrix}{{a}_{11}}&{{a}_{12}}&\cdots&{{a}_{1n}}\\{{a}_{21}}&{{a}_{22}}&{}&{{a}_{2n}}\\\vdots&\vdots&{}&{}\\{{a}_{m1}}&{{a}_{m2}}&\cdots&{{a}_{mm}}\\\end{matrix}\right]\left[\begin{matrix}{{x}_{1}}\\{{x}_{2}}\\\vdots\\{{x}_{n}}\\\end{matrix}\right]=\left[\begin{matrix}{{b}_{1}}\\{{b}_{2}}\\\vdots\\{{b}_{n}}\\\end{matrix}\right]$$.

Or, AX = B, where $$A={{\left[ \begin{matrix}{{a}_{11}} & {{a}_{12}}& \cdots & {{a}_{1n}} \\{{a}_{21}} & {{a}_{22}} & {} & {{a}_{2n}} \\\vdots & \vdots & {} & {} \\{{a}_{m1}} & {{a}_{m2}} & \cdots & {{a}_{mm}} \\\end{matrix} \right]}_{m\times n}}$$,  $$X={{\left[ \begin{matrix}{{x}_{1}} \\{{x}_{2}} \\\vdots \\{{x}_{n}} \\\end{matrix} \right]}_{n\times 1}}$$ and  $$B=\left[ \begin{matrix}{{b}_{1}} \\{{b}_{2}} \\\vdots \\{{b}_{n}} \\\end{matrix} \right]$$ and the m x n matrix A is called the coefficient matrix of the system of linear equations.

SOLUTION: A set of values of the variables x1, x2, …. xn which simultaneously satisfy all the equations is called a solution of the system of equations.

For example, x = 2, y = -3 is a solution of the system of linear equations

3x + y = 3, 2x + y = 1

Because 3(2) + (-3) = 3 and 2(2) + (-3) = 1

HOMOGENEOUS AND NON-HOMOGENEOUS SYSTEMS OF LINEAR EQUATIONS: A system of equations AX = B is called a homogeneous system if B = 0.

Otherwise, it is called a non-homogeneous system of equations.

For example, the system of equations 2x + 3y = 0, 3x – y = 0

Is a homogeneous system of linear equations whereas the system of equations given by 2x + 3y = 1, 3x – y = 5

Is a non-homogenous system of linear equations.

ALGORITHM:

STEP I: Obtain the system of equations and express it in the matrix from AX=B.

STEP II: Find |A|.

STEP III: If |A| ≠ 0, then compute A-1 = 1/ |A| (adj A)

STEP IV: Use the formula X = A-1B to obtain the unique solution.

EXAMPLE: Determine the product $$\left[ \begin{matrix}-4 & 4 & 4 \\-7 & 1 & 3 \\5 & -3 & -1 \\\end{matrix} \right]\left[ \begin{matrix}1 & -1 & 1 \\1 & -2 & -2 \\2 & 1 & 3 \\\end{matrix} \right]$$ and use it to solve the system of equations: x – y + z = 4, x – 2y – 2z = 9, 2x + y + 3z = 1.

SOLUTION: Let $$A=\left[ \begin{matrix}1 & -1 & 1 \\1 & -2 & -2 \\2 & 1 & 3 \\\end{matrix} \right]$$ and $$C=\left[ \begin{matrix}-4 & 4 & 4 \\-7 & 1 & 3 \\5 & -3 & -1 \\\end{matrix} \right]$$. Then, the given product CA is given by

$$CA=\left[ \begin{matrix}-4 & 4 & 4 \\-7 & 1 & 3 \\5 & -3 & -1 \\\end{matrix} \right]\left[ \begin{matrix}1 & -1 & 1 \\1 & -2 & -2 \\2 & 1 & 3 \\\end{matrix} \right]$$.

= $$\left[ \begin{matrix}-4+4+8 & 4-8+4 & -4-8+12 \\-7+1+6 & 7-2+3 & -7-2+9 \\5-3-2 & -5+6-1 & 5+6-3 \\\end{matrix} \right]$$.

= $$\left[ \begin{matrix}8 & 0 & 0 \\0 & 8 & 0 \\0 & 0 & 8 \\\end{matrix} \right]$$.

= $$8\left[ \begin{matrix}1 & 0 & 0 \\0 & 1 & 0 \\0 & 0 & 1 \\\end{matrix} \right]$$ = 8I₃.

⇒ ⅛ CA = I₃

⇒ (⅛C) A = I₃

⇒ A¯¹ = ⅛ C

⇒ $${{A}^{-1}}=\frac{1}{8}\left[ \begin{matrix}-4 & 4 & 4 \\-7 & 1 & 3 \\5 & -3 & -1 \\\end{matrix} \right]$$ … (i)

The given system of equations can be written in matrix form as $$\left[ \begin{matrix}1 & -1 & 1 \\1 & -2 & -2 \\2 & 1 & 3 \\\end{matrix} \right]\left[ \begin{matrix}x \\y \\z \\\end{matrix} \right]=\left[ \begin{matrix}4 \\9 \\1 \\\end{matrix} \right]$$.

Or, AX = B, where $$A=\left[ \begin{matrix}1 & -1 & 1 \\1 & -2 & -2 \\2 & 1 & 3 \\\end{matrix} \right]$$, $$X=\left[ \begin{matrix}x \\y \\z \\\end{matrix} \right]$$ and $$B=\left[ \begin{matrix}4 \\9 \\1 \\\end{matrix} \right]$$.

The solution of this system of equations is given by X = A-1B

⇒  $$X=\frac{1}{8}\left[ \begin{matrix}-4 & 4 & 4 \\-7 & 1 & 3 \\5 & -3 & -1 \\\end{matrix} \right]\left[ \begin{matrix}4 \\9 \\1 \\\end{matrix} \right]$$ [Using (i)]

⇒ $$\left[ \begin{matrix}x \\y \\z \\\end{matrix} \right]=\frac{1}{8}\left[ \begin{matrix}-16 & +36 & +4 \\-28 & +9 & +3 \\20 & -27 & -1 \\\end{matrix} \right]=\frac{1}{8}\left[ \begin{matrix}24 \\-16 \\-8 \\\end{matrix} \right]=\left[ \begin{matrix}3 \\-2 \\-1 \\\end{matrix} \right]$$.

x = 3, y = -2 and z = -1