Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
1K views15 pages

Matrices & Application of Matrices

This document discusses matrices and their application in cryptography. It defines what a matrix is and provides examples of different matrix sizes and types. It then explains how matrices can be used for encryption and decryption in cryptography. Specifically, it shows how a message can be encoded using matrix multiplication with an encoding matrix, transmitted, and then decoded by the recipient using the inverse matrix for decryption.

Uploaded by

aaaa
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1K views15 pages

Matrices & Application of Matrices

This document discusses matrices and their application in cryptography. It defines what a matrix is and provides examples of different matrix sizes and types. It then explains how matrices can be used for encryption and decryption in cryptography. Specifically, it shows how a message can be encoded using matrix multiplication with an encoding matrix, transmitted, and then decoded by the recipient using the inverse matrix for decryption.

Uploaded by

aaaa
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 15

Matrices

&
Application of Matrices
Matrices
 Matrix (plural matrices) is a rectangular
table of elements (or entries)

 These elements are abstract quantities that


can be added and multiplied….
 Numbers
 Matrices come in all possible rectangular shapes, the following are a
number of examples of matrices

 In general, we denote a matrix by

 Each aij is called an element of the matrix (or an entry of the matrix);
this denotes the element in row i and column j. The entries of the
matrix are organized in horizontal rows and vertical columns
 The size, or dimension, of the matrix is n x m, where,
 n is the number of rows of the matrix,
 m is the number of column of the matrix.

 For example, the following matrices are of dimensions 1x4, 3x1,


2x3, and 4x2 respectively

 A special kind of matrix is a square matrix,


 i.e. a matrix with the same number of rows and columns.
 If a square matrix has n rows and n columns, we say that the matrix has
order n.
 The matrix is a square matrix of order 3.
Application of Matrices
 Graph theory
 The adjacency matrix of a finite graph is a basic notion of graph theory.
 Linear combinations of quantum states in Physics
 The first model of quantum mechanics by Heisenberg in 1925
represented the theory's operators by infinite-dimensional matrices
acting on quantum states. This is also referred to as matrix mechanics.
 Computer graphics
 4×4 transformation rotation matrices are commonly used in computer
graphics.
 Solving linear equations
 Using Row reduction
 Cramer's Rule ( Determinants)
 Using the inverse matrix
 Cryptography.
Application of Matrices
in
Cryptography
Cryptography
 Cryptography, is concerned with keeping communications private.

 Cryptography mainly consists of Encryption and Decryption

 Encryption is the transformation of data into some unreadable form.


 Its purpose is to ensure privacy by keeping the information hidden from
anyone for whom it is not intended, even those who can see the
encrypted data.
 Decryption is the reverse of encryption
 It is the transformation of encrypted data back into some intelligible
form.

 Encryption and Decryption require the use of some secret information,


usually referred to as a key.

 Depending on the encryption mechanism used, the same key might be used
for both encryption and decryption, while for other mechanisms, the keys
used for encryption and decryption might be different.
Application of matrix to
Cryptography
 One type of code, which is extremely difficult to break, makes use of
a large matrix to encode a message.

 The receiver of the message decodes it using the inverse of the


matrix.

 This first matrix, used by the sender is called the encoding matrix
and its inverse is called the decoding matrix, which is used by the
receiver.
Message to be sent:
PREPARE TO NEGOTIATE
and the encoding matrix be

 − 3 − 3 − 4
0 1 1 

 4 3 4 

We assign a number for each letter of the alphabet.


Such that A is 1, B is 2, and so on. Also, we assign the number 27 to
space between two words. Thus the message becomes:

P R E P A R E * T O * N E G O T I A T E
16 18 5 16 1 18 5 27 20 15 27 14 5 7 15 20 9 1 20 5
Encoding
 Since we are using a 3 by 3 matrix, we break the enumerated
message above into a sequence of 3 by 1 vectors:
16 16 5 15  5 20  20
18 1 27  27  7 9 5
             
 5  18  20 14  15  1  27

 Note that it was necessary to add a space at the end of the


message to complete the last vector.
 We encode the message by multiplying each of the above vectors
by the encoding matrix.
 We represent above vectors as columns of a matrix and perform its
matrix multiplication with the encoding matrix
− 3 − 3 − 4 16 16 5 15 5 20 20
0 1 1  18 1 27 27 7 9 5 

 4 3 4   5 18 20 14 15 1 27 
 We get

− 122 − 123 − 176 − 182 − 96 − 91 − 183


 23 19 47 41 22 10 32 

 138 139 181 197 101 111 203 

 The columns of this matrix give the encoded message.

 Encoding is complete
Transmission

The message is transmitted in a linear form

− 122, 23, 138, − 123, 19, 139, − 176, 47, 181,


− 182, 41, 197, − 96, 22, 101, − 91, 10, 111,
− 183 32 203.
Decoding
 To decode the message:
 The receiver writes this string as a sequence of 3 by 1 column matrices
and repeats the technique using the inverse of the encoding matrix.
 The inverse of this encoding matrix is the decoding matrix.

1 0 1
4 4 3 

− 4 − 3 − 3

 To decode the message, perform the matrix multiplication


1 0 1 − 122 − 123 − 176 − 182 − 96 − 91 − 183
4 4 3   23 19 47 41 22 10 32 
 
− 4 − 3 − 3  138 139 181 197 101 111 203 

 Matrix obtained is
16 16 5 15 5 20 20
18 1 27 27 7 9 5 
 
 5 18 20 14 15 1 27 
Decoded Message

 The columns of this matrix, written in linear form, give the original
message
16 18 5 16 1 18 5 27 20 15 27 14 5 7 15 20 9 1 20 5
P R E P A R E * T O * N E G O T I A T E

Message received:

PREPARE TO NEGOTIATE
Thank You !

You might also like