1. Introduction
Random numbers are essential to cryptography, simulation (Monte Carlo [
1], protein molecule dynamics [
2], and other physical systems that require true randomness), secure communications and quantum key distribution. Classical random number generators are inherently deterministic and rely on algorithmic complexity. In contrast, quantum mechanics provides intrinsic unpredictability. Solid-state QRNG platforms are desirable for room-temperature operation, chip-scale integration and long-term stability.
The oldest QRNG implementations were based on radioactive decay, and they have decreased in popularity due to low bit rate and necessity for radioactive materials [
3]. Noise in electronic circuits is another implementation of QRNG, but they suffer from the issue that it is difficult to separate quantum flicker noise from thermal noise and can show memory effects [
4]. Most QRNG platforms are based on quantum optics and benefit from the relative affordability of optical devices [
5]. In contrast to NV center-based QRNG implementations, a large class of modern QRNG systems relies on internal physical noise sources such as vacuum fluctuations, amplified spontaneous emission, or laser phase noise [
6]. These approaches convert intrinsic fluctuations in optical or electronic fields into random numbers and can achieve significantly higher generation rates, ranging from Mbps to Gbps in integrated photonic platforms [
7,
8,
9]. While these approaches provide high throughput, they often rely on indirect entropy sources and require careful modeling and calibration of classical noise contributions, motivating interest in physically well-defined single-photon emitters such as NV centers.
The nitrogen-vacancy (NV) center in diamond (point-like defects in a carbon lattice) is a robust, optically addressable quantum system exhibiting spin-dependent fluorescence, single-photon emission and long coherence times at room temperature [
10]. For an NV center, the vacancy (V) is surrounded by three carbon atoms and a carbon atom-substituting nitrogen atom (N) that can be located in one of the four possible positions (directions); see
Figure 1. Diamond is a compact, physically and chemically robust as well as non-toxic platform, capable of operating in harsh environments with high pressure of up to 60 GPa and temperatures ranging from cryogenic temperatures to 600 K [
11]. In this work we investigate both ensemble and single-emitter NV-based QRNG implementations and analyze their statistical performance.
NV centers in diamond have been used for QRNG in previous studies as single-photon sources also in combination with a beamsplitter, achieving about 34 randomly generated bits per second [
12]. In this study we quantify the nanostructure effect on the quality of the generated bit randomness.
2. Principles of Randomness
We looked at two randomness extraction methods in this study: a time-of-arrival method [
13] and a beamsplitter method [
14].
The time-of-arrival method allows us to create random bits by separating our data in discrete bins. We choose a set time bin width
, which will be used to extract random bits from the time of arrival data. Once the time scale has been discretized, we need to check if a photon detection event has occurred. If a single or many events occurred in the chosen interval then we set that bin’s value to “1”, and if no events occurred, to “0”. By doing this, we get a random binary sequence. The width of the time bin comes from Poisson distribution (
1) when choosing the highest variation.
The value
is defined as the total events per time interval and can be calculated as the total photon count
N over the full time scale
t (in the case of the data presented here,
varies depending on the red photon flux, on the order of tens of kilo-counts per second).
The width we can define as , where n is the expected counts per bin. Since we want to get the highest order of variance, we set , from which we will get . Since both and n are known, we can calculate the optimal . Since the parameter dynamically changes per data set, we cannot choose one single bin width. In most cases the average bin width for the measured data sets was determined to be 45 μs (optimizing for the lowest bias in the results). As the binning aggregates detection events over finite time intervals, it is possible that it can induce correlations due to detector dead time, afterpulsing, or slow system fluctuations (we did not evaluate whether the binning procedure introduced temporal correlations in the generated bit sequences in the scope of this study).
Quantum mechanics guarantees that when a photon hits a balanced beamsplitter, the outcome—the photon is transmitted or reflected—is intrinsically random. No hidden variables or classical mechanisms determine the result. This physical process gives a natural 1-bit random variable: detector A clicks—output 0; detector B clicks—output 1. Quantum mechanics describes the output state as a superposition:
This superposition collapses only when the photon is detected. Because quantum mechanics dictates that the photon cannot “decide” the path beforehand, each bit is fundamentally unpredictable.
3. Experimental Setup
We constructed a table-top confocal microscope experimental setup for locating single NV centers in diamonds (see
Figure 2)—a device prototype for quantum random number generation. In a confocal system, both a physical pinhole and a single-mode optical fiber can act as the spatial filter that improves Z-resolution. We used a single-mode optical fiber [
15] instead of a pinhole [
16] for confocal microscopy due to the fact that a pinhole is more prone to mechanical drift sensitivity, slight misalignment degrades resolution, and it does not spatially filter mode structure. A single-mode fiber provides better spatial filtering (higher contrast), excellent background rejection, improved signal stability and mode cleaning. The output from the optical fiber is sent to a Hanbury Brown–Twiss setup—a 50:50 beamsplitter [
17].
To excite the NV centers in diamond, a 532 nm green laser (Verdi V18 by Coherent)) was operated at 1.0 W output power with a plate polarizer (PBSW-532 by Thorlabs) placed in the path of the laser beam at a slight angle to divert away any back reflections from the laser output aperture coming from the rest of the experimental setup, and the laser power after the plate polarizer was 10 mW. Free-space mirrors were used to guide the light to the diamond to avoid any laser power fluctuation noise introduced by optical fibers. The guided green light was focused on the diamond through an objective (Plan Fluor 100x/1.30 Oil WD 0.16 by Nikon). A beam expander (GBE03-A by Thorlabs) was used to backfill the objective (for increased resolution). Immersion oil (type LDF, formula code 387, by Cargille Laboratories) was used in combination with a glass slide.
The emitted red fluorescence from the diamond was gathered through the same objective. A dichroic mirror (DMLP605 by Thorlabs), a single-mode optical fiber and a longpass filter (FELH0550 by Thorlabs) were used to separate the emitted red fluorescence from the green exciting light and guide it to two single-photon detectors (SPDMH2 by Thorlabs; active area diameter: 100 μm; photon detection efficiency: 70% at 670 nm; dead time between detected photons: 45 ns; afterpulsing probability: 0.2%) through a 50:50 beamsplitter cube (CCM1-BS013/M by Thorlabs). We used collimators to guide the light in the single-mode fiber (TC25APC-633 by Thorlabs) and to collect the light coming out from the fiber (F240FC-532 by Thorlabs). The TTL signals from the single-photon detectors were synchronized and collected using an oscilloscope (RTB2004 by Rohde & Schwarz; using a 200 μs per division time-scale resolution). The diamond was moved with respect to the objective using a XYZ translation stage (NanoMax-TS MAX373DK1/M by Thorlabs).
The objective in combination with the immersion oil, when back filled using the beam expander, yields a XY resolution (diffraction-limited, ideal case) of about 300 nm for red 650 nm light, so we set our measurement step to be 0.25 μm for moving in the X and Y directions with the translation stage.
3.1. Nanodiamond Ensemble QRNG
We used 100 nm scale fluorescent nanodiamonds (FNDs) with an NV center concentration of approximately 3 ppm. Typically, for this type of nanodiamonds, the number of NV centers per nanocrystal are on the order of 100. The nanodiamonds were used to firstly calibrate our confocal microscope setup, optimizing for red fluorescence collection efficiency and data collection rate; see
Figure 3. The experimental setup can distinguish signals from NV centers with a contrast of around 90% with respect to the background. The nanodiamonds were prepared by mixing, diluting them in isopropanol (using sonication) and depositing a small drop of this solution on a microscope glass slide.
In nanodiamond crystals containing randomly distributed NV centers, spontaneous emission timing is governed by quantum decay processes. Photon detection time fluctuations are fundamentally quantum. Random bits are extracted from photon arrival time bins as explained above.
3.2. Single NV Nanopillar QRNG
We also used a diamond sample with single NV centers located at the top of fabricated nanopillars on a diamond surface from a company—Qnami, Muttenz, Switzerland; see
Figure 4. The manufacturer states that in 30% of cases, there is a single NV center located at the tip of a single nanopillar (a few NV centers or none in other cases).
These types of nanopillars improve the light collection efficiency by about 20 times compared with typical bulk diamonds, yielding higher signal-to-background ratios; see
Figure 5. It can be seen that with our experimental setup configuration, we are detecting approximately 28 times fewer counts from the nanopillar diamond than from the nanodiamonds (many NV centers in brighter spots, approximately 3 ppm), but signals from the nanopillars are still clearly visible (few or single NV centers at each bright spot).
Single NV centers ensure emission of one photon at a time. Randomness arises from beamsplitter path selection (50:50). This approach provides higher entropy certification since it is based on single-quantum events.
4. Results
Here we present the analysis of the generated random numbers from both measurement cases—nanodiamonds and single NV centers at nanopillars. We calculated the conditional min-entropy and performed NIST SP 800-22 tests [
18].
The quality of the generated random bit sequences is quantified using conditional min-entropy, a standard metric in cryptographic randomness certification. For a discrete random variable
X with outcomes
x, the min-entropy is defined as
, reflecting the probability of the most likely outcome—that is, the success probability of an optimal single-guess attack on the output. Unlike Shannon entropy, which measures average uncertainty, min-entropy provides a conservative worst-case bound particularly suited to security applications. A value of
bit corresponds to a perfectly uniform binary source in which both outcomes are equally likely and no prediction strategy performs better than random guessing, while
indicates a fully deterministic source. The conditional min-entropy used here, defined in Equation (
4), extends this to account for any piece of side information
y available to an adversary, and is estimated from the measured detector click probabilities
and
following the approach in [
12]:
4.1. Results Using NV Centers in Nanodiamonds
Focusing specifically on a few nanodiamonds we get a photon flux on the order of 140 kcps for the brightest spot, see
Figure 6.
Results of NIST SP 800-22 tests for the brightest nanodiamond spot are compiled in
Table 1. The original values for generating random bits using the time binning method described above without detector debiasing, i.e., detector A and B click probabilities, are
= 0.2130 and
= 0.7870; total counts = 31,998. The calculated conditional min-entropy is
= 0.3455 bits.
Due to the fact that the detectors are not perfectly even and the light going in to both detectors is not perfectly aligned, we used the Von Neumann debiasing [
19] method for the registered photons. After debiasing:
= 0.5001, and
= 0.4999; total counts = 4025.
= 0.9786 bits. It can be seen that the min-entropy for the debiased data indicates higher quality of randomness for the data at the cost of reduced bit count—31,998/4025 = 7.9 times less bits.
Von Neumann debiasing was selected due to its implementation simplicity and its provably secure, assumption-free output. It requires no knowledge of the bias structure and produces output bits that are exactly uniform without introducing free parameters that could complicate interpretation across the two sources. Its principal drawback is efficiency, since for a source with bias p, the output rate scales as , approaching zero for strongly biased inputs.
More efficient alternatives that could be used for improved implementations exist. The Peres extractor [
20], a recursive generalization of Von Neumann debiasing, processes discarded bit pairs to approach the entropy rate while retaining the seedless, deterministic character of Von Neumann debiasing. Toeplitz matrix hashing [
12,
21], a construction from the two-universal hash family, achieves near-optimal extraction close to the min-entropy bound and only requires a valid lower bound on min-entropy—making it theoretically better suited to single-photon sources exhibiting antibunching. Both represent well-established progressions toward a certified, high-throughput implementation and are the recommended post-processing methods for a production QRNG system based on the architectures demonstrated here.
4.2. Results Using a Single NV Center in a Structured Diamond with Nanopillars
Focusing on one particular bright spot in the nanopillar diamond (see
Figure 7) we get a photon flux on the order of 5 kcps.
Results of NIST SP 800-22 tests for one bright nanopillar diamond spot are compiled in
Table 2.
The original values, without detector debiasing, of detector A and B click probabilities are = 0.4319 and = 0.5681; total counts = 19,276. The calculated conditional min-entropy is = 0.8158 bits. After debiasing, these are = 0.4941 and = 0.5059; total counts = 5015. = 0.9817 bits, with a reduced bit count of 19276/5015 = 3.8 times less bits.
5. Discussion
The two QRNG implementations investigated in this work operate in fundamentally different physical regimes. The nanodiamond system consists of an ensemble of NV centers, producing multi-emitter fluorescence with effectively Poissonian photon statistics, whereas the nanopillar device isolates individual or few NV centers and approaches the single-emitter regime. This distinction directly impacts the intrinsic randomness properties of the generated bit streams. Their photon statistics and noise characteristics differ, and a direct comparison of randomness metrics such as min-entropy does not isolate material or device performance. A controlled comparison would require normalization of photon statistics and emitter number. The comparison presented here is phenomenological, rather than a strict equivalent comparison. The observed differences in entropy may arise from both photon statistics (multi-photon vs. single-photon emission) and experimental factors, such as signal-to-noise ratio, detector response and experimental setup throughput.
The nanodiamond ensemble exhibits significantly higher brightness, with count rates approximately 28 times larger than those observed for the nanopillar structures. This is primarily due to the presence of multiple emitters within each nanocrystal and a larger effective excitation volume. In contrast, the nanopillar count rate is limited by the excited-state lifetime of a single NV center (10–20 ns), resulting in lower photon flux but improved control over emission statistics.
This difference in photon statistics is reflected in the raw entropy values. Prior to any post-processing, the nanodiamond system exhibits substantial bias (), arising from multiple emitters, larger excitation volume, background fluorescence, and unequal coupling into the detection channels. While multi-photon events in these ensembles can be partially filtered to improve statistics, it occurs at the cost of further decreasing extraction efficiency. The nanopillar system shows significantly higher intrinsic min-entropy (), consistent with reduced multi-photon contributions and more balanced detection probabilities.
After applying Von Neumann debiasing [
19], both systems converge to high-quality randomness with min-entropy values close to unity (0.98 bits). However, this comes at the cost of reduced bit rates. The nanodiamond implementation requires approximately an eightfold reduction in data, while the nanopillar system requires only a fourfold reduction. This demonstrates that the nanopillar approach provides higher entropy efficiency, as a larger fraction of the raw data can be retained after bias removal.
Von Neumann debiasing removes first-order bias but does not eliminate higher-order correlations or memory effects. Therefore, the quality of the initial physical randomness source remains critical. The improved performance of the nanopillar system reflects its more favorable photon statistics rather than post-processing alone.
The statistical testing results further reflect limitations imposed by finite data size. Several NIST SP 800-22 tests are marked as “ineligible” due to insufficient bit sequence length relative to the requirements (at least
bits) of the test suite [
18]. In addition, failures in tests such as the Random Excursion test are attributed to statistical fluctuations arising from limited data rather than systematic deviations from randomness. The tests that could be applied consistently show no statistically significant departure from random behavior. All eligible tests pass with
p-values below the significance thresholds for both systems. Extending data sets for full NIST suite validation should be the direct next step toward a fully certified implementation.
Although single NV centers are expected to exhibit photon antibunching [
22], a quantitative measurement of the second-order autocorrelation function
was limited by insufficient coincidence statistics with the present experimental setup implementation. A precise determination of
would require longer acquisition times and improved experimental setup throughput.
Compared with QRNG systems based on internal noise sources such as vacuum fluctuations or laser phase noise [
8], which can achieve Mbps to Gbps bit rates, NV center-based QRNG systems operate at significantly lower rates but provide a more direct physical link between the quantum emission process and the generated randomness. This enables more transparent entropy estimation and source characterization, at the cost of reduced throughput.
Nanopillar design optimizations have primarily focused on enhancing photon collection efficiency, improving ODMR contrast, and increasing single-photon source brightness [
23]. Further optimization specifically targeting QRNG performance, such as maximizing emission rate while minimizing background contributions, represents an important direction for future work.
6. Conclusions
We have demonstrated and compared two solid-state quantum random number generation implementations based on NV centers in diamond: an ensemble nanodiamond system and a nanopillar-isolated single-emitter system, both operating at room temperature.
The results reveal a clear trade-off between photon flux and intrinsic randomness quality. Nanodiamond ensembles provide higher count rates (raw bits) but exhibit significant bias due to multi-emitter fluorescence and background contributions, requiring substantial post-processing. In contrast, nanopillar-isolated NV centers exhibit higher intrinsic min-entropy (randomness quality), reflecting more favorable photon statistics.
After debiasing, both systems achieve high-quality randomness with min-entropy values approaching unity. However, the nanopillar approach demonstrates higher entropy efficiency, retaining a larger fraction of usable bits.
Diamond-based QRNG platforms provide a robust and potentially scalable route toward randomness generation with room-temperature operation and compatibility with integrated quantum technologies.
Author Contributions
Conceptualization, V.K. and M.A.; Methodology, H.M. and M.A.; Software, O.R. and H.M.; Validation, O.R., V.K., H.M. and M.J.; Formal analysis, O.R. and H.M.; Investigation, R.L., V.K., M.J. and M.A.; Resources, M.J.; Writing—original draft, O.R., R.L., V.K. and H.M.; Writing—review & editing, M.A.; Visualization, O.R.; Supervision, R.L. and M.A.; Project administration, M.A.; Funding acquisition, M.A. All authors have read and agreed to the published version of the manuscript.
Funding
We acknowledge the support from Recovery and Resilience Facility project “Internal and External Consolidation of the University of Latvia” (No.5.2.1.1.i.0/2/24/I/CFLA/007), grant project “Single Photon Sources for Quantum Technologies Using Nitrogen-Vacancy Centres in Diamond”, No. LU-BA-PA-2024/1-0071.
Data Availability Statement
The original contributions presented in this study are included in the article. Further inquiries can be directed to the corresponding authors.
Conflicts of Interest
The authors declare no conflicts of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript; or in the decision to publish the results.
References
- Lebedev, A.; Möslein, A.; Yaman, O.I.; Rajan, D.; Intallura, P. Effects of the entropy source on Monte Carlo simulations. arXiv 2025, arXiv:2409.11539. [Google Scholar]
- Hollingsworth, S.A.; Dror, R.O. Molecular Dynamics Simulation for All. Neuron 2018, 99, 1129–1143. [Google Scholar] [CrossRef] [PubMed]
- Schmidt, H. Quantum-Mechanical Random-Number Generator. J. Appl. Phys. 1970, 41, 462–468. [Google Scholar] [CrossRef]
- Holman, W.; Connelly, J.; Dowlatabadi, A. An integrated analog/digital random noise source. IEEE Trans. Circuits Syst. I Fundam. Theory Appl. 1997, 44, 521–528. [Google Scholar] [CrossRef]
- Herrero-Collantes, M.; Garcia-Escartin, J.C. Quantum random number generators. Rev. Mod. Phys. 2017, 89, 015004. [Google Scholar] [CrossRef]
- Guillan-Lorenzo, O.; Troncoso-Costas, M.; Alvarez-Outarelo, D.; Diaz-Otero, F.J.; Garcia-Escartin, J.C. Optical quantum random number generators: A comparative study. Opt. Quantum Electron. 2023, 55, 185. [Google Scholar] [CrossRef]
- Marangon, D.G.; Smith, P.R.; Walk, N.; Paraïso, T.K.; Dynes, J.F.; Lovic, V.; Sanzaro, M.; Roger, T.; De Marco, I.; Lucamarini, M.; et al. A fast and robust quantum random number generator with a self-contained integrated photonic randomness core. Nat. Electron. 2024, 7, 396–404. [Google Scholar] [CrossRef]
- Wang, X.; Zheng, T.; Jia, Y.; Huang, J.; Zhu, X.; Shi, Y.; Wang, N.; Lu, Z.; Zou, J.; Li, Y. Compact Quantum Random Number Generator Based on a Laser Diode and a Hybrid Chip with Integrated Silicon Photonics. Photonics 2024, 11, 468. [Google Scholar] [CrossRef]
- Smith, P.R.; Marangon, D.G.; Paraiso, T.K.; Dynes, J.F.; Shields, A.J. Noise-rejecting photonic integrated circuit for robust quantum random number generation. Opt. Quantum 2025, 3, 439–444. [Google Scholar] [CrossRef]
- Doherty, M.W.; Manson, N.B.; Delaney, P.; Jelezko, F.; Wrachtrup, J.; Hollenberg, L.C. The nitrogen-vacancy colour centre in diamond. Phys. Rep. 2013, 528, 1–45. [Google Scholar] [CrossRef]
- Barry, J.F.; Schloss, J.M.; Bauch, E.; Turner, M.J.; Hart, C.A.; Pham, L.M.; Walsworth, R.L. Sensitivity optimization for NV-diamond magnetometry. Rev. Mod. Phys. 2020, 92, 015004. [Google Scholar] [CrossRef]
- Chen, X.; Greiner, J.N.; Wrachtrup, J.; Gerhardt, I. Single Photon Randomness based on a Defect Center in Diamond. Sci. Rep. 2019, 9, 18474. [Google Scholar] [CrossRef] [PubMed]
- Wayne, M.A.; Jeffrey, E.R.; Akselrod, G.M.; Kwiat, P.G. Photon arrival time quantum random number generation. J. Mod. Opt. 2009, 56, 516–522. [Google Scholar] [CrossRef]
- Jennewein, T.; Achleitner, U.; Weihs, G.; Weinfurter, H.; Zeilinger, A. A fast and compact quantum random number generator. Rev. Sci. Instrum. 2000, 71, 1675–1680. [Google Scholar] [CrossRef]
- Yuan, Z.; Mukherjee, S.; Thompson, J.D.; de Leon, N.P.; Gardill, A.; Kolkowitz, S. An instructional lab apparatus for quantum experiments with single nitrogen-vacancy centers in diamond. Am. J. Phys. 2024, 92, 892–900. [Google Scholar] [CrossRef]
- Panadero, I.; Guerra, J.C.; Caravaca, E.; Hidalgo, F.J.; Acedo, P.; de Dios, C.; Torrontegui, E. Harnessing individual nitrogen-vacancy centers with a compact and portable confocal microscope. Europhys. Lett. 2025, 149, 20001. [Google Scholar] [CrossRef]
- Brown, R.H.; Twiss, R.Q. Correlation between photons in two coherent beams of light. Nature 1956, 177, 27–29. [Google Scholar] [CrossRef]
- Bassham, L.E.; Rukhin, A.L.; Soto, J.; Nechvatal, J.R.; Smid, M.E.; Barker, E.B.; Leigh, S.D.; Levenson, M.; Vangel, M.; Banks, D.L.; et al. A Statistical Test Suite for Random and Pseudorandom Number Generators for Cryptographic Applications; National Institute of Standards and Technology: Gaithersburg, MD, USA, 2010. [CrossRef]
- von Neumann, J. Various techniques used in connection with random digits. In Monte Carlo Method; National Bureau of Standards Applied Mathematics Series; National Bureau of Standards: Washington, DC, USA, 1951; Volume 12, pp. 36–38. [Google Scholar]
- Peres, Y. Iterating Von Neumann’s Procedure for Extracting Random Bits. Ann. Stat. 1992, 20, 590–597. [Google Scholar] [CrossRef]
- Carter, J.; Wegman, M.N. Universal classes of hash functions. J. Comput. Syst. Sci. 1979, 18, 143–154. [Google Scholar] [CrossRef]
- Beveratos, A.; Brouri, R.; Poizat, J.P.; Grangier, P. Bunching and Antibunching from Single NV Color Centers in Diamond. In Quantum Communication, Computing, and Measurement 3; Springer: Boston, MA, USA, 2002; pp. 261–267. [Google Scholar] [CrossRef]
- Engels, J.; Weippert, J.; Luo, T.; Kustermann, J.; Quellmalz, P.; Mathes, N.; Lindner, L.; Giese, C.; Kirste, L.; Knittel, P.; et al. High ODMR contrast and alignment of NV centers in microstructures grown on heteroepitaxial diamonds. Appl. Phys. Lett. 2024, 124, 164001. [Google Scholar] [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. |