Article
Research and Development

TIME ANALYSIS COMPARISON OF HILL CIPHER AND AFFINE HILL CIPHER DECRYPTION USING MATLAB

Date: 07/01/2024
Author: Gülbahar AKGÜN
Contributor: ebβ„’ Research Team

Hill cipher system, it can be decrypted using the system 𝐢 = 𝑃 βˆ™ 𝐾 βˆ’1 (π‘šπ‘œπ‘‘ 𝑛) . Affine Hill cipher the decryption system expression is represented by π‘₯ = 𝐻 βˆ’1 (𝑦 βˆ’ 𝑉)(π‘šπ‘œπ‘‘ 𝑛). We used English alphabet so 𝑛 = 26 because English alphabet consists of 26 letters. In this research, matrices of size 20x20, 100x100, 200x200 and 300x300. Although the decryption process of this cipher was simplified using Matlab, it still required a considerable amount of time, even for a program. The results obtained from Matlab showed that as the size of the matrices increased, decryption became progressively more difficult. Using Matlab for Hill cipher decryption is 𝑑 = π‘π‘π‘’π‘‘π‘–π‘šπ‘’, π‘Ž = 0 + 100 βˆ— π‘Ÿπ‘Žπ‘›π‘‘(20,20), 𝑏 = π‘Ÿπ‘œπ‘’π‘›π‘‘(π‘Ž), π‘₯ = 0 + 25 βˆ— π‘Ÿπ‘Žπ‘›π‘‘(20,1), π‘˜ = π‘Ÿπ‘œπ‘’π‘›π‘‘(π‘₯), 𝑔 = 𝑏 βˆ— π‘˜, 𝑐 = 𝑖𝑛𝑣(𝑏), 𝑦 = 0 + 25 βˆ— π‘Ÿπ‘Žπ‘›π‘‘(20,1), 𝑗 = 𝑐 βˆ— 𝑦, 𝑙 = π‘Ÿπ‘œπ‘’π‘›π‘‘(𝑗), 𝑝 = π‘šπ‘œπ‘‘(𝑙, 26), π‘§π‘Žπ‘šπ‘Žπ‘› = π‘π‘π‘’π‘‘π‘–π‘šπ‘’ βˆ’ 𝑑. Using Matlab for Affine Hill cipher decryption is 𝑑 = π‘π‘π‘’π‘‘π‘–π‘šπ‘’, 𝑦 = 0 + 25 βˆ— π‘Ÿπ‘Žπ‘›π‘‘(20,1), π‘˜ = π‘Ÿπ‘œπ‘’π‘›π‘‘(𝑦), π‘š = 0 + 25 βˆ— π‘Ÿπ‘Žπ‘›π‘‘(20,1), 𝑛 = π‘Ÿπ‘œπ‘’π‘›π‘‘(π‘š), 𝑝 = π‘˜ βˆ’ 𝑛, π‘Ž = 0 + 100 βˆ— π‘Ÿπ‘Žπ‘›π‘‘(20,20), 𝑏 = π‘Ÿπ‘œπ‘’π‘›π‘‘(π‘Ž), 𝑐 = 𝑖𝑛𝑣(𝑏), 𝑙 = 𝑐 βˆ— 𝑝, π‘Ÿ = π‘šπ‘œπ‘‘(𝑙, 26), π‘§π‘Žπ‘šπ‘Žπ‘› = π‘π‘π‘’π‘‘π‘–π‘šπ‘’ βˆ’ 𝑑. This is the result of operations performed using Matlab.