February 2020
Beginner
621 pages
19h 34m
English
The ciphertext
was encrypted using a Hill cipher with matrix
Decrypt it.
SOLUTION
There are several ways to input a matrix. One way is the following. A matrix can be entered as matrix(2,2,[a,b,c,d]). Type evalm(M&*N) to multiply matrices and Type evalm(v&*M) to multiply a vector on the right by a matrix
Here is the encryption matrix.
> M:=matrix(3,3,[1,2,3,4,5,6,7,8,10])
We need to invert the matrix mod 26:
> invM:=map(x->x mod 26, inverse(M))
The command map(x->x mod 26, E) takes each number in an expression E and reduces it mod 26.
This is the inverse of the matrix mod 26. We can check this ...
Read now
Unlock full access