Preprint
Article

This version is not peer-reviewed.

Innovative Quantum Encryption Method for RGB Images Based on Bit-Planes and Logistic Maps

A peer-reviewed article of this preprint also exists.

Submitted:

22 January 2025

Posted:

22 January 2025

You are already at the latest version

Abstract

This study presents a novel encryption method for RGB (Red-Green-Blue) color images that combines scrambling techniques with the logistic map equation. In this method, image scrambling serves as a reversible transformation, rendering the image unintelligible to unauthorized users and thus enhancing security against potential attacks. The proposed encryption scheme, called Bit-Plane Representation of Quantum Images (BRQI), utilizes quantum operations in conjunction with a one-dimensional chaotic system to increase encryption efficiency. The encryption algorithm operates in two phases: first, the quantum image undergoes scrambling through bit-plane manipulation, and second, the scrambled image is mixed with a key image generated using the logistic map. To assess the performance of the algorithm, simulations and analyses were conducted, evaluating parameters such as entropy (a measure of disorder) and correlation coefficients confirm the effectiveness and robustness of this algorithm in safeguarding and encoding color images. The results show that the proposed quantum color image encryption algorithm surpasses classical methods in terms of security, robustness, and computational complexity.

Keywords: 
;  ;  ;  

1. Introduction

Both steganography and cryptography are crucial for information security, yet they serve different functions. Cryptography focuses on obscuring the content of information, ensuring that even if the message is intercepted, it remains unreadable to unauthorized parties. In contrast, steganography aims to hide the existence of the information by embedding it within seemingly innocuous carriers such as images, audio files, or text, making it difficult to detect. Cryptography encrypts messages using algorithms and keys, transforming them into unreadable formats. Despite this, encrypted messages can sometimes reveal signs of their encrypted nature, suggesting the presence of concealed information. Steganography, however, hides the message within a cover medium, such as an image or audio file, without leaving visible traces to those not aware of the technique. For instance, if sensitive data needs to be transmitted securely, cryptography would encrypt the message, resulting in a secure but visibly encrypted output that indicates the presence of sensitive information. Steganography, on the other hand, would embed the message within a harmless image or audio file, making the hidden information nearly impossible to detect without knowledge of the steganographic method [1,2,3,4,5,6]. In encryption, two primary methodologies are utilized: scrambling and replacement. Scrambling involves disrupting the pixel arrangement of the original image using algorithms such as Arnold, Fibonacci, and Hilbert [7,8,9,10,11]. Replacement, on the other hand, focuses on altering pixel values, thereby modifying the statistical properties of the encrypted image. Both methods are crucial for ensuring secure data transmission. In the realm of quantum image processing, preserving information security is of utmost importance. The spatial domain of a quantum image encompasses two key attributes: pixel position and color information [12]. Quantum image representation has advanced over time, with lattice-based qubit representations becoming common. One notable technique is the quantum image representation based on bit-planes, which has garnered attention due to its benefits in encryption and image processing. Several factors contribute to the focus on encryption and image processing within quantum image processing, including the impressive capabilities of quantum coherent states, entanglement, and superposition. These factors significantly enhance the encryption process and boost quantum storage capacity. For an image with a “22n “ pixel configuration, such as “2n × 2n “, fewer qubits are required compared to other representations. These include Normal Arbitrary Superposition State (NASS), Flexible Representation of Quantum Images (FRQI), Multi-Channel Quantum Images (MCQI), Quantum Multi-Channel Representation (QMCR), Generalized NEQR (GNEQR), and Novel Enhanced Quantum Representation (NEQR) [13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29]. Quantum image processing offers several advantages over classical methods. For instance, Quantum Fourier Transform and Quantum Discrete Cosine Transform provide enhanced efficiency. Image processing and encryption operations can be simulated on classical computers using linear algebra, complex vectors, and unitary matrices. Quantum states are often described by probability distributions rather than individual states, with measurements producing probability distributions as output. The normalized quantum state of an image captures both color and pixel position, enabling image storage and processing through quantum Fourier transforms for binary images. Feynman’s computational model introduced the concept of quantum image representation through quantum computers. The FRQI model, for instance, provides a quantum representation for images with a specific number of qubits required for grayscale images. Two-dimensional arrays of qubits represent quantum images, illustrating quantum entanglement states [21]. The MCQI model offers a standardized quantum representation for color images of size 2n × 2n with a minimal qubit requirement of 2n+3. Compared to FRQI, MCQI is more efficient for image processing, storage, and encryption. It supports watermarking algorithms for color images, whereas FRQI is limited to grayscale images. Encoding a 64×64 color image in classical systems requires 12288 bits, but the MCQI model achieves encryption with just 15 qubits, reducing computational complexity and resource usage. Additionally, MCQI enables simultaneous color image data processing with three qubits, simplifying processing and ensuring consistent color handling across the entire image [23]. The NASS quantum image representation allows for processing both color and grayscale images using 2n quantum qubits for a 22n pixel image, with each qubit representing a single bit of image data [22]. The NEQR model enhances the FRQI model by processing and storing individual pixels using qubits in their base state rather than amplitude. It achieves faster quantum image processing by a factor of two and offers a compression rate up to 1.5 times higher than FRQI while preserving image recovery accuracy. This model provides greater flexibility and simplifies complex pixel color analysis [23]. The Quantum Multi-Channel Representation (QMCR) model introduces a new method for representing color images in quantum computing. QMCR uses two entangled qubit sequences to separately encode color data and pixel locations, improving data representation fidelity. It requires 2n+24 qubits for a 2n × 2n color image, highlighting its enhanced capabilities and finer resolution in quantum environments [25]. The Bit-Plane Representation of Quantum Images (BRQI) has significantly increased storage capacity, with grayscale images benefiting from a factor of “24” and color images from a factor of “218”. Color images, consisting of three-color channels with 8 binary bits each, can be decomposed into 24 binary images, known as bit-planes. This information is detailed in Table 1, which also includes the number of qubits required for color and grayscale images [13]. This paper employs the BRQI technique with n+6 qubits for color image processing. In quantum encryption, key logic gates such as Pauli-X Gates (Bit-Inversion gates) and Swap Gates are used to manipulate qubits, ensuring secure data transmission and retention [30].

2. Preliminaries

To start, this section provides a brief review of quantum bits and quantum gates as fundamental concepts in quantum computing as well as the BRQI representation, which is a key component of our proposed scheme.

2.1. Bit and Qubits

Conventional computers process data and perform calculations using a binary system of bits, which can represent either a 1 or a 0. In contrast, quantum computers employ qubits, which have the remarkable capability to exist in both 1 and 0 states at the same time at least until a measurement is taken, after which their states are determined.
In practice a qubit is represented by a two-level physical system such as an electron with spin two ± 1 / 2   and it is shown mathematically by a vector within a two-dimensional complex vector space called Hibert space. Basis qubits are shown by 0 and 1 , along with their corresponding dual states:
0 = 1 0 ,   1 = 0 1 ,   0 = 1 0 ,   1 = 0 1
Generally, a qubit can be in basis states or in a superposition of the basis states shown as
Ψ = α 0 + β 1 = α β
In this context, α and β are referred to as probability amplitudes. In this context, the probability of measuring 0   is given by α 2 , whereas the probability of measuring 1 is represented by β 2 , so
α 2 + β 2 = 1
In quantum computation, we are dealing with two-quibit, three-qubit and multi-qubit systems. For instance, a two-qubit configuration possesses four fundamental computational states, namely 00 , 01 , 10 , and 11 , therefore a general form of a two-qubit system can be given by:
Ψ = α 00 00 + α 01 01 + α 10 10 + α 11 11 = α 00 α 01 α 10 α 11
α 00 2 + α 01 2 + α 10 2 + α 11 2 = 1
Similar to the case of a single qubit, the same principles extend to a two-qubit system:
00 = 0 0 = 1 0 1 0 = 1 × 1 0 0 × 1 0 = 1 0 0 0 01 = 0 1 = 1 0 0 1 = 1 × 0 1 0 × 0 1 = 0 1 0 0 10 = 1 0 = 0 1 1 0 = 0 × 1 0 1 × 1 0 = 0 0 1 0 11 = 1 1 = 0 1 0 1 = 0 × 0 1 1 × 0 1 = 0 0 0 1
One of the most important quantum phenomena in the context of quantum computation is quantum entanglement. For an entangled system of two or more particles, the state of one particle instantly influences the state of the other, regardless of the distance separating them. As an example:
Ψ 1 = α 1 00 + β 1 11
α 1 2 + β 1 2 = 1
In the case of Ψ 1 , the state of the first quantum dictates the state of the second quantum: if the first quantum is in state 0 , the second quantum will also be in state 0 ; conversely, if the first quantum is in state 1 , the second quantum will likewise be in stat 1 .

2.2. Quantum Gates and Circuits

Quantum circuits use logic gates to process information, applying logical transformations through unitary transformations of quantum states. These quantum gates can be represented using matrix notation. A quantum logic gate that acts on a single qubit is known as a single quantum gate. When a qubit Ψ   nters a quantum circuit of a single qubit gate, the output will be U Ψ , which can be represented in matrix form.
Ψ = α β   ,     U = a b c d                    U Ψ = a b c d α β =   a α + b β c α + d β
Common examples of single-qubit gates are identity gate, Pauli gate (X, Y and Z), Hadamard gate and rotation gates. The most common single qubit gates are sorted in Table 2.
For instance, the Hadamard gate (H) which is a two-qubit quantum gate plays a crucial role in creating a superposition and transforming the input state of a qubit, it takes the initial state of 0   and generates two states a superposition state including both 0   and 1 as follows:
H 0 = 2 2 1 1 1 1 1 0 = 2 2 1 1 = 2 2 0 + 2 2 1 H 1 = 2 2 1 1 1 1 0 1 = 2 2 1 1 = 2 2 0 2 2 1
In addition to single qubit gates, for the aim of quantum computation, two-qubit gates, three-qubit gates and multi-qubit gates are needed. The most common two-qubit gate is Controlled-NOT (CNOT gate)
In a CNOT gate, the initial qubit functions as a control qubit, while the subsequent qubit, which is influenced by the first, is referred to as the target qubit. When the first qubit is in the state 1 , the second qubit undergoes a reversal which is shown as:
C N O T 00 = 1 0 0 0 0 1 0 0 0 0 0 1 0 0 1 0 1 0 0 0 = 1 0 0 0 = 00 C N O T 01 = 1 0 0 0 0 1 0 0 0 0 0 1 0 0 1 0 0 1 0 0 = 0 1 0 0 = 01 C N O T 10 = 1 0 0 0 0 1 0 0 0 0 0 1 0 0 1 0 0 0 1 0 = 0 0 0 1 = 11 C N O T 11 = 1 0 0 0 0 1 0 0 0 0 0 1 0 0 1 0 0 0 0 1 = 0 0 1 0 = 10
When the number of control qubits in a CNOT gate is augmented to two, the resulting gate is referred to as a Toffoli gate.
Moreover, the two-qubit SWAP gate facilitates the exchange of two qubits. It enables the swapping of their states, leading to a rearrangement of information or entanglement between the qubits. Additionally, there are two other important gates in quantum computing [13,49]. The most common two-qubit gates are shown in Table 3.

3. Our Proposed Model for Quantum Encryption Method for RGB Images Based on Bit-Planes and Logistic Maps

Considering that the model and algorithm presented in the upcoming article are based on the image processing method utilizing bitplanes, this method will first be briefly reviewed. Then we present our innovative model for quantum RGB images encryption based on bit-planes and logistic maps.

3.1. BRQI for RGB Color Images

To begin with, the bitplane image processing model should be utilized, which is a modified version of the generalized NEQR (GNEQR) model. The key difference is that we treat each pixel of the image as consisting of bitplanes (8 bits). A grayscale image is composed of 8 binary bits, enabling its decomposition into 8 binary images (or 8 bitmaps), as depicted in Figure 1. Each bitmap derived from a grayscale image can be represented using the GNEQR model in the following manner.
Ψ m j = 1 2 n x = 0 2 n k 1 y = 0 2 k 1 g x , y x y  
where j denotes the j-th bitplane, j=0, 1,…,7 , m=1 , g x , y C 1 = 0,1 .
The least significant bit (LSB) of the image depicted in Figure 2 can be preserved:
Ψ 1 0 = 1 2 3 1 00 0 + 0 00 1 + 1 01 0 + 1 01 1 + 0 10 0 + 0 10 1 + 1 11 0 + 0 11 1 ,
To depict the eight bitplanes through a state representation, we establish BRQI, which is composed of eight GNEQR states in the (12) configuration.
Ψ B 8 = 1 2 3 l = 0 2 3 1 Ψ m l l = 1 2 n + 3 l = 0 2 3 1 x = 0 2 n k 1 y = 0 2 k 1 g x , y x y l ,
In the context of the l -th bitplane, where g x , y C 1 = 0,1 and l are defined, it can be inferred from Equation (14) that the BRQI method utilizes merely n+4 qubits to encode a 2 n k × 2 k = 2 n grayscale image. This represents a 16-fold enhancement in storage capacity when compared to the GNEQR approach outlined in Equation (12).
The circuit implementation for BRQI, as detailed in Equation (14), is illustrated in Figure 3, while the corresponding abbreviation circuits are depicted in Figure 4. In Figure 3, the gate U S is characterized as follows.
U S = g x , y 1 I + g x , y X ,
The symbol represents an exclusive-or operator. Specifically, if g x , y = 0 is true, then U S = I is applicable; otherwise, U S = X is the result.
The circuit enclosed within the red dashed box serves to implement.
I H n k H k H 3 0 0 n k 0 k 0 3 = 1 2 n + 3 l = 0 2 3 1 x = 0 2 n k 1 y = 0 2 k 1 0 x y l ,
In this context, H n and 0 n represent the n-fold tensor products of the spaces H and 0 , respectively. The circuit depicted within the dashed box corresponding to bitplane j (where j=0, 1...,7) is responsible for storing the j-th bitplane in quantum systems. Consequently, the circuit U G illustrated in Figure 4 is executed.
1 2 n + 3 l = 0 2 3 1 x = 0 2 n k 1 y = 0 2 k 1 0 x y l   Ψ B 8 ,
For instance, we can store the image in Figure 2 in quantum systems using the circuit in Figure 5.
The circuit enclosed within the dashed box labeled l represents the implementation for the l-th bitplane, denoted as Ψ 1 j , where j takes on values from 0 to 7. Notably, the pixel values for the 3rd, 4th, and 7th bitplanes are all zero, resulting in the corresponding circuits being inactive. Additionally, since the pixel values for the 5th and 6th bitplanes are both one, their implementation circuits can be streamlined, as illustrated in the dashed boxes 5 and 6. The output generated by the circuit depicted in Figure 5 is:
Ψ B 8 = 1 2 3 l = 0 7 Ψ 1 l l   Ψ 1 1 = 1 2 3 1 00 0 + 0 00 1 + 0 01 0 + 0 01 1 + 1 10 0 + 0 10 1 + 0 11 0 + 0 11 1 , Ψ 1 2 = 1 2 3 0 00 0 + 1 00 1 + 0 01 0 + 1 01 1 + 0 10 0 + 1 10 1 + 1 11 0 + 1 11 1 , Ψ 1 3 = Ψ 1 4 = Ψ 1 7 = 1 2 3 x = 0 3 y = 0 1 0 x y , Ψ 1 5 = Ψ 1 6 = 1 2 3 x = 0 3 y = 0 1 1 x y ,
An RGB color image can be separated into three distinct grayscale images or into 24 individual bitplanes. The color representation for m qubits using a basis state c can be articulated in the following manner:
c = c m 1 c m 2 c 0 = c m 1 c m 2 c 0 ,
Where c 0 , , c m 2 , c m 1 0 , 1 . For the image on the gray scale is c = c 8 c 7 c 0 and the color image ( r , g , b ) is c = c 23 c 22 c 0 , which is r = c 23 c 22 c 16 , g = c 15 c 14 c 8 and b = c 7 c 6 c 0 .
An illustration of the gates is depicted in a color image to explain the BRQI circuit. This research examined the quantum circuit of the BRQI in Figure 6 using color images of 2 n k × 2 k , where n + 6 qubits are employed to represent the circuit. The qubits utilized in this system are composed of n qubits dedicated to coordinates, in addition to 6 extra qubits allocated for each pixel in the image. These additional qubits consist of one for binary color, three for bit surfaces, and two for color channel. The gate U G encompasses both the X-Pauli gate (NOT gate) and the Identity gate for binary color. Furthermore, it encompasses the states 0 or 1 for the coordinates and Bit-planes that correspond to each image. This comprehensive setup enables the simulation of the image on a quantum circuit.
The representation of Ψ B 24 is depicted by the red dashed box in Figure 6
0 0 n k 0 k 0 3 0 0 0 0 n k 0 k 0 3 00 Ψ B 24 1 3 × 2 n + 3 ( l = 0 2 3 1 x = 0 2 n k 1 y = 0 2 k 1 0 x y l 01 + l = 0 2 3 1 x = 0 2 n k 1 y = 0 2 k 1 0 x y l 10 + l = 0 2 3 1 x = 0 2 n k 1 y = 0 2 k 1 0 x y l 11 ) ,
The expression for Ψ B 24 representing color images of size 2 n × 2 n can be stated as follows:
Ψ B 24 = 1 3 Ψ B R 01 + Ψ B G 10 + Ψ B B 11 = 1 3 ( 1 2 2 n + 3 l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 g R x , y x y l 01 + 1 2 2 n + 3 l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 g G x , y x y l 10 + 1 2 2 n + 3 l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 g B x , y x y l 11 )
The given expression states that g R x , y , g G x , y , g B x , y are elements of the set 0,1 . Additionally, x is equal to i n 1 i 0 and y is equal to j n 1 j 0 , where i 0 , , i n 1 and j 0 , , j n 1 are elements of the set {0,1}. The variable l represents the l -th bitplane [13].
For a 2 × 2 color image like Figure 7, the states Ψ P i x e l 2 R (Quantum states of the red color channel), Ψ P i x e l 2 G (Quantum states of the green color channel) and Ψ p i x e l 2 B (Quantum states of the blue color channel) can be expressed in accordance with Equation (21) as shown below:
Ψ P i x e l 2 R = 1 2 2 n + 3 ( 0 0 1 000 + 0 0 1 001 + 0 0 1 010 + 0 0 1 011 + 0 0 1 100 + 0 0 1 101 + 1 0 1 110 + 1 0 1 111 ) , Ψ P i x e l 2 G = 1 2 2 n + 3 l = 0 2 3 1 0 0 1 l ,                              Ψ P i x e l 2 B = 1 2 2 n + 3 l = 0 2 3 1 0 0 1 l ,

3.2. Our Model for RGB Images Encryption Based on Bit-Planes and Logistic Maps

Based on Reference 13 by Li, H; et al. and also Equations (12) to (21), Equation (22) provides a general framework for describing quantum states and the bit-planes model. In the following, we will clearly explain and implement the bit-planes model through an example, using a 2x2 color image that includes the red, green, and blue color channels.
In the following subsections, we present our proposed quantum image interleaving operation and algorithm, which consist of two main processes: the scrambling process and the image construction process.

3.2.1. Image Scrambling Process

Quantum image scrambling is a process that alters and disrupts the information contained in an image, making it challenging to discern its core patterns and features. In the proposed model, the quantum imgage scrambling process can be achieved in following steps:
the original image. The operator U S acts on the qubits of the Bit-planes, resulting in observable changes as described in Equation (23).
1.
Swapping bit-planes;
The first step in the quantum image scrambling process of our proposed model involves swapping bit-planes. During this step, the bit-plane layers of the image are exchanged, causing a random redistribution of the image’s information. This disruption makes it significantly harder to identify the image’s patterns and key features. The aim can be done by using bit-planes swapping operator which is defined as follows:
U S = U S 1 U S 2 U S 3 U S 1 = I 2 n + 2 Swap | 01 01 | , U S 2 = I 2 n + 1 Swap ( 3 ) | 10 10 | , U S 3 = I 2 n + 1 Swap I | 11 11 | ,
The U S   operator, by affecting the Bit-planes of each pixel, causes the Bit-planes of the red color channel to move in such a way that the first Bit-plane moves with the second Bit-plane and the fifth Bit-plane moves with the sixth Bit-plane. As you can see in the circuit of Figure 8a, for the green color channel, the first Bit plane is moved with the fourth Bit plane, as well as the third Bit plane with the sixth Bit plane, and finally, for the blue color channel, the second Bit plane is moved with the fourth Bit plane and Also, the third Bit plane is moved with the fifth Bit plane, and the effect of this operator on the image of Figure 8b can be seen in a simulated form on Figure 8c. Figure 8a illustrates the impact of this operator on the movement of Bit-planes within the red color channel, specifically L 2   and L 3 . Similarly, in the green color channel, it affects L 1 and L 3 , while in the blue color channel, it influences L 1   and L 2 . Additionally, Figure 8 showcases the resulting image after the swapping bit-planes step.
2.
Transferring image bitplanes;
The second step in the quantum image scrambling process of our proposed model involves transferring image bit-planes. This step allows for the reassignment of bit-planes to new positions or the creation of entirely new bit-plane configurations. By doing so, it generates new combinations of image bit-planes, further increasing the variability and complexity of the image data. The bit-plane transfer function can be defined as follows:
U X B = U X B 1 U X B 2 U X B 3 U X B 1 = I 2 n + 3 X | 01 01 | U X B 2 = I 2 n + 2 X I | 10 10 | , U X B 3 = I 2 n + 1 X I 2 | 11 11 | ,
The U X B operator also moves the Bit-planes like the U S   operator, with the difference that all the Bit-planes are moved two by two with each other, causing more image pixels to change, and as you can see in Figure 9-(c) Using two of the simple quantum gates, Pauli-X Gate and Identity Gate, as seen in the circuit of Figure 9-(a), and in other words, the U X B operator is responsible for moving Bit-planes, and by moving Giving all Bit-planes at once in a unique way, and pairing them two by two, distinguishes itself from the Bit-planes swap operator. Figure 9 shows the quantum circuit along with the resulting image under the influence of the transmission image bitplanes process.
L 1 L 2 L 3 L 1 L 2 ~ L 3 ,    L 1 L 2 L 3 L 1 ~ L 2 L 3 ,    L 1 L 2 L 3 ~ L 1 L 2 L 3
3.
Color complement.
The final step in the quantum image scrambling process of our proposed model is color complement. By using color complement process, the colors in the image are reversed. This process alters the image’s colors to complement each other, resulting in visually appealing effects while also enhancing security which is given by the following operator:
U X C E P = X I 2 n 1 1 1 I 5  
Based on Figure 10, the even-pixels’ coordinates for X Y can be represented in the following manner:
X Y = x n 1 x 0 y n 1 y 0 = i n 1 i 0 j n 1 j 0 , X Y f o r e v e n p i x e l s = x n 1 x 0 y n 1 y 1 1 = i n 1 i 0 j n 1 j 1 1 ,
Where i 1 , , i n 1 , j 1 , , j n 1 0,1 .
Figure 10. A 4×4 color image with alternating markings on even and odd pixels.
Figure 10. A 4×4 color image with alternating markings on even and odd pixels.
Preprints 146875 g010
As observed, the Pauli-X gate and Identity gate were applied, affecting only the binary color qubit of the even pixels (28). As shown in Figure 10, the even pixels exhibit a unique property., Since x and y correspond to the spatial coordinates of the pixels, by converting the y-coordinate to 2y for odd pixels and 2y+1 for even pixels, we can easily apply the color complement operator to the even pixels based on the proposed algorithm.
U X C E P Ψ B 24 = ( 1 3 × 2 2 n + 3 l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 1 g R x , y x 2 y l 01 + l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 1 g G x , y x 2 y l 10 + l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 1 g B ( x , y ) x 2 y l 11 + l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 1 1 g R ( x , y ) x 2 y + 1 l 01 + l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 1 1 g G ( x , y ) x 2 y + 1 l 10 + l = 0 2 3 1 x = 0 2 n 1 y = 0 2 n 1 1 1 g B ( x , y ) x 2 y + 1 l 11 )
This operator influences the color of all bit planes for each even pixels in the image. Figure 11 illustrates the results of the first two stages of the scrambling process applied to the Lena image, employing the color complement method from the proposed model.
Figure 12-(a) presents the quantum circuit for the initial segment of our encryption algorithm, which focuses on image scrambling. Additionally, Figure 12-(c) displays the simulated output of this first phase of encryption applied to the Lena image. Since our encryption algorithm concludes by merging the image scrambling derived from bitplanes with an image generated using a logistic map of the same dimensions as the original image, we move forward to create an image referred to as the key image, which complicates the recovery of the encrypted image.

3.2.2. Constructing Process

Finally, as the last step of our model, we apply logestic map to the encrypted quantum image. The logistic map is a powerful tool for understanding complex behavior in dynamical systems. In other words, the logistic map is a mathematical model and a recurrence equation that studies the dynamics of nonlinear systems and their complex behaviors, and its applications can be seen in fields such as periodic behavior, chaos, and also in artificial intelligence. This model is also used in social sciences and economics. The discrete version of the Logistic function, is known as the Logistic Map. As you can see in Equation (29), x t 1 represents the population in generation t and r is a control parameter that determines the population growth rate. The logistic map is an invertible map; that is, it can be iterated forward in time and reach an x t from x t 1 , but the reverse is not possible. This map is also called the iterative mapping function. Statistically, for small values of r between 0 and 1, our function has a stable behavior, and if this value is between 1 and 3, our function has a periodic and oscillating behavior, but if this value is greater than 3, our logistic map becomes chaotic, which we have used here for values in the range [3.569945, 4] to generate a completely random and irregular sequence of numbers, and then by creating an order and arrangement of these numbers in a way that we will discuss below, and with the help of simulation and conversion of this sequence of numbers into an image called the key image, which is used for the last part of our encryption algorithm [31,32,33,34,42]. The key image for the desired encryption is generated by performing a Binary XOR operation with the image obtained from the first phase. This process yields an encrypted image, with the function parameter r set at 3.86 and the initial value x 0 set to 0.31717115 (29)[43].
x t = r x t 1 1 x t 1 ,
The selection of the repetition number for the random sequence in this particular condition should be done in a manner that ensures the resulting simulation image falls within the dimensions of the output image from the first phase. To achieve this, the number of iterations should be set to t = 1,2 , or in other words t = 3 × 8 × 2 n × 2 n , where for a Lena image with dimensions of 256×256, t should be equal to 1572864. The obtained numerical sequence forms a matrix with dimensions of 1×1572864 using Matlab, with all numbers in the sequence being less than one. To convert this matrix into a sequence of zeros and ones, the numbers are rounded to the nearest zero or one. At this stage, the desired matrix needs to be transformed into a matrix with dimensions of 196608×8. This is achieved by arranging the elements from the previous matrix in a specific manner. The first column of the new matrix contains elements 1 to 196608, the second column contains elements 196609 to 393216, and so on, until all 8 columns and 196608 rows are filled. Each row in this matrix represents an 8-digit binary number. By converting these binary numbers into decimal numbers, the resulting matrix will have dimensions of 196608×1. Next, the obtained matrix is further converted into a matrix with dimensions of 65536×3. The conversion process involves arranging the elements in a specific manner. The first column of the new matrix contains elements 1 to 65536, the second column contains elements 65537 to 131072, and the third column follows a similar pattern. Each column in this matrix represents a color channel (red, green, or blue) of the key image. By converting each column into a 256×256 matrix, three matrices are created, each representing a color channel of the key image. Finally, by merging these three matrices, a single image is produced, which represents the result of the second phase of the key image encryption process. This merged image is the outcome of the encryption process (Figure 13). The Binary XOR operation is prominently featured in the quantum comparator circuit, which marks the culmination of the encryption process. This circuit, as shown in Figure 14b, holds a crucial role in the verification and alignment of various components such as qubits, coordinates, bit-planes, and color channels from two images. The purpose is to ensure coherence throughout the encryption procedure, as depicted in Figure 12c and Figure 13d. Following this, the application of the Pauli-X gate to the qubit of the output image obtained in the initial phase generates the resultant encryption image, as illustrated in Figure 15b. It is important to note that this operation is carried out when the binary color qubit of the key image is in the state represented by |1⟩.
In Figure 15, the complete implementation circuit of the algorithm is presented. The Quantum comparator circuit, denoted as U c in Figure 15, incorporates the Binary XOR (exclusive OR) operation as depicted in Figure 14b. Section V of this study involves the encryption of several images using the aforementioned algorithm, and the outcomes are displayed in Table 4.

4. Analyzing the Proposed Method

By Analyzing the histogram of the algorithm reveals that a smoother peak distribution and a flatter alignment indicate a more effective and efficient image scrambling process. This is evident in Figure 16, where the histogram of the Lena image is examined. Figure 16a shows the irregular histogram of each color channel in the Lena image before encryption, while Figure 16b depicts the transformation into a smoother and more uniform histogram after encryption using the proposed algorithm.
Figure 16. Histogram: (a)before encryption. (b)after encryption.
Figure 16. Histogram: (a)before encryption. (b)after encryption.
Preprints 146875 g016
Figure 17. Multiple images prior to and following the encryption process: (a) Lena. (b) Image-1. (c) Image-2. (d) Image-3. (e) Image-4. (f) Image-5. (g) encrypted Lena. (h) encrypted Image-1. (i) encrypted Image-2. (j) encrypted Image-3. (k) encrypted Image-4. (l) encrypted Image-5.
Figure 17. Multiple images prior to and following the encryption process: (a) Lena. (b) Image-1. (c) Image-2. (d) Image-3. (e) Image-4. (f) Image-5. (g) encrypted Lena. (h) encrypted Image-1. (i) encrypted Image-2. (j) encrypted Image-3. (k) encrypted Image-4. (l) encrypted Image-5.
Preprints 146875 g017aPreprints 146875 g017b
Figure 18. Correlation distributions of Lena’s image in each direction.
Figure 18. Correlation distributions of Lena’s image in each direction.
Preprints 146875 g018aPreprints 146875 g018b
Shannon introduced the concept of information entropy in 1949, which has proven to be highly valuable in quantifying randomness within an encryption system. When applied to color images, the Shannon Entropy can be determined by analyzing the probability distribution of pixel intensities. This entropy measurement also serves as an indicator of the image’s irregularity, effectively describing the distribution of gray levels present. A value closer to 8, representing the number of gray levels, signifies the utilization of an encryption algorithm that generates a greater degree of irregularity and random arrangement of pixels [35,36,37]. In Table 4, the entropy of multiple images is compared to evaluate the impact of the encryption algorithm. The results indicate that the proposed algorithm demonstrates notable improvements in both efficiency and effectiveness in scrambling images. The calculations were conducted using the software “Matlab”. The formula for computing information entropy is presented as follows [44].
E n t r o p y = i = 0 2 N 1 p h i l o g 2 p h i ,
The probability of the i-th gray level, denoted as p h i , represents the likelihood of that specific gray level occurring. This probability is calculated by normalizing the histogram counts, which takes into account the number of gray levels, denoted as N.
Figure 19. Correlation distributions of the encrypted Lena image in each direction.
Figure 19. Correlation distributions of the encrypted Lena image in each direction.
Preprints 146875 g019aPreprints 146875 g019b
The encryption of an image can be considered highly secure when the correlation coefficient between adjacent pixels is minimized. In order to achieve this, an appropriate encryption algorithm should aim to reduce the correlation coefficient between horizontally, vertically, and diagonally positioned pixels as much as possible [38,39]. The calculation of the correlation coefficient is performed using a specific Formula (31).
C r = N i = 1 N x i × y i i = 1 N x i × i = 1 N y i N i = 1 N x i 2 i = 1 N x i 2 × N i = 1 N y i 2 i = 1 N y i 2 ,
The given expression represents the relationship between the values of two neighboring pixels, denoted as x and y, in an image. The variable N represents the total number of pixels present in the image [39,40,41].
By conducting a comparative analysis of the correlation coefficient for multiple images in Table 5, both before and after encryption using the algorithm under consideration, it becomes evident that the mentioned encryption method provides a high level of security.
It is important to note that with knowledge of all the steps of the encryption algorithm, along with access to the key image and its associated variables, one can easily decrypt the encrypted image. Furthermore, the order in which each operator is applied at each stage is critical. By understanding these components, it is sufficient to reverse the process step by step to recover the original image. We successfully restored the original image using the MATLAB program.

5. Conclusions

This paper presents a novel quantum image encryption algorithm aimed at enhancing the security of image transmission and storage. The algorithm operates in two main stages: Color Image Scrambling and the integration of a logistic map. In the first stage, the original quantum image undergoes scrambling using the Bit-plane Swap Operator, Image Bitplane Transfer Operator, and Color Complement Operator, ensuring effective disruption of the image’s original structure. An image called the key image is created in the second part, the construction process, which is a chaotic sequence created by the logistic map. then, the two images resulting from the image scrambling process and the construction process by the quantum comparator are the output of our encryption algorithm. This combination leverages the principles of quantum mechanics and chaos theory, offering robust security superior to classical methods. The security of the proposed algorithm is further reinforced against potential quantum threats, such as quantum cloning machines, due to the inherent randomness and sensitivity of chaotic systems. Various metrics are employed to evaluate its effectiveness, including histograms, entropy, and correlation coefficients. Post-encryption histograms display a uniform distribution of color spectrums, effectively mitigating the risk of statistical attacks and safeguarding the original image. Correlation analyses reveal a significant reduction in pixel dependency, demonstrating the algorithm’s ability to disrupt spatial patterns. The entropy of the Lena image, recorded at approximately 7.75 before encryption, reaches the ideal maximum of 8 after applying the algorithm, indicating highly secure encryption. This pattern is consistent across multiple test images. Additionally, the correlation distributions analyzed in three directions for neighboring pixels confirm the algorithm’s capability to achieve spatial independence after encryption. These findings strongly support the exceptional performance of the proposed quantum encryption algorithm, demonstrating its effectiveness, efficiency, and heightened security in comparison to existing methods. This work represents a significant step forward in leveraging quantum computing for advanced image encryption.

Supplementary Materials

Not applicable.

Author Contributions

Conceptualization, L. FM. and M.N; data curation, S. B, L. FM. and M.N; formal analysis, S. B, L. FM. and M.N.; investigation, S. B, L. FM. and M.N; methodology, S. B, L. FM. and M.N; resources, S. B, L. FM. and M.N; software, S. B; supervision, L. FM. and M.N; validation, S. B, L. FM. and M.N; writing—original draft, S. B, L. FM. and M.N; writing—review & editing, S. B, L. FM. and M.N. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Data Availability Statement

Not applicable.

Acknowledgments

The first and the second authors thank Islamic Azad University for supporting this research.

Conflicts of Interest

The authors declare no conflicts of interest.

References

  1. Morkel, T.; Eloff, J.H.P.; Olivier, M.S. An Overview of Image Steganography. Information and Computer Security Architecture (ICSA) Research Group, 2005.
  2. Pahati, O.J. Confounding Carnivore: How to Protect Your Online Privacy. AlterNet, 2001-11-29. Archived from the original on 2007-07-16. Retrieved 2008-09-02.
  3. Singh, L.D.; Singh, K.M. Image Encryption Using Elliptic Curve Cryptography. Procedia Computer Science 2015, 54, 287–294.
  4. Lukac, R.; Plataniotis, K.N. Bit-Level-Based Secret Sharing for Image Encryption. Pattern Recognition 2005, 38, 873–882.
  5. Mishra, R.; Bhanodiya, P. A Review on Steganography and Cryptography. In Proceedings of the International Conference on Advances in Computer Engineering and Applications, IEEE, March 2015.
  6. Kamali, S.H.; Shakerian, R.; Hedayati, M.; Rahmani, M. A New Modified Version of Advanced Encryption Standard Based Algorithm for Image Encryption. In Proceedings of the International Conference on Electronics and Information Engineering, IEEE, August 2010.
  7. Jiang, N.; Wang, L.; Wu, W. Quantum Hilbert Image Scrambling. International Journal of Theoretical Physics 2014, 53, 2655–2663.
  8. Jiang, N.; Wu, W.; Wang, L. The Quantum Realization of Arnold and Fibonacci Image Scrambling. Quantum Information Processing 2014, 13, 2179–2192.
  9. Sankpal, P.R.; Vijaya, P.A. Image Encryption Using Chaotic Maps: A Survey. In Proceedings of the Fifth International Conference on Signal and Image Processing, IEEE, January 2014.
  10. Chen, J.X.; Zhu, Z.L.; Liu, Z.; Fu, C.; Zhang, L.B.; Yu, H. A Novel Double-Image Encryption Scheme Based on Cross-Image Pixel Scrambling in Gyrator Domains. Optics Express 2014, 22, 10343–10356.
  11. Wong, K.W.; Kwok, B.S.H.; Yuen, C.H. An Efficient Diffusion Approach for Chaos-Based Image Encryption. Chaos, Solitons & Fractals 2009, 42, 1877–1888.
  12. Yang, Y.; Jia, X.; Xu, P.; Tian, J. Analysis and Improvement of the Watermark Strategy for Quantum Images Based on Quantum Fourier Transform. Quantum Information Processing 2013, 12, 2971–2990.
  13. Li, H.; Chen, X.; Xia, H.; Liang, Y.; Zhou, Z. A Quantum Image Representation Based on Bitplanes. In Proceedings of the IEEE, 2018.
  14. Yan, F.; Iliyasu, A.M.; Venegas-Andraca, S.E. A Survey of Quantum Image Representations. Quantum Information Processing 2016, 15, 1065–1085.
  15. Erhard, M.; Krenn, M.; Zeilinger, A. Advances in High-Dimensional Quantum Entanglement. Nature Reviews Physics 2020, 2, 365–381.
  16. Vedral, V. Quantum Entanglement. Nature Physics 2014, 10, 256–258.
  17. Delaubert, V.; Treps, N.; Fabre, C.; Bachor, H.A.; Réfrégier, P. Quantum Limits in Image Processing. EPL (Europhysics Letters) 2008, 81, 44001.
  18. Venegas-Andraca, S.E.; Bose, S. Storing, Processing, and Retrieving an Image Using Quantum Mechanics. In Proceedings of Quantum Information and Computation, Volume 5105, pp. 137–147, 2003.
  19. Chakraborty, S.; Mandal, S.B.; Shaikh, S.H. Quantum Image Processing: Challenges and Future Research Issues. International Journal of Information Technology 2018, 10, 1–15.
  20. Ventura, D.; Martinez, T. Quantum Associative Memory with Exponential Capacity. In Proceedings of the IEEE International Joint Conference on Neural Networks, World Congress on Computational Intelligence, Vol. 1, pp. 509–513, May 1998.
  21. Le, P.Q.; Dong, F.; Hirota, K. A Flexible Representation of Quantum Images for Polynomial Preparation, Image Compression, and Processing Operations. Quantum Information Processing 2011, 10, 63–84.
  22. Li, H.S.; Zhu, Q.; Li, M.C.; et al. Multidimensional Color Image Storage, Retrieval, and Compression Based on Quantum Amplitudes and Phases. Information Sciences 2014, 273, 212–232.
  23. Sun, B.; Iliyasu, A.M.; Yan, F.; Dong, F.; Hirota, K. An RGB Multi-Channel Representation for Images on Quantum Computers. Journal of Advanced Computational Intelligence and Intelligent Informatics 2013, 17, 404–417.
  24. Zhang, Y.; Lu, K.; Gao, Y.; Wang, M. NEQR: A Novel Enhanced Quantum Representation of Digital Images. Quantum Information Processing 2013, 12, 2833–2860.
  25. Abdolmaleky, M.; Naseri, M.; Batle, J.; Farouk, A.; Gong, L.H. Red-Green-Blue Multi-Channel Quantum Representation of Digital Images. Optik 2017, 128, 121–132.
  26. Li, H.S.; Fan, P.; Xia, H.Y.; et al. Quantum Implementation Circuits of Quantum Signal Representation and Type Conversion. IEEE Transactions on Circuits and Systems I: Regular Papers 2018, 65, 1–14.
  27. Mona Abdolmaleky, Mosayeb Naseri, Josep Batle, Ahmed Farouk, Li-Hua Gong, Red-Green-Blue multi-channel quantum representation of digital images, Optik, Volume 128, 2017, Pages 121-132, ISSN 0030-4026. [CrossRef]
  28. Heidari, S., Naseri, M. A Novel LSB Based Quantum Watermarking. Int J Theor Phys 55, 4205–4218 (2016). [CrossRef]
  29. Mosayeb Naseri, Shahrokh Heidari, Masoud Baghfalaki, Negin fatahi, Reza Gheibi, Josep Batle, Ahmed Farouk, Atefeh Habibi, A new secure quantum watermarking scheme, Optik, Volume 139, 2017, Pages 77-86, ISSN 0030-4026. [CrossRef]
  30. U.S. District Court Rules in Favor of Copyright Protection for Standards Incorporated by Reference into Federal Regulations. Available online: www.ansi.org (accessed on November 24, 2017).
  31. Zhang, L.; Liao, X.; Wang, X. An Image Encryption Approach Based on Chaotic Maps. Information Sciences 2005, 24, 237–245.
  32. Fridrich, J. Image Encryption Based on Chaotic Maps. In Proceedings of the IEEE International Conference on Systems, Man, and Cybernetics, Orlando, FL, USA, October 12–15, 1997; pp. 1105–1110.
  33. Peng, J.; Jin, S.; Chen, G.; Yang, Z.; Liao, X. An Image Encryption Scheme Based on Chaotic Map. In Proceedings of the Fourth International Conference on Natural Computation, ICNC ’08, Vol. 4, pp. 595–599, 2008.
  34. Jakobson, M.V. Absolutely Continuous Invariant Measures for One-Parameter Families of One-Dimensional Maps. Communications in Mathematical Physics 1981, 81, 39–88.
  35. Thum, Ch. Measurement of the Entropy of an Image with Application to Image Focusing. IEEE Transactions on Pattern Analysis and Machine Intelligence 1984, 31, 203–211.
  36. Wu, X.; Wang, K.; Wang, X.; Kan, H. Lossless Chaotic Color Image Cryptosystem Based on DNA Encryption and Entropy. Nonlinear Dynamics 2017, 87, 1–12.
  37. Cheng, H.D.; Jiang, X.H.; Wang, J. Color Image Segmentation Based on Histogram Thresholding and Region Merging. Pattern Recognition 2002, 35, 373–393.
  38. Abdullah, A.H.; Enayatifar, R.; Lee, M. A Hybrid Genetic Algorithm and Chaotic Function Model for Image Encryption. Applied Mathematics and Computation 2012, 66, 185–198.
  39. Pareek, N.K.; Patidar, V.; Sud, K.K. Image Encryption Using Chaotic Logistic Map. Image and Vision Computing 2006, 24, 926–934.
  40. Pisarchik, A.N.; Zanin, M. Image Encryption with Chaotically Coupled Chaotic Maps. Physica D: Nonlinear Phenomena 2008, 237, 2638–2648.
  41. Rhouma, R.; Meherzi, S.; Belghith, S. OCML-Based Colour Image Encryption. Information Sciences 2009, 40, 309–318.
  42. Kwok, H.S.; Tang, W.K.S. A Fast Image Encryption System Based on Chaotic Maps with Finite Precision Representation. Chaos, Solitons & Fractals 2007, 33, 1919–1928.
  43. May, R.M. Simple Mathematical Models with Very Complicated Dynamics. Nature 1976, 261, 459–467.
  44. Wu, Y.; Zhou, Y.; Saveriades, G.; Agaian, S.; Noonan, J.P.; Natarajan, P. Local Shannon Entropy Measure with Statistical Tests for Image Randomness. Information Sciences 2013, 222, 323–342.
  45. Mackenzie, Charles E. (1980). Coded Character Sets, History and Development. The Systems Programming Series (1 ed.). Addison-Wesley Publishing Company, Inc. p. x.
  46. Bemer, Robert William (2000-08-08). “Why is a byte 8 bits? Or is it?”. Computer History Vignettes. Archived from the original on 2017-04-03. Anderson, John B.; Johnnesson, Rolf (2006), Understanding Information Transmission.
  47. Haykin, Simon (2006), Digital Communications.
  48. Shannon, Claude Elwood (July 1948). “A Mathematical Theory of Communication”. Bell System Technical Journal.
  49. Wang, Zhaobin, Minzhe Xu, and Yaonan Zhang. “Review of quantum image processing.” Archives of Computational Methods in Engineering 29, no. 2 (2022): 737-761.
  50. K. K. S. K. R. A. (2018). Quantum Image Processing: A Survey. Quantum Information Processing, 17(6), 1-25.
  51. Zhang, Y., & Wang, Y. (2019). Quantum Image Representation and Processing. Quantum Information Science, 5(2), 1-12.
  52. Li, Y., & Zhang, Y. (2020). Quantum Algorithms for Image Processing. Journal of Quantum Computing, 3(1), 45-60.
  53. K. A. & K. S. (2021). Advances in Quantum Image Processing Techniques. International Journal of Quantum Information, 19(4), 1-15.
  54. J. Q. & L. H. (2022). Applications of Quantum Image Processing in Medical Imaging. Medical Physics, 49(3), 1234-1245.
  55. K. A. (2020). Quantum Image Processing: Theory and Applications. Journal of Modern Physics, 11(5), 789-802.
  56. S. M. & T. R. (2021). Quantum Computing for Image Processing: A Review. Journal of Computer Vision and Image Processing, 10(2), 150-165.
  57. H. L. & Y. Z. (2022). Quantum Image Processing: Challenges and Opportunities. Quantum Computing Reviews, 4(1), 23-40.
  58. R. F. & A. T. (2023). Quantum Algorithms for Image Analysis. International Journal of Quantum Information Science, 6(1), 1-30.
  59. M. J. & K. S. (2023). Quantum Techniques for Image Enhancement. Journal of Imaging Science and Technology, 67(3), 1-15.
  60. G. S. & L. P. (2021). Quantum Image Processing: A New Paradigm. Quantum Information, 7(2), 45-78.
  61. T. R. & F. J. (2020). Quantum Image Processing: Algorithms and Applications. Journal of Quantum Algorithms, 2(3), 100-120.
  62. P. H. & S. A. (2021). Quantum Computing in Image Processing: A Comprehensive Review. Journal of Quantum Computing Research, 5(1), 1-50.
  63. Q. R. & T. S. (2022). Quantum Image Processing for Remote Sensing Applications. Remote Sensing Journal, 14(4), 234-250.
  64. A. B. & C. D. (2023). Quantum Techniques for Medical Image Processing. Medical Imaging Journal, 12(2), 99-115.
  65. H. T. & J. K. (2023). The Future of Quantum Image Processing: Trends and Predictions. Future Computing Journal, 8(1), 1-20.
  66. L. M. & N. O. (2022). Quantum Image Processing: Theoretical Insights and Practical Applications. Journal of Theoretical Physics, 15(3), 200-220.
  67. S. P. & R. Q. (2021). Quantum Algorithms for Image Enhancement and Analysis. International Journal of Quantum Algorithms, 4(2), 50-70.
  68. D. E. & F. G. (2023). Exploring Quantum Image Processing Techniques for Enhanced Object Recognition. Computer Vision and Image Processing Journal, 9(1), 1-30.
  69. J. K. & L. M. (2023). Quantum Image Processing: Bridging Theory and Practice. Journal of Quantum Information Science, 6(2), 150-175.
Figure 1. Bitplanes of a grayscale image
Figure 1. Bitplanes of a grayscale image
Preprints 146875 g001
Figure 2. A 4×2 grayscale image.
Figure 2. A 4×2 grayscale image.
Preprints 146875 g002
Figure 3. The circuit design for the implementation of BRQI in grayscale images.
Figure 3. The circuit design for the implementation of BRQI in grayscale images.
Preprints 146875 g003
Figure 4. The BRQI abbreviation circuit designed for grayscale images is represented within the red dashed box, denoted as U G .
Figure 4. The BRQI abbreviation circuit designed for grayscale images is represented within the red dashed box, denoted as U G .
Preprints 146875 g004
Figure 5. The circuit design for the implementation of BRQI in the context of grayscale images.
Figure 5. The circuit design for the implementation of BRQI in the context of grayscale images.
Preprints 146875 g005
Figure 6. The circuit implementation of BRQI for RGB color images is being discussed.
Figure 6. The circuit implementation of BRQI for RGB color images is being discussed.
Preprints 146875 g006
Figure 7. a color image 2×2.
Figure 7. a color image 2×2.
Preprints 146875 g007
Figure 13. The key image is formed by utilizing the logistic map equation as its foundation. It comprises four distinct components: (a) the image in the red channel, (b) the image in the green channel, (c) the image in the blue channel, and (d) the outcome of the second stage encryption, which is referred to as the Key Image.
Figure 13. The key image is formed by utilizing the logistic map equation as its foundation. It comprises four distinct components: (a) the image in the red channel, (b) the image in the green channel, (c) the image in the blue channel, and (d) the outcome of the second stage encryption, which is referred to as the Key Image.
Preprints 146875 g013
Figure 14. (a) A quantum comparator circuit for two images of size ( 2 n k × 2 k ) utilizing BRQI. (b) A quantum comparator circuit incorporating the Binary XOR (exclusive OR) operation for the key image and the image encrypted by the initial phase algorithm.
Figure 14. (a) A quantum comparator circuit for two images of size ( 2 n k × 2 k ) utilizing BRQI. (b) A quantum comparator circuit incorporating the Binary XOR (exclusive OR) operation for the key image and the image encrypted by the initial phase algorithm.
Preprints 146875 g014
Figure 15. (a) The circuit for implementing the image scrambling algorithm. (b) The encrypted image after the final processing.
Figure 15. (a) The circuit for implementing the image scrambling algorithm. (b) The encrypted image after the final processing.
Preprints 146875 g015
Figure 8. The process of swapping bit-planes involves the following components: (a) The implementation circuit of U S   , (b) a 256×256 color image, and (c) the outcome of the bit-planes swap operation.
Figure 8. The process of swapping bit-planes involves the following components: (a) The implementation circuit of U S   , (b) a 256×256 color image, and (c) the outcome of the bit-planes swap operation.
Preprints 146875 g008
Figure 9. The process of transferring Image Bit-planes. (a) The circuit design of U X B . (b) A color image with dimensions of 256×256. (c) The outcome of the Image Bit-planes transfer process.
Figure 9. The process of transferring Image Bit-planes. (a) The circuit design of U X B . (b) A color image with dimensions of 256×256. (c) The outcome of the Image Bit-planes transfer process.
Preprints 146875 g009
Figure 11. The functioning of color inversion. (a) The execution circuit of U X C E P . (b) A 256×256 image with colors. (c) The outcome of the color inversion process.
Figure 11. The functioning of color inversion. (a) The execution circuit of U X C E P . (b) A 256×256 image with colors. (c) The outcome of the color inversion process.
Preprints 146875 g011
Figure 12. illustrates an image scrambling algorithm that operates on bitplanes. The diagram (a) showcases the implementation circuit of the image scrambling process. In addition, the Lena image is presented in diagram (b). Lastly, diagram (c) demonstrates the encryption of Lena’s image through the utilization of the initial phase algorithm.
Figure 12. illustrates an image scrambling algorithm that operates on bitplanes. The diagram (a) showcases the implementation circuit of the image scrambling process. In addition, the Lena image is presented in diagram (b). Lastly, diagram (c) demonstrates the encryption of Lena’s image through the utilization of the initial phase algorithm.
Preprints 146875 g012
Table 1. The evaluation of Quantum image representations (QIRs) is conducted for an image consisting of 22n pixels.
Table 1. The evaluation of Quantum image representations (QIRs) is conducted for an image consisting of 22n pixels.
QIR Qubits (GI) Qubits (CI) Pixel encoding
FRQI 2n+1 --- Amplitude
MCQI --- 2n+3 Amplitude
NASS 2n 2n Amplitude
NEQR 2n+8 --- Basis states
QMCR --- 2n+24 Basis states
GNEQR 2n+8 2n+24 Basis states
BRQI 2n+4 2n+6 Basis states
Table 2. presents a compilation of frequently utilized single quantum gates.
Table 2. presents a compilation of frequently utilized single quantum gates.
Gate type Circuit Matrix
NOT Preprints 146875 i001 0 1 1 0
Identity Preprints 146875 i002 1 0 0 1
Hadamard Preprints 146875 i003 2 2 1 1 1 1
Pauli-X Preprints 146875 i004 0 1 1 0
Pauli-Y Preprints 146875 i005 0 i i 0
Pauli-Z Preprints 146875 i006 1 0 0 1
R X θ Preprints 146875 i007 cos θ sin θ sin θ cos θ
Table 3. Frequently utilized multiple quantum gates.
Table 3. Frequently utilized multiple quantum gates.
Gate type Circuit Matrix
CNOT Preprints 146875 i008 1 0 0 0 0 1 0 0 0 0 0 1 0 0 1 0
Swap Preprints 146875 i009 1 0 0 0 0 0 1 0 0 1 0 0 0 0 0 1
0CNOT Preprints 146875 i010 0 1 0 0 1 0 0 0 0 0 1 0 0 0 0 1
Toffoli Preprints 146875 i011 1 0 0 1 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 1 1 0
Table 4. Entropy Analysis.
Table 4. Entropy Analysis.
Image Red Green Blue Average
Lena Plain 7.26647529 7.57641548 6.99698477 7.75230230
encrypted 7.99706260 7.99747581 7.99666707 7.99914383
Image-1 Plain 4.78364119 4.73370893 5.05956128 4.86826736
encrypted 7.99166776 7.99227987 7.99282306 7.99439984
Image-2 Plain 4.67421401 4.85111012 5.01229852 4.87986000
encrypted 7.99187429 7.99281031 7.99301983 7.99462144
Image-3 Plain 7.64643957 7.33613706 7.64931401 7.66549665
encrypted 7.99729804 7.99722871 7.99718760 7.99893469
Image-4 Plain 7.36835372 7.63346757 7.14444474 7.74964698
encrypted 7.99633432 7.99722933 7.99718431 7.99910385
Image-5 Plain 7.91513367 7.73168494 7.64447837 7.88854042
encrypted 7.99727711 7.99705858 7.99729900 7.99914117
Table 5. Correlation coefficients of plain image and encrypted image.
Table 5. Correlation coefficients of plain image and encrypted image.
Image Red Green Blue
Lena Plain horizontal 0.94496092 0.94394613 0.90382255
vertical 0.97160053 0.97138740 0.94575043
diagonal 0.92060182 0.92063101 0.86947909
Encrypted horizontal 0.04684634 0.05272363 0.05873554
vertical -0.08600054 -0.07969069 -0.06718450
diagonal 0.03889228 0.03631901 0.05433776
Image-1 Plain horizontal 0.92722854 0.92541146 0.92171877
vertical 0.93122544 0.92875145 0.92504564
diagonal 0.88693262 0.88339981 0.87809024
Encrypted horizontal -0.04400776 -0.04404985 -0.03493985
vertical -0.02690263 -0.02770975 -0.01463662
diagonal -0.04237329 -0.04804702 -0.03113912
Image-2 Plain horizontal 0.79642455 0.81825466 0.82329247
vertical 0.85224205 0.86751412 0.86920629
diagonal 0.70727947 0.73512158 0.74101511
Encrypted horizontal -0.03844896 -0.03945518 -0.02958604
vertical -0.03513343 -0.04033299 -0.02344154
diagonal -0.03173505 -0.03945518 -0.02184033
Image-3 Plain horizontal 0.93243145 0.89115097 0.93705562
vertical 0.91626012 0.86801252 0.92639075
diagonal 0.89600855 0.83303664 0.90363931
Encrypted horizontal 0.05921598 0.06870314 0.07175162
vertical -0.01380835 -0.00194525 0.00106863
diagonal 0.05774048 0.06055552 0.07260252
Image-4 Plain horizontal 0.95116615 0.97288558 0.94465043
vertical 0.95408423 0.97791858 0.95067943
diagonal 0.92085361 0.95553869 0.91182653
Encrypted horizontal 0.03727045 0.04323486 0.04399785
vertical -0.08462279 -0.07850834 -0.07398065
diagonal 0.03837588 0.03645186 0.04947882
Image-5 Plain horizontal 0.91795308 0.90593869 0.95240375
vertical 0.89809097 0.88392991 0.94136339
diagonal 0.87193455 0.86353650 0.93517466
Encrypted horizontal 0.04486794 0.05486874 0.05032741
vertical -0.05127246 -0.04212630 -0.04436001
diagonal 0.03982164 0.04169260 0.04825240
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.
Copyright: This open access article is published under a Creative Commons CC BY 4.0 license, which permit the free download, distribution, and reuse, provided that the author and preprint are cited in any reuse.
Prerpints.org logo

Preprints.org is a free preprint server supported by MDPI in Basel, Switzerland.

Subscribe

Disclaimer

Terms of Use

Privacy Policy

Privacy Settings

© 2025 MDPI (Basel, Switzerland) unless otherwise stated