# Matrices

Matrices

A rectangular array of m × n numbers (real or complex) in the form of m horizontal lines (called rows) and n vertical lines (called columns), is called a matrix of order m by n, written as m × n matrix. Such an array is enclosed by [ ] or ( ). In this article, we will learn the meaning of matrices, types of matrices, important formulas, etc.

## Introduction to Matrices

[latexpage]
At first, we sample $f(x)$ in the $N$ ($N$ is odd) equidistant points around $x^*$:
$f_k = f(x_k),\: x_k = x^*+kh,\: k=-\frac{N-1}{2},\dots,\frac{N-1}{2}$
where $h$ is some step.
Then we interpolate points $\{(x_k,f_k)\}$ by polynomial
\label{eq:poly}
P_{N-1}(x)=\sum_{j=0}^{N-1}{a_jx^j}

Its coefficients $\{a_j\}$ are found as a solution of system of linear equations:
\label{eq:sys}

Here are references to existing equations: (\ref{eq:poly}), (\ref{eq:sys}).
Here is reference to non-existing equation (\ref{eq:unknown}).

An m × n matrix is usually written as:

\$latex A=\left[ \begin{matrix} {{a}_{11}} & {{a}_{12}} & ….. & {{a}_{1n}} \\ {{a}_{21}} & {{a}_{22}} & ….. & {{a}_{2n}} \\ \vdots & \vdots & \vdots & \vdots \\ {{a}_{m1}} & {{a}_{m2}} & ….. & {{a}_{mn}} \\ \end{matrix} \right]In brief, the above matrix is represented by A = [aij] mxn. The number a11, a12, ….. etc., are known as the elements of the matrix A, where aij belongs to the ith row and jth column and is called the (i, j)th element of the matrix A = [aij].

### Important Formulas for Matrices

If A, B are square matrices of order n, and In is a corresponding unit matrix, then

(b) | adj A | = | A |n-1 (Thus A (adj A) is always a scalar matrix)

(k) A is symmetric ⇒adj A is also symmetric

(l) A is diagonal ⇒adj A is also diagonal

(m) A is triangular ⇒adj A is also triangular

(n) A is singular ⇒| adj A | = 0

## Types of Matrices

(i) Symmetric Matrix: A square matrix A =[{{a}_{ij}}] is called a symmetric matrix if {{a}_{ij}}={{a}_{ji}}, for all i, j.

(ii) Skew-Symmetric Matrix: when {{a}_{ij}}=-{{a}_{ji}}

(iii) Hermitian and skew – Hermitian Matrix: A={{A}^{\theta }} (Hermitian matrix)(Aθ represents conjugate transpose)

{{A}^{\theta }}=-A (skew-Hermitian matrix)

(iv) Orthogonal matrix: if A{{A}^{T}}={{I}_{n}}={{A}^{T}}A

(v) Idempotent matrix: if {{A}^{2}}=A

(vi) Involuntary matrix: if {{A}^{2}}=I\,\,or\,\,{{A}^{-1}}=A

(vii) Nilpotent matrix: A square matrix A is nilpotent, if A= 0, p is an integer.

### Trace of matrix

The trace of a square matrix is the sum of the elements on the main diagonal.

(i) tr\left( \lambda A \right)=\lambda tr\left( A \right)

(ii) tr(A+B)=tr(A)+tr(B)

(iii) tr(AB)=tr(BA)

### Matrix Transpose

(i) {{({{A}^{T}})}^{T}}=A \;\;\;\;\;\; \\(ii) {{(A\pm B)}^{T}}={{A}^{T}}\pm {{B}^{T}} \;\;\;\;\; \\(iii) {{(AB)}^{T}}={{B}^{T}}{{A}^{T}}\\(iv) {{(kA)}^{T}}=k{{\left( A \right)}^{T}} \;\;\;\;\;\; \\ (v) {{({{A}_{1}}{{A}_{2}}{{A}_{3}}…….{{A}_{n-1}}{{A}_{n}})}^{T}}=A_{n}^{T}A_{n-1}^{t}……A_{3}^{T}A_{2}^{T}A_{1}^{T}\\

(vi) {{I}^{T}}=I \;\;\;\;\;\;\; \\ (vii) tr(A)=t({{A}^{T}})

### Properties of Matrix Multiplication

(i) AB\ne BA \;\;\;\;\;\;\; (ii) (AB)C=A(BC) \;\;\;\;\;(iii) A.(B+C)=A.B+A.C

## Inverse of a Matrix

A-1 exists if A is non singular i.e. |A|\ne 0 (i) {{A}^{-1}}=\frac{1}{|A|}(Adj.A) \;\;\;\;\;\; (ii) {{A}^{-1}}A={{I}_{n}}=A{{A}^{-1}} \;\;\;\;\; (iii) {{({{A}^{T}})}^{-1}}={{({{A}^{-1}})}^{T}} \;\;\;\;\;\; (iv){{({{A}^{-1}})}^{-1}}=A \;\;\;\;\;\;\;\; (v) |{{A}^{-1}}|=|A{{|}^{-1}}=\frac{1}{|A|}

### Order of a Matrix

A matrix which has m rows and n columns is called a matrix of order m x n

E.g. the order of \begin{bmatrix}\;\;\; 4\;\;\;\;\;\;\;-1\;\;\;\;\;\;\;5 & & \\ \;\;\;6\;\;\;\;\;\;\;\;\;\;8\;\;\;\;\;-7\end{bmatrix} matrix is 2 x 3.

Note: (a) The matrix is just an arrangement of certain quantities.

(b) The elements of a matrix may be real or complex numbers. If all the elements of a matrix are real, then the matrix is called a real matrix.

(c) An m x n matrix has m.n elements.

Illustration 1: Construct a 3×4 matrix A = [aij], whose elements are given by aij = 2i + 3j.

Solution: In this problem, I and j are the number of rows and columns respectively. By substituting the respective values of rows and columns in aij = 2i + 3j we can construct the required matrix.

Given aij = 2i + 3j

so a11 = 2+3 = 5, a12 = 2+6 = 8

Similarly, a13 = 11, a14=14, a21 = 7, a22=10, a23=13, a24=16,a31=9, a32=12, a33=15, a34=18

A=\begin{bmatrix} 5& 8& 11& 14\\ 7& 10& 13& 16\\ 9& 12& 18& 18 \end{bmatrix}.

Illustration 2: Construct a 3 x 4 matrix, whose elements are given by: aij =\frac{1}{2}|-3i+j|

Solution:

Method for solving this problem is the same as in the above problem.

Since {{a}_{ij}}=\frac{1}{2}|-3i+j|we\,have {{a}_{11}}=\frac{1}{2}|-3(1)+1|=\frac{1}{2}|-3+1|=\frac{1}{2}|-2|=\frac{2}{2}=1 {{a}_{12}}=\frac{1}{2}|-3(1)+2|=\frac{1}{2}|-3+2|=\frac{1}{2}|-1|=\frac{1}{2} {{a}_{13}}=\frac{1}{2}|-3(1)+3|=\frac{1}{2}|-3+3|=\frac{1}{2}(0)=0 {{a}_{14}}=\frac{1}{2}|-3(1)+4|=\frac{1}{2}|-3+4|=\frac{1}{2};\,\,\,\,\,\,\,\,\,\,{{a}_{21}}=\frac{1}{2}|-3(2)+1|=\frac{1}{2}|-6+1|=\frac{5}{2} {{a}_{22}}=\frac{1}{2}|-3(2)+2|=\frac{1}{2}|-6+2|=\frac{4}{2}=2;\,\,\,\,\,\,\,\,\,\,{{a}_{23}}=\frac{1}{2}|-3(2)+3|=\frac{1}{2}|-6+3|=\frac{3}{2} {{a}_{24}}=\frac{1}{2}|-3(2)+4|=\frac{1}{2}|-6+4|=\frac{2}{2}=1;\,\,\,\,\,\,Similarly\,\,{{a}_{31}}=4,{{a}_{32}}=\frac{7}{2},{{a}_{33}}=3,{{a}_{34}}=\frac{5}{2}

Hence, the required matrix is given by A = \begin{bmatrix} 1& \frac{1}{2}& 0& \frac{1}{2} \\ \frac{5}{2}& 2& \frac{3}{2}& 1 \\ 4& \frac{7}{2}& 3& \frac{5}{2} \end{bmatrix}

### Trace of a Matrix

Let A = [aij]nxn and B = [bij]nxn and λ be a scalar,

(i) tr(λA) = λ tr(A) (ii) tr(A + B) = tr(A) + tr(B) (iii) tr(AB) = tr(BA)

## Transpose of Matrix

The matrix obtained from a given matrix A by changing its rows into columns or columns into rows is called the transpose of matrix A and is denoted by AT or A’. From the definition it is obvious that if the order of A is m x n, then the order of AT becomes n x m; E.g. transpose of matrix

\begin{bmatrix} a_1 &a_2 &a_3 \\ b_1& b_2& b_3 \end{bmatrix}_{2\times3} is \begin{bmatrix} a_1 & b_1\\ a_2 & b_2\\ a_3 & b_3 \end{bmatrix}_{3\times2} .

### Properties of Transpose of Matrix

(i) (AT)T= A (ii) (A + B)T = AT+ BT (iii) (AB)T = BTAT (iv) (kA)T = k(A)T

(v) (A1A2A3 ……An-1An)T = A_{n}^{T}A_{n-1}^{T}…..A_{3}^{T}A_{2}^{T}A_{1}^{T} (vi) IT = I (vii) tr(A) = tr(AT)

## Problems on Matrices

Illustration 3: If A=\begin{bmatrix} 1 &-2 &3 \\ -4 & 2 & 5 \end{bmatrix} and B=\begin{bmatrix} 1 &3 \\ -1&0 \\ 2&4 \end{bmatrix} . then prove that (AB)T = BTAT.

Solution:

By obtaining the transpose of AB i.e. (AB)T and multiplying BT and AT we can easily get the result.

Here, AB =\begin{bmatrix} 1 & -2 &3 \\ -4& 2& 5 \end{bmatrix}  \begin{bmatrix} 1 &3 \\ -1&0 \\ 2& 4 \end{bmatrix}=\begin{bmatrix} 1(1)-2(-1)+3(2) &1(3)-2(0)+3(4) \\ -4(1)+2(-1)+5(2) &-4(3)+2(0)+5(4) \end{bmatrix} = \begin{bmatrix} 9 &15 \\ 4& 8 \end{bmatrix}.

∴ (AB)^{T}=\begin{bmatrix} 9 & 4\\ 15& 8 \end{bmatrix};B^{T}A^{T} ==\begin{bmatrix} 1 & -1 &2 \\ 3& 0& 4 \end{bmatrix} \begin{bmatrix} 1 &-4 \\ -2&2 \\ 3& 5 \end{bmatrix}=\begin{bmatrix} 1(1)-1(-2)+2(3) &1(-4)-1(2)+2(5) \\ 3(1)+0(-2)+4(3) &3(-4)+0(2)+4(5) \end{bmatrix} = \begin{bmatrix} 9 &4 \\ 15 & 8 \end{bmatrix}=(AB)^{T}

Illustration 4: If A=\begin{bmatrix} 5 &-1 &3 \\ 0& 1& 2 \end{bmatrix} and B=\begin{bmatrix} 0 &2 &3 \\ 1& -1 &4 \end{bmatrix}. then what is (B’)’A’ equal to?

Solution:

In this problem, we use the properties of the transpose of a matrix to get the required result.

We have ={({B}’)}'{A}’ =B{A}’=\begin{bmatrix} 0 &2 &3 \\ 1& -1 &4 \end{bmatrix}\begin{bmatrix} 5 &0 \\ -1&1 \\ 3& 2 \end{bmatrix}=\begin{bmatrix} 7 & 8\\ 18& 7 \end{bmatrix}.

Illustration 5: If the matrix A=\left[ \begin{matrix} 3-x & 2 & 2 \\ 2 & 4-x & 1 \\ -2 & -4 & -1-x \\ \end{matrix} \right]

is a singular matrix then find x. Verify whether AAT = I for that value of x.

Solution:

Using the condition of a singular matrix, i.e. |A| = 0, we get the value of x and then substituting the value of x in matrix A and multiplying it to its transpose we will obtain the required result.

Here, A is a singular matrix if |A| = 0, i.e., \left| \begin{matrix} 3-x & 2 & 2 \\ 2 & 4-x & 1 \\ -2 & -4 & -1-x \\ \end{matrix} \right|=0

R3 –> R3 + R2

\left| \begin{matrix} 3-x & 2 & 2 \\ 2 & 4-x & 1 \\ 0 & -x & -x \\ \end{matrix} \right|=0C2 → C2-C3

\left| \begin{matrix} 3-x & 0 & 2 \\ 2 & 3-x & 1 \\ 0 & 0 & -x \\ \end{matrix} \right|=0Here, x = 0, 3.

When x = 0, A = \left[ \begin{matrix} 3 & 2 & 2 \\ 2 & 4 & 1 \\ -2 & -4 & -1 \\ \end{matrix} \right]

∴ A{{A}^{T}}=\left[ \begin{matrix} 3 & 2 & 2 \\ 2 & 4 & 1 \\ -2 & -4 & -1 \\ \end{matrix} \right]\left[ \begin{matrix} 3 & 2 & -2 \\ 2 & 4 & -4 \\ 2 & 1 & -1 \\ \end{matrix} \right]

\left[ \begin{matrix} 17 & 16 & -16 \\ 16 & 21 & -21 \\ -16 & -21 & 21 \\ \end{matrix} \right]\ne I

When x = 3, A = \left[ \begin{matrix} 0 & 2 & 2 \\ 2 & 1 & 1 \\ -2 & -4 & -4 \\ \end{matrix} \right];\,\,\,

∴ A{{A}^{T}}=\left[ \begin{matrix} 0 & 2 & 2 \\ 2 & 1 & 1 \\ -2 & -4 & -4 \\ \end{matrix} \right]\left[ \begin{matrix} 0 & 2 & -2 \\ 2 & 1 & -4 \\ 2 & 1 & -4 \\ \end{matrix} \right]=\left[ \begin{matrix} 8 & 4 & -16 \\ 4 & 6 & -12 \\ -16 & -12 & 36 \\ \end{matrix} \right]\ne I

Note: simple way to solve is that if A is a singular matrix then |A| = 0 and |AT| = 0. But |I| is 1.

Hence, AAT ≠ I if |A| = 0.

Illustration 6: If the matrix A = \left[ \begin{matrix} a & b & c \\ b & c & a \\ c & a & b \\ \end{matrix} \right]

where a, b, c, are positive real numbers such that abc = 1 and ATA = I then find the value of a3 + b3 + c3.

Solution:

Given: abc = 1 and ATA = I

Here, A= \left[ \begin{matrix} a & b & c \\ b & c & a \\ c & a & b \\ \end{matrix} \right].So,{{A}^{T}}=\left[ \begin{matrix} a & b & c \\ b & c & a \\ c & a & b \\ \end{matrix} \right],

Interchanging rows and columns.

⇒ But{{A}^{T}}A=I(given). \begin{bmatrix}a & b &c \\ b&c & a\\ c & a & b\end{bmatrix}\begin{bmatrix}a & b &c \\ b&c & a\\ c & a & b\end{bmatrix}=\begin{bmatrix}1 & 0 &0 \\ 0&1 & 0\\ 0 & 0 & 1\end{bmatrix}

Solving above equation, we have

(a2 + b2 + c2) = 1 and ab + bc + ca = 0  . …..(i)

We know, (a + b + c)2 = (a2 + b2 + c2) + 2(ab + bc + ca)

= 1

or (a + b + c) = 1  ….(ii)

Again ,we have (a3 + b3 + c-3abc) = (a + b + c) (a2 + b2 + c-ab – bc – ca)

Since abc = 1

Using  (i) and (ii), we have

(a3 + b3 + c-3) = 1

or a3 + b3 + c=4

Illustration 7: If \left[ \begin{matrix} x+3 & z+4 & 2y-7 \\ -6 & a-1 & 0 \\ b-3 & -21 & 0 \\ \end{matrix} \right]=\left[ \begin{matrix} 0 & 6 & 3y-2 \\ -6 & -3 & 2c+z \\ 2b+4 & -21 & 0 \\ \end{matrix} \right]

then find the values of a, b, c, x, y and z.

Solution:

As the two matrices are equal, their corresponding elements are also equal. Therefore, by equating the corresponding elements of the given matrices, we will obtain the values of a, b, c, x, y and z.

\left[ \begin{matrix} x+3 & z+4 & 2y-7 \\ -6 & a-1 & 0 \\ b-3 & -21 & 0 \\ \end{matrix} \right]=\left[ \begin{matrix} 0 & 6 & 3y-2 \\ -6 & -3 & 2c+z \\ 2b+4 & -21 & 0 \\ \end{matrix} \right]Comparing both sides, we get [x + 3 = 0] ⇒ x = – 3 . . . . (i)

And z+4=6 \;\;\;\;\;\; \Rightarrow z=6-4 \;\;\;\;\;\; \Rightarrow z=2 … (ii)

and 2y-7=3y-2\;\;\;\;\;\;\;\;\;\; \Rightarrow 2y-3y=-2+7\;\;\;\;\;\;\;\;\;\; \Rightarrow -y=5\;\;\;\;\;\;\;\;\;\; \Rightarrow y=-5 … (iii)

and a-1=-3 \;\;\;\;\;\;\;\;\;\; \Rightarrow a=-3+1 \;\;\;\;\;\;\;\;\;\; \Rightarrow a=-2 … (iv)

and b-3=2b+4\;\;\;\;\;\;\; \Rightarrow b-2b=4+3 \;\;\;\;\;\;\; \Rightarrow -b=7 \;\;\;\;\;\;\; \Rightarrow b=-7 … (v)

and 2c+z=0 \;\;\;\;\;\; \Rightarrow 2c+2=0 \;\;\;\;\;\; \Rightarrow 2c=-2 \Rightarrow c=\frac{-2}{2}\;\;\;\;\;\;\Rightarrow c=-1 … (vi)

Thus

a = -2, b = -7, c = -1, x = -3, y = -5 and z = 2

Illustration 8: 20\left[\begin{array}{cc}1 & -\tan \theta / 2 \\ \tan \theta / 2 & 1\end{array}\right]\left[\begin{array}{cc}1 & \tan \theta / 2 \\ -\tan \theta / 2 & 1\end{array}\right]^{-1} \text { is equal to} – \\ (1) \left[\begin{array}{cc}\sin \theta & -\cos \theta \\ \cos \theta & \sin \theta\end{array}\right] \\ (2) \left[\begin{array}{cc}\cos \theta & \sin \theta \\ -\sin \theta & \cos \theta\end{array}\right] \\ (3) \left[\begin{array}{cc}\cos \theta & -\sin \theta \\ \sin \theta & \cos \theta\end{array}\right] \\ (4) \text { None of these} \\ Solution:\\ \left[\begin{array}{cc}1 & \tan \theta / 2 \\ -\tan \theta / 2 & 1\end{array}\right]^{-1}=\frac{1}{\sec ^{2} \theta / 2}\left[\begin{array}{cc}1 & -\tan \theta / 2 \\ \tan \theta / 2 & 1\end{array}\right] \\ \therefore \quad Product \begin{array}{l} =\frac{1}{\sec ^{2} \theta / 2}\left[\begin{array}{cc} 1 & -\tan \theta / 2 \\ \tan \theta / 2 & 1 \end{array}\right]\left[\begin{array}{cc} 1 & -\tan \theta / 2 \\ \tan \theta / 2 & 1 \end{array}\right] \\ =\frac{1}{\sec ^{2} \theta / 2}\left[\begin{array}{cc} 1-\tan ^{2} \theta / 2 & -2 \tan \theta / 2 \\ 2 \tan \theta / 2 & 1-\tan ^{2} \theta / 2 \end{array}\right] \\ =\left[\begin{array}{cc} \cos ^{2} \theta / 2-\sin ^{2} \theta / 2 & -2 \sin \theta / 2 \cos \theta / 2 \\ 2 \sin \theta / 2 \cos \theta / 2 & \cos ^{2} \theta / 2-\sin ^{2} \theta / 2 \end{array}\right] \\ =\left[\begin{array}{cc} \cos \theta & -\sin \theta \\ \sin \theta & \cos \theta \end{array}\right] \end{array}

Illustration 9: \text \ If \ A=\left[\begin{array}{lll}0 & -1 & 2 \\ 2 & -2 & 0\end{array}\right], B=\left[\begin{array}{ll}0 & 1 \\ 1 & 0 \\ 1 & 1\end{array}\right] \ and \ M=A B, \ then \ M^{-1} \ is \ equal \ to -\\ (1) \left[\begin{array}{cc}2 & -2 \\ 2 & 1\end{array}\right]\\ (2) \left[\begin{array}{cc}1 / 3 & 1 / 3 \\ -1 / 3 & 1 / 6\end{array}\right]\\ (3) \left[\begin{array}{cc}1 / 3 & -1 / 3 \\ 1 / 3 & 1 / 6\end{array}\right]\\ (4) \left[\begin{array}{cc}1 / 3 & -1 / 3 \\ -1 / 3 & 1 / 6\end{array}\right]\\ Solution: M=\left[\begin{array}{lll}0 & -1 & 2 \\ 2 & -2 & 0\end{array}\right]\left[\begin{array}{ll}0 & 1 \\ 1 & 0 \\ 1 & 1\end{array}\right]=\left[\begin{array}{cc}1 & 2 \\ -2 & 2\end{array}\right]\\ |M|=6, \operatorname{adj} M=\left[\begin{array}{cc}2 & -2 \\ 2 & 1\end{array}\right] \\ M^{-1}=\frac{1}{6}\left[\begin{array}{cc}2 & -2 \\ 2 & 1\end{array}\right]=\left[\begin{array}{cc}1 / 3 & -1 / 3 \\ 1 / 3 & 1 / 6\end{array}\right]\\ Answer: [3]