Thursday, March 11, 2010

Cryptology

To encode a short message a number can be assigned to each letter of the alphabet according
to a given table. The text as a sequence of numbers will be organized into a square matrix A;
in the case that the number of letters is lower than the number of elements of the matrix A,
the rest of the matrix can be filled with zero elements. Let a nonsingular square matrix C be
given. To encode the text the matrix A can be multiplied by the matrix C for example on the
left. Let the following table and the matrix C be given:

A B C D E F G H I J K L M N O P Q R S T U V W X y Z
8 7 5 13 9 16 18 22 4 23 11 3 21 1 6 15 12 19 2 14 17 20 25 24 10 26

C =

2 0 1
1 0 1
0 1 0

We put the text ”BILA KOCKA” (a white cat) into the matrix A:
A =

7 4 3
8 11 6
5 11 8

and encode the text:
Z = CA =

19 19 14
12 15 11
8 11 6

.
To decode the message we have to multiply the matrix Z by the matrix C−1 on the left:
C−1Z =

1 −1 0
0 0 1
−1 2 0


19 19 14
12 15 11
8 11 6

= A.
Since the matrix multiplication is not commutative, it is necessary to keep the order of
the matrices in the product. If we multiply the matrices C−1 and Z in the opposite order, we
obtain

ZC−1=

19 19 14
12 15 11
8 11 6



1 −1 0
0 0 1
−1 2 0

=

5 9 19
1 10 15
2 4 11

and it means ”CERNY PSIK”(a black dog).

FIRAS ABDEL DAYEM
http://www.mff.cuni.cz/veda/konference/wds/contents/pdf06/WDS06_106_m8_Ulrychova.pdf

No comments:

Post a Comment