You are on page 1of 7

CRYPTOGRAPHY

(MS211) LINEAR ALGEBRA


Cryptography(3x3)

Let plain text => “ SAFE MESSAGES”


Let key “ciphering“ ==>
Since key is a 3x3 matrix , plain text should be converted into column vectors of length 3.
(nx1)matrices
(3x1)matrices
So we get : SAF EME SSA GES
ENCRYPTION / Code: # C = KP Mod26

(1) P = 

C = KP Mod (26)

C= Mod 26  C =  Take mod26 


.
.
.
(4) P = 
C = KP Mod (26)

C=Mod 26  C = Take mod26 

SAF-EME-SSA-GES (PLANE)  HDS-IOE-YQO-CAA (CIPHER)


DECRYPTION/Decode : # P = K**-1 C Mod26 # k**-1= 1 / I d I adj(k)

Finding determinant value :

HERE d =  2(24-13(17)) -8 (7(6)-8(17)) +15(7(13)-8(4)

|d| = 1243

Now we find multiplicative inverse of the determinant .


d.d**-1 = Mod26
So 1243(d**-1) = Mod26 ROUGH
d**-1 = 5
So d**-1 = 5 1243*5 Mod26
6215 Mod26
1
Now we find adjoint of (K)
Here 3x3 matrix

K=

For 1st element

4(16)-13(7) = -197

For 2nd element

7(13)-8(4) = -94
After solving all we get = Cofactor matrix
Now we will do transpose:

adj(K) = <= This is the adjoint matrix

Now resolving (–) signs.

adj(K) = 

adj(k) =

NOW , K**-1 = |d**-1| adj(K)

K**-1 = 5 x 
Now,we find its modulus26 to simplify:

Modulus is  K=

Now , we have decryption formula: # P = k**-1 C Mod26

CIPHER = HDS IOE YQO CAA

First for HDS

P = k**-1 C Mod26 =Mod26

P=   

Similarly we do same with others:


AFTER DECODING:
CIPHER HDS IOE YQO CAA
PLAIN SAF EME SSA GES

You might also like