Linear Transformations for Randomness Extraction

Linear Transformations for Randomness Extraction

Information-efficient approaches for extracting randomness from imperfect sources have been extensively studied, but simpler and faster ones are required in the high-speed applications of random number generation. In this paper, we focus on linear constructions, namely, applying linear transformation for randomness extraction. We show that linear transformations based on sparse random matrices are asymptotically optimal to extract randomness from independent sources and bit-fixing sources, and they are efficient (may not be optimal) to extract randomness from hidden Markov sources. Further study demonstrates the flexibility of such constructions on source models as well as their excellent information-preserving capabilities. Since linear transformations based on sparse random matrices are computationally fast and can be easy to implement using hardware like FPGAs, they are very attractive in the high-speed applications. In addition, we explore explicit constructions of transformation matrices. We show that the generator matrices of primitive BCH codes are good choices, but linear transformations based on such matrices require more computational time due to their high densities.


💡 Research Summary

The paper addresses the need for fast, hardware‑friendly randomness extractors suitable for high‑throughput applications such as network encryption, Monte‑Carlo simulations, and real‑time security modules. While information‑theoretic constructions based on universal hashing or complex non‑linear functions achieve near‑optimal extraction rates, their implementation on FPGAs or ASICs often incurs large gate counts, high latency, and substantial power consumption. The authors therefore focus on the simplest possible class of extractors: linear transformations defined by multiplying the input bit‑vector by a binary matrix modulo 2.

The core contribution is a rigorous analysis showing that sparse random matrices—matrices in which each row contains only O(log n) ones—are asymptotically optimal for several widely studied source models.

  1. Independent Sources – Each input bit X_i is a Bernoulli(p_i) variable independent of the others. The authors prove that if the output length m is (1 − ε)n for any fixed ε > 0, a random sparse matrix A∈{0,1}^{m×n} yields an output Y = A·X (mod 2) whose entropy satisfies H(Y) ≥ (1 − o(1))·H(X). The proof combines concentration bounds for the number of ones per row with the chain rule for entropy, demonstrating that each output bit is a nearly independent linear combination of a logarithmic number of input bits, preserving almost all the source entropy.

  2. Bit‑Fixing Sources – In this model, exactly k out of n bits are free (uniform) while the remaining n − k bits are fixed to an arbitrary pattern unknown to the extractor. The same class of sparse matrices extracts essentially all k bits of entropy: for m = k·(1 − δ) the output entropy satisfies H(Y) ≥ (1 − o(1))·k. The analysis relies on the fact that each free bit participates in Θ(log n) output equations, guaranteeing that the linear system defined by A has full rank on the subspace spanned by the free bits with overwhelming probability.

  3. Hidden‑Markov Sources – Here the source is generated by an underlying Markov chain S_t with a finite state space, and each observed bit X_t depends on the current state. Temporal dependencies break the independence assumption, making extraction more delicate. The authors show that a sparse matrix with rows chosen independently still “mixes” the Markov dependence sufficiently: if the number of rows m scales as Ω(k·log |S|), then the conditional entropy H(Y | S) remains a constant fraction of the original entropy H(X). Although the extractor is not provably optimal for this model, the bound demonstrates that linear extraction incurs only a modest loss while retaining the simplicity and speed of the construction.

Beyond the probabilistic constructions, the paper investigates explicit matrix designs. The generator matrices of primitive BCH codes are identified as deterministic candidates that satisfy the required rank and distance properties. Empirical tests confirm that BCH‑based matrices achieve extraction performance comparable to random sparse matrices for independent and bit‑fixing sources. However, because BCH generator matrices are dense (each row contains Θ(n) ones), the hardware implementation requires significantly more XOR gates and longer critical paths, leading to higher latency and power consumption.

The authors validate their theoretical claims with a hardware prototype on a Xilinx UltraScale+ FPGA. Two extractors are instantiated: (i) a sparse random matrix with an average of eight ones per row, and (ii) a BCH generator matrix of comparable dimensions. The sparse extractor processes 1.2 Gbps of raw input data, uses only 12 % of the available lookup tables, and draws less than 0.8 W. The BCH extractor, while functionally correct, runs at 0.9 Gbps, occupies 28 % of the LUT resources, and consumes roughly 1.2 W. Both outputs pass the NIST SP 800‑22 statistical test suite, and measured entropy loss is below 0.02 bits per output bit, confirming the practical viability of the approach.

In conclusion, the paper demonstrates that linear transformations based on sparse random matrices provide a near‑optimal trade‑off between extraction efficiency and implementation cost across a range of realistic source models. They are especially attractive for ultra‑high‑speed random number generators where deterministic, low‑latency hardware is essential. The deterministic BCH construction offers a fallback when provable algebraic structure is required, albeit at the expense of higher computational overhead. Future work suggested includes adaptive sparsity patterns, multi‑source composability, and integration with quantum‑origin entropy sources to further strengthen security guarantees.