Matrices and Linear Transformations Matrix Operations
Notation
An m × n m \times n m × n matrix A A A has m m m rows and n n n columns. The entry in row i i i , column j j j is a i j a_{ij} a ij .
Addition and Scalar Multiplication
For A , B ∈ ′ { ′ M ′ } ′ m × n ( ′ { ′ R ′ } ′ ) A, B \in \mathcal{'\{'}M{'\}'}_{m \times n}(\mathbb{'\{'}R{'\}'}) A , B ∈ ′ { ′ M ′ } ′ m × n ( ′ { ′ R ′ } ′ ) and λ ∈ ′ { ′ R ′ } ′ \lambda \in \mathbb{'\{'}R{'\}'} λ ∈ ′ { ′ R ′ } ′ :
( A + B ) i j = a i j + b i j , ( λ A ) i j = λ a i j (A + B)_{ij} = a_{ij} + b_{ij}, \qquad (\lambda A)_{ij} = \lambda a_{ij} ( A + B ) ij = a ij + b ij , ( λ A ) ij = λ a ij
Matrix Multiplication
If A A A is m × p m \times p m × p and B B B is p × n p \times n p × n , the product C = A B C = AB C = A B is m × n m \times n m × n with:
c i j = ∑ k = 1 p a i k b k j c_{ij} = \sum_{k=1}^{p} a_{ik}b_{kj} c ij = ∑ k = 1 p a ik b k j
Key properties:
( A B ) C = A ( B C ) (AB)C = A(BC) ( A B ) C = A ( B C ) (associative)
A ( B + C ) = A B + A C A(B + C) = AB + AC A ( B + C ) = A B + A C (distributive)
A B ≠ B A AB \ne BA A B = B A in general (not commutative)
( A B ) T = B T A T (AB)^T = B^T A^T ( A B ) T = B T A T
Example. If A = ( 1 2 3 4 ) A = \begin{pmatrix} 1 & 2 \\ 3 & 4 \end{pmatrix} A = ( 1 3 2 4 ) and B = ( 5 6 7 8 ) B = \begin{pmatrix} 5 & 6 \\ 7 & 8 \end{pmatrix} B = ( 5 7 6 8 ) :
A B = ( 1 ⋅ 5 + 2 ⋅ 7 1 ⋅ 6 + 2 ⋅ 8 3 ⋅ 5 + 4 ⋅ 7 3 ⋅ 6 + 4 ⋅ 8 ) = ( 19 22 43 50 ) AB = \begin{pmatrix} 1 \cdot 5 + 2 \cdot 7 & 1 \cdot 6 + 2 \cdot 8 \\ 3 \cdot 5 + 4 \cdot 7 & 3 \cdot 6 + 4 \cdot 8 \end{pmatrix} = \begin{pmatrix} 19 & 22 \\ 43 & 50 \end{pmatrix} A B = ( 1 ⋅ 5 + 2 ⋅ 7 3 ⋅ 5 + 4 ⋅ 7 1 ⋅ 6 + 2 ⋅ 8 3 ⋅ 6 + 4 ⋅ 8 ) = ( 19 43 22 50 )
B A = ( 23 34 31 46 ) ≠ A B BA = \begin{pmatrix} 23 & 34 \\ 31 & 46 \end{pmatrix} \ne AB B A = ( 23 31 34 46 ) = A B
Determinants
2 × 2 2 \times 2 2 × 2 Determinant
det ( a b c d ) = a d − b c \det\begin{pmatrix} a & b \\ c & d \end{pmatrix} = ad - bc det ( a c b d ) = a d − b c
3 × 3 3 \times 3 3 × 3 Determinant (Cofactor Expansion)
det A = a 11 ∣ a 22 a 23 a 32 a 33 ∣ − a 12 ∣ a 21 a 23 a 31 a 33 ∣ + a 13 ∣ a 21 a 22 a 31 a 32 ∣ \det A = a_{11}\begin{vmatrix} a_{22} & a_{23} \\ a_{32} & a_{33} \end{vmatrix} - a_{12}\begin{vmatrix} a_{21} & a_{23} \\ a_{31} & a_{33} \end{vmatrix} + a_{13}\begin{vmatrix} a_{21} & a_{22} \\ a_{31} & a_{32} \end{vmatrix} det A = a 11 a 22 a 32 a 23 a 33 − a 12 a 21 a 31 a 23 a 33 + a 13 a 21 a 31 a 22 a 32
Example. det ( 1 0 2 3 1 − 1 2 4 1 ) \det\begin{pmatrix} 1 & 0 & 2 \\ 3 & 1 & -1 \\ 2 & 4 & 1 \end{pmatrix} det 1 3 2 0 1 4 2 − 1 1
= 1 ∣ 1 − 1 4 1 ∣ − 0 + 2 ∣ 3 1 2 4 ∣ = 1 ( 1 + 4 ) + 2 ( 12 − 2 ) = 5 + 20 = 25 = 1\begin{vmatrix} 1 & -1 \\ 4 & 1 \end{vmatrix} - 0 + 2\begin{vmatrix} 3 & 1 \\ 2 & 4 \end{vmatrix} = 1(1 + 4) + 2(12 - 2) = 5 + 20 = 25 = 1 1 4 − 1 1 − 0 + 2 3 2 1 4 = 1 ( 1 + 4 ) + 2 ( 12 − 2 ) = 5 + 20 = 25
Properties
det ( A B ) = det ( A ) det ( B ) \det(AB) = \det(A)\det(B) det ( A B ) = det ( A ) det ( B )
det ( A T ) = det ( A ) \det(A^T) = \det(A) det ( A T ) = det ( A )
det ( λ A ) = λ n det ( A ) \det(\lambda A) = \lambda^n \det(A) det ( λ A ) = λ n det ( A ) for n × n n \times n n × n matrix A A A
Swapping two rows multiplies the determinant by − 1 -1 − 1
If two rows are equal, det ( A ) = 0 \det(A) = 0 det ( A ) = 0
det ( A ) = 0 \det(A) = 0 det ( A ) = 0 if and only if A A A is singular (non-invertible)
Matrix Inverses
Definition
If A A A is a square matrix, its inverse A − 1 A^{-1} A − 1 satisfies:
A A − 1 = A − 1 A = I AA^{-1} = A^{-1}A = I A A − 1 = A − 1 A = I
A A A is invertible if and only if det ( A ) ≠ 0 \det(A) \ne 0 det ( A ) = 0 .
2 × 2 2 \times 2 2 × 2 Inverse
A − 1 = 1 a d − b c ( d − b − c a ) A^{-1} = \frac{1}{ad - bc}\begin{pmatrix} d & -b \\ -c & a \end{pmatrix} A − 1 = a d − b c 1 ( d − c − b a )
Example. Find the inverse of A = ( 3 1 5 2 ) A = \begin{pmatrix} 3 & 1 \\ 5 & 2 \end{pmatrix} A = ( 3 5 1 2 ) .
det ( A ) = 6 − 5 = 1 ≠ 0 \det(A) = 6 - 5 = 1 \ne 0 det ( A ) = 6 − 5 = 1 = 0 , so A A A is invertible.
A − 1 = ( 2 − 1 − 5 3 ) A^{-1} = \begin{pmatrix} 2 & -1 \\ -5 & 3 \end{pmatrix} A − 1 = ( 2 − 5 − 1 3 )
Inverse via Row Reduction (Gauss-Jordan)
To find A − 1 A^{-1} A − 1 , augment A A A with I I I and apply row operations:
[ A ∣ I ] → r o w o p s [ I ∣ A − 1 ] \left[\,A \mid I\,\right] \xrightarrow{\mathrm{row\ ops}} \left[\,I \mid A^{-1}\,\right] [ A ∣ I ] row ops [ I ∣ A − 1 ]
If the left half reduces to I I I , the right half is A − 1 A^{-1} A − 1 . If the left half has a zero row, A A A is
singular.
Example. Find A − 1 A^{-1} A − 1 for A = ( 1 2 3 0 1 4 0 0 1 ) A = \begin{pmatrix} 1 & 2 & 3 \\ 0 & 1 & 4 \\ 0 & 0 & 1 \end{pmatrix} A = 1 0 0 2 1 0 3 4 1 .
Since A A A is upper triangular, det ( A ) = 1 ⋅ 1 ⋅ 1 = 1 \det(A) = 1 \cdot 1 \cdot 1 = 1 det ( A ) = 1 ⋅ 1 ⋅ 1 = 1 .
[ 1 2 3 1 0 0 0 1 4 0 1 0 0 0 1 0 0 1 ] \left[\begin{array}{ccc|ccc} 1 & 2 & 3 & 1 & 0 & 0 \\ 0 & 1 & 4 & 0 & 1 & 0 \\ 0 & 0 & 1 & 0 & 0 & 1 \end{array}\right] 1 0 0 2 1 0 3 4 1 1 0 0 0 1 0 0 0 1
R 1 → R 1 − 2 R 2 R_1 \to R_1 - 2R_2 R 1 → R 1 − 2 R 2 :
[ 1 0 − 5 1 − 2 0 0 1 4 0 1 0 0 0 1 0 0 1 ] \left[\begin{array}{ccc|ccc} 1 & 0 & -5 & 1 & -2 & 0 \\ 0 & 1 & 4 & 0 & 1 & 0 \\ 0 & 0 & 1 & 0 & 0 & 1 \end{array}\right] 1 0 0 0 1 0 − 5 4 1 1 0 0 − 2 1 0 0 0 1
R 1 → R 1 + 5 R 3 R_1 \to R_1 + 5R_3 R 1 → R 1 + 5 R 3 , R 2 → R 2 − 4 R 3 R_2 \to R_2 - 4R_3 R 2 → R 2 − 4 R 3 :
[ 1 0 0 1 − 2 5 0 1 0 0 1 − 4 0 0 1 0 0 1 ] \left[\begin{array}{ccc|ccc} 1 & 0 & 0 & 1 & -2 & 5 \\ 0 & 1 & 0 & 0 & 1 & -4 \\ 0 & 0 & 1 & 0 & 0 & 1 \end{array}\right] 1 0 0 0 1 0 0 0 1 1 0 0 − 2 1 0 5 − 4 1
A − 1 = ( 1 − 2 5 0 1 − 4 0 0 1 ) A^{-1} = \begin{pmatrix} 1 & -2 & 5 \\ 0 & 1 & -4 \\ 0 & 0 & 1 \end{pmatrix} A − 1 = 1 0 0 − 2 1 0 5 − 4 1
Solving Systems of Linear Equations
The system A ′ { ′ x ′ } ′ = ′ { ′ b ′ } ′ A\mathbf{'\{'}x{'\}'} = \mathbf{'\{'}b{'\}'} A ′ { ′ x ′ } ′ = ′ { ′ b ′ } ′ where A A A is n × n n \times n n × n :
Unique solution: det ( A ) ≠ 0 \det(A) \ne 0 det ( A ) = 0 , giving ′ { ′ x ′ } ′ = A − 1 ′ { ′ b ′ } ′ \mathbf{'\{'}x{'\}'} = A^{-1}\mathbf{'\{'}b{'\}'} ′ { ′ x ′ } ′ = A − 1 ′ { ′ b ′ } ′
No solution or infinitely many: det ( A ) = 0 \det(A) = 0 det ( A ) = 0
Cramer's Rule
If det ( A ) ≠ 0 \det(A) \ne 0 det ( A ) = 0 , the i i i -th component of the solution is:
x i = det ( A i ) det ( A ) x_i = \frac{\det(A_i)}{\det(A)} x i = d e t ( A ) d e t ( A i )
where A i A_i A i is A A A with the i i i -th column replaced by ′ { ′ b ′ } ′ \mathbf{'\{'}b{'\}'} ′ { ′ b ′ } ′ .
Example. Solve { 2 x + y = 5 x − y = 1 \begin{cases} 2x + y = 5 \\ x - y = 1 \end{cases} { 2 x + y = 5 x − y = 1 .
A = ( 2 1 1 − 1 ) , det ( A ) = − 2 − 1 = − 3 A = \begin{pmatrix} 2 & 1 \\ 1 & -1 \end{pmatrix}, \quad \det(A) = -2 - 1 = -3 A = ( 2 1 1 − 1 ) , det ( A ) = − 2 − 1 = − 3
x = det ( 5 1 1 − 1 ) − 3 = − 6 − 3 = 2 , y = det ( 2 5 1 1 ) − 3 = − 3 − 3 = 1 x = \frac{\det\begin{pmatrix} 5 & 1 \\ 1 & -1 \end{pmatrix}}{-3} = \frac{-6}{-3} = 2, \qquad y = \frac{\det\begin{pmatrix} 2 & 5 \\ 1 & 1 \end{pmatrix}}{-3} = \frac{-3}{-3} = 1 x = − 3 d e t ( 5 1 1 − 1 ) = − 3 − 6 = 2 , y = − 3 d e t ( 2 1 5 1 ) = − 3 − 3 = 1
Gaussian Elimination
For systems of any size, use row reduction to transform the augmented matrix to row echelon
form, then back-substitute.
Each linear transformation of ′ { ′ R ′ } ′ 2 \mathbb{'\{'}R{'\}'}^2 ′ { ′ R ′ } ′ 2 can be represented by a 2 × 2 2 \times 2 2 × 2 matrix.
Transformation Matrix Effect on Area Reflection in x x x -axis ( 1 0 0 − 1 ) \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix} ( 1 0 0 − 1 ) Preserved Reflection in y y y -axis ( − 1 0 0 1 ) \begin{pmatrix} -1 & 0 \\ 0 & 1 \end{pmatrix} ( − 1 0 0 1 ) Preserved Reflection in y = x y = x y = x ( 0 1 1 0 ) \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix} ( 0 1 1 0 ) Preserved Rotation θ \theta θ anticlockwise ( cos θ − sin θ sin θ cos θ ) \begin{pmatrix} \cos\theta & -\sin\theta \\ \sin\theta & \cos\theta \end{pmatrix} ( cos θ sin θ − sin θ cos θ ) Preserved Enlargement by k k k ( k 0 0 k ) \begin{pmatrix} k & 0 \\ 0 & k \end{pmatrix} ( k 0 0 k ) Scaled by k 2 k^2 k 2 Stretch parallel to x x x -axis by k k k ( k 0 0 1 ) \begin{pmatrix} k & 0 \\ 0 & 1 \end{pmatrix} ( k 0 0 1 ) Scaled by $ Shear parallel to x x x -axis by k k k ( 1 k 0 1 ) \begin{pmatrix} 1 & k \\ 0 & 1 \end{pmatrix} ( 1 0 k 1 ) Preserved
If transformation A A A is followed by transformation B B B , the combined transformation is represented
by the matrix product B A BA B A (note the order: apply A A A first, then B B B ).
Example. Find the matrix for a rotation of 90 ∘ 90\,{}^{\circ} 90 ∘ anticlockwise about the origin,
followed by a reflection in the x x x -axis.
A = ( 0 − 1 1 0 ) ( r o t a t i o n ) , B = ( 1 0 0 − 1 ) ( r e f l e c t i o n ) A = \begin{pmatrix} 0 & -1 \\ 1 & 0 \end{pmatrix} \quad \mathrm{(rotation)}, \qquad B = \begin{pmatrix} 1 & 0 \\ 0 & -1 \end{pmatrix} \quad \mathrm{(reflection)} A = ( 0 1 − 1 0 ) ( rotation ) , B = ( 1 0 0 − 1 ) ( reflection )
B A = ( 0 − 1 − 1 0 ) BA = \begin{pmatrix} 0 & -1 \\ -1 & 0 \end{pmatrix} B A = ( 0 − 1 − 1 0 )
This is equivalent to a reflection in the line y = − x y = -x y = − x .
Invariant Points and Lines
An invariant point satisfies A ′ { ′ x ′ } ′ = ′ { ′ x ′ } ′ A\mathbf{'\{'}x{'\}'} = \mathbf{'\{'}x{'\}'} A ′ { ′ x ′ } ′ = ′ { ′ x ′ } ′ , i.e. ( A − I ) ′ { ′ x ′ } ′ = ′ { ′ 0 ′ } ′ (A - I)\mathbf{'\{'}x{'\}'} = \mathbf{'\{'}0{'\}'} ( A − I ) ′ { ′ x ′ } ′ = ′ { ′ 0 ′ } ′ .
An invariant line is a line mapped to itself (points on the line may move along it).
Eigenvalues and Eigenvectors
Definition
For a square matrix A A A , a scalar λ \lambda λ is an eigenvalue if there exists a non-zero vector
′ { ′ v ′ } ′ \mathbf{'\{'}v{'\}'} ′ { ′ v ′ } ′ such that:
A ′ { ′ v ′ } ′ = λ ′ { ′ v ′ } ′ A\mathbf{'\{'}v{'\}'} = \lambda\mathbf{'\{'}v{'\}'} A ′ { ′ v ′ } ′ = λ ′ { ′ v ′ } ′
The vector ′ { ′ v ′ } ′ \mathbf{'\{'}v{'\}'} ′ { ′ v ′ } ′ is the corresponding eigenvector .
Characteristic Equation
det ( A − λ I ) = 0 \det(A - \lambda I) = 0 det ( A − λ I ) = 0
This is a polynomial equation of degree n n n in λ \lambda λ whose roots are the eigenvalues.
Finding Eigenvectors
For each eigenvalue λ i \lambda_i λ i , solve ( A − λ i I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ (A - \lambda_i I)\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} ( A − λ i I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ .
Worked Examples
Example. Find the eigenvalues and eigenvectors of A = ( 4 1 2 3 ) A = \begin{pmatrix} 4 & 1 \\ 2 & 3 \end{pmatrix} A = ( 4 2 1 3 ) .
Characteristic equation:
det ( 4 − λ 1 2 3 − λ ) = ( 4 − λ ) ( 3 − λ ) − 2 = λ 2 − 7 λ + 10 = 0 \det\begin{pmatrix} 4 - \lambda & 1 \\ 2 & 3 - \lambda \end{pmatrix} = (4 - \lambda)(3 - \lambda) - 2 = \lambda^2 - 7\lambda + 10 = 0 det ( 4 − λ 2 1 3 − λ ) = ( 4 − λ ) ( 3 − λ ) − 2 = λ 2 − 7 λ + 10 = 0
( λ − 5 ) ( λ − 2 ) = 0 ⟹ λ 1 = 5 , λ 2 = 2 (\lambda - 5)(\lambda - 2) = 0 \implies \lambda_1 = 5, \quad \lambda_2 = 2 ( λ − 5 ) ( λ − 2 ) = 0 ⟹ λ 1 = 5 , λ 2 = 2
For λ 1 = 5 \lambda_1 = 5 λ 1 = 5 : ( A − 5 I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ (A - 5I)\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} ( A − 5 I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ :
( − 1 1 2 − 2 ) ( x y ) = ( 0 0 ) ⟹ − x + y = 0 ⟹ y = x \begin{pmatrix} -1 & 1 \\ 2 & -2 \end{pmatrix}\begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 0 \\ 0 \end{pmatrix} \implies -x + y = 0 \implies y = x ( − 1 2 1 − 2 ) ( x y ) = ( 0 0 ) ⟹ − x + y = 0 ⟹ y = x
Eigenvector: ′ { ′ v ′ } ′ 1 = ( 1 1 ) \mathbf{'\{'}v{'\}'}_1 = \begin{pmatrix} 1 \\ 1 \end{pmatrix} ′ { ′ v ′ } ′ 1 = ( 1 1 ) (or any scalar multiple).
For λ 2 = 2 \lambda_2 = 2 λ 2 = 2 : ( A − 2 I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ (A - 2I)\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} ( A − 2 I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ :
( 2 1 2 1 ) ( x y ) = ( 0 0 ) ⟹ 2 x + y = 0 ⟹ y = − 2 x \begin{pmatrix} 2 & 1 \\ 2 & 1 \end{pmatrix}\begin{pmatrix} x \\ y \end{pmatrix} = \begin{pmatrix} 0 \\ 0 \end{pmatrix} \implies 2x + y = 0 \implies y = -2x ( 2 2 1 1 ) ( x y ) = ( 0 0 ) ⟹ 2 x + y = 0 ⟹ y = − 2 x
Eigenvector: ′ { ′ v ′ } ′ 2 = ( 1 − 2 ) \mathbf{'\{'}v{'\}'}_2 = \begin{pmatrix} 1 \\ -2 \end{pmatrix} ′ { ′ v ′ } ′ 2 = ( 1 − 2 ) .
Diagonalisation
If A A A has n n n linearly independent eigenvectors, it can be diagonalised :
A = P D P − 1 A = PDP^{-1} A = P D P − 1
where D D D is the diagonal matrix of eigenvalues and P P P has eigenvectors as columns.
Applications:
Computing A n A^n A n efficiently: A n = P D n P − 1 A^n = PD^nP^{-1} A n = P D n P − 1
Solving systems of differential equations
Principal component analysis (statistics)
Trace and Determinant
For a 2 × 2 2 \times 2 2 × 2 matrix with eigenvalues λ 1 , λ 2 \lambda_1, \lambda_2 λ 1 , λ 2 :
t r ( A ) = λ 1 + λ 2 = a 11 + a 22 \mathrm{tr}(A) = \lambda_1 + \lambda_2 = a_{11} + a_{22} tr ( A ) = λ 1 + λ 2 = a 11 + a 22
det ( A ) = λ 1 λ 2 \det(A) = \lambda_1 \lambda_2 det ( A ) = λ 1 λ 2
3 × 3 3 \times 3 3 × 3 Eigenvalue Example
Example. Find the eigenvalues and eigenvectors of A = ( 2 0 0 0 3 − 1 0 − 1 3 ) A = \begin{pmatrix} 2 & 0 & 0 \\ 0 & 3 & -1 \\ 0 & -1 & 3 \end{pmatrix} A = 2 0 0 0 3 − 1 0 − 1 3 .
Characteristic equation:
det ( 2 − λ 0 0 0 3 − λ − 1 0 − 1 3 − λ ) = ( 2 − λ ) [ ( 3 − λ ) 2 − 1 ] = 0 \det\begin{pmatrix} 2 - \lambda & 0 & 0 \\ 0 & 3 - \lambda & -1 \\ 0 & -1 & 3 - \lambda \end{pmatrix} = (2 - \lambda)\bigl[(3 - \lambda)^2 - 1\bigr] = 0 det 2 − λ 0 0 0 3 − λ − 1 0 − 1 3 − λ = ( 2 − λ ) [ ( 3 − λ ) 2 − 1 ] = 0
( 2 − λ ) ( λ 2 − 6 λ + 8 ) = ( 2 − λ ) ( λ − 2 ) ( λ − 4 ) = 0 (2 - \lambda)(\lambda^2 - 6\lambda + 8) = (2 - \lambda)(\lambda - 2)(\lambda - 4) = 0 ( 2 − λ ) ( λ 2 − 6 λ + 8 ) = ( 2 − λ ) ( λ − 2 ) ( λ − 4 ) = 0
λ 1 = 2 \lambda_1 = 2 λ 1 = 2 (algebraic multiplicity 2), λ 2 = 4 \lambda_2 = 4 λ 2 = 4 .
For λ = 2 \lambda = 2 λ = 2 : ( A − 2 I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ (A - 2I)\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} ( A − 2 I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ gives ( 0 0 0 0 1 − 1 0 − 1 1 ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ \begin{pmatrix} 0 & 0 & 0 \\ 0 & 1 & -1 \\ 0 & -1 & 1 \end{pmatrix}\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} 0 0 0 0 1 − 1 0 − 1 1 ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ ,
so v 2 = v 3 v_2 = v_3 v 2 = v 3 with v 1 v_1 v 1 free. Two linearly independent eigenvectors: ′ { ′ v ′ } ′ 1 = ( 1 , 0 , 0 ) \mathbf{'\{'}v{'\}'}_1 = (1, 0, 0) ′ { ′ v ′ } ′ 1 = ( 1 , 0 , 0 )
and ′ { ′ v ′ } ′ 2 = ( 0 , 1 , 1 ) \mathbf{'\{'}v{'\}'}_2 = (0, 1, 1) ′ { ′ v ′ } ′ 2 = ( 0 , 1 , 1 ) .
For λ = 4 \lambda = 4 λ = 4 : ( A − 4 I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ (A - 4I)\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} ( A − 4 I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ gives − v 2 − v 3 = 0 -v_2 - v_3 = 0 − v 2 − v 3 = 0 and − v 1 = 0 -v_1 = 0 − v 1 = 0 ,
so ′ { ′ v ′ } ′ 3 = ( 0 , 1 , − 1 ) \mathbf{'\{'}v{'\}'}_3 = (0, 1, -1) ′ { ′ v ′ } ′ 3 = ( 0 , 1 , − 1 ) .
The matrix is diagonalisable: P = ( 1 0 0 0 1 1 0 1 − 1 ) P = \begin{pmatrix} 1 & 0 & 0 \\ 0 & 1 & 1 \\ 0 & 1 & -1 \end{pmatrix} P = 1 0 0 0 1 1 0 1 − 1 ,
D = ( 2 0 0 0 2 0 0 0 4 ) D = \begin{pmatrix} 2 & 0 & 0 \\ 0 & 2 & 0 \\ 0 & 0 & 4 \end{pmatrix} D = 2 0 0 0 2 0 0 0 4 .
Solving Systems Using Row Reduction
Augmented Matrix Method
For a system of m m m equations in n n n unknowns, write the augmented matrix [ A ∣ ′ { ′ b ′ } ′ ] [A | \mathbf{'\{'}b{'\}'}] [ A ∣ ′ { ′ b ′ } ′ ] and apply
elementary row operations to reach row echelon form.
Elementary row operations:
Swap two rows (R i ↔ R j R_i \leftrightarrow R_j R i ↔ R j ).
Multiply a row by a non-zero scalar (R i → k R i R_i \to kR_i R i → k R i ).
Add a multiple of one row to another (R i → R i + k R j R_i \to R_i + kR_j R i → R i + k R j ).
Example: Three Equations in Three Unknowns
Solve the system:
x + 2 y − z = 3 x + 2y - z = 3 x + 2 y − z = 3
2 x − y + z = 1 2x - y + z = 1 2 x − y + z = 1
3 x + y + 2 z = 10 3x + y + 2z = 10 3 x + y + 2 z = 10
Augmented matrix:
[ 1 2 − 1 3 2 − 1 1 1 3 1 2 10 ] \left[\begin{array}{ccc|c} 1 & 2 & -1 & 3 \\ 2 & -1 & 1 & 1 \\ 3 & 1 & 2 & 10 \end{array}\right] 1 2 3 2 − 1 1 − 1 1 2 3 1 10
R 2 → R 2 − 2 R 1 R_2 \to R_2 - 2R_1 R 2 → R 2 − 2 R 1 , R 3 → R 3 − 3 R 1 R_3 \to R_3 - 3R_1 R 3 → R 3 − 3 R 1 :
[ 1 2 − 1 3 0 − 5 3 − 5 0 − 5 5 1 ] \left[\begin{array}{ccc|c} 1 & 2 & -1 & 3 \\ 0 & -5 & 3 & -5 \\ 0 & -5 & 5 & 1 \end{array}\right] 1 0 0 2 − 5 − 5 − 1 3 5 3 − 5 1
R 3 → R 3 − R 2 R_3 \to R_3 - R_2 R 3 → R 3 − R 2 :
[ 1 2 − 1 3 0 − 5 3 − 5 0 0 2 6 ] \left[\begin{array}{ccc|c} 1 & 2 & -1 & 3 \\ 0 & -5 & 3 & -5 \\ 0 & 0 & 2 & 6 \end{array}\right] 1 0 0 2 − 5 0 − 1 3 2 3 − 5 6
Back-substitute: 2 z = 6 ⟹ z = 3 2z = 6 \implies z = 3 2 z = 6 ⟹ z = 3 . Then − 5 y + 9 = − 5 ⟹ y = 14 / 5 = 2.8 -5y + 9 = -5 \implies y = 14/5 = 2.8 − 5 y + 9 = − 5 ⟹ y = 14/5 = 2.8 .
Then x + 5.6 − 3 = 3 ⟹ x = 0.4 x + 5.6 - 3 = 3 \implies x = 0.4 x + 5.6 − 3 = 3 ⟹ x = 0.4 .
Solution: ( x , y , z ) = ( 2 / 5 , 14 / 5 , 3 ) (x, y, z) = (2/5,\, 14/5,\, 3) ( x , y , z ) = ( 2/5 , 14/5 , 3 ) .
Nature of Solutions
For an n × n n \times n n × n system A ′ { ′ x ′ } ′ = ′ { ′ b ′ } ′ A\mathbf{'\{'}x{'\}'} = \mathbf{'\{'}b{'\}'} A ′ { ′ x ′ } ′ = ′ { ′ b ′ } ′ :
det ( A ) \det(A) det ( A ) Rank Solutions ≠ 0 \ne 0 = 0 n n n Unique solution = 0 = 0 = 0 and consistent< n \lt n < n Infinitely many solutions = 0 = 0 = 0 and inconsistent— No solution
3 × 3 3 \times 3 3 × 3 Determinant and Inverse
Cofactor Expansion Along Any Row or Column
The determinant can be computed by expanding along any row i i i :
det ( A ) = ∑ j = 1 n ( − 1 ) i + j a i j M i j \det(A) = \sum_{j=1}^{n} (-1)^{i+j}\, a_{ij}\, M_{ij} det ( A ) = ∑ j = 1 n ( − 1 ) i + j a ij M ij
where M i j M_{ij} M ij is the minor (determinant of the submatrix obtained by removing row i i i and column j j j ).
Choosing a row or column with the most zeros minimises computation.
Adjugate Method for 3 × 3 3 \times 3 3 × 3 Inverse
A − 1 = 1 det ( A ) a d j ( A ) A^{-1} = \frac{1}{\det(A)}\,\mathrm{adj}(A) A − 1 = d e t ( A ) 1 adj ( A )
where the adjugate (adjoint) matrix is the transpose of the cofactor matrix.
Example. Find A − 1 A^{-1} A − 1 for A = ( 1 2 0 0 1 3 1 0 1 ) A = \begin{pmatrix} 1 & 2 & 0 \\ 0 & 1 & 3 \\ 1 & 0 & 1 \end{pmatrix} A = 1 0 1 2 1 0 0 3 1 .
det ( A ) = 1 ( 1 − 0 ) − 2 ( 0 − 3 ) + 0 = 1 + 6 = 7 \det(A) = 1(1 - 0) - 2(0 - 3) + 0 = 1 + 6 = 7 det ( A ) = 1 ( 1 − 0 ) − 2 ( 0 − 3 ) + 0 = 1 + 6 = 7 .
Cofactor matrix: C = ( 1 3 − 1 − 2 1 2 6 − 3 1 ) C = \begin{pmatrix} 1 & 3 & -1 \\ -2 & 1 & 2 \\ 6 & -3 & 1 \end{pmatrix} C = 1 − 2 6 3 1 − 3 − 1 2 1 .
a d j ( A ) = C T = ( 1 − 2 6 3 1 − 3 − 1 2 1 ) \mathrm{adj}(A) = C^T = \begin{pmatrix} 1 & -2 & 6 \\ 3 & 1 & -3 \\ -1 & 2 & 1 \end{pmatrix} adj ( A ) = C T = 1 3 − 1 − 2 1 2 6 − 3 1 .
A − 1 = 1 7 ( 1 − 2 6 3 1 − 3 − 1 2 1 ) A^{-1} = \frac{1}{7}\begin{pmatrix} 1 & -2 & 6 \\ 3 & 1 & -3 \\ -1 & 2 & 1 \end{pmatrix} A − 1 = 7 1 1 3 − 1 − 2 1 2 6 − 3 1
Applications of Eigenvalues
Powers of Matrices
If A = P D P − 1 A = PDP^{-1} A = P D P − 1 , then A n = P D n P − 1 A^n = PD^nP^{-1} A n = P D n P − 1 , where D n D^n D n is trivial to compute (just raise diagonal
entries to the n n n -th power).
Example. Compute A 10 A^{10} A 10 for A = ( 3 1 2 4 ) A = \begin{pmatrix} 3 & 1 \\ 2 & 4 \end{pmatrix} A = ( 3 2 1 4 ) .
From earlier, λ 1 = 5 \lambda_1 = 5 λ 1 = 5 , λ 2 = 2 \lambda_2 = 2 λ 2 = 2 , P = ( 1 1 1 − 2 ) P = \begin{pmatrix} 1 & 1 \\ 1 & -2 \end{pmatrix} P = ( 1 1 1 − 2 ) .
D 10 = ( 5 10 0 0 2 10 ) D^{10} = \begin{pmatrix} 5^{10} & 0 \\ 0 & 2^{10} \end{pmatrix} D 10 = ( 5 10 0 0 2 10 )
A 10 = P D 10 P − 1 A^{10} = PD^{10}P^{-1} A 10 = P D 10 P − 1
Systems of Differential Equations
The system d ′ { ′ x ′ } ′ d t = A ′ { ′ x ′ } ′ \dfrac{d\mathbf{'\{'}x{'\}'}}{dt} = A\mathbf{'\{'}x{'\}'} d t d ′ { ′ x ′ } ′ = A ′ { ′ x ′ } ′ has solution ′ { ′ x ′ } ′ ( t ) = e A t ′ { ′ x ′ } ′ ( 0 ) \mathbf{'\{'}x{'\}'}(t) = e^{At}\mathbf{'\{'}x{'\}'}(0) ′ { ′ x ′ } ′ ( t ) = e A t ′ { ′ x ′ } ′ ( 0 ) ,
which can be evaluated using diagonalisation: e A t = P e D t P − 1 e^{At} = Pe^{Dt}P^{-1} e A t = P e D t P − 1 .
Common Pitfall
A matrix is diagonalisable if and only if it has a full set of linearly independent eigenvectors. A
matrix with repeated eigenvalues may or may not be diagonalisable. For example,
( 1 1 0 1 ) \begin{pmatrix} 1 & 1 \\ 0 & 1 \end{pmatrix} ( 1 0 1 1 ) has eigenvalue 1 1 1 with algebraic multiplicity 2 2 2 but
geometric multiplicity 1 1 1 ; it is not diagonalisable.
Additional Worked Examples
Worked Example: 3 × 3 3 \times 3 3 × 3 System with No Unique Solution
Determine the nature of solutions for the system:
x + 2 y + 3 z = 4 x + 2y + 3z = 4 x + 2 y + 3 z = 4
2 x + 4 y + 6 z = 8 2x + 4y + 6z = 8 2 x + 4 y + 6 z = 8
x − y + z = 1 x - y + z = 1 x − y + z = 1
Solution Augmented matrix:
[ 1 2 3 4 2 4 6 8 1 − 1 1 1 ] \left[\begin{array}{ccc|c} 1 & 2 & 3 & 4 \\ 2 & 4 & 6 & 8 \\ 1 & -1 & 1 & 1 \end{array}\right] 1 2 1 2 4 − 1 3 6 1 4 8 1
R 2 → R 2 − 2 R 1 R_2 \to R_2 - 2R_1 R 2 → R 2 − 2 R 1 , R 3 → R 3 − R 1 R_3 \to R_3 - R_1 R 3 → R 3 − R 1 :
[ 1 2 3 4 0 0 0 0 0 − 3 − 2 − 3 ] \left[\begin{array}{ccc|c} 1 & 2 & 3 & 4 \\ 0 & 0 & 0 & 0 \\ 0 & -3 & -2 & -3 \end{array}\right] 1 0 0 2 0 − 3 3 0 − 2 4 0 − 3
Swap R 2 R_2 R 2 and R 3 R_3 R 3 :
[ 1 2 3 4 0 − 3 − 2 − 3 0 0 0 0 ] \left[\begin{array}{ccc|c} 1 & 2 & 3 & 4 \\ 0 & -3 & -2 & -3 \\ 0 & 0 & 0 & 0 \end{array}\right] 1 0 0 2 − 3 0 3 − 2 0 4 − 3 0
Row 2 gives − 3 y − 2 z = − 3 -3y - 2z = -3 − 3 y − 2 z = − 3 , so y = 3 − 2 z 3 = 1 − 2 z 3 y = \dfrac{3 - 2z}{3} = 1 - \dfrac{2z}{3} y = 3 3 − 2 z = 1 − 3 2 z .
Row 1 gives x + 2 ( 1 − 2 z 3 ) + 3 z = 4 x + 2\!\left(1 - \dfrac{2z}{3}\right) + 3z = 4 x + 2 ( 1 − 3 2 z ) + 3 z = 4 , so x + 2 − 4 z 3 + 3 z = 4 x + 2 - \dfrac{4z}{3} + 3z = 4 x + 2 − 3 4 z + 3 z = 4 ,
hence x = 2 − 5 z 3 x = 2 - \dfrac{5z}{3} x = 2 − 3 5 z .
Let z = 3 t z = 3t z = 3 t (to avoid fractions): x = 2 − 5 t x = 2 - 5t x = 2 − 5 t , y = 1 − 2 t y = 1 - 2t y = 1 − 2 t , z = 3 t z = 3t z = 3 t .
The system has infinitely many solutions parametrised by t ∈ ′ { ′ R ′ } ′ t \in \mathbb{'\{'}R{'\}'} t ∈ ′ { ′ R ′ } ′ .
Worked Example: Composition of Transformations
Find the matrix representing an enlargement by scale factor 2 2 2 about the origin, followed by a
reflection in the line y = x y = x y = x . Determine the image of the point ( 3 , 1 ) (3, 1) ( 3 , 1 ) .
Solution Enlargement by 2 2 2 : E = ( 2 0 0 2 ) E = \begin{pmatrix} 2 & 0 \\ 0 & 2 \end{pmatrix} E = ( 2 0 0 2 ) .
Reflection in y = x y = x y = x : R = ( 0 1 1 0 ) R = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix} R = ( 0 1 1 0 ) .
Combined transformation (enlargement first, then reflection): T = R E T = RE T = R E .
T = ( 0 1 1 0 ) ( 2 0 0 2 ) = ( 0 2 2 0 ) T = \begin{pmatrix} 0 & 1 \\ 1 & 0 \end{pmatrix}\begin{pmatrix} 2 & 0 \\ 0 & 2 \end{pmatrix} = \begin{pmatrix} 0 & 2 \\ 2 & 0 \end{pmatrix} T = ( 0 1 1 0 ) ( 2 0 0 2 ) = ( 0 2 2 0 )
Image of ( 3 , 1 ) (3, 1) ( 3 , 1 ) :
( 0 2 2 0 ) ( 3 1 ) = ( 2 6 ) \begin{pmatrix} 0 & 2 \\ 2 & 0 \end{pmatrix}\begin{pmatrix} 3 \\ 1 \end{pmatrix} = \begin{pmatrix} 2 \\ 6 \end{pmatrix} ( 0 2 2 0 ) ( 3 1 ) = ( 2 6 )
The image is ( 2 , 6 ) (2, 6) ( 2 , 6 ) .
Worked Example: 3 × 3 3 \times 3 3 × 3 Eigenvalues with Complex Roots
Find the eigenvalues of A = ( 1 0 − 1 0 2 0 1 0 1 ) A = \begin{pmatrix} 1 & 0 & -1 \\ 0 & 2 & 0 \\ 1 & 0 & 1 \end{pmatrix} A = 1 0 1 0 2 0 − 1 0 1 .
Solution Characteristic equation:
det ( 1 − λ 0 − 1 0 2 − λ 0 1 0 1 − λ ) = 0 \det\begin{pmatrix} 1 - \lambda & 0 & -1 \\ 0 & 2 - \lambda & 0 \\ 1 & 0 & 1 - \lambda \end{pmatrix} = 0 det 1 − λ 0 1 0 2 − λ 0 − 1 0 1 − λ = 0
Expand along the second row:
( 2 − λ ) ∣ 1 − λ − 1 1 1 − λ ∣ = 0 (2 - \lambda)\begin{vmatrix} 1 - \lambda & -1 \\ 1 & 1 - \lambda \end{vmatrix} = 0 ( 2 − λ ) 1 − λ 1 − 1 1 − λ = 0
( 2 − λ ) [ ( 1 − λ ) 2 + 1 ] = 0 (2 - \lambda)\bigl[(1 - \lambda)^2 + 1\bigr] = 0 ( 2 − λ ) [ ( 1 − λ ) 2 + 1 ] = 0
( 2 − λ ) ( λ 2 − 2 λ + 2 ) = 0 (2 - \lambda)(\lambda^2 - 2\lambda + 2) = 0 ( 2 − λ ) ( λ 2 − 2 λ + 2 ) = 0
From 2 − λ = 0 2 - \lambda = 0 2 − λ = 0 : λ 1 = 2 \lambda_1 = 2 λ 1 = 2 .
From λ 2 − 2 λ + 2 = 0 \lambda^2 - 2\lambda + 2 = 0 λ 2 − 2 λ + 2 = 0 : λ = 2 ± 4 − 8 2 = 1 ± i \lambda = \dfrac{2 \pm \sqrt{4 - 8}}{2} = 1 \pm i λ = 2 2 ± 4 − 8 = 1 ± i .
The three eigenvalues are λ = 2 \lambda = 2 λ = 2 , λ = 1 + i \lambda = 1 + i λ = 1 + i , λ = 1 − i \lambda = 1 - i λ = 1 − i .
Since complex eigenvalues of a real matrix come in conjugate pairs, this is consistent. The matrix
is not diagonalisable over ′ { ′ R ′ } ′ \mathbb{'\{'}R{'\}'} ′ { ′ R ′ } ′ but is diagonalisable over ′ { ′ C ′ } ′ \mathbb{'\{'}C{'\}'} ′ { ′ C ′ } ′ .
Worked Example: Adjugate Method for 3 × 3 3 \times 3 3 × 3 Inverse
Find the inverse of A = ( 2 1 0 1 3 1 0 1 2 ) A = \begin{pmatrix} 2 & 1 & 0 \\ 1 & 3 & 1 \\ 0 & 1 & 2 \end{pmatrix} A = 2 1 0 1 3 1 0 1 2 using the
adjugate method.
Solution First, compute det ( A ) \det(A) det ( A ) by expanding along the first row:
det ( A ) = 2 ∣ 3 1 1 2 ∣ − 1 ∣ 1 1 0 2 ∣ + 0 = 2 ( 6 − 1 ) − 1 ( 2 − 0 ) = 10 − 2 = 8 \det(A) = 2\begin{vmatrix} 3 & 1 \\ 1 & 2 \end{vmatrix} - 1\begin{vmatrix} 1 & 1 \\ 0 & 2 \end{vmatrix} + 0 = 2(6 - 1) - 1(2 - 0) = 10 - 2 = 8 det ( A ) = 2 3 1 1 2 − 1 1 0 1 2 + 0 = 2 ( 6 − 1 ) − 1 ( 2 − 0 ) = 10 − 2 = 8
Now compute the cofactor matrix C C C :
C 11 = + ∣ 3 1 1 2 ∣ = 5 C_{11} = +\begin{vmatrix} 3 & 1 \\ 1 & 2 \end{vmatrix} = 5 C 11 = + 3 1 1 2 = 5 , C 12 = − ∣ 1 1 0 2 ∣ = − 2 C_{12} = -\begin{vmatrix} 1 & 1 \\ 0 & 2 \end{vmatrix} = -2 C 12 = − 1 0 1 2 = − 2 , C 13 = + ∣ 1 3 0 1 ∣ = 1 C_{13} = +\begin{vmatrix} 1 & 3 \\ 0 & 1 \end{vmatrix} = 1 C 13 = + 1 0 3 1 = 1
C 21 = − ∣ 1 0 1 2 ∣ = − 2 C_{21} = -\begin{vmatrix} 1 & 0 \\ 1 & 2 \end{vmatrix} = -2 C 21 = − 1 1 0 2 = − 2 , C 22 = + ∣ 2 0 0 2 ∣ = 4 C_{22} = +\begin{vmatrix} 2 & 0 \\ 0 & 2 \end{vmatrix} = 4 C 22 = + 2 0 0 2 = 4 , C 23 = − ∣ 2 1 0 1 ∣ = − 2 C_{23} = -\begin{vmatrix} 2 & 1 \\ 0 & 1 \end{vmatrix} = -2 C 23 = − 2 0 1 1 = − 2
C 31 = + ∣ 1 0 3 1 ∣ = 1 C_{31} = +\begin{vmatrix} 1 & 0 \\ 3 & 1 \end{vmatrix} = 1 C 31 = + 1 3 0 1 = 1 , C 32 = − ∣ 2 0 1 1 ∣ = − 2 C_{32} = -\begin{vmatrix} 2 & 0 \\ 1 & 1 \end{vmatrix} = -2 C 32 = − 2 1 0 1 = − 2 , C 33 = + ∣ 2 1 1 3 ∣ = 5 C_{33} = +\begin{vmatrix} 2 & 1 \\ 1 & 3 \end{vmatrix} = 5 C 33 = + 2 1 1 3 = 5
C = ( 5 − 2 1 − 2 4 − 2 1 − 2 5 ) C = \begin{pmatrix} 5 & -2 & 1 \\ -2 & 4 & -2 \\ 1 & -2 & 5 \end{pmatrix} C = 5 − 2 1 − 2 4 − 2 1 − 2 5
a d j ( A ) = C T = ( 5 − 2 1 − 2 4 − 2 1 − 2 5 ) \mathrm{adj}(A) = C^T = \begin{pmatrix} 5 & -2 & 1 \\ -2 & 4 & -2 \\ 1 & -2 & 5 \end{pmatrix} adj ( A ) = C T = 5 − 2 1 − 2 4 − 2 1 − 2 5
(Since this matrix is symmetric, C T = C C^T = C C T = C .)
A − 1 = 1 8 ( 5 − 2 1 − 2 4 − 2 1 − 2 5 ) A^{-1} = \frac{1}{8}\begin{pmatrix} 5 & -2 & 1 \\ -2 & 4 & -2 \\ 1 & -2 & 5 \end{pmatrix} A − 1 = 8 1 5 − 2 1 − 2 4 − 2 1 − 2 5
Worked Example: Matrix Power via Diagonalisation
Compute A 5 A^5 A 5 where A = ( 3 − 1 2 0 ) A = \begin{pmatrix} 3 & -1 \\ 2 & 0 \end{pmatrix} A = ( 3 2 − 1 0 ) .
Solution Characteristic equation: λ ( λ − 3 ) + 2 = λ 2 − 3 λ + 2 = 0 \lambda(\lambda - 3) + 2 = \lambda^2 - 3\lambda + 2 = 0 λ ( λ − 3 ) + 2 = λ 2 − 3 λ + 2 = 0 , so
( λ − 1 ) ( λ − 2 ) = 0 (\lambda - 1)(\lambda - 2) = 0 ( λ − 1 ) ( λ − 2 ) = 0 , giving λ 1 = 1 \lambda_1 = 1 λ 1 = 1 , λ 2 = 2 \lambda_2 = 2 λ 2 = 2 .
For λ 1 = 1 \lambda_1 = 1 λ 1 = 1 : ( 2 − 1 2 − 1 ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ ⟹ 2 x = y \begin{pmatrix} 2 & -1 \\ 2 & -1 \end{pmatrix}\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} \implies 2x = y ( 2 2 − 1 − 1 ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ ⟹ 2 x = y .
Eigenvector: ′ { ′ v ′ } ′ 1 = ( 1 2 ) \mathbf{'\{'}v{'\}'}_1 = \begin{pmatrix} 1 \\ 2 \end{pmatrix} ′ { ′ v ′ } ′ 1 = ( 1 2 ) .
For λ 2 = 2 \lambda_2 = 2 λ 2 = 2 : ( 1 − 1 2 − 2 ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ ⟹ x = y \begin{pmatrix} 1 & -1 \\ 2 & -2 \end{pmatrix}\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} \implies x = y ( 1 2 − 1 − 2 ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ ⟹ x = y .
Eigenvector: ′ { ′ v ′ } ′ 2 = ( 1 1 ) \mathbf{'\{'}v{'\}'}_2 = \begin{pmatrix} 1 \\ 1 \end{pmatrix} ′ { ′ v ′ } ′ 2 = ( 1 1 ) .
P = ( 1 1 2 1 ) , D = ( 1 0 0 2 ) P = \begin{pmatrix} 1 & 1 \\ 2 & 1 \end{pmatrix}, \quad D = \begin{pmatrix} 1 & 0 \\ 0 & 2 \end{pmatrix} P = ( 1 2 1 1 ) , D = ( 1 0 0 2 )
P − 1 = 1 1 − 2 ( 1 − 1 − 2 1 ) = ( − 1 1 2 − 1 ) P^{-1} = \frac{1}{1 - 2}\begin{pmatrix} 1 & -1 \\ -2 & 1 \end{pmatrix} = \begin{pmatrix} -1 & 1 \\ 2 & -1 \end{pmatrix} P − 1 = 1 − 2 1 ( 1 − 2 − 1 1 ) = ( − 1 2 1 − 1 )
A 5 = P D 5 P − 1 = ( 1 1 2 1 ) ( 1 0 0 32 ) ( − 1 1 2 − 1 ) A^5 = PD^5P^{-1} = \begin{pmatrix} 1 & 1 \\ 2 & 1 \end{pmatrix}\begin{pmatrix} 1 & 0 \\ 0 & 32 \end{pmatrix}\begin{pmatrix} -1 & 1 \\ 2 & -1 \end{pmatrix} A 5 = P D 5 P − 1 = ( 1 2 1 1 ) ( 1 0 0 32 ) ( − 1 2 1 − 1 )
= ( 1 32 2 32 ) ( − 1 1 2 − 1 ) = ( − 1 + 64 1 − 32 − 2 + 64 2 − 32 ) = ( 63 − 31 62 − 30 ) = \begin{pmatrix} 1 & 32 \\ 2 & 32 \end{pmatrix}\begin{pmatrix} -1 & 1 \\ 2 & -1 \end{pmatrix} = \begin{pmatrix} -1 + 64 & 1 - 32 \\ -2 + 64 & 2 - 32 \end{pmatrix} = \begin{pmatrix} 63 & -31 \\ 62 & -30 \end{pmatrix} = ( 1 2 32 32 ) ( − 1 2 1 − 1 ) = ( − 1 + 64 − 2 + 64 1 − 32 2 − 32 ) = ( 63 62 − 31 − 30 )
Common Pitfalls
Matrix multiplication is not commutative. A B ≠ B A AB \ne BA A B = B A in general. When composing
transformations, the order matters: the matrix for "transform A A A then transform B B B " is B A BA B A , not
A B AB A B .
Forgetting the factor of λ n \lambda^n λ n in det ( λ A ) \det(\lambda A) det ( λ A ) . Scaling a matrix by λ \lambda λ
multiplies the determinant by λ n \lambda^n λ n , where n n n is the dimension. A common mistake is to
write det ( λ A ) = λ det ( A ) \det(\lambda A) = \lambda\det(A) det ( λ A ) = λ det ( A ) instead of λ n det ( A ) \lambda^n\det(A) λ n det ( A ) .
Wrong sign in the 2 × 2 2 \times 2 2 × 2 inverse. The inverse of ( a b c d ) \begin{pmatrix} a & b \\ c & d \end{pmatrix} ( a c b d )
is 1 a d − b c ( d − b − c a ) \dfrac{1}{ad - bc}\begin{pmatrix} d & -b \\ -c & a \end{pmatrix} a d − b c 1 ( d − c − b a ) . The − b -b − b and − c -c − c are easily
misplaced.
Confusing algebraic and geometric multiplicity. The algebraic multiplicity of an eigenvalue is
its multiplicity as a root of the characteristic equation. The geometric multiplicity is the
dimension of the corresponding eigenspace. The geometric multiplicity is always less than or equal
to the algebraic multiplicity.
Assuming every matrix is diagonalisable. Only matrices with a full set of linearly independent
eigenvectors can be diagonalised. Matrices with defective eigenvalues (geometric multiplicity less
than algebraic multiplicity) require the Jordan normal form instead.
Row operation errors in Gauss-Jordan elimination. When finding the inverse via augmented
matrices, remember that row operations must be applied to both sides simultaneously. A single
arithmetic mistake propagates through all remaining steps.
Incorrect cofactor signs. The sign of the cofactor C i j C_{ij} C ij is ( − 1 ) i + j (-1)^{i+j} ( − 1 ) i + j . This follows a
checkerboard pattern starting with + + + in the top-left corner. A common error is to use all
positive signs.
Misidentifying invariant lines. An invariant line is mapped to itself, but points on the line
may move. To find invariant lines, solve ( A − λ I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ (A - \lambda I)\mathbf{'\{'}v{'\}'} = \mathbf{'\{'}0{'\}'} ( A − λ I ) ′ { ′ v ′ } ′ = ′ { ′ 0 ′ } ′ where λ \lambda λ
is an eigenvalue. Every eigenvector lies on an invariant line through the origin.
Exam-Style Problems
Compute A B − B A AB - BA A B − B A where A = ( 1 2 0 3 ) A = \begin{pmatrix} 1 & 2 \\ 0 & 3 \end{pmatrix} A = ( 1 0 2 3 ) and
B = ( 4 − 1 1 2 ) B = \begin{pmatrix} 4 & -1 \\ 1 & 2 \end{pmatrix} B = ( 4 1 − 1 2 ) .
Find the inverse of ( 1 0 2 − 1 3 1 2 1 0 ) \begin{pmatrix} 1 & 0 & 2 \\ -1 & 3 & 1 \\ 2 & 1 & 0 \end{pmatrix} 1 − 1 2 0 3 1 2 1 0 using
row reduction, and verify your answer by multiplication.
Find the eigenvalues and eigenvectors of
A = ( 5 4 1 2 ) A = \begin{pmatrix} 5 & 4 \\ 1 & 2 \end{pmatrix} A = ( 5 1 4 2 ) . Use diagonalisation to find A 6 A^6 A 6 .
A triangle has vertices at ( 0 , 0 ) (0, 0) ( 0 , 0 ) , ( 2 , 0 ) (2, 0) ( 2 , 0 ) , and ( 1 , 3 ) (1, 3) ( 1 , 3 ) . Find the matrix of the transformation
that reflects the triangle in the y y y -axis and then enlarges it by a factor of 2 2 2 about the
origin. Determine the area of the image.
Determine the values of k k k for which the system
{ x + k y + z = 1 x + y + k z = k k x + y + z = 1 \begin{cases} x + ky + z = 1 \\ x + y + kz = k \\ kx + y + z = 1 \end{cases} ⎩ ⎨ ⎧ x + k y + z = 1 x + y + k z = k k x + y + z = 1
has (a) a unique solution, (b) no solution, (c) infinitely many solutions.
Find the characteristic equation of
A = ( 2 1 0 0 2 1 0 0 2 ) A = \begin{pmatrix} 2 & 1 & 0 \\ 0 & 2 & 1 \\ 0 & 0 & 2 \end{pmatrix} A = 2 0 0 1 2 0 0 1 2 and explain why A A A is
not diagonalisable.
The matrix T = ( cos θ − sin θ sin θ cos θ ) T = \begin{pmatrix} \cos\theta & -\sin\theta \\ \sin\theta & \cos\theta \end{pmatrix} T = ( cos θ sin θ − sin θ cos θ )
represents a rotation. Find the eigenvalues when θ = π 2 \theta = \dfrac{\pi}{2} θ = 2 π and interpret them
geometrically.
Use Cramer's rule to solve
{ 3 x + 2 y − z = 4 x − y + 2 z = − 1 2 x + 3 y + z = 7 \begin{cases} 3x + 2y - z = 4 \\ x - y + 2z = -1 \\ 2x + 3y + z = 7 \end{cases} ⎩ ⎨ ⎧ 3 x + 2 y − z = 4 x − y + 2 z = − 1 2 x + 3 y + z = 7 .
Cross-References
Differential equations and systems solved via matrix methods: see Differential Equations
Proof and reasoning for properties of determinants: see Proof
Diagnostic Test
Ready to test your understanding of Matrices ? The diagnostic test contains the hardest questions within the IB specification for this topic, each with a full worked solution.
Unit tests probe edge cases and common misconceptions. Integration tests combine Matrices with other IB mathematics topics to test synthesis under exam conditions.
See Diagnostic Guide for instructions on self-marking and building a personal test matrix.