Skip to content
Related Articles

Related Articles

How to find the Diagonal of a Matrix?

View Discussion
Improve Article
Save Article
  • Difficulty Level : Basic
  • Last Updated : 31 Jul, 2022
View Discussion
Improve Article
Save Article

British Mathematician Arthur Cayley was the first person to develop the algebraic aspect of the matrix. After that, Psychiat Heisenberg used matrices as a tool to explain his famous Quantum principle. The study of matrices originated while solving different types of simple and complex linear problems, which is cumbersome to solve without matrices. A rectangular array of mn numbers in the form of m horizontal lines called rows, and n vertical lines called columns is called a matrix of order m x n. This arrays is enclosed by  [ ]  or ( ) or || ||  . Each number of the m x n matrix is known as the element of the matrix. A matrix is generally denoted by capital alphabetical characters, and its element is denoted by small alphabetical characters with suffix ij, which indicates to row and column number, i.e. aij, is called elements of matrix A. 

A= \begin{bmatrix}      2 & 6 & 4 \\      1 & 2 & 3 \\      8 &9  &7       \end{bmatrix}

  • The elements of the matrix may be scalar or vector quantity. 
  • A matrix is only an arrangement of numbers; it has no definite value. i.e.  [5] ≠ 5. 

Some important terms related to matrix

  • Elements of a Matrix: Each of the M, N numbers of the Matrix is called an element or an entry of the Matrix.
  •  Notation of a Matrix: A matrix is generally represented by the symbols [aij] or (aij) or ||aij||. A matrix is denoted by a single capital letter such as A, B, C etc. 
  • Order of a Matrix: A matrix having m rows and n columns is said to be a matrix of order m x n. 

Diagonal Elements of a Matrix 

An element aij of a matrix A = [aij] is a diagonal elements of matrix if i = j, such as when rows and column suffixes are equal. Thus, a11 , a22 , a33, a44, … so on are diagonal elements of the matrix A  = [aij]. 

  • Principal  Diagonal of a Matrix 

The principal diagonal is also known as the leading diagonal. The diagonal of a square matrix running from the upper left entities to the lower right entities are principal diagonal of a matrix. 

A =  \begin{bmatrix} a_{11} & 0 & 0 \\ 0 & a_{22} & 0 \\ 0 & 0 & a_{33} \end{bmatrix}

Here, Principal Diagonal elements are non-zeroes. 

  • Counter diagonal  

It’s also called anti diagonal of a matrix.  The diagonal of a square matrix running from the upper right entities to the lower-left entities is called the counter diagonal of a matrix. 

B =  \begin{bmatrix} 0 & 0 & b_{13} \\ 0 & b_{22} & 0 \\ b_{31} & 0 & 0 \end{bmatrix}

Here, Counter diagonal elements are non-zeroes. 

Note: Above, we considered examples in principal and counter diagonal. Elements of the matrix other than diagonal are considered as zeroes for better clarification.

Sample problems 

Question 1: Find out the diagonal element of the below matrix.

A =  \begin{bmatrix} 9 & 0 & 25 \\ 0 & 8 & 0  \\ 0 & 0 & 1 \end{bmatrix}

Solution: 

As we know, To find the diagonal of matrix or diagonal elements is not a heavy task; it is just a basic practice of matrices. If anyone told us to find the diagonal element, we only found the principal diagonal as a result. which is running from the upper left entities  to the lower right entities  

Diagonal element of matrix,

a11 = 9, a22 = 8, a33 = 1

Question 2: Find trace of matrix A, given below.

A =  \begin{bmatrix} 1 & 2 & 3 \\ 0 & 2 & 0 \\ 5 & 0 & 5 \end{bmatrix}

Solution: 

Trace of matrix: It’s actually sum of principal diagonal element. 

tr(A) = a11 + a22 + a33;

So, after observation of matrix

We can say, a11 = 1, a22 = 2, a33 = 5

tr(a) = 1 + 2 + 5 = 8 

Question 3: Find the inverse of diagonal matrix: 

A =  \begin{bmatrix} 2 & 0 & 0 \\ 0 & -3 & 0 \\ 0 & 0 & 5 \end{bmatrix}

Solution:

Determinant of matrix of A,

|A| = -30

Adjoint of matrix A, 

adj(A) =  \begin{bmatrix} -15 & 0 & 0 \\ 0 & 10 & 0 \\ 0 & 0 & -6 \end{bmatrix}

We know inverse of matrix A is: A-1 = \frac{adj(A)}{|A|}

A-1 =  \begin{bmatrix} \frac{1}{2} & 0 &0 \\ 0 & \frac{-1}{3}& 0 \\ 0 & 0 & \frac{1}{5} \end{bmatrix}         

Question 4: Find value of a11 + a23  – a22 + a31 from given below matrix.      

A =  \begin{bmatrix} 8 & 2 & 5 \\ 0 & 2 & 9 \\ 5 & 6 & 5 \end{bmatrix}         

Solution:  

We know standard matrix syntax. 

A = \begin{bmatrix} a_{11} & a_{12} & a_{13} \\ a_{21}& a_{22} & a_{23} \\ a_{31} & a_{32} & a_{33} \end{bmatrix}             

By comparing it to our matrix we can say,

a11 = 8, a23 = 9, a22 = 2, a31 = 5    

Required result: a11 + a23  – a22 + a31 = 8 + 9 – 2 – 5 =  10

Question 5: Find the product of diagonal element of below matrix:

A =  \begin{bmatrix} 2 & 5 & 6 \\ 1 & 4 & 8 \\ 4 & 2 & 1 \end{bmatrix}

Solution:  

The diagonal element of the above matrix are 2, 4, and 1, respectively

Product of diagonal: 2 × 4 × 1 = 8 

Question 6: Find the determinant of the matrix given below: 

A =  \begin{bmatrix} 5 & 2 & 6 \\ 4 & 1 & 8 \\ 2 & 4 & 1 \end{bmatrix}

Solution: 

Determinant of matrix A, 

|A| = 5 (1 – 32) – 2 (16 – 4) + 6 (16 – 2)

|A| = 5(-31) – 2(12) + 6(14) 

|A| = -155 – 24 + 84 = -95

Question 7: Find the sum of counter  diagonal of matrix , common element of principle and counter diagonal: 

A =  \begin{bmatrix} 8 & 2 & 5 \\ 0 & 2 & 9 \\ 5 & 6 & 5 \end{bmatrix}

Solution: 

We know square matrix running from the upper right entities to the lower left entities are counter diagonals of matrix. 

So, counter diagonal elements are 

a13 = 5 a22 = 2 a31 = 5 

The common element of principal and counter diagonal is 2. 


My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!