# Implementation of MS Circle Map in Digital Image Encryption
## 3 Results and Discussion
### Correlation Analysis  
Correlation analysis is a method used to determine the direction and strength of the relationship between two variables or neighboring pixels in an image [32]. It always falls between \(-1\) and \(1\): a value of \(+1\) indicates a perfect positive correlation, \(-1\) a perfect \begin{table}
\begin{tabular}{c c c c c c} \hline \multirow{2}{*}{**Test Data**} & \multicolumn{2}{c}{**Test Statistic Value (Color)**} & \multirow{2}{*}{**Test Data**} & \multirow{2}{*}{**Test Statistic Value**} \\  & **Red** & **Green** & **Blue** & \\ \hline
1 & 268.164062 & 258.437500 & 253.164063 & 16 & 247.1875 \\ \hline
2 & 250.863281 & 277.939453 & 275.384765 & 17 & 246.248046 \\ \hline
3 & 235.232421 & 270.956542 & 233.668940 & 18 & 246.130859 \\ \hline
4 & 243.031901 & 251.895833 & 271.606770 & 19 & 219.767578 \\ \hline
5 & 238.991699 & 244.717773 & 310.002929 & 20 & 288.8857429 \\ \hline
6 & 288.055501 & 288.981445 & 254.281127 & 21 & 251.916582 \\ \hline
7 & 275.367187 & 248.243923 & 267.787905 & 22 & 274.582754 \\ \hline
8 & 235.268904 & 227.270254 & 272.959297 & 23 & 274.217978 \\ \hline
9 & 260.675238 & 209.334056 & 264.488281 & 24 & 223.690285 \\ \hline
10 & 250.142578 & 205.775390 & 270.474609 & 25 & 253.832031 \\ \hline
11 & 275.858398 & 263.105468 & 242.437988 & 26 & 272.104980 \\ \hline
12 & 245.902588 & 223.680786 & 226.968017 & 27 & 267.083251 \\ \hline
13 & 229.420138 & 230.788194 & 260.524305 & 28 & 286.586805 \\ \hline
14 & 259.599826 & 206.467013 & 222.075520 & 29 & 266.861979 \\ \hline
15 & 240.970703 & 235.670138 & 267.295355 & 30 & 270.957248 \\ \hline Average & 253.1696 & 242.8843 & 259.5413 & Average & 259.3369 \\ \hline \end{tabular}
\end{table} 
Table 8: Statistical test results of color and grayscale images. negative correlation, and 0 no correlation. The closer to +1 the correlation value, the higher the linear relationship between neighboring pixels in displaying information on features: objects, colors, and textures contained in an image. The greater the correlation value is close to +1, the higher the linear relationship between neighboring pixels in forming and displaying information on features: objects, colors, and textures contained in an image. Conversely, the smaller the correlation value is close to 0, the lower the linear relationship between neighboring pixels, and, in this case, no information can be read. Table 9 shows the correlation coefficient of neighboring pixels in the original color images and their encrypted image, while Table 10 shows the correlation coefficient for grayscale images and their encrypted image. The correlation coefficient value is calculated in three directions: horizontal, diagonal, and vertical. In both tables, it can be seen that, for the original images, all correlation values are quite large, and some are close to 1. Meanwhile, in their encrypted images, all correlation values are very small and very close to 0. Based on the calculation results where the correlation of neighboring pixels of all encrypted images has a very small value approaching 0, it can be concluded that the encrypted images using the MS Circle Map function are invulnerable to statistical attacks. \begin{table}
\begin{tabular}{c c c c c c c} \hline \hline \multirow{2}{*}{**Test Data**} & \multicolumn{3}{c}{**Correlation Coefficient Values of**} & \multicolumn{3}{c}{**Correlation Coefficient Values of**} \\  & \multicolumn{3}{c}{**Plain Grayscale Images**} & \multicolumn{3}{c}{**Encrypted Grayscale Images**} \\ \cline{2-7}  & **Horizontal** & **Vertical** & **Diagonal** & **Horizontal** & **Vertical** & **Diagonal** \\ \hline
1 & 0.96063 & 0.93627 & 0.91181 & \(-\)0.001 & 0.00352 & 0.0041 \\ \hline
2 & 0.95844 & 0.93544 & 0.91289 & \(-\)0.0016 & 0.00377 & \(-\)0.0033 \\ \hline
3 & 0.98365 & 0.97155 & 0.95976 & \(-\)0.0011 & \(-\)0.0018 & \(-\)0.0013 \\ \hline \hline \end{tabular}
\end{table} 
Table 10: Correlation coefficient of the grayscale images.