## 2 Study of Used Discrete Chaotic Maps: Statistical Test and Hardware Metrics
### Statistical Performance: NIST, Histogram, and Chi-Square Test  
**NIST statistical test**  
The NIST test is widely considered one of the most effective standards for evaluating the randomness of binary data [37]. This test is a statistical package consisting of 188 proposed tests and sub-tests (15 different tests in total) for evaluating the randomness of binary sequences of arbitrary length. These tests focus on different kinds of non-randomness that can be present in sequences. A \(p\)-value is calculated for each test to show the results of the test. A \(p\)-value \(\geq\) 0.01 indicates that the sequence was considered random with 99% confidence. A \(p\)-value \(\leq\) 0.01 implies the conclusion that the sequence is not random with 99% confidence.  
Figure 1: Circuit Diagram of 32-bit (internal feedback) LFSR.  
**Histogram and Chi-square test analysis**  
Another key property of any robust pseudo-chaotic number generator is to provide a uniform distribution in the whole phase space. To assert the uniformity of generated sequences, it is necessary to apply on them the chi-square test \(\chi^{2}\) given by the following formula:  
\[\chi^{2}_{exp}=\sum_{i=0}^{N_{c}-1}\frac{\left(O_{i}-E_{i}\right)^{2}}{E_{i}} \tag{6}\]  
where \(N_{c}=1000\) represents the number of classes, \(O_{i}\) represents the number of calculated samples in the \(ith\) class \(E_{i}\), where the class \(E_{i}\) is the expected number of samples of a uniform distribution, which is equal to \(N_{S}/N_{c}\).  
To confirm the uniformity of a produced sequence, the experimental chi-square value must be smaller than the theoretical value \(\chi^{2}_{exp}<\chi^{2}_{th}\). Furthermore, if the experimental chi-square value is less than the theoretical one, the resulting sequence is more uniform.  
At the top of Figure 2a-f, from left to right, we present the proportion achieved versus the test for the discrete Logistic map, Skew-Tent map, PWLCM, 3D-Chebyshev map, 32-bit LFSR, and 3D-Chebyshev map coupled with a 32-bit LFSR respectively (see Figure 3). As we can see, the sequences generated by the discrete chaotic maps alone and the 32-bit LFSR do not successfully pass all NIST tests, and some are far from the acceptance criterion of a test indicated by the red line. In addition, we note that the PWLCM map outperforms the other chaotic maps studied, in terms of several tests passed. Moreover, obtained results for the generated sequences by the coupled 3D- Chebyshev map with the 32-bit LFSR show that all NIST tests, except the Block-frequency test, have passed, demonstrating that the coupled technique with the 32-bit LFSR improves the cryptographic properties of the 3D-Chebyshev map (this is true for any type of chaotic map).  
Figure 2: NIST test and histograms of studied chaotic maps, 32-bit LFSR, and the 3D-Chebyshev coupled with the 32-bit LFSR. (**a**) NIST test results of the discrete Logistic map. (**b**) NIST test results of the discrete Skew-Tent map. (**c**) NIST test results of the discrete PWLCM map. (**d**) NIST test results of the discrete 3D-Chebyshev map. (**e**) IST test results of the 32-bit LFSR. (**f**) NIST test results of the discrete 3D-Chebyshev map coupled with LFSR. (**g**) The histogram of a sequence \(XL\). (**h**) The histogram of a sequence \(XS\). (**i**) The histogram of a sequence \(XP\). (**j**) The histogram of a sequence \(XT\). (**k**) The histogram of a sequence \(Q\). (**l**) The histogram of a sequence \(XT\).  
At the bottom of Figure 2g-l, we give the corresponding histogram for each chaotic map, the 32-bit LFSR, and the coupled 3D-Chebyshev map with the 32-bit LFSR. We notice that, visually, the histograms obtained by the chaotic maps are not uniform, except for the 32-bit LFSR and the discrete 3D-Chebyshev coupled with the 32-bit LFSR. This observation is asserted by the obtained experimental and theoretical results of the chi-square tests given in Table 1.