100% found this document useful (1 vote)
59 views

Quantum Image Encryption Using DNA Codec

1) The document proposes a new method for encrypting quantum images that combines quantum DNA coding and pixel-level scrambling using quantum Hilbert transforms. 2) The method aims to increase security and robustness over previous algorithms by encoding pixel color information using quantum DNA properties and scrambling pixel positions. 3) Simulation results showed the encrypted images had high average information entropy levels across RGB channels and uniform peak histogram values, indicating the method can withstand statistical and differential attacks better than earlier approaches.

Uploaded by

vivek verma
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
59 views

Quantum Image Encryption Using DNA Codec

1) The document proposes a new method for encrypting quantum images that combines quantum DNA coding and pixel-level scrambling using quantum Hilbert transforms. 2) The method aims to increase security and robustness over previous algorithms by encoding pixel color information using quantum DNA properties and scrambling pixel positions. 3) Simulation results showed the encrypted images had high average information entropy levels across RGB channels and uniform peak histogram values, indicating the method can withstand statistical and differential attacks better than earlier approaches.

Uploaded by

vivek verma
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 16

entropy

Article
Quantum Image Encryption Based on Quantum DNA Codec
and Pixel-Level Scrambling
Jie Gao 1 , Yinuo Wang 2 , Zhaoyang Song 1 and Shumei Wang 2, *

1 School of Information and Control Engineering, Qingdao University of Technology, Qingdao 266520, China
2 School of Science, Qingdao University of Technology, Qingdao 266520, China
* Correspondence: [email protected]

Abstract: In order to increase the security and robustness of quantum images, this study combined
the quantum DNA codec with quantum Hilbert scrambling to offer an enhanced quantum image
encryption technique. Initially, to accomplish pixel-level diffusion and create enough key space for
the picture, a quantum DNA codec was created to encode and decode the pixel color information
of the quantum image using its special biological properties. Second, we used quantum Hilbert
scrambling to muddle the image position data in order to double the encryption effect. In order to
enhance the encryption effect, the altered picture was then employed as a key matrix in a quantum
XOR operation with the original image. The inverse transformation of the encryption procedure
may be used to decrypt the picture since all the quantum operations employed in this research are
reversible. The two-dimensional optical image encryption technique presented in this study may
significantly strengthen the anti-attack of quantum picture, according to experimental simulation
and result analysis. The correlation chart demonstrates that the average information entropy of the
RGB three channels is more than 7.999, the average NPCR and UACI are respectively 99.61% and
33.42%, and the peak value of the ciphertext picture histogram is uniform. It offers more security and
robustness than earlier algorithms and can withstand statistical analysis and differential assaults.

Keywords: quantum information; DNA coding; quantum image encryption; quantum image scrambling

Citation: Gao, J.; Wang, Y.; Song, Z.;


Wang, S. Quantum Image Encryption
Based on Quantum DNA Codec and
1. Introduction
Pixel-Level Scrambling. Entropy 2023,
25, 865. https://doi.org/
With the development of internet and communication technology, image has become
10.3390/e25060865 the most widely used information transmission medium. Compared with text informa-
tion, images contain more information. As a result, researchers suggest quantum image
Academic Editors: Rosario Lo Franco,
processing by extending the digital picture to the quantum computing framework [1,2].
Giuliano Benenti and Brian R.
Quantum image processing (QIP) is committed to using quantum computing technol-
La Cour
ogy to capture, restoration, and other classical image operations. its exponential storage
Received: 16 January 2023 capacity and parallelism give this technology a strong advantage in implementing opera-
Revised: 14 April 2023 tions requiring high real-time operations such as image retrieval and processing.
Accepted: 22 May 2023 The special behavior of quantum particles is regarded as the rules of quantum physics
Published: 29 May 2023 and the tool of mathematical logic. In 1992, Lucien Hardy proposed Hardy’s paradox
while proving Bell’s theorem [3], and continued to prove the nonlocality of two particles in
1993 [4]. Moreover, Shor [5] and Grover [6] created quantum algorithms using the same
quantum computer property for integer factoring and database searching, respectively.
Copyright: © 2023 by the authors.
These algorithms perform better than their traditional versions in terms of running time.
Licensee MDPI, Basel, Switzerland.
References [5,6], which laid the foundation for diverse applications of quantum computing
This article is an open access article
in the information sciences, served as an inspiration for a great number of researchers [7–16].
distributed under the terms and
Quantum image encryption can be “unconditionally secure” based on the Heisen-
conditions of the Creative Commons
berg uncertainty principle because of quantum features such as quantum entanglement,
Attribution (CC BY) license (https://
creativecommons.org/licenses/by/
coherence, parallelism, and superposition. Quantum picture encryption employs the “No-
4.0/).
Cloning Theorem”, derived from the Heisenberg uncertainty principle, to encrypt image

Entropy 2023, 25, 865. https://doi.org/10.3390/e25060865 https://www.mdpi.com/journal/entropy


Entropy 2023, 25, 865 2 of 16

data, whereas conventional encryption typically restricts the timeliness of decryption oper-
ations. That is, because the basis of replication is measurement, and because measurement
often modifies the quantum state, it is impossible to accomplish the process of accurate
duplication of any unknown quantum state in quantum mechanics.
To establish image protection in the sphere of digital pictures [17], the genuine and
meaningful images are often transformed into meaningless forms. Today’s latest research
hot topic is the quantum picture encryption technique created by fusing together quan-
tum computing and digital imaging [18–20]. There are several quantum image repre-
sentation techniques now being used [21], including FRQI [22], NEQR [23], MCQI [24],
NASS [25,26], QUALPI [27], and others. Image information encryption has caught the
attention of academics working in the area of quantum information processing. Recently,
several quantum image encryption methods have been created, including a quantum image
encryption scheme based on quantum image decomposition [28], an iterative extended
Arnold transform-based quantum image encryption method, and a quantum image cyclic
shift operation-based quantum image encryption strategy [29].
DNA coding has attracted wide attention because of its advantages such as large
storage capacity and strong parallel processing ability. Compared with the traditional
cryptography based on mathematical problems, DNA cryptography combines the two
fields of mathematics and biology, which greatly enhances the security and robustness of
DNA cryptography. In 1994, Adleman carried out the world’s first DNA computing ex-
periment [30] and published related results in the journal Science. This result revealed that
DNA molecules have computing power in addition to their stable genetic properties, and
have since opened up a new information age [31–33]. At present, DNA coding is also grad-
ually emerging in the field of encryption [34–37]. Scholars have proposed a classical image
encryption algorithm that combines DNA coding technology with quantum walking [38].
In this research, a DNA coding technique and picture Hilbert scrambling were com-
bined to develop a quantum image encryption scheme. The encryption technique uses
Hilbert quantum image scrambling and quantum picture DNA coding and decoding. By
closely integrating the two technologies, the goal of enhancing picture security may be
achieved by more effectively reducing the high connection between neighboring pixels. We
also developed the quantum DNA codec’s implementation circuit.
The rest of this article is structured as follows: Section 2 introduces the background.
Section 3 shows the quantum circuit model. In Section 4, the flow of encryption and
decryption algorithm is shown in detail. Section 5 introduces the theoretical analysis and
experimental simulation. Finally, Section 6 draws a conclusion.

2. Related Work
2.1. Quantum Color Image Representation
NCQI is a quantum color digital image representation method proposed in 2017 [39].
We briefly reviewed the NCQI quantum representation model so as to introduce the
quantum image encryption algorithm proposed in this paper.
The NCQI model of a 2n × 2n image |ψi can be mathematically expressed as follows:

2n −1 2n −1
1
|ψi = n
2 ∑ ∑ |c(y,x) i ⊗ |yx i, (1)
y =0 x =0
E
where c(y,x) represents the color value of the pixel, which can be encoded by binary
sequence Rq−1 · · · R0 Gq−1 · · · G0 Bq−1 · · · B0 .
Every pixel contained in a color channel, which has a range of [0, 2q − 1], is represented
by three components: the horizontal position X, the vertical position Y, and the color
information c(y,x) . The R, G, and B range [0, 2q − 1] of each channel is utilized to store
picture data in an NCQI state of a color image using the 2n + 3q qubits.
Figure 1 is an example of a 4-by-4-color picture with the three channels, R, G, and
B, with the range size 0, 28 − 1 , n = 1, and q = 8. The equation in Figure 1 states that

Entropy 2023, 25, 865 3 of 16

the whole NCQI is kept in a state of normalized quantum superposition, with each base
standing in for a single pixel.

Figure 1. A color image and its quantum representation of NCQI.

2.2. DNA Coding Method and Operation


Adenine (A), thymine (T), cytosine (C), and guanine (G) are the four nucleotides
that make up the molecular structure of deoxyribonucleic acid (DNA), which is based
on the biological model (G). The DNA pairing rule states that A and T pair and C and G
pair. Similarly, in the binary complementary calculation, 1 and 0 are complementary, and
eight coding schemes which accord with the rules of a biological model were obtained by
encoding each nucleic acid base with 2-bit binary number respectively, as shown in Table 1.
Each RGB three-channel pixel in a color image is represented as a 24-bit binary sequence as
part of the encryption procedure, where each color channel’s 8-bit binary sequence may be
represented by four bases. For instance, scheme 1 will produce CACT if an image pixel’s
R-channel gray value is 71, which is represented by the binary sequence 01000111.

Table 1. DNA coding rules.

1 2 3 4 5 6 7 8
00 A A C C G G T T
01 C G A T A T C G
10 G C T A T A G C
11 T T G G C C A A

2.3. Quantum Hilbert Scrambling


With the development of quantum image processing, many image scrambling methods
have emerged [40,41]. In this work, quantum Hilbert image scrambling [42] was used.
An original image of size 2n × 2n can be regarded as a matrix. We call this matrix the
starting matrix (or original matrix) Sn and used 1 to 22n to encode all pixels,

· · · 2n
 
1 2 3
 2n + 1 2n + 2 2n + 3 · · · 2n +1 
Sn =  (2)
 
.. .. .. .. .. 
 . . . . . 
22n − 1 +1 2 2n − 1 +2 22n − 1 +3 ··· 2 .2n

 
1 2
The arrangement of Sn is Hn . For example, H0 = (1), H1 = , H2 =
4 3
 
1 2 15 16

 4 3 14 13  , where Hn (i, j) represents the pixel at position (i, j) of the starting
 5 8 9 12 
6 7 10 11
matrix Sn . Hilbert curves (see Figure 2) and scrambled images (see Figure 3) can be
obtained along the Hn .
Entropy 2023, 25, 865 4 of 16

Figure 2. Hilbert curve.

Figure 3. Results of performing a single Hilbert image scrambling.

This paper adopted the improved Hilbert scrambling recursive generation algorithm
in [42]. If A is a matrix, then A T represents its transposition, Aud its upper and lower
direction reversed, Ald its left and right inversion, and App its centre rotation matrix. For a
quantum computer to implement Hilbert image scrambling,
 !
H ( H + 4 n E )T
 n n n
 , n is even
( Hn + 3 × 4n En )pp ( Hn + 2 × 4n En )T


Hn+1 = , (3)
( Hn + 3 × 4n En )pp
 
 Hn
, n is odd

( Hn + 4n En )T ( Hn + 2 × 4n En )T

··· 1
 
1 1

1 2
  1 ··· 1 
1
where n is a positive integer and the initial matrix is H1 = , En =  .. .
 
4 3 .. ..
..
 . . . . 
1 1 ··· 1
According to reference [42], initialization, and even and odd basic circuits, are also
integrated circuits, and the process is described in Figure 4. The three parts that make up
the three basic circuits are called three circuit modules.
Entropy 2023, 25, 865 5 of 16

Figure 4. Flow chart of recursive generation algorithm.

2.4. Quantum XOR


According to reference [43], it needs to be divided into 22n sub-operations Yy,x in order
to implement the XOR operation on each pixel value of the quantum image. Use Y to
represent a matrix of the same size as the image in the sub-operation:

···
 
y0,1 y0,2n −1
Y= .. .. ..
, (4)
 
. . .
y 2n −1,0 · · · y2 −1,2 −1
n n

where yy,x = m0yx m1yx m2yx m3yx , · · · , m23 i


yx , myx ∈ 0, 1, and the quantum gate operation se-
quence F are generated according to yi,j :

···
 
b0,1 b0,2n −1
F= .. .. ..
, (5)
 
. . .
b2n −1,0 · · · b2n −1,2n −1
(
0 V1 23 , i X, miyx = 1
where Fyx = Vyx yx . . . Vyx Vyx = represents the realization of the X-gate
I, miyx = 0
i , respectively:
transformation or I-gate transformation of Cyx
   
0 1 1 0
GX = , GI = (6)
1 0 0 1.

When F is applied to the entire image, there are:

2n −1 2n −1
F| I i = ∏ ∏ Fyx | I i
x =0 y =0
2n −1 2n −1
1 E
=
2n ∑ ∑ ⊗23 C i
i =0 yx ⊗ m i
yx | yx i (7)
x =0 y =0
2n −1 2n −1
1
= n
2 ∑ ∑ | f (y, x )i|yx i,
x =0 y =0

where | f (Y, X )i represents the new pixel value after pixel scrambling, and |CYX i is the
pixel sequence.

3. Quantum Circuit Design


The design of the DNA codec simulator’s quantum circuit, which is a crucial compo-
nent of our quantum picture encryption technique, is presented in this section.
Entropy 2023, 25, 865 6 of 16

3.1. Quantum DNA Codec Simulator


Based on the classical DNA coding technology and the quantum image representation
of NCQI, a DNA codec simulation circuit for quantum images was designed.
In our proposed encryption algorithm, quantum DNA coding and decoding tech-
nology were used to encrypt pixel color information. NCQI representation can directly
transform the color value information of a color image with three-channel color values in
the range of [0, 2q − 1] of 2n × 2n into a binary sequence of 3q bits, so we took every two
lines as a combination to reflect the concept of bases in biology.
We encapsulated the whole quantum DNA codec into a black box. We only needed to
input the binary sequence of the image into the black box and enter the sequence number
of the coding and decoding scheme to complete the DNA codec operation of the quantum
image. Di,j was used to represent the quantum DNA codec, where i is the coding scheme
sequence number and j is the decoding scheme sequence number. As shown in Figure 5,
six lines were added to reflect the sequence number of the codec scheme, and |ψ0 i and
|ψ1 i were input lines as binary sequences. Three quantum lines b0 ,b1 ,b2 can represent the
numerical value of the decoding scheme sequence number. When designing quantum
circuits, we used two auxiliary circuits. While reducing a lot of time complexity, we only
added a little space complexity. Therefore, it can effectively reduce the circuit complexity
and improve the operation efficiency. If we decode it with option 6, the circuit module
of the scheme will be run directly through the three quantum lines b0 ,b1 ,b2 . As a result,
only the sequence number of the decoding scheme can be input to run the circuit to realize
automatic decoding, and there is no need to select the circuit. Figure 6 shows the quantum
circuits of seven decoding schemes encoded in Rule 1.

Figure 5. QuantumDNA codec analog circuit.

Figure 6. Seven kinds of quantum DNA codec simulators encoded by Rule 1.

In this paper, we designed the quantum circuits of seven kinds of decoders with
scheme one as the coding scheme, and showed the process of transforming the same binary
sequence from scheme one to the other seven schemes. As shown in Table 1, the sequence
was first quantum DNA encoded according to scheme 1. If the second scheme is used for
Entropy 2023, 25, 865 7 of 16

decoding, it is necessary to reverse the two lines when the high qubits are different from the
low qubits, that is, to realize the interchange between C and G. If the third scheme is used
for decoding, it is necessary to reverse all the low qubits, that is, to realize the interchange
between A and C and between T and G. If we use scheme 4 to decode, we need to reverse
the high qubit and the low qubit at the same time and, if the high qubit is different from
the low qubit, we need to flip the low qubit. If we use scheme 5 to decode, contrary to
scheme 4, we need to flip high qubits when high qubits are different from low qubits, and
if high qubits and low qubits flip low qubits at the same time. If decoding is carried out in
scheme 6, each set of high qubits needs to be flipped. If we use scheme 7 to decode, when
the high qubit and the low qubit are all flipped, the interchange between An and T will be
realized. If we use scheme 8 to decode, it is necessary to reverse all the high and low qubits,
that is, to realize the interchange between A and T and between C and G.

3.2. Hilbert Image Scrambling Quantum Circuit


The Hilbert scrambling operation of quantum image was divided into three steps:
quantum image partition and Hilbert image scrambling parity operation, in which the
parity operation is carried out alternately. The composition of these three basic circuits is
described below. In this section, k is an integer and 0 ≤ k ≤ n − 1.

3.2.1. Initialization Module


The initialization quantum module is beneficial to the segmentation of the quantum
image and the formation of Hn , and the partition module PARTITION (K) plays a major role.
The PARTITION (k) module can divide the input image of size 2n × 2n into 2n−k−1 × 2n−k−1
blocks of size 2k+1 × 2k+1 ; the initialization module quantum circuit is shown in Figure 7a:

Figure 7. Initializing the quantum circuit. (a) implement the block function (b) implement the
scrambling function when k is odd (c) realize the scrambling function when k is even

3.2.2. Odd(k) Module


The main function of the Odd(k) module is to encrypt the pixel position information,
where k is odd and 1 ≤ k ≤ n − 1. The main role is the odd module O(k) in the Odd(k)
module. Figure 7b shows the complete quantum circuit of the O(k) module.

3.2.3. Even (k) Module


As with the function of the Odd(k) module, the function of the Even (k) module is
to transform the pixel position, where k is even and 2 ≤ k ≤ n − 1. Figure 7c shows the
complete Even (k) quantum circuit.

4. Encryption and Decryption of Quantum Images


Quantum image diffusion and scrambling are the two key components of this paper’s
encryption phase. At the diffusion step, the picture is made confusing by using DNA
coding and various decoding techniques, and the original image is quantum XOR coded.
The approach employs iterative Hilbert scrambling during the scrambling stage to encrypt
the image’s pixel location data.
Entropy 2023, 25, 865 8 of 16

4.1. Encryption Process


Using quantum Hilbert scrambling and DNA coding technology, we designed the
following quantum image encryption method. The original input quantum image size is
2n × 2n and the image representation is NCQI. The encryption flow chart is shown below.
Figure 8 shows the encryption process of Rule 1.

Figure 8. Algorithm flow chart applied to rule one.

Step 1: The pixel matrix of the original image is divided into three RGB channels, and
the NCQI representation model is loaded as a quantum image.

2n −1 2n −1
1
|ψ1 i =
2n ∑ ∑ |c(y, x )i ⊗ |yx i. (8)
y =0 x =0

Step 2: The quantum color image is encoded and decoded through the quantum image
DNA codec.
In the NCQI representation, the RGB color information will be input into the circuit
in binary form, so this paper used rule 1 in Table 1 to encode the binary sequence, and
then decodes the sequence according to rule 6, that is, the quantum image is input to the
quantum DNA codec, the D1,6 operation is performed, and the output is |ψ2 i.

|ψ2 i = D1,6 |ψ1 i. (9)

Step 3: Perform Hilbert quantum image scrambling with |ψ2 i iteration.


|ψ2 ihas 2n × 2n = 22n pixels, and if the original image pixel order is “1, 2, 3, 4, . . . , 22n ”,
the  PARTITION (0) will separate the picture into 2 × 2 sub-images, that is,
 partition module
a a+1
. The last two pixels of each sub-image are switched by the C-NOT gate,
a+2 a+3
which will separate the picture into 2 × 2 sub-images.
The partition module PARTITION (1) divides the image into sub-images of 4 × 4 and
so on, and operates in sequence O(1), E(2), O(3), E(4), . . . , O(n − 1)/E(n − 1) until it is
executed to PARTITION (n − 2).
Finally, the scrambled sub-image is restored to the original image size 2n × 2n and
named |ψ3 i.

|ψ3 i = Q2n |ψ2 i, (10)

where Q2n represents performing Hilbert quantum image scrambling on an image of size
2n × 2n .
Step 4: Between the original picture and the scrambled image, use quantum XOR coding.
Entropy 2023, 25, 865 9 of 16

Generate matrix YYX from the pixel color value of image |ψ1 i and convert each element
into an octet binary,

···
 
y0,0 y0,2n −1
YYX =  .. .. ..
, (11)
 
. . .
y2n −1,0 · · · y2n −1,2n −1

where yyx = m0yx m1yx m2yx . . . m23 i


yx , myx ∈ 0, 1. According to matrix YYX , the quantum XOR
operation matrix F is generated, which is the same as yyx ,byx = Vyx 0 V 1 V 2 . . . V 23 , where
yx yx yx
0 ∼ V 7 controls the R channel in the quantum circuit, V 8 ∼ V 15 controls the G channel,
Vyx yx ( yx yx

16 ∼ V 23 controls the B channel, V i = X, miyx = 1


and Vyx yx yx obtain image |ψ4 i.
I, miyx = 0
Step 5: Decode the image with different rules through the quantum image DNA codec
simulator.
|ψ4 i is encoded and decoded by quantum DNA codec, perform the D1,7 operation to
get |ψ5 i, and the encryption is completed.

|ψ5 i = D1,7 |ψ4 i. (12)

4.2. Decryption Process


The reversibility of quantum circuits serves as the foundation for the quantum image
decryption technique developed in this research. As a whole, the procedure is as follows:
Step 1: On the encrypted picture, peform the inverse quantum DNA coding and
decoding procedure.
The quantum circuit module of the DNA encoder and the quantum DNA codec D7,1
are both used to decrypt the encrypted picture to produce the result |ψ4 i.
Step 2: Inverse quantum XOR coding.

|ψ3 i = X5−1 |ψ4 i. (13)

Step 3: The quantum image is iterated to perform Hilbert inverse scrambling.


Because the biggest difference between the quantum circuit and the classical circuit is that
the quantum circuit is reversible, and there is no information loss in this process, the Hilbert
image scrambling quantum circuit in this paper is reversible. We can input the scrambled
image |ψ3 i and obtain the reconstructed image |ψ2 i using quantum Hilbert inverse scrambling.

|ψ2 i = Q2−n1 |ψ3 i. (14)

Step 4: Pass |ψ2 i through quantum DNA codec D6,1 to obtain the original image |ψ1 i.

|ψ1 i = D6,1 |ψ2 i. (15)

5. Safety Analysis
We performed simulation experiments in MATLAB and Python using classical com-
puters since there are no quantum computers available. We did not take into account the
impact of decoherence and inaccuracy in the quantum version while processing numerical
data. In order to examine the encrypted data in this part, three color pictures of pineapples,
roses, and plants with pixel sizes of 512 × 512 were utilized as the original image. The
following summarizes the encryption and decryption simulation findings. Figure 9 shows
the comparison of the results before and after the application of this algorithm.
Entropy 2023, 25, 865 10 of 16

Figure 9. Effect of encryption and decryption.

5.1. Histogram Analysis


One of the key indications needed to assess the security of encryption techniques is
the histogram, which may considerably reflect the intensity distribution of picture pixels.
The encrypted histograms of the three photos are shown in Figures 10–12.
In contrast to the non-uniform peak distribution of the plaintext histogram, which is
seen in the image, the peak value of the histogram encrypted by this approach becomes
uniform. As a result, the attacker is unable to obtain the picture data by studying the
ciphertext image’s histogram.

Figure 10. RGB three-channel histogram of pineapple before and after encryption.
Entropy 2023, 25, 865 11 of 16

Figure 11. RGB three-channel histogram of rose before and after encryption.

Figure 12. RGB three-channel histogram of plants before and after encryption.

5.2. Correlation Analysis of Adjacent Pixels


A crucial metric for determining the efficacy of the encryption technique is the correla-
tion between neighboring pixels. As there is a significant connection between neighboring
pixels in the original picture, a good encryption technique should minimize this correla-
tion to zero. In this study, we utilized this coefficient to compare the correlation between
neighboring pixels both before and after the method was applied

cov( x, y)
r= p , (16)
D ( x ) D (y)

where A and pB representp the values of adjacent pixels, cov( A, B) is the covariance of A
and B, and D ( A) and D ( B) are the variances of A and B. In this section, the pixel
correlation between the original image and the ciphertext image was analyzed horizontally,
Entropy 2023, 25, 865 12 of 16

vertically, and diagonally. The results are shown in Figures 13 and 14, and the specific data
are reflected in Tables 2 and 3, where C-Image represents the ciphertext image.
The suggested encryption technique clearly creates a sizable correlation gap between
the ciphertext picture and the original image based on the data shown in the chart, demon-
strating the algorithm’s effectiveness.

Pineapple

(a)

Rose

(b)

Plants

(c)
Figure 13. (a) Pineapple correlation analysis; (b) Rose correlation analysis; (c) Plants correlation analysis.

Table 2. Correlation analysis value of original image.

Image Channel Horizontal Vertical Diagonal


R 0.9849 0.9813 0.9833
Pineapple G 0.9753 0.9763 0.9588
B 0.9597 0.9550 0.9251
R 0.9835 0.9844 0.9753
Rose G 0.9651 0.9643 0.9466
B 0.9461 0.9446 0.9115
R 0.9539 0.9583 0.9256
Plants G 0.9556 0.9563 0.9238
B 0.9478 0.9540 0.9148

Table 3. Three-channel correlation analysis of ciphertext images.

Image Channel Horizontal Vertical Diagonal


R 0.0002 0.0045 0.0051
C-Pineapple G 0.0026 0.0012 0.0044
B 0.0037 0.0046 0.0029
R 0.0028 0.0049 0.0049
C-Rose G 0.0055 0.0023 0.0086
B 0.0034 0.0053 0.0014
R 0.0010 0.0081 0.0004
C-Plants G 0.0052 0.0043 0.0025
B 0.0057 0.0042 0.0033
Entropy 2023, 25, 865 13 of 16

Ciphertext image-
Pineapple

(a)

Ciphertext image-
Rose

(b)

Ciphertext image-
Plants

(c)
Figure 14. (a) Correlation analysis after pineapple encryption; (b) Correlation analysis after Rose
encryption; (c) Correlation analysis after plants encryption.

5.3. Key Sensitivity Analysis


Two words that are often used to characterize the quantity of pixels and the av-
erage intensity of change between the original picture and the ciphertext image are
NPCR and UACI. In accordance with the associated ideal value, the key sensitivity of the
NPCR = 99.6094%, UACI = 33.4635% algorithm should be as high as possible; the more
closely the numerical value resembles the ideal value, the stronger the security of the
encryption technique should be. The data for this method’s NPCR and UACI are shown
in Table 4. Table 5 compares our work numerically to the NPCR and UACI algorithms
that have been proposed in different papers. This indicates very clearly how much more
efficiently the technique used in this research can guarantee picture confidentiality.

Table 4. Three-channel average NPCR and UACI data.

Image RGB Average NPCR RGB Average UACI


C-Pineapple 99.6138% 33.4944%
C-Rose 99.6204% 33.5147%
C-Plants 99.6097% 33.5643%

Table 5. Comparison of information entropy of different algorithms.

Algorithm Average NPCR Average UACI


Proposed 99.61% 33.42%
Ref. [44] 99.61% 31.60%
Ref. [45] 99.57% 33.38%

5.4. Information Entropy


We often use information entropy to evaluate the unpredictability of the distribution
of ciphertext pictures. The ciphertext image’s pixels may be distributed evenly via a decent
picture encryption method, making the image more resistant to outside attacks. The perfect
information entropy is eight. The image encryption effect is better and the value is more
Entropy 2023, 25, 865 14 of 16

closely aligned with the ideal value as the pixel distribution becomes more uniform. The
information entropy of our recommended approach is shown in Table 6. The following
table provides ample proof of the algorithm’s strong security and robustness by showing
that the average information entropy of RGB’s three channels may reach 7.999.
Table 6. Information entropy data.

Ciphertext Image R G B
Pineapple 7.99925 7.99901 7.99921
Rose 7.99910 7.99930 7.99889
Plants 7.99922 7.99895 7.99912

5.5. Key Space


The modified picture serves as the key matrix in the encryption procedure described
in this research. The color picture is 512 × 512 in size, making its key space 2512×512×24
pixels, which is sufficient to stave against brute force assaults.

5.6. Scheme Reversibility Verification


Indicators used often to assess picture quality in the field of image processing include
peak signal-to-noise ratio (PSNR) and structural similarity (SSIM).

5.6.1. Peak Signal-to-Noise Ratio


To evaluate the image’s decryption quality, we employed PSNR. The floating-point
value that PSNR returns will range from 30 to 50 if the two input photos are comparable;
the higher the number, the greater the similarity. The PSNR values of plaintext pictures
and encrypted images with a size of 512 to 512 are larger than 30 dB, according to simu-
lation findings, and the average value is 43.4590. Table 7 displays the specific data. This
demonstrates the algorithm’s strong ability to aid in rebuilding.

5.6.2. Structural Similarity


The SSIM value ranges from 0 to 1. The value of SSIM increases with the degree
of similarity between the two photos. The picture acquired using the image decryption
approach suggested in this work was compared with the original image. Table 7 displays
the specific data. The average value of SSIM determined by the simulation results is
0.980358, which shows that the technology has an excellent decryption and recovery effect.
Table 7. Image similarity analysis.

Name PSNR SSIM


Pineapple 43.7358 0.982998
Rose 42.9974 0.979976
Plants 43.6438 0.978102
Average 43.4590 0.980358

6. Conclusions
Quantum image processing is committed to the use of quantum computing technology
to capture, restoration, and other classical image operations. Because of its exponential
storage capacity and parallelism, this technology has a strong advantage in realizing real-
time operations such as image retrieval and processing. In this paper, the circuit of a
quantum DNA codec was designed, and the image information was encrypted by using the
biological characteristics of DNA and the physical properties of quantum mechanics. At
the end of this article, the combination of DNA technology and quantum image encryption
was studied and verified. According to the simulation, average NPCR = 99.6094%, average
NPCR = 33.4244%, the average information entropy of RGB three channels is more than
7.999, and the average value of SSIM determined by the simulation results is 0.980358.
Entropy 2023, 25, 865 15 of 16

These results unmistakably demonstrate the viability and effectiveness of the quantum
picture encryption system presented in this research, which is based on DNA codec and
Hilbert scrambling.
In this encryption scheme, a quantum DNA codec was designed to enable the biologi-
cal field to participate in the quantum image encryption process. It is hoped that it can play
a greater role in the later research. In the follow-up work, we hope to combine quantum
random walk with DNA technology to realize the integration of physics and biology again.
This will be the focus of our next paper.

Author Contributions: Conceptualization, Y.W.; Methodology, J.G. and Y.W.; Software, Z.S.; Valida-
tion, Z.S.; Formal analysis, J.G.; Data curation, Z.S.; Writing—original draft, J.G.; Writing—review
& editing, J.G.; Visualization, J.G. and Y.W.; Supervision, Y.W. and S.W.; Project administration,
S.W.; Funding acquisition, S.W. All authors have read and agreed to the published version of
the manuscript.
Funding: This work was supported by the Natural Science Foundation of Shandong Province, China
(Grant Nos. ZR2021MF049), Joint Fund of Natural Science Foundation of Shandong Province (Grant
Nos. ZR2022LLZ012), Joint Fund of Natural Science Foundation of Shandong Province (Grant Nos.
ZR2021LLZ001), Project supported by the National Natural Science Foundation of China (Grant Nos.
11975132), National Natural Science Foundation of China (Grant Nos. 12005110) and the Natural
Science Foundation of Shandong Province, China (Grant Nos. ZR2022JQ04).
Institutional Review Board Statement: Not applicable.
Informed Consent Statement: Not applicable.
Data Availability Statement: The data are contained within the article.
Conflicts of Interest: The authors declare no conflict of interest.

References
1. Wang, Z.B.; Xu, M.Z.; Zhang, Y.N. Review of Quantum Image Processing. Arch. Comput. Methods Eng. 2022, 29, 737–761.
[CrossRef]
2. Nielsen, M.A.; Chuang, I. Quantum computation and quantum information. Am. J. Phys. 2002, 70, 558–559
3. Hardy, L. Quantum mechanics, local realistic theories, and Lorentz-invariant realistic theories. Phys. Rev. Lett. 1992, 68, 2981.
[CrossRef]
4. Hardy, L. Nonlocality for two particles without inequalities for almost all entangled states. Phys. Rev. Lett. 1993, 71, 1665.
[CrossRef]
5. Shor, P.W. Algorithms for quantum computatio: Discrete logarithms and factoring. In Proceedings of the 35th Annual Symposium
on Foundations of Computer Science, Santa Fe, NM, USA, 20–22 November 1994; pp. 124–134.
6. Grover, L.K. A fast quantum mechanical algorithm for database search. In Proceedings of the Twenty Eighth Annual ACM
Symposium on Theory of Computing, Philadelphia, PA, USA, 22–24 May 1996; pp. 212–219.
7. Ashikhmin, A.; Litsyn, S.; Tsfasman, M.A. Asymptotically good quantum codes. Phys. Rev. A 2001, 63, 032311. [CrossRef]
8. Ashikhmin, A.; Knill, E. Nonbinary quantum stabilizer codes. IEEE Trans. Inf. Theory 2001, 47, 3065–3072. [CrossRef]
9. Trugenberger, C.A. Probabilistic quantum memories. Phys. Rev. Lett. 2001, 87, 067901. [CrossRef]
10. Trugenberger, C.A. Phase transitions in quantum pattern recognition. Phys. Rev. Lett. 2002, 89, 277903. [CrossRef]
11. Venegas-Andraca, S.E.; Bose, S. Storing, processing, and retrieving an image using quantum mechanics. Quantum Inf. Comput.
2003, 5105, 137–147.
12. Klappenecker, A.; Rotteler, M. Discrete cosine transforms on quantum computers. In Proceedings of the 2nd International
Symposium on Image and Signal Processing and Analysis, Pula, Croatia, 19–21 June 2001; pp. 464–468.
13. Fijany, A.; Williams, C.P. Quantum wavelet transform: Fast algorithms and complete circuits. In Quantum Computing and Quantum
Communications; Springer: Berlin/Heidelberg, Germnay, 1999; pp. 10–33.
14. Beach, G.; Lomont, C.; Cohen, C. Quantum image processing (quip). In Proceedings of the 32nd Applied Imagery Pattern
Recognition Workshop, Washington, DC, USA, 15–17 October 2003; pp. 39–44.
15. Caraiman, S.; Manta, V.I. New applications of quantum algorithms to computer graphic: The quantum random sample consensus
algorithm. In Proceedings of the 6th ACM Conference on Computing Frontiers, Ischia, Italy, 18–20 May 2009 ; pp. 81–88.
16. Caraiman, S.; Manta, V.I. Image segmentation on a quantum computer. Quantum Inf. Process. 2015, 14, 1693–1715. [CrossRef]
17. Castleman, K.R. Digital Image Processing; Prentice Hall Press: Hoboken, NJ, USA, 1996.
18. Li, H.S.; Li, C.Y.; Chen, X.; Xia, H.Y. Quantum Image Encryption Algorithm Based on NASS. Int. J. Theor. Phys. 2018, 57, 3745–3760.
[CrossRef]
Entropy 2023, 25, 865 16 of 16

19. Li, H.S.; Li, C.Y.; Chen, X.; Xia, H.Y. Quantum image encryption based on phase-shift transform and quantum Haar wavelet packet
transform. Mod. Phys. Lett. A 2019, 34, 1950214. [CrossRef]
20. Yang, Y.G.; Xia, J.; Jia, X.; Zhang, H. Novel image encryption/decryption based on quantum Fourier transform and double phase
encoding. Quantum Inf. Process. 2013, 12, 3477–3493. [CrossRef]
21. Yan, F.; Iliyasu, A.M.; Venegas-Andraca, S.E. A survey of quantum image representations. Quantum Inf. Process. 2016, 15, 1–35.
[CrossRef]
22. Le, P.Q.; Dong, F.; Hirota, K. A flexible representation of quantum images for polynomial preparation, image compression, and
processing operations. Quantum Inf. Process. 2011, 10, 63–84. [CrossRef]
23. Zhang, Y.; Lu, K.; Gao, Y.H.; Wang, M. NEQ: A novel enhanced quantum representation of digital images. Quantum Inf. Process.
2013, 12, 2833–2860. [CrossRef]
24. Sun, B.; Iliyasu, A.; Yan, F.; Dong, F.Y.; Hirota, K. An RGB multi-channel representation for images on quantum computers. J. Adv.
Comput. Intell. Intell. Inform. 2013, 17, 404–415. [CrossRef]
25. Li, H.S.; Zhu, Q.X.; Zhou, R.G.; Lan, S.; Yang, X.J. Multi-dimensional color image storage and retrieval for a normal arbitrary
quantum superposition state. Quantum Inf. Process. 2014, 13, 991–1011. [CrossRef]
26. Li, H.S.; Zhu, Q.X.; Lan, S.; Shen, C.Y.; Zhou, R.G.; Mo, J. Image storage, retrieval, compression and segmentation in a quantum
system. Quantum Inf. Process. 2013, 12, 2269–2290. [CrossRef]
27. Zhang, Y.; Lu, K.; Gao, Y.H.; Xu, K. A novel quantum representation for log-polar images. Quantum Inf. Process. 2013, 12, 3103–3126.
[CrossRef]
28. Zhang, J.L.; Huang, Z.J.; Li, X.; Wu, M.Q.; Wang, X.Y.; Dong, Y.M. Quantum Image Encryption Based on Quantum Image
Decomposition. Int. J. Theor. Phys. 2021, 60, 2930–2942. [CrossRef]
29. Zhou, N.R.; Hu, Y.Q.; Gong, L.H.; Li, G.Y. Quantum image encryption scheme with iterative generalized Arnold transforms and
quantum image cycle shift operations. Quantum Inf. Process. 2017, 16, 164. [CrossRef]
30. Adleman, L.M. Molecular computation of solutions to combinatorial problems. Science 1994, 266, 1021–1024. [CrossRef]
31. Leier, A.; Richter, C.; Banzhaf, W.; Rauhe, H. Cryptography with DNA binary strands. Biosystems 2000, 57, 13–22. [CrossRef]
32. Chang, W.L.; Guo, M.Y.; Ho, M.S.H. Fast parallel molecular algorithms for DNA-based computatio. factoring integers. IEEE Trans.
Nanobiosci. 2005, 4, 149–163. [CrossRef]
33. Basu, S.; Karuppiah, M.; Nasipuri, M.; Halder, A.K.; Radhakrishnan, N. Bio-inspired cryptosystem with DNA cryptography and
neural networks. J. Syst. Archit. 2019, 94, 24–31. [CrossRef]
34. Alghafis, A.; Firdousi, F.; Khan, M.; Batool, S.I.; Amin, M. An efficient image encryption scheme based on chaotic and Deoxyri-
bonucleic acid sequencing. Math. Comput. Simul. 2020, 177, 441–466. [CrossRef]
35. Liu, Y.; Zhang, J.D. A Multidimensional Chaotic Image Encryption Algorithm based on DNA Coding. Multimed. Tools Appl. 2020,
79, 21579–21601. [CrossRef]
36. Wang, X.Y.; Zhang, Y.Q.; Bao, X.M. A novel chaotic image encryption scheme using DNA sequence operations. Opt. Lasers Eng.
2015, 73, 53–61. [CrossRef]
37. Zhang, X.Q.; Wang, X.S. Multiple-image encryption algorithm based on DNA encoding and chaotic system. Multimed. Tools Appl.
2019, 78, 7841–7869. [CrossRef]
38. Wang, Y.N.; Song, Z.Y.; Ma, H.Y. Color image encryption algorithm based on DNA code and alternating quantum random walk.
Acta Phys. Sin. 2021, I, 230302. [CrossRef]
39. Sang, J.Z.; Wang, S.; Li, Q. A novel quantum representation of color digital images. Quantum Inf. Process. 2017, 16, 42. [CrossRef]
40. Arnold, V.I.; Avez, A. Ergodic Problems of Classical Mechanics; Benjamin: Amsterdam, The Netherlands, 1968; Volume 9.
41. Wang, S.; Xu, X.S. A new algorithm of Hilbert scanning matrix and its MATLAB program. J. Image Graph. 2006, 11, 119–122.
42. Jiang, N.; Wang, L.; Wu, W.Y. Quantum Hilbert Image Scrambling. Int. J. Theor. Phys. 2014, 53, 2463–2484. [CrossRef]
43. Gong, L.H.; He, X.T.; Zhou, N.R. Quantum Image Encryption Algorithm Based on Quantum Image XOR Operations. Int. J. Theor.
Phys. 2016, 55, 3234–3250. [CrossRef]
44. Vagish, K.D.; Rajakumaran, C.; Kavitha, R. Chaos based encryption of quantum images. Multimed. Tools Appl. 2020, 79,
23849–23860.
45. Li, C.; Yang, X.Z. An image encryption algorithm based on discrete fractional wavelet transform and quantum chaos. Optik 2022,
260, 169042. [CrossRef]

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.

You might also like