# Characterization of a Quantum Random Number Generator Based on Vacuum Fluctuations
## 4 Results and Discussion
### Randomness Validation  
To complement the validation of the implemented QRNG, a sample size of 6.8 Gbit was subjected to three state-of-the-art suites of randomness tests: the TestU01's _SmallCrush_ library [46], [PERSON] test battery [47], and NIST SP 800-22 statistical suite [48]. These results are, respectively, represented in Tables A1-A3 for data subjected to both random extractors. As can be seen, the output of both extractors passes the majority of statistical tests, which shows the effectiveness of the post-processing stage and is an excellent indicator of quality for the implement generator. No discernible difference was identified between the quality of the hashed variants. Nonetheless, the SHA-512 extractor implementation is  
Figure 8: Assessment of (**a**) the electronic to total entropy ratio and (**b**) effective entropy that can be extracted in each sample for multiple sequence lengths. significantly faster. However, in the NIST statistical suite (Table A3), it should be mentioned the failure of the _OverlappingTemplate_ test. As described in [48], this test detects deviations in the expected number of occurrences of a given bit pattern \(B\) with a certain length \(m\). With this objective, each bit sequence was divided into substrings of 1032 bit and a 1-bit sliding window was used to search for a 9-bit run of ones. Streams with too many or too few occurrences of 9-bit runs of ones will conclusively be rejected with a \(p\)-value \(\leq 0.01\). For multiple runs of the test, a uniform distribution of \(p\)-values is expected to occur, and a minimum of 488 runs must pass. In the _OverlappingTemplate_ test, only 484 sequences satisfied this condition for the SHA-512 extractor variant. Conversely, 487 sequences passed this evaluation with the Toeplitz extractor, which indicates a marginally better result. A similar result can be seen in the distribution of \(p\)-values represented in Figure 9,b for the SHA-512 and Toeplitz-hashed variants, respectively. Here, the former clearly shows a more pronounced deviation from a uniform distribution, with 20.6% of the values contained between \([0,0.1]\). Yet, the failure of both data variants is significant as it implies a flaw in the entropy source, entropy evaluation, or the randomness test itself, and not in the implementation of a particular randomness extractor. Consequently, although a conclusive reason for the observed result is difficult to give, a more extensive characterization of the entropy source and the raw output should be made to assess any potential correlations. This result may yet originate in undetected correlations induced by the TIA, or in some excess noise not properly accounted for, which leads to an overestimation of the available entropy and a reduction in the statistical distance to a uniform distribution. Additionally, the abnormal runs of ones can originate in the relatively small number of unique 4-bit sequences output by the generator. In the meantime, this problem may be mitigated by restricting the use of the output of this QNRG implementation as a seed to a cryptographically secure PRNG. In this way, the presence of some bias, namely the yielding of an abnormal frequency of 9-bit sequences of ones (and consequently of zeros), is detected. Given these results, we are forced to reject the hypothesis that the QRNG yields an output arbitrarily close to a uniform distribution, although this does not imply the absence of useful randomness or that the output is periodic. In fact, the implementation successfully passes a significant majority of the evaluations, including the other randomness test suites, which highlights its viability as a randomness source. As a complementary analysis, we calculated the correlation coefficients from all data variants, including the raw unprocessed variant where only the binning process was applied.