## 3 Implementation
### Proposed Method
#### 3.2.2 Chaotic Random and Singular Value Matrix Formation  
The suggested technique begins by transforming the original image by using SVD. The encryption matrix is then calculated and compressed. We employed four types of chaos based on the QKCS to construct the chaotic random matrix here (to create the chaotic random matrix, the state variables of generalized logistics, Arnold, sine, and novel 3D Gauss models are employed). The following is the four-step process of the chaotic random and singular value matrix formation:  
1. SVD computation: \[X_{M}=USV^{T}\] (10) In (10), \(S\in\mathbb{R}^{n1\times n2}\) is a diagonal matrix containing singular values. The matrices \(U\in\mathbb{R}^{n1\times n2}\) and \(V\in\mathbb{R}^{n1\times n2}\) are unitary in which their columns are singular vectors. 2. Given a starting condition and an appropriate step size, we construct the sequence \(Q=\{q_{i}\}\) of the QKCS using the 3D Gauss system, logistic, Arnold, and sine maps. 3. We convert the sequence \(Q=\{q_{i}\}\) into the integer sequence \(Q*=\{q_{i}*\}\). 4. We reconfigure the pattern \(Q*\) to build the matrix \(Q_{M}\), which is a random matrix created through the QKCS system. 2.3 Step-by-Step Image Encryption and Compression Process Based on the Quad Key System (Sender's Side)  
Figure 7 depicts the recommended image compression and encryption technique procedure at the sender and receiver sides. The basic method consists of SVD and the combination of four chaotic maps, including a 3D Gauss map, an Arnold map, a logistic map, and a sine map. Figure 8 is a gallery of test images originally retrieved from the SIPI dataset. Furthermore, Figure 9 demonstrates the proposed algorithm for the Lena, Cameraman, Baboon, and Pepper images. Below is a detailed step-by-step description of the compression and encryption technique. **Step 1:** Read an image A of size \(M\times N\). Initially, the image is divided into three parts or matrices, i.e., \(U\), \(S\), and \(V\), by using SVD, where \(S\) is a diagonal matrix containing the sorted singular values of the input matrix in descending order. The matrices \(U\) and \(V\) are orthogonal matrices in which their columns are singular vectors. For a given \(M\times N\) input matrix, (11) below displays the sizes of the corresponding \(U\), \(S\), and \(V\) matrices. \[A_{M\times N}=U_{M\times M}\cdot S_{M\times N}\cdot(V_{N\times N})^{T} \tag{11}\]  
**Step 2:** The rank of the input matrix is determined by the number of non-zero elements on the diagonal of the matrix \(S\). By approximating the original matrix with a matrix of the lower rank \(S\), which is constructed by deleting tiny singular values, a compressed matrix is achieved. Figure 8: Test images (retrieved from the SIPI dataset). Figure 7: Proposed quad key-secured algorithm for the sender and receiver sides. **Step 3:** Using Equation (3) (sine map), the chaotic sequence \(x_{i}\) is created, and \(x_{i}\) is used to generate the diffusion sequence by (12). \[X_{i}=mod(floor(x_{i}\times 10^{5}),256) \tag{12}\]  
Then, as shown in (13), perform a bitwise XOR operation on the compressed image \(A^{\prime}\). \[A1=A^{\prime}\oplus X_{i} \tag{13}\]  
**Step 4:** Apply Equation (4), to obtain the scrambled image (\(A2\)) by using the Arnold transformation (see Algorithm 1 in Section 2.2.3). **Step 5:** Using Equation (2) (logistic map), the chaotic sequence \(y_{i}\) is created and \(y_{i}\) is used to generate the diffusion sequence by (14). \[Y_{i}=mod(floor(y_{i}*10^{5}),256) \tag{14}\]  
Figure 9: Results for the proposed quad key-secured algorithm. Then, as shown in (15), perform a bitwise XOR operation on the \(A2\) image. \[A3=A2\oplus X_{i} \tag{15}\]  
**Step 6:** A 3D Gauss map is used to generate the final key. In this key, we employed Equations (7)-(9), to produce the pseudo-random sequences \(x\), \(y\), and \(z\) as seen in Figure 6.  
**Step 7:** Image \(A3\) is first read, and then row and column permutations using \(x\) and \(y\) sequences are used to produce a shuffled image.