Matrix & Matrix Operations

Utkarsh Mathur
5 min readJan 18, 2022

--

This article was originally part of my Numerical Linear Algebra series but since I deterred from the course of pursuing Numerical Linear Algebra and instead study Linear Algebra from a different source, I am publishing this as a standalone article. Below is the reference to the only remaining article of the series.

Let’s start by defining a matrix. Matrix is a rectangular array of numbers arranged in the form of rows and columns.

Representation of a Matrix

The number of rows and columns of a matrix is called dimensions of a matrix. For the matrix A in the image above the dimensions are m x n. The transpose of a matrix is obtained by writing the rows of the matrix in order as the columns of the matrix. The transpose of matrix A is denoted as Aᵀ. The dimensions of Aᵀ would be n x m.

Types of Matrices

Let us define some of the types of matrices commonly found in literature.

  1. Row Matrix :- A row matrix is formed by a single row. The dimensions of a row matrix are 1 x n.
  2. Square Matrix :- A matrix of the order m x n is said to be square if m =n. The dimensions of a square matrix and its transpose are same.
  3. Diagonal Matrix :- A square matrix of the order n x n is said to be diagonal if aᵢⱼ = 0 for all i ≠ j while the diagonal entries may be zero or non-zero.
  4. Scalar Matrix :- A diagonal matrix is said to be scalar matrix if all the diagonal elements are equal.
  5. Identity Matrix :- A scalar matrix is said to be identity matrix if all the diagonal elements are equal to 1.
  6. Upper Triangular Matrix :- A square matrix of the order n x n is said to be upper triangular matrix if aᵢⱼ = 0 for all i > j.
  7. Lower Triangular Matrix :- A square matrix of the order n x n is said to be lower triangular matrix if aᵢⱼ = 0 for all i <j.

Symmetric Matrix :- Any square matrix is said to be symmetric if A = Aᵀ.

  1. Skew Symmetric Matrix :- Any square matrix is said to be skew symmetric matrix if A =-Aᵀ. Interestingly, all the diagonal elements of a skew symmetric matrix are 0.
  2. Hermitian Matrix :- A square matrix of the order n x n is said to be hermitian matrix if the transpose of the conjugate of the matrix is equal to the original matrix. A real hermitian matrix is a symmetric matrix. All the diagonal elements of a hermitian matrix are real.
  3. Skew Hermitian Matrix :- A square matrix of the order n x n is said to be skew hermitian matrix if the transpose of the conjugate of the matrix is equal to the negative of the original matrix. A real skew hermitian matrix is a skew symmetric matrix. All the diagonal elements of a skew-hermitian matrix are either 0 or purely imaginary.

Addition of Matrices

Let us consider two matrices A = ( aᵢⱼ )ₘ ₓ ₙ and B= ( bᵢⱼ )ₘ ₓ ₙ. The sum of A and B is defined as A + B =( aᵢⱼ + bᵢⱼ)ₘ ₓ ₙ.

Addition of Matrices have various properties:

  1. Closure :- If A & B are of the dimensions m x n then their sum will also be of the dimensions m x n.
  2. Associative :- A + ( B + C ) = ( A + B ) + C
  3. Additive :- A + O = A , where O is zero matrix.
  4. Additive Inverse :- A + (-A) = O.
  5. Commutative :- A + B = B + A.

Multiplication of Matrices

For the multiplication of matrices A & B to be possible, the number of columns of A should be equal to the number of rows of B. The image below illustrates multiplication of two matrices (pardon my penmanship).

Illustration of Multiplication of Matrices

For the sake of demonstration of various multiplication properties of matrices let us consider matrices A = ( aᵢⱼ )ₙ ₓ ₙ , B = ( bᵢⱼ )ₙ ₓ ₙ , and C = ( cᵢⱼ )ₙ ₓ ₙ.

  1. Associative :- A ( BC ) = ( AB )C
  2. Left Distributive :- A (B+C) = AB + AC
  3. Right Distributive :- (A+B) C = AC + BC
  4. Scalar Multiplication :- r(AB) = (rA)B = A(rB) where r is a scalar

Properties of Transpose

  1. (Aᵀ)ᵀ = A
  2. (A + B)= Aᵀ + Bᵀ
  3. (AB)= BᵀAᵀ
  4. (rA)= rAᵀ

Adjoint Matrix

Adjoint of a square matrix is the transpose of the cofactor matrix C, where C is the matrix formed by the cofactors of the elements of A. Cofactor of aᵢⱼ, in a matrix A, is the determinant of the matrix obtained by removing row i and column j from matrix A. A few properties of adjoint of a matrix are:

  1. adj(I) = I
  2. adj(AB) = adjB adjA
  3. adj(cA) = cⁿ⁻¹adj(A)

Inverse of Matrix

For a square matrix A, if there exist a matrix B such that AB = BA = I, then B is called inverse of A and is denoted by A⁻¹.

Some of the properties of inverse of matrix are stated below:

  1. (AB)⁻¹ = B⁻¹A⁻¹
  2. (A⁻¹)⁻¹ = A
  3. (kA)⁻¹ = k⁻¹ A⁻¹
  4. Inverse of a matrix is unique.

Now that we are familiar with the concepts of addition, multiplication, adjoint, and inverse of matrix let us acquaint ourselves with a few more famous matrices.

  1. Orthogonal Matrix :- A square matrix of the order n x n is said to be orthogonal if AAᵀ = I.
  2. Unitary Matrix :- A square matrix of order n x n is said to be unitary if the multiplication of A and the transpose of its conjugate is I.
  3. Idempotent Matrix :- A square matrix is called idempotent if A² = A. If A is both idempotent and invertible then A = I.
  4. Involutory Matrix :- A square matrix is called involutory if A² = I.
  5. Nilpotent Matrix :- Any square matrix of order n x n is said to be a nilpotent matrix of index k if Aᵏ = O but Aᵏ⁻¹O.

This was all for this article. In the next part, I’ll talk about the geometry of linear equations. If you want to contact me just drop a comment. Till then learn, practice, and evolve 🖖🏼.

--

--

Utkarsh Mathur

Data Science Student at University at Buffalo and a conduit to the stories data tell.