1 Introduction
With the evolution of technology, random generators, which exhibit random behavior, have become very important in different fields. However, generators that have perfect randomness are not widely used due to their high cost and slow performance
[1]. To solve these problems, random generators are replaced by pseudo-random generators, which produce deterministic sequences based on mathematical formulas, achieving excellent randomness and statistical properties similar to white noise
[2-6]. These generators are widely used in many fields such as satellites
[7], digital information processing systems
[8], and cryptography
[9], where pseudo-random sequences are used for generating secret keys, authentication, ensuring confidentiality, and information integrity.
There are many methods to construct pseudo-random sequences, such as the m-sequence and the gold-sequence
[10, 11]. However, these methods have low complexity and are not suitable for cryptography, due to their limited speed of creation. In recent years, another method based on chaotic systems has been used to generate a pseudo-random sequence with excellent performance.
Chaotic systems are generated by deterministic equations and have several advantages in generating random sequences, such as sensitivity to small changes in initial conditions, non-periodicity, and unpredictability
[12]. There are two types of chaotic systems: continuous chaotic systems and discrete chaotic systems. Recent studies have focused on proposing new hyperchaotic systems, which have better random behavior and can effectively improve the security of pseudo-random sequences compared to classical chaotic systems. In recent studies, several methods have been proposed to generate pseudo-random sequences based on hyperchaotic systems
[13-16].
In this paper, a new pseudo-random sequence generation method is proposed based on two chaotic systems, the logistic map, and a seven-dimensional (7D) hyperchaotic system. Firstly, the logistic map generates a variable in each iteration, which is adjusted to ensure its values are between 1 and 7. Then, this variable is used to select one variable from the 7D hyperchaotic system. Secondly, the selected variable is modified to fill the pseudo-random sequence with one of the remaining six variables of the 7D hyperchaotic system. Thirdly, the two steps are repeated times (depending on the needs of the application) to obtain the pseudo-random sequence.
Based on the above information, the proposed algorithm has the following advantages. 1) The proposed pseudo-random sequence is generated using a 7D hyperchaotic system, which means that the sequence is highly sensitive to the initial conditions, similar to the 7D hyperchaotic system. 2) The processes for generating the pseudo-random sequence from the 7D hyperchaotic system are simple and do not require a lot of hardware. 3) Since the proposed pseudo-random sequence is generated using a 7D hyperchaotic system, the generator exhibits the random behavior of both the 7D hyperchaotic system and the proposed method. 4) The proposed pseudo-random generator does not have a limit on the number of bits it can generate, allowing it to produce bits according to the specific needs of the application it is implemented in.
The remainder of the paper is organized as follows: Section 2 introduces the methods used in this paper. Section 3 describes the empirical research (the proposed pseudo-random generator). Section 4 provides the analysis results and discussion. Finally, conclusions are given in Section 5.
2 Methods
2.1 Logistic Map
The logistic map is one of the simplest discrete, dynamic, non-linear systems
[17]. It is defined as follows:
where,
represents the initial condition,
the parameter coefficient, and
signifies the number of iterations.
Figure 1 shows the bifurcation of the logistic map. It demonstrates that the logistic map has chaotic behavior when
is close to
.
Figure 1 Logistic map bifurcation diagram |
Full size|PPT slide
Figure 2 shows the difference between two signals when a small change occurs in the initial state. The first signal is obtained with an initial condition
, while the second signal is obtained with an initial condition
. It is observed a slight error in the initial condition results in two distinct signals.
Figure 2 Logistic map with two different initial conditions |
Full size|PPT slide
2.2 7D Hyperchaotic System
In 2019, Yu, et al.
[13] proposed a new seven-dimensional (7D) hyperchaotic system, which is described by
where
are the system state variables,
, and
are the system parameters. When
, and
; the 7D hyperchaotic system is in a chaotic state, and for the initial condition
, the Lyapunov exponents of the hyperchaotic system are:
,
,
The phase diagrams of the 7D hyperchaotic system are shown in
Figure 3, where (a), (b), (c), (d), (e) and (f) correspond to the phase diagrams of the attractors for
, and
respectively.
Figure 3 Phase diagram of 7D hyperchaotic system: (a) ; (b) ; (c) ; (d) ; (e) ; (f) |
Full size|PPT slide
Based on the above analyses, the 7D hyperchaotic has the following advantages: First, two of the Lyapunov exponents of the hyperchaotic system are greater than zero. Second, the dynamic behavior of the 7D hyperchaotic system (shown in
Figure 3) is more complex, with phase trajectories separated in multiple directions. As a result, the 7D hyperchaotic system demonstrates effective random generation capabilities.
3 Empirical Research
The proposed pseudo-random generator is obtained from the logistic map and the 7D hyperchaotic system, and the detailed steps are as follows:
● Step 1: The logistic map is iterated times (where is the number of values needed from the pseudo-random generator) with the initial values . Then, to avoid the transient, the first values from the logistic map are abandoned.
● Step 2: The 7D hyperchaotic is iterated times with initial values and , Then, the first values from each of the seven sequences are abandoned to obtain the sequences and with length .
● Step 2: The sequence from step 1 (logistic map sequence) is used as the initial controller for the pseudo-random generator. At each iteration, a new parameter is calculated using a variable of the logistic map sequence as follows
where mod is the modular operator, and gives the greatest integer less than or equal to .
● Step 3: The values of the parameter range between one and seven, determining the selection of a variable from the 7D hyperchaotic system at each iteration. If is equal to one , the selected value is taken from the first sequence . If is equal to two , the selected value is taken from the second sequence . If is equal to three , the selected value is taken from the third sequence. If is equal to four , the selected value is taken from the fourth sequence . If is equal to five , the selected value is taken from the fifth sequence . If is equal to six , the selected value is taken from the sixth sequence . If is equal to three , the selected value is taken from the last sequence . The resulting values are stored in the parameter .
● Step 4: A new parameter is calculated using the parameter as follows
● Step 5: The values of the parameter range between one and six, determining the selection of a variable from the 7D hyperchaotic system at each iteration to fill the pseudo-random sequence.
● Step 6: For example, if the variable selected in step 3 is , it means that the pseudo-random sequence is filled with a value from the other six variables of the 7D hyperchaotic system and ). The value of parameter determines which sequence fills the pseudo-random sequence. If is equal to one , the pseudo-random sequence is filled by one value from the second sequence . If is equal to two , the pseudo-random sequence is filled by one value from the third sequence . If is equal to three , the pseudo-random sequence is filled by one value from the fourth sequence . If is equal to four , the pseudo-random sequence is filled by one value from the fifth sequence . If is equal to five , the pseudo-random sequence is filled by one value from the sixth sequence . If is equal to seven , the pseudo-random sequence is filled by one value from the last sequence .
● Step 7: Steps 2 to 6 are repeated times to obtain the desired pseudo-random sequence.
4 Result Analysis
This section presents the results of simulations implemented using Matlab 2010 on a 64-bit computer with an Intel (R) Core (TM) i3 CPU @2.13 GHZ with 4.00 Go RAM and Microsoft Windows 7 operating system.
4.1 Analysis Results and Discussion of the Proposed Generator
The initial condition of the logistic map is
and the initial conditions of the 7D hyperchaotic system used are
$ x_0=0.12,y_0=0.38,z_0=0.22,w_0=0.54,u_0=0.43,p_0=0.51, $ and
, with
To evaluate the performance of the proposed pseudo-random generator, several tests proposed by NIST (the National Institute of Standards and Technology) are used
[18]. These tests include entropy, frequency, mean, variance, autocorrelation factor, and spectral tests. To apply these tests to our pseudo-random generator, the values of the pseudo-random sequence
are modified as follows
4.1.1 Entropy
The entropy test is an important metric used to measure the amount of information in a data source, and it can be measured by
[19]
where
represents the possible number of states in a sequence,
and
is the frequency of occurrence of each state. This test evaluates the probability of each value occurring in the sequence, and a good random generator should have equal probabilities, which correspond to the ideal value. The entropy test is used in this paper to evaluate the sequences
(Equation (4)),
(Equation (6)), and
(Equation (7)) and it is listed in
Table 1.
Table 1 Entropy values of the proposed generator |
Sequences | Logistic map sequence c1 | Selected variable c2 | Pseudo-random sequence S |
Entropy | 2.8073020 | 2.5849165 | 7.9981 |
Ideal values | 2.8073549 | 2.5849625 | 8 |
% For ideal value | 99.998% | 99.998% | 99.976% |
In the parameter (the logistic map sequence), equals 7 (there are 7 possible states from 1 to 7). If all these states occur with equal frequency, the entropy value equals , which is the ideal value in this case. The entropy value of the parameter c1 in our proposed pseudo-random generator is , which is very close to the ideal value. Therefore, we can conclude that the parameter is sampled from the seven variables of the 7D hyperchaotic system with equal frequency.
In the sequence (the selected variable), equals 6 (there are 6 possible states from 1 to 6). If all these states occur with equal frequency, the entropy value equals , which is the ideal value in this case. The entropy value of the sequence in our proposed pseudo-random generator is , which is very close to the ideal value. Therefore, we can conclude that the pseudo-random generator is filled from the six sequences of the 7D hyperchaotic system with equal frequency.
In the sequence (the pseudo-random sequence), equals 256 (there are 256 possible states from 0 to 255). If all these states have the same frequency, the entropy value equals which is the ideal value in this case. The entropy value of the sequence in our proposed pseudo-random generator is 7.9981, indicating that the sequence has a ratio of of a source that contains an equiprobable frequency. Therefore, the proposed pseudo-random generator passes the entropy test.
4.1.2 Frequency
One of the standard tests to evaluate the pseudo-random generator is the frequency test, where a good pseudo-random sequence must have a uniform distribution among its values, meaning that the values within the sequence occur with nearly equal frequency
[20].
Figure 4 shows the frequency distribution of values in the sequence
.
Figure 4 Frequency of the pseudo-random sequence |
Full size|PPT slide
As can be seen in
Figure 4, it is observed that all values (0 to 255) have approximately equal frequency. Therefore, our proposed pseudo-random generator passes the frequency test.
4.1.3 Mean, Variance, and Autocorrelation Factor Tests
The simplest tests to evaluate the distribution of numbers in the pseudo-random generator are the mean, variance, and autocorrelation factors. These tests consist of calculating the mean
, variance
, and autocorrelation factor of the pseudo-random sequence, defined as follows
[20]:
where
, and
is the largest value in the sequence. The ideal values for a good pseudo-random sequence are
, and
, for the mean, variance, and autocorrelation factor, respectively.
Figure 5 gives the results of calculating the mean, variance, and autocorrelation factor of the proposed pseudo-random sequence.
Figure 5 Mean, variance, and autocorrelation factor tests of the pseudo-random sequence |
Full size|PPT slide
From
Figure 5, we can see that the results of the mean, variance, and autocorrelation factor tests of our pseudo-random sequence are close to the ideal values. Therefore, the proposed pseudo-random generator has good random behavior.
4.1.4 Spectral Test
The spectral test is an important metric used to assess the quality of a random generator, and it is considered the most powerful known test. It involves studying the distribution of values created by the pseudo-random generator in different dimensional spaces, such as two dimensions (2D) and three dimensions (3D)
[19]. In 2D, each pair of consecutive values represents the coordinates of a point in space, while in 3D, each triplet of consecutive values represents the coordinates of a point in space. For a good random generator, the points should be uniformly distributed in a square in 2D and uniformly distributed in a cube in 3D.
Figures 6 and
7 show the 2D and 3D distributions of our pseudo-random sequence, respectively.
Figure 6 2D distribution of the pseudo-random sequence |
Full size|PPT slide
Figure 7 3D distribution of the pseudo-random sequence |
Full size|PPT slide
From
Figures 6 and
7, we can see that the points are uniformly distributed in a square for 2D and a cube for 3D. Therefore, the proposed pseudo-random generator passes the spectral test.
4.1.5 Computational Complexity
The speed of bit production is an important metric for any pseudo-random generator. To evaluate the time required to generate the proposed pseudo-random sequence, the quantity of bits generated per second is listed in
Table 2 and compared with recent works.
Table 2 Quantity of bits produced per second by different generators (unit: Mbit) |
Generator | Proposed | [21] | [22] | [23] |
Quantity of Bits | 28.43 | 21.50 | 14.48 | 3.89 |
From
Table 2, it can be observed that the proposed generator can achieve a higher bits per second output compared to the recent works.
4.1.6 Analysis of the Choice of Initial Conditions
To determine how the initial conditions of the chaotic system can affect the proposed generator, a modification is applied to the initial condition of the logistic map
to generate the pseudo-random sequence. Moreover, another modification is applied to one initial condition of the 7D hyperchaotic system
. The three results (initial conditions without modification, modification in the logistic map, and modification in the 7D hyperchaotic system) are then tested using the spectral test (
Figure 8).
Figure 8 Spectral test using different initial conditions |
Full size|PPT slide
From
Figure 8, it can be observed that small changes in the initial conditions produce completely different sequences, which means that the proposed generator performs well in applications where a sensitive pseudo-random generator, such as cryptography, is needed.
4.2 Application of the Proposed Generator
In this paper, the proposed pseudo-random generator is used for encrypting images using a stream cipher. The proposed generator creates a sequence of values corresponding to the number of pixels in the image, and then each pixel is XORed with a value from the pseudo-random sequence to obtain the encrypted image (
Figure 9).
The encryption key in this paper consists of
$ L_0=0.1,\mu=3.9999,x_0=0.12,y_0=0.38,z_0=0.22,w_0=0.54, u_0=0.43,p_0=0.51, $ and
. The plain images used are "Lena", and "Cameraman" both sized
pixels, and the encrypted images are shown in
Figure 10.
Figure 10 Plain and encrypted images |
Full size|PPT slide
From
Figure 10, it is shown the encrypted images appear visually identical and do not give any visual information about the plain images.
4.3 Histogram
The histogram metric illustrates the distribution of pixel values in an image. The pixel distribution in plain images is uneven. While in cipher images, pixel distribution should be uniform
[24].
Figure 11 shows the histograms of both plain and cipher images.
Figure 11 Histogram of (a) plain images, (b) cipher images |
Full size|PPT slide
From
Figure 11, it is observed that the histograms of the cipher images differ significantly from those of the plain images, and the pixel distribution in the cipher images is almost uniform, indicating that statistical analysis of the histogram in the cipher images cannot give any information about plain images. Therefore, the proposed algorithm exhibits resistance against statistical attacks.
4.3.1 Correlation Coefficients Analysis
The correlation between pixels is an important index in images. In plain images, pixel correlation is strong, and in a good encrypted image, this correlation should be reduced as possible. The correlation coefficient
between adjacent pixels,
and
is defined as follows
[25]
where
and
are the expectation and variance of the variable
, respectively. The correlation value ranges between
and
. A correlation close to
or
indicates a high correlation between the pixels, while a correlation close to
indicates a weak correlation between the pixels. By randomly picking up
pairs of adjacent pixels from plain images and their corresponding encrypted images in the horizontal, vertical, and diagonal directions, the pixel distributions are shown in
Figure 12. Moreover, the correlation coefficients are listed in
Table 3.
Figure 12 Correlation between pixels in horizontal, vertical, and diagonal directions for (a) Plain image, (b) encrypted image |
Full size|PPT slide
Table 3 Correlation coefficients of different images |
Images | Plain Image | | Cipher Image |
Horizontal | Vertical | Diagonal | | Horizontal | Vertical | Diagonal |
Lena | 0.9412 | 0.9699 | 0.9155 | | | | |
Cameraman | 0.9335 | 0.9592 | 0.9087 | | 0.0016 | 0.0048 | |
From
Figure 12 and
Table 3, we can see that most pixels in the plain image lie along the same line, indicating a strong relationship between adjacent pixels. On the other hand, in the encrypted image, the pixels are randomly distributed in space, indicating a weak correlation between adjacent pixels. Moreover, the coefficients of the encrypted images are close to zero, indicating a lower correlation between adjacent pixels in these images.
4.3.2 Information Entropy
In grayscale images, the pixels are encoded with 8 bits, which means that the ideal entropy value for images is 8. The entropy values for different plain images and their corresponding encrypted images are given in
Table 4.
Table 4 Information entropy of different images |
Images | Plain Image Entropy | Encrypted Image Entropy | % For Ideal Value |
Lena | 7.4442 | 7.9977 | 99.971% |
Cameraman | 7.2972 | 7.9967 | 99.959% |
From
Table 4, we can see that the entropy values are close to the ideal value (8), which means that the encrypted images can resist entropy attacks.
5 Conclusion
This paper introduces a new pseudo-random generator based on two chaotic systems: the logistic map and a 7D hyperchaotic system. The pseudo-random sequence is obtained using two controllers: the first controller is the logistic map, and the second controller is a variable from the 7D hyperchaotic system. The main advantage of the pseudo-random is its ability to generate bits according to the needs of the application without a limit on the number it can produce. The values of the sequence obtained by the logistic map are modified to select one variable from the seven variables. The results show that the seven variables are used approximately with equal frequency. Moreover, the selected values are modified to choose one variable from the remaining six variables of the 7D hyperchaotic system to fill the pseudo-random sequence. The results show that these six variables are used approximately with the same frequency in filling the pseudo-random sequence. The simulation results and performance analyses show that our pseudo-random generator has good random behavior and passes several NIST tests, including entropy, frequency, and distribution of values. Therefore, the proposed pseudo-random generator can be effectively used in different fields, such as cryptography.
{{custom_sec.title}}
{{custom_sec.title}}
{{custom_sec.content}}