Home / IB DP Maths / Application and Interpretation HL / IB Mathematics AI SL Definition of a matrix Study Notes

IB Mathematics AI SL Definition of a matrix Study Notes - New Syllabus

IB Mathematics AI SL Definition of a matrix Study Notes

LEARNING OBJECTIVE

  • Definition of a matrix

Key Concepts: 

MAI HL and SL Notes – All topics

MATRICES

♦ A matrix is simply a rectangular array of numbers (called elements). Some typical examples:

\(
\begin{pmatrix}
1 & 2 & 7 \\
-3 & 0 & 5
\end{pmatrix}, \quad
\begin{pmatrix}
4 & 6 \\
2 & 11
\end{pmatrix}, \quad
\begin{pmatrix}
4 & -8 \\
2.5 & 4 \\
0 & 1/2 \\
1 & 3.1
\end{pmatrix}
\)

A matrix is usually denoted by a capital letter, say:

\(
A = \begin{pmatrix}
1 & 2 & 7 \\
-3 & 0 & 5
\end{pmatrix}, \quad
B = \begin{pmatrix}
4 & 6 \\
2 & 11
\end{pmatrix}, \quad
C = \begin{pmatrix}
4 & -8 \\
2.5 & 4 \\
0 & 1/2 \\
1 & 3.1
\end{pmatrix}
\)

The first matrix above has 2 rows and 3 columns. We say that \( A \) is a \( 2 \times 3 \) (“two by three”) matrix, or otherwise that the order of \( A \) is \( 2 \times 3 \).

Likewise, \( B \) is a \( 2 \times 2 \) matrix while \( C \) is a \( 4 \times 2 \) matrix.

The general form of a \( 2 \times 3 \) matrix is:

\(
A = \begin{pmatrix}
a_{11} & a_{12} & a_{13} \\
a_{21} & a_{22} & a_{23}
\end{pmatrix}
\)

(notice that \( a_{23} \), for example, is the element in row 2 and column 3).

♦ SQUARE MATRICES
No of rows = No of columns. The order of a square matrix is \( n \times n \), e.g., \( 2 \times 2 \), \( 3 \times 3 \), \( 4 \times 4 \), etc. (in this case, we may also say: “a square matrix of order \( n \)”).

For example,

\(
\begin{pmatrix}
1 & 2 \\
3 & 4
\end{pmatrix}, \quad
\begin{pmatrix}
1 & 2 & 3 \\
4 & 5 & 6 \\
7 & 8 & 9
\end{pmatrix}
\)

are square matrices of order 2 and 3, respectively.

We also say that the elements \( a_{11}, a_{22}, a_{33}, \ldots \) (indicated above) form the main diagonal of the square matrix.

♦ ROW MATRICES
Matrices of order \( 1 \times n \). For example:

\(
A = \begin{pmatrix} 2 & 7 & 3 \end{pmatrix} \quad \text{is a } 1 \times 3 \text{ row matrix.}
\)

\(
B = \begin{pmatrix} 4 & 2 & 6 & -1 & 0 & 6 \end{pmatrix} \quad \text{is a } 1 \times 6 \text{ row matrix.}
\)

♦ COLUMN MATRICES (or VECTORS)
Matrices of order \( m \times 1 \). For example:

\(
A = \begin{pmatrix} 1 \\ 4 \\ 2 \end{pmatrix} \quad \text{is a } 3 \times 1 \text{ vector.}
\)

\(
B = \begin{pmatrix} -1 \\ 3 \end{pmatrix} \quad \text{is a } 2 \times 1 \text{ vector.}
\)

Notice: Matrices of order \( 1 \times 1 \) are also defined, for example \( C = (5) \).

♦ THE ZERO MATRIX O
All elements are 0. The \( 2 \times 3 \) zero matrix is:

\(
O = \begin{pmatrix}
0 & 0 & 0 \\
0 & 0 & 0
\end{pmatrix}
\)

The \( 2 \times 2 \) zero matrix is:

\(
O = \begin{pmatrix}
0 & 0 \\
0 & 0
\end{pmatrix}, \quad \text{and so on!}
\)

♦ EQUAL MATRICES: \( A = B \)
\( A = B \) if:
\( A \) and \( B \) have the same order.
 The corresponding elements are equal.

 

\(
A = \begin{pmatrix} 2 & x \\ a & 3 \end{pmatrix}, \quad
B = \begin{pmatrix} 1 & 2 & 3 \\ 2 & 3 & 0 \end{pmatrix}, \quad
C = \begin{pmatrix} y & 7 \\ 0 & 3 \end{pmatrix}, \quad
D = \begin{pmatrix} s & t & u \\ v & w & 7 \end{pmatrix}
\)

It cannot be \( A = B \) since \( A \) is \( 2 \times 2 \) while \( B \) is \( 2 \times 3 \).
\( A = C \) implies \( y = 2 \), \( x = 7 \), \( a = 0 \) (\( 3 = 3 \) holds anyway!).
\( B \neq D \) since \( 0 \neq 7 \) (although both are \( 2 \times 3 \)).

Let \( A \) and \( B \) have the same order. We define some new matrices:

♦ THE SUM \( A + B \)
We simply add the corresponding elements.

♦ THE DIFFERENCE \( A – B \)
We simply subtract the corresponding elements.

♦ THE SCALAR PRODUCT \( nA \) (\( n \) is a scalar, i.e., a number)
We simply multiply each element of \( A \) by \( n \).

\(
A = \begin{pmatrix} 1 & 2 & 3 \\ 4 & 1 & 5 \end{pmatrix}, \quad
B = \begin{pmatrix} 3 & 5 & 0 \\ 2 & 3 & 7 \end{pmatrix}
\)

Then:

\(
A + B = \begin{pmatrix} 4 & 7 & 3 \\ 6 & 4 & 12 \end{pmatrix}, \quad
A – B = \begin{pmatrix} -2 & -3 & 3 \\ 2 & -2 & -2 \end{pmatrix}, \quad
B – A = \begin{pmatrix} 2 & 3 & -3 \\ -2 & 2 & 2 \end{pmatrix}
\)

\(
3A = \begin{pmatrix} 3 & 6 & 9 \\ 12 & 3 & 15 \end{pmatrix}, \quad
-3A = \begin{pmatrix} -3 & -6 & -9 \\ -12 & -3 & -15 \end{pmatrix}, \quad
-A = -1A = \begin{pmatrix} -1 & -2 & -3 \\ -4 & -1 & -5 \end{pmatrix}
\)

\(
\frac{1}{2}A = \begin{pmatrix} 1/2 & 1 & 3/2 \\ 2 & 1/2 & 5/2 \end{pmatrix} \quad \text{or} \quad 0.5A = \begin{pmatrix} 0.5 & 1 & 1.5 \\ 1 & 0.5 & 2.5 \end{pmatrix}
\)

\(
2A + 3B = 2 \begin{pmatrix} 1 & 2 & 3 \\ 4 & 1 & 5 \end{pmatrix} + 3 \begin{pmatrix} 3 & 5 & 0 \\ 2 & 3 & 7 \end{pmatrix} = \begin{pmatrix} 11 & 19 & 6 \\ 14 & 11 & 31 \end{pmatrix}
\)

 

Example

Let \( A = \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} \) and \( B = \begin{pmatrix} 2 & 0 \\ 5 & -1 \end{pmatrix} \). Find the matrix \( X \) if:

\(
2A + X = 3B
\)

▶️Answer/Explanation

Solution:

Method 1: (Analytical and safe but laborious)

Let \( X = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \). Then:

\(
2A + X = 3B \quad \Leftrightarrow \quad 2 \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} + \begin{pmatrix} a & b \\ c & d \end{pmatrix} = 3 \begin{pmatrix} 2 & 0 \\ 5 & -1 \end{pmatrix}
\)

\(
\Leftrightarrow \quad \begin{pmatrix} 2 + a & 4 + b \\ 6 + c & 8 + d \end{pmatrix} = \begin{pmatrix} 6 & 0 \\ 15 & -3 \end{pmatrix}
\)

Hence:

\(
2 + a = 6 \Leftrightarrow a = 4, \quad 4 + b = 0 \Leftrightarrow b = -4, \quad 6 + c = 15 \Leftrightarrow c = 9, \quad 8 + d = -3 \Leftrightarrow d = -11
\)

Therefore:

\(
X = \begin{pmatrix} 4 & -4 \\ 9 & -11 \end{pmatrix}
\)

Method 2: (Quicker)

We solve for \( X \) (as a usual equation):

\(
2A + X = 3B \quad \Leftrightarrow \quad X = 3B – 2A
\)

\(
\Leftrightarrow \quad X = 3 \begin{pmatrix} 2 & 0 \\ 5 & -1 \end{pmatrix} – 2 \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} = \begin{pmatrix} 6 & 0 \\ 15 & -3 \end{pmatrix} – \begin{pmatrix} 2 & 4 \\ 6 & 8 \end{pmatrix} = \begin{pmatrix} 4 & -4 \\ 9 & -11 \end{pmatrix}
\)

The following operation is the most important one for matrices:

 

♦ THE PRODUCT OF TWO MATRICES: \( AB \)

\(
\begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} \begin{pmatrix} 2 & 3 \\ 5 & 1 \end{pmatrix} = ?
\)

It is NOT \( \begin{pmatrix} 2 & 6 \\ 15 & 4 \end{pmatrix} \) as someone would expect!! Here, we do not multiply the corresponding elements.

Multiply a row-matrix by a column-matrix:

\(
\begin{pmatrix} a & b & c \end{pmatrix} \begin{pmatrix} x \\ y \\ z \end{pmatrix} = (ax + by + cz)
\)

Notice that we multiply the corresponding elements and add the results.

\(
\begin{pmatrix} 2 & 3 & 5 \end{pmatrix} \begin{pmatrix} 3 \\ 4 \\ 1 \end{pmatrix} = (2 \cdot 3 + 3 \cdot 4 + 5 \cdot 1) = (23)
\)

Now we are ready to multiply two matrices \( A \) and \( B \) in general. First of all, the orders of \( A \) and \( B \) must be as follows:

\(
\begin{array}{c|c}
A & B \\
\hline
m \times k & k \times n
\end{array}
\)

That is, the number of columns of \( A \) = number of rows of \( B \).

The order of the new matrix \( AB \) will be \( m \times n \).

\(
\begin{array}{|c|c|c|}
\hline
\text{Order of } A & \text{Order of } B & \text{Order of } AB \\
\hline
3 \times 5 & 5 \times 8 & 3 \times 8 \\
\hline
3 \times 2 & 2 \times 1 & 3 \times 1 \\
\hline
2 \times 2 & 2 \times 2 & 2 \times 2 \\
\hline
2 \times 3 & 2 \times 3 & \text{Not defined} \\
\hline
\end{array}
\)

The multiplication takes place as follows:
 We multiply rows of \( A \) by columns of \( B \).
 (Row \( i \)) \( \times \) (Column \( j \)) will give the element \( a_{ij} \).

Let:

\(
A = \begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix}, \quad
B = \begin{pmatrix} 2 & 5 \\ 3 & 3 \\ 1 & 2 \end{pmatrix}
\)

Notice that the order of \( AB \) is expected to be \( 2 \times 2 \).

For the first row of \( AB \): multiply row 1 of \( A \) by each column of \( B \) separately:

\(
AB = \begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix} \begin{pmatrix} 2 & 5 \\ 3 & 3 \\ 1 & 2 \end{pmatrix} = \begin{pmatrix} 1 \cdot 2 + 2 \cdot 3 + 3 \cdot 1 & 1 \cdot 5 + 2 \cdot 3 + 3 \cdot 2 \\ – & – \end{pmatrix} = \begin{pmatrix} 11 & 17 \\ – & – \end{pmatrix}
\)

For the second row of \( AB \): multiply row 2 of \( A \) by each column of \( B \) separately:

\(
AB = \begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix} \begin{pmatrix} 2 & 5 \\ 3 & 3 \\ 1 & 2 \end{pmatrix} = \begin{pmatrix} 11 & 17 \\ 4 \cdot 2 + 5 \cdot 3 + 6 \cdot 1 & 4 \cdot 5 + 5 \cdot 3 + 6 \cdot 2 \end{pmatrix} = \begin{pmatrix} 11 & 17 \\ 29 & 47 \end{pmatrix}
\)

Example

\(
A = \begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix}, \quad
B = \begin{pmatrix} 2 & 5 \\ 3 & 3 \\ 1 & 2 \end{pmatrix}
\)

\(
\begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix} \begin{pmatrix} 2 \\ 3 \\ 1 \end{pmatrix} = \begin{pmatrix} 11 \\ 29 \end{pmatrix}, \quad
\begin{pmatrix} 1 & 2 & 3 \end{pmatrix} \begin{pmatrix} 5 \\ 3 \\ 2 \end{pmatrix} = \begin{pmatrix} 17 \end{pmatrix}
\)

\( AB \) =?

▶️Answer/Explanation

Solution:

\(
AB = \begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix} \begin{pmatrix} 2 & 5 \\ 3 & 3 \\ 1 & 2 \end{pmatrix} = \begin{pmatrix} 11 & 17 \\ 29 & 47 \end{pmatrix}
\)

 

 

Example

\(
A = \begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix}, \quad
B = \begin{pmatrix} 2 & 5 \\ 3 & 3 \\ 1 & 2 \end{pmatrix}
\)

\(
\begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix} \begin{pmatrix} 2 \\ 3 \\ 1 \end{pmatrix} = \begin{pmatrix} 11 \\ 29 \end{pmatrix}, \quad
\begin{pmatrix} 1 & 2 & 3 \end{pmatrix} \begin{pmatrix} 5 \\ 3 \\ 2 \end{pmatrix} = \begin{pmatrix} 17 \end{pmatrix}
\)

\( BA \) =?

▶️Answer/Explanation

Solution:

\(
BA = \begin{pmatrix} 2 & 5 \\ 3 & 3 \\ 1 & 2 \end{pmatrix} \begin{pmatrix} 1 & 2 & 3 \\ 4 & 5 & 6 \end{pmatrix} = \begin{pmatrix} 2 + 20 & 4 + 25 & 6 + 30 \\ 3 + 12 & 6 + 15 & 9 + 18 \\ 1 + 8 & 2 + 10 & 3 + 12 \end{pmatrix} = \begin{pmatrix} 22 & 29 & 36 \\ 15 & 21 & 27 \\ 9 & 12 & 15 \end{pmatrix}
\)

NOTICE: In general, \( AB \neq BA \). They may be of different order, or perhaps only one of the products could be defined (e.g., if \( A \) is \( 2 \times 3 \) and \( B \) is \( 3 \times 5 \)).

Even if both matrices \( A \) and \( B \) are square matrices, say \( 2 \times 2 \), the resulting \( 2 \times 2 \) matrices \( AB \) and \( BA \) are not equal in general.

 

 

Example

\( A = \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} \) and \( B = \begin{pmatrix} 1 & 1 \\ 0 & 2 \end{pmatrix} \)

▶️Answer/Explanation

Solution:

\(
AB = \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} \begin{pmatrix} 1 & 1 \\ 0 & 2 \end{pmatrix} = \begin{pmatrix} 1 & 5 \\ 3 & 11 \end{pmatrix}, \quad
BA = \begin{pmatrix} 1 & 1 \\ 0 & 2 \end{pmatrix} \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} = \begin{pmatrix} 4 & 6 \\ 6 & 8 \end{pmatrix}
\)

Sometimes though, it happens \( AB = BA \). Then we say that matrices \( A \) and \( B \) commute.

 

 

Example

\( A = \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} \) and \( B = \begin{pmatrix} 5 & 4 \\ 6 & 11 \end{pmatrix} \).

▶️Answer/Explanation

Solution:

\(
AB = \begin{pmatrix} 17 & 26 \\ 39 & 56 \end{pmatrix}, \quad
BA = \begin{pmatrix} 17 & 26 \\ 39 & 56 \end{pmatrix}
\)

The following square matrix plays a key role in our theory.

♦ THE IDENTITY MATRIX \( I \)
1 in the main diagonal, 0 elsewhere. Namely:

\(
I = \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix}, \quad
I = \begin{pmatrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \end{pmatrix}, \quad
I = \begin{pmatrix} 1 & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 1 \end{pmatrix}, \quad \text{etc.}
\)

Example

\( A = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \) and \( I = \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix} \).

▶️Answer/Explanation

Solution:

\(
AI = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix} = \begin{pmatrix} a & b \\ c & d \end{pmatrix} = A, \quad
IA = \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix} \begin{pmatrix} a & b \\ c & d \end{pmatrix} = \begin{pmatrix} a & b \\ c & d \end{pmatrix} = A
\)

In general, for any matrix \( A \):

\(
AI = A \quad \text{and} \quad IA = A
\)

(provided that the orders of \( A \) and \( I \) are appropriate!).

In other words, the identity matrix \( I \) plays the role of 1 (unit) when we multiply matrices!

 

♦ PROPERTIES OF MATRIX OPERATIONS
The following properties hold:

For addition of matrices 
\( A + B = B + A \) Commutative law 
\( (A + B) + C = A + (B + C) \) Associative law 
 \( A + O = A = O + A \)  \( O \) is the identity for addition 

 For multiplication of matrices 
\( (AB)C = A(BC) \) | Associative law 
 \( AI = A = IA \) | \( I \) is the identity for multiplication 

Remember that the commutative law does not hold for multiplication, i.e., \( AB \neq BA \) in general.

For addition and multiplication of matrices together 
 \( (A + B)C = AC + BC \) Distributive laws 
 \( C(A + B) = CA + CB \) 

 For multiplication by scalars \( m, n \in \mathbb{R} \) 
\( m(A + B) = mA + mB \)  Distributive laws 
 \( (m + n)A = mA + nA \) 
 \( m(nA) = (mn)A \) 

THE DETERMINANT detA – THE INVERSE \( A^{-1} \)

2×2 DETERMINANT

Let \( A = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \). The determinant of \( A \) is the number:

\(
\text{det}A = ad – bc
\)

It is also denoted by:

\(
\text{det} \begin{pmatrix} a & b \\ c & d \end{pmatrix} = ad – bc \quad \text{or} \quad \begin{vmatrix} a & b \\ c & d \end{vmatrix} = ad – bc
\)

Example

\( A = \begin{pmatrix} 5 & 2 \\ 3 & 4 \end{pmatrix} \).

\( B = \begin{pmatrix} 2 & -4 \\ 3 & -6 \end{pmatrix} \)

▶️Answer/Explanation

Solution:

\(
\text{det}A = \begin{vmatrix} 5 & 2 \\ 3 & 4 \end{vmatrix} = 5 \cdot 4 – 2 \cdot 3 = 14
\)

\(
\text{det}B = \begin{vmatrix} 2 & -4 \\ 3 & -6 \end{vmatrix} = -12 + 12 = 0
\)

 

 

Example

Solve the equation:

\(
\begin{vmatrix} x & -1 \\ 2 & x – 3 \end{vmatrix} = 0
\)

▶️Answer/Explanation

Solution:

\(
x(x – 3) + 2 = 0 \quad \Leftrightarrow \quad x^2 – 3x + 2 = 0 \quad \Leftrightarrow \quad x = 1 \quad \text{or} \quad x = 2
\)

♦ 3×3 DETERMINANT

Let:

\(
A = \begin{pmatrix} a_1 & a_2 & a_3 \\ b_1 & b_2 & b_3 \\ c_1 & c_2 & c_3 \end{pmatrix}
\)

In exams, the \( 3 \times 3 \) determinant, \( \text{det}A \), will be asked only by GDC.

Although it is not in the syllabus, just for information we mention the definition of the determinant of \( A \). It is the number:

\(
\text{det}A = a_1b_2c_3 + a_2b_3c_1 + a_3b_1c_2 – a_1b_3c_2 – a_2b_1c_3 – a_3b_2c_1
\)

A more elegant way to estimate \( \text{det}A \) is:

\(
\text{det}A = a_1 \begin{vmatrix} b_2 & b_3 \\ c_2 & c_3 \end{vmatrix} – a_2 \begin{vmatrix} b_1 & b_3 \\ c_1 & c_3 \end{vmatrix} + a_3 \begin{vmatrix} b_1 & b_2 \\ c_1 & c_2 \end{vmatrix}
\)

 We multiply the elements of the first row, \( a_1, a_2, a_3 \), by three smaller determinants respectively.
For \( a_1 \), the corresponding \( 2 \times 2 \) determinant can be obtained if we eliminate the row and the column of \( a_1 \).
 Similarly for \( a_2 \) and \( a_3 \).
 We alternate the signs (\( + – + \)).

Example

\( A = \begin{pmatrix} 2 & 3 & 4 \\ 5 & 6 & 7 \\ 1 & 2 & 8 \end{pmatrix} \).

▶️Answer/Explanation

Solution:

\(\text{det}A = 2 \begin{vmatrix} 6 & 7 \\ 2 & 8 \end{vmatrix} – 3 \begin{vmatrix} 5 & 7 \\ 1 & 8 \end{vmatrix} + 4 \begin{vmatrix} 5 & 6 \\ 1 & 2 \end{vmatrix} = 2 \cdot 34 – 3 \cdot 33 + 4 \cdot 4 = -15\)

Notice: The following terminology is also used:
 If \( \text{det}A = 0 \), we say that the matrix \( A \) is singular.
 If \( \text{det}A \neq 0 \), we say that the matrix \( A \) is non-singular.

Consider the following special cases:

\(
A = \begin{pmatrix} a & x & y \\ 0 & b & z \\ 0 & 0 & c \end{pmatrix}, \quad
B = \begin{pmatrix} a & 0 & 0 \\ x & b & 0 \\ y & z & c \end{pmatrix}, \quad
C = \begin{pmatrix} a & 0 & 0 \\ 0 & b & 0 \\ 0 & 0 & c \end{pmatrix}
\)

Matrices like \( A \) are called upper-triangular (0’s below main diagonal).
Matrices like \( B \) are called lower-triangular (0’s above main diagonal).
Matrices like \( C \) are called diagonal (0’s below and above main diagonal).

For the determinant of such a matrix, we just multiply the elements of the main diagonal:

\(
\text{det}A = abc, \quad \text{det}B = abc, \quad \text{det}C = abc
\)

For example:

\(
\begin{vmatrix} 2 & 0 & 0 \\ 0 & 3 & 0 \\ 0 & 0 & 4 \end{vmatrix} = 2 \cdot 3 \cdot 4 = 24, \quad
\begin{vmatrix} 2 & \sqrt{2} & 5 \\ 0 & 3 & -8 \\ 0 & 0 & 4 \end{vmatrix} = 2 \cdot 3 \cdot 4 = 24
\)

♦ THE INVERSE \( A^{-1} \) OF A 2×2 MATRIX

Let \( A = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \). Given that \( \text{det}A \neq 0 \) (and only then), we define the inverse of \( A \) as follows:

\(
A^{-1} = \frac{1}{\text{det}A} \begin{pmatrix} d & -b \\ -c & a \end{pmatrix}
\)

Example

\( A = \begin{pmatrix} 2 & 6 \\ 1 & 4 \end{pmatrix} \). Then \( \text{det}A = 2 \), and the inverse matrix is:?

▶️Answer/Explanation

Solution:

Let \( A = \begin{pmatrix} 2 & 6 \\ 1 & 4 \end{pmatrix} \). Then \( \text{det}A = 2 \), and the inverse matrix is:

\(
A^{-1} = \frac{1}{2} \begin{pmatrix} 4 & -6 \\ -1 & 2 \end{pmatrix} = \begin{pmatrix} 2 & -3 \\ -1/2 & 1 \end{pmatrix}
\)

Let \( B = \begin{pmatrix} 2 & 8 \\ 1 & 4 \end{pmatrix} \). Then \( \text{det}B = 0 \), and hence, \( B^{-1} \) is not defined.

To justify the term “inverse”, let’s multiply the matrices \( A \) and \( A^{-1} \) of the example above:

\(
AA^{-1} = \begin{pmatrix} 2 & 6 \\ 1 & 4 \end{pmatrix} \begin{pmatrix} 2 & -3 \\ -1/2 & 1 \end{pmatrix} = \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix} = I
\)

\(
A^{-1}A = \begin{pmatrix} 2 & -3 \\ -1/2 & 1 \end{pmatrix} \begin{pmatrix} 2 & 6 \\ 1 & 4 \end{pmatrix} = \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix} = I
\)

This is not accidental! In general:

\(
AA^{-1} = I \quad \text{and} \quad A^{-1}A = I
\)

NOTICE: Compare with numbers:

 

♦ NUMBERS  MATRICES 

 The inverse of number \( a \) is \( a^{-1} \). \( aa^{-1} = 1 \) and \( a^{-1}a = 1 \). | The inverse of a matrix \( A \) is \( A^{-1} \). \( AA^{-1} = I \) and \( A^{-1}A = I \). 
 Is any number invertible? NO. Only if \( a \neq 0 \) (if \( a = 0 \), \( a^{-1} \) is not defined). | Is any Matrix invertible? NO. Only if \( \text{det}A \neq 0 \) (if \( \text{det}A = 0 \), \( A^{-1} \) is not defined). 
 If \( a \) is invertible, then \( a^{-1} = \frac{1}{a} \). | If \( A \) is invertible, then \( A^{-1} = \frac{1}{\text{det}A} \begin{pmatrix} d & -b \\ -c & a \end{pmatrix} \). 

NOTICE: If \( AB = I \) or \( BA = I \), we know that \( A \) is invertible and \( B \) is the inverse of \( A \), that is:

\(
A^{-1} = B
\)

(\( B \) is also invertible and \( B^{-1} = A \)).

♦ THE INVERSE \( A^{-1} \) OF A 3×3 MATRIX

The explicit formula for \( A^{-1} \) is out of our scope! It is enough to know that:
 \( A^{-1} \) exists only if \( \text{det}A \neq 0 \).
 \( AA^{-1} = I \) and \( A^{-1}A = I \).
 If \( AB = I \) or \( BA = I \), then \( B \) is the inverse of \( A \).
 \( A^{-1} \) can be found by GDC.

Example

Let:

\(
A = \begin{pmatrix} 2 & 5 & 1 \\ 3 & 2 & 0 \\ 4 & 3 & 0 \end{pmatrix}, \quad
B = \begin{pmatrix} 0 & 3 & -2 \\ 0 & -4 & 3 \\ 1 & 14 & -11 \end{pmatrix}
\)

a) Find \( AB \) and \( BA \).
b) Find the inverse of \( A \).
c) Find the inverse of \( B \).

▶️Answer/Explanation

Solution:

Solution:
a) We can easily verify that \( AB = I \) and \( BA = I \).
b) Clearly \( A^{-1} = B \) (the GDC also gives the same result).
c) Similarly, \( B^{-1} = A \) (the GDC also gives the same result).

Notice that we cannot divide matrices, for example, \( \frac{B}{A} \) is not defined. However, we can multiply \( B \) by \( A^{-1} \), either as \( BA^{-1} \) or as \( A^{-1}B \), according to the situation.

The following example will be characteristic:

 

 

Example

Let \( A = \begin{pmatrix} 2 & 6 \\ 1 & 4 \end{pmatrix} \) and \( C = \begin{pmatrix} 20 & 28 \\ 13 & 18 \end{pmatrix} \). Find \( B \) given that \( AB = C \).

▶️Answer/Explanation

Solution:

Method 1: (Analytical)

Let \( B = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \). Then:

\(
AB = \begin{pmatrix} 2 & 6 \\ 1 & 4 \end{pmatrix} \begin{pmatrix} a & b \\ c & d \end{pmatrix} = \begin{pmatrix} 2a + 6c & 2b + 6d \\ a + 4c & b + 4d \end{pmatrix}
\)

Then \( AB = C \) implies:

\(
\begin{pmatrix} 2a + 6c & 2b + 6d \\ a + 4c & b + 4d \end{pmatrix} = \begin{pmatrix} 20 & 28 \\ 13 & 18 \end{pmatrix}
\)

That is:

\(
2a + 6c = 20, \quad 2b + 6d = 28, \quad a + 4c = 13, \quad b + 4d = 18
\)

The first two equations give \( a = 1 \), \( c = 3 \). The second two equations give \( b = 2 \), \( d = 4 \). Therefore:

\(
B = \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix}
\)

Method 2: (Solve for \( B \))

The matrix \( A \) is invertible with \( A^{-1} = \begin{pmatrix} 2 & -3 \\ -1/2 & 1 \end{pmatrix} \). Thus, we may multiply both parts of \( AB = C \) by \( A^{-1} \) on the left:

\(
AB = C \quad \Leftrightarrow \quad A^{-1}AB = A^{-1}C \quad \Leftrightarrow \quad IB = A^{-1}C \quad \Leftrightarrow \quad B = A^{-1}C
\)

Hence:

\(
B = \begin{pmatrix} 2 & -3 \\ -1/2 & 1 \end{pmatrix} \begin{pmatrix} 20 & 28 \\ 13 & 18 \end{pmatrix} = \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix}
\)

 

 THE LINEAR SYSTEM AX=B

An equation of matrices may involve an unknown matrix \( X \).

Suppose that the matrices \( A \), \( B \) and \( C \) are given.
Find the unknown matrix \( X \) in each of the following equations:

Example

1. \( A + X = B \)
2. \( 2A + X = 3B \)
3. \( -3A + 2X = 5B \)
4. \( AX = B \)
5. \( XA = B \)
6. \( AXB = C \)
7. \( AX + B = A \)
8. \( XA – B = XC \)
9. \( AX + X = B \)

▶️Answer/Explanation

Solution:

1. \( X = B – A \)
2. \( X = 3B – 2A \)
3. \( 2X = 3A + 5B \Rightarrow X = \frac{1}{2}(3A + 5B) \)
4. \( X = A^{-1}B \) (mind the order!)
5. \( X = BA^{-1} \) (mind the order!)
6. \( X = A^{-1}CB^{-1} \)
7. \( AX = A – B \Rightarrow X = A^{-1}(A – B) \Rightarrow X = I – A^{-1}B \)
8. \( XA – XC = B \Rightarrow X(A – C) = B \Rightarrow X = B(A – C)^{-1} \)
9. \( (A + I)X = B \Rightarrow X = (A + I)^{-1}B \)

Example

Let \( A = \begin{pmatrix} 2 & 5 \\ 1 & 3 \end{pmatrix} \) and \( B = \begin{pmatrix} 3 & 4 \\ 1 & 2 \end{pmatrix} \).

Solve the equations

(a) \( -3A + 2X = 5B \)
(b) \( AX = B \)
(c) \( XA = B \)
(d) \( AX + B = A \)
(e) \( AX + X = B \)

▶️Answer/Explanation

Solution:

(a) \( -3A + 2X = 5B \Leftrightarrow X = \frac{1}{2}(3A + 5B) \)
\( \Leftrightarrow X = \frac{1}{2} \begin{pmatrix} 21 & 35 \\ 8 & 19 \end{pmatrix} = \begin{pmatrix} \frac{21}{2} & \frac{35}{2} \\ 4 & \frac{19}{2} \end{pmatrix} \)

(b) \( AX = B \Leftrightarrow X = A^{-1}B \)
\( \Leftrightarrow X = \begin{pmatrix} 3 & -5 \\ -1 & 2 \end{pmatrix} \begin{pmatrix} 3 & 4 \\ 1 & 2 \end{pmatrix} \)
\( \Leftrightarrow X = \begin{pmatrix} 4 & 2 \\ -1 & 0 \end{pmatrix} \)

(c) \( XA = B \Leftrightarrow X = BA^{-1} \)
\( \Leftrightarrow X = \begin{pmatrix} 3 & 4 \\ 1 & 2 \end{pmatrix} \begin{pmatrix} 3 & -5 \\ -1 & 2 \end{pmatrix} \)
\( \Leftrightarrow X = \begin{pmatrix} 5 & -7 \\ 1 & -1 \end{pmatrix} \)

(d) \( AX + B = A \Leftrightarrow X = I – A^{-1}B \)
\( \Leftrightarrow X = \begin{pmatrix} 1 & 0 \\ 0 & 1 \end{pmatrix} – \begin{pmatrix} 4 & 2 \\ -1 & 0 \end{pmatrix} \)
\( \Leftrightarrow X = \begin{pmatrix} -3 & -2 \\ 1 & 1 \end{pmatrix} \)

(e) \( AX + X = B \Leftrightarrow X = (A + I)^{-1}B \)
\( \Leftrightarrow X = \begin{pmatrix} 3 & 5 \\ 1 & 4 \end{pmatrix}^{-1} \begin{pmatrix} 3 & 4 \\ 1 & 2 \end{pmatrix} \)
\( \Leftrightarrow X = \frac{1}{7} \begin{pmatrix} 4 & -5 \\ -1 & 3 \end{pmatrix} \begin{pmatrix} 3 & 4 \\ 1 & 2 \end{pmatrix} \)
\( \Leftrightarrow X = \frac{1}{7} \begin{pmatrix} 7 & 6 \\ 0 & 2 \end{pmatrix} = \begin{pmatrix} 1 & \frac{6}{7} \\ 0 & \frac{2}{7} \end{pmatrix} \)

♦ SYSTEMS OF LINEAR EQUATIONS – THE EQUATION AX=B
Consider the 2×2 system (2 equations, 2 unknowns)

\( 2x + 3y = 9 \)
\( 4x + 7y = 19 \)

If we solve it in the traditional way (or by GDC) we will find:
\( x = 3 \) and \( y = 1 \) (check!).

We can describe this system by using matrices.

Let

\( A = \begin{pmatrix} 2 & 3 \\ 4 & 7 \end{pmatrix} \) (the matrix of coefficients)
\( X = \begin{pmatrix} x \\ y \end{pmatrix} \) (the vector of unknowns)
\( B = \begin{pmatrix} 9 \\ 19 \end{pmatrix} \) (the vector of constants)

The equation of matrices \( AX = B \) is equivalent to

\( \begin{pmatrix} 2 & 3 \\ 4 & 7 \end{pmatrix} \begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 9 \\ 19 \end{pmatrix}, \text{ that is } \begin{pmatrix} 2x + 3y \\ 4x + 7y \end{pmatrix} = \begin{pmatrix} 9 \\ 19 \end{pmatrix} \)

which gives in fact the system of linear equations above!

Consider now a 3×3 system:

\( 5x + 11y – 21z = -22 \)
\( x + 2y – 4z = -4 \)
\( 3x – 2y + 3z = 11 \)

Again, if

\( A = \begin{pmatrix} 5 & 11 & -21 \\ 1 & 2 & -4 \\ 3 & -2 & 3 \end{pmatrix}, \) \( X = \begin{pmatrix} x \\ y \\ z \end{pmatrix}, \) \( B = \begin{pmatrix} -22 \\ -4 \\ 11 \end{pmatrix} \),

the system can be written in the form \( AX = B \).

In general, any system of \( n \) linear equations and \( n \) unknowns (that is \( n \times n \)) can be expressed in the form

\( AX = B \)

Hence, if \( A \) is invertible (that is if \( \det A \neq 0 \)) the solution is given by

\( X = A^{-1}B \)

Example

Consider the 2×2 system given above

\( 2x + 3y = 9 \)
\( 4x + 7y = 19 \)

which can be written in the form \( AX = B \).

▶️Answer/Explanation

Solution:

Since \( \det A = \begin{vmatrix} 2 & 3 \\ 4 & 7 \end{vmatrix} = 2 \neq 0 \),

\( A^{-1} = \frac{1}{2} \begin{pmatrix} 7 & -3 \\ -4 & 2 \end{pmatrix} = \begin{pmatrix} \frac{7}{2} & -\frac{3}{2} \\ -2 & 1 \end{pmatrix} \)

The solution of the system is given by

\( X = A^{-1}B = \begin{pmatrix} \frac{7}{2} & -\frac{3}{2} \\ -2 & 1 \end{pmatrix} \begin{pmatrix} 9 \\ 19 \end{pmatrix} = \begin{pmatrix} 3 \\ 1 \end{pmatrix} \)

In other words, \( x = 3 \) and \( y = 1 \).

Example

Consider the 3×3 system given above

\( 5x + 11y – 21z = -22 \)
\( x + 2y – 4z = -4 \)
\( 3x – 2y + 3z = 11 \)

which can be written in the form \( AX = B \).

▶️Answer/Explanation

Solution:

The GDC gives

\( A^{-1} = \begin{pmatrix} \frac{2}{7} & -\frac{9}{7} & \frac{2}{7} \\ \frac{15}{7} & -\frac{78}{7} & \frac{1}{7} \\ \frac{8}{7} & -\frac{43}{7} & \frac{1}{7} \end{pmatrix} \)

The solution of the system is given by

\( X = A^{-1}B = \begin{pmatrix} \frac{2}{7} & -\frac{9}{7} & \frac{2}{7} \\ \frac{15}{7} & -\frac{78}{7} & \frac{1}{7} \\ \frac{8}{7} & -\frac{43}{7} & \frac{1}{7} \end{pmatrix} \begin{pmatrix} -22 \\ -4 \\ 11 \end{pmatrix} = \begin{pmatrix} 2 \\ -1 \\ 1 \end{pmatrix} \)

Example

Let \( A = \begin{pmatrix} 0 & 3 & -2 \\ 0 & -4 & 3 \\ 1 & 14 & -11 \end{pmatrix}, \) \( A’ = \begin{pmatrix} 2 & 5 & 1 \\ 3 & 2 & 0 \\ 4 & 3 & 0 \end{pmatrix}, \) \( B = \begin{pmatrix} 1 \\ 1 \\ 1 \end{pmatrix}, \) \( C = \begin{pmatrix} 1 & 1 \\ 1 & 1 \\ 1 & 1 \end{pmatrix} \).

a) Find \( AA’ \). What do you deduce?
b) Write down the system of three linear equations which corresponds to the matrix equation \( AX = B \).
c) Solve the system of linear equations \( AX = B \).
d) Solve the matrix equation \( AX = C \) (this is not a system).

▶️Answer/Explanation

Solution:

a) We easily obtain \( AA’ = I \). So \( A \) and \( A’ \) are inverse to each other.
\( A’ = A^{-1} \).

b)
\( \begin{cases} 3y – 2z = 1 \\ -4y + 3z = 1 \\ x + 14y – 11z = 1 \end{cases} \)

c) \( AX = B \Leftrightarrow X = A^{-1}B \Leftrightarrow X = \begin{pmatrix} 2 & 5 & 1 \\ 3 & 2 & 0 \\ 4 & 3 & 0 \end{pmatrix} \begin{pmatrix} 1 \\ 1 \\ 1 \end{pmatrix} \Leftrightarrow X = \begin{pmatrix} 8 \\ 5 \\ 7 \end{pmatrix} \).
That is \( x = 8, y = 5, z = 7 \).

d) \( AX = C \Leftrightarrow X = A^{-1}C \Leftrightarrow X = \begin{pmatrix} 2 & 5 & 1 \\ 3 & 2 & 0 \\ 4 & 3 & 0 \end{pmatrix} \begin{pmatrix} 1 & 1 \\ 1 & 1 \\ 1 & 1 \end{pmatrix} \Leftrightarrow X = \begin{pmatrix} 8 & 8 \\ 5 & 5 \\ 7 & 7 \end{pmatrix} \).

Notice though that if \( A \) is not invertible (\( A^{-1} \) does not exist) the system \( AX = B \) cannot be solved in this way. In general,

for the system \( AX = B \):

 \( \det A \neq 0 \) (\( A^{-1} \) exists)  • UNIQUE SOLUTION \( X = A^{-1}B \) 
 \( \det A = 0 \) (\( A^{-1} \) doesn’t exist) |• NO SOLUTION, or • INFINITELY MANY (\( \infty \)) SOLUTIONS 

REMARK. Compare with numbers. For the equation \( ax = b \):

 \( a \neq 0 \) (\( a^{-1} = \frac{1}{a} \) exists)  • Unique solution \( x = \frac{b}{a} \). 
\( a = 0 \) (\( a^{-1} \) doesn’t exist)  • No solution (e.g., \( 0x = 5 \) has no solution) • Infinitely many solutions (e.g., \( 0x = 0 \), true for any \( x \in \mathbb{R} \)) 

In IB exams, \( A \) will always be invertible (\( \det A \neq 0 \), unique solution).

However, it is worth seeing two examples of systems of linear equations where \( \det A = 0 \).

Example

Consider the systems

(a)

\( x + 2y = 1   \)
\( 2x + 4y = 5 \)

(b)

\( x + 2y = 1 \)

\( 2x + 4y = 2 \)

▶️Answer/Explanation

Solution:

For both, \( \det A = \begin{vmatrix} 1 & 2 \\ 2 & 4 \end{vmatrix} = 0 \),

so the systems have either no solution or an infinite number of solutions.

We multiply the first equation by 2 and obtain \( 2x + 4y = 2 \). Hence the two systems take the equivalent form:

\( (a) \quad 2x + 4y = 2 \quad (b) \quad 2x + 4y = 2 \)
\( 2x + 4y = 5 \quad 2x + 4y = 2 \)

System (a) has no solution (impossible). [Check also by GDC.]
System (b) reduces to just one equation: \( x + 2y = 1 \).

There are infinitely many solutions (all points of the line \( x + 2y = 1 \)).
If we solve for \( x \): \( x = 1 – 2y \),
\( y \in \mathbb{R} \) (free variable). [Check also by GDC.]

In fact, for each value of \( y \), we obtain a different solution \( \begin{pmatrix} x \\ y \end{pmatrix} \):
for \( y = 0 \): \( \begin{pmatrix} 1 \\ 0 \end{pmatrix} \), for \( y = 1 \): \( \begin{pmatrix} -1 \\ 1 \end{pmatrix} \), for \( y = 2 \): \( \begin{pmatrix} -3 \\ 2 \end{pmatrix} \), etc.

For \( 3 \times 3 \) systems with \( \det A = 0 \), the GDC gives the answer.

Example

Consider the systems

\( (a) \quad 2x + 3y + 3z = 3 \quad (b) \quad 2x + 3y + 3z = 3 \)
\( x + y – 2z = 4 \quad x + y – 2z = 4 \)
\( 5x + 7y + 4z = 5 \quad 5x + 7y + 4z = 10 \)

▶️Answer/Explanation

Solution:

For both systems,

\( \det A = \begin{vmatrix} 2 & 3 & 3 \\ 1 & 1 & -2 \\ 5 & 7 & 4 \end{vmatrix} = 0 \)

The GDC gives:
(a) The system has no solution.
(b) The system has infinitely many solutions:

\( x = 14 + 16z \)
\( y = -5 + 7z \)
\( z \in \mathbb{R} \text{ (free variable)} \)

Scroll to Top