Average Minimal Hamming Distance in Codes & Quantum Data
- Average minimal Hamming distance is defined as the minimum average pairwise Hamming distance over a code, distinguishing its interpretations in coding theory and quantum sampling.
- It leverages Delsarte linear programming and Krawtchouk polynomials to derive explicit lower bounds and optimize extremal properties in binary codes.
- Extensions include sample-based analysis in quantum data, where efficient nearest-neighbor and Fourier-analytic techniques quantify bit-string complexity.
Searching arXiv for the cited works to ground the article in the relevant literature. Average minimal Hamming distance denotes a family of closely related functionals on Hamming spaces. In binary coding theory, the principal quantity is the minimum average Hamming distance of an code , defined by minimizing the average pairwise distance
over all codes of size ; the resulting extremal value is denoted (0706.3295). In quantum-sampling analysis, the term refers instead to the average, over a set of distinct measured bit-strings, of each sample’s nearest-neighbor Hamming distance,
which is used as a sample-level descriptor of bit-string complexity (Golubev et al., 3 Jun 2026). Related literature also studies the expectation or ensemble average of the minimum distance itself, rather than an average of pairwise or nearest-neighbor distances (Hao et al., 2019, 0905.4545).
1. Definitions and distinctions
For binary codes, is the set of binary words of length , and an code is a subset with 0. The average Hamming distance of 1 is
2
and the minimum average distance over all 3 codes is
4
This is an isodiametric extremal problem in Hamming space: the optimization variable is the entire code, and the objective averages over all ordered pairs in the code (0706.3295).
A distinct quantity appears in the analysis of quantum measurement data. There one begins with a collection 5 of 6 distinct bit-strings of length 7, defines the Hamming distance
8
then assigns to each sample its nearest-neighbor distance 9, and finally averages these nearest-neighbor distances to obtain 0 (Golubev et al., 3 Jun 2026). Here the functional is not an extremum over all codes of fixed size; it is a statistic of an observed sample set.
A common source of confusion is the distinction between minimum average distance and minimum distance. In the coding-theoretic notation of (0706.3295) and (Yu et al., 2019), the optimized object is an average over all pairs. By contrast, the random linear-code literature studies
1
and the Hamming-accumulate-accumulate literature studies probabilistic or ensemble-average behavior of that minimum distance (Hao et al., 2019, 0905.4545). These quantities are related only indirectly.
2. Delsarte linear programming for minimum average distance
The basic linear-programming framework for 2 is Delsarte’s approach via the dual distance distribution. If 3 is the usual distance distribution of a binary code 4, and 5 is the binary Krawtchouk polynomial of degree 6, then the dual distance distribution is
7
The key facts are
8
together with the identity
9
Consequently, a lower bound on 0 follows from an upper bound on 1 (0706.3295).
This yields the linear program
2
subject to
3
4
and
5
The proof method uses dual feasible polynomials 6 satisfying sign constraints such as 7, 8 on forbidden 9, and 0 on allowed 1. By standard LP duality this yields an upper bound on 2, hence a lower bound on 3 (0706.3295).
A later reformulation works in the binary Hamming space 4. If 5 has size 6 and distance distribution
7
then its average Hamming distance is
8
With 9, one defines
0
where 1 is the 2th Krawtchouk polynomial, and obtains
3
This gives a primal–dual LP pair whose feasible dual vectors directly generate lower bounds on 4 (Yu et al., 2019).
3. Explicit lower bounds and sparse-code regimes
The linear-programming method yields several closed-form lower bounds on 5 that are valid for every integer pair 6 with 7. For very small codes,
8
For small codes,
9
More significantly, for codes of moderate size with 0, the paper gives formulas that are nontrivial as soon as 1 is of order 2 (0706.3295).
If 3 is even, then
4
If 5 is odd, then
6
Further refinements depend on the residue class of 7: 8
These formulas are important because the earlier “classical” bound of Althöfer–Sillke,
9
is only useful when 0. For codes of size 1 that bound is vacuous, whereas the new bounds give a constant-order lower bound (0706.3295).
The numerical example 2, 3 illustrates the difference. The classical bound gives
4
whereas the even-5 bound gives
6
The paper further proves the asymptotic statement
7
This establishes the exact constant 8 in the limit for the sparse code size 9 (0706.3295).
4. Improved LP bounds, dense-code asymptotics, and Fourier weights
For code size 0 with fixed 1, the improved LP analysis of Yu and Tan constructs a two-point dual feasible solution supported at 2 and 3, with 4 and 5, rather than the single-point solution used earlier (Yu et al., 2019). Evaluating the dual objective and optimizing over 6 yields the asymptotic bound
7
where
8
The same paper shows that this is asymptotically optimal for the Fu–Wei–Yeung LP: for large 9, no nonnegative dual feasible vector can asymptotically do better than the function 0 obtained by the two-point construction. In that sense, all possible asymptotic bounds that can be derived by that linear program have been characterized (Yu et al., 2019).
A further aspect of the theory is its Fourier-analytic reformulation. If 1 and 2 has size 3, then the degree-4 Fourier weight is
5
For 6,
7
so the average-distance bound is equivalent to
8
The paper also gives higher-degree bounds: 9 This places the coding-theoretic LP inside a broader MacWilliams–Delsarte and Fourier-analytic framework (Yu et al., 2019).
5. Expectation and ensemble averages of minimum distance
Closely related literature studies the expectation or ensemble average of the minimum Hamming distance, rather than the minimum over codes of an average pairwise distance. For a random linear code of dimension 00 in 01, with
02
the paper on random linear codes shows that
03
and that the c.d.f. of 04 is 05-close to the c.d.f. of the minimum of 06 independent Binomial07 variables (Hao et al., 2019). When 08, the minimum exhibits a Gumbel-limit description on an arithmetic lattice, and the expectation has the asymptotic form
09
The leading-order term is therefore 10 (Hao et al., 2019).
For Hamming-accumulate-accumulate ensembles, the relevant object is the ensemble-average weight enumerator and the induced probabilistic lower bound on 11. If 12 is formed by serial concatenation of an 13 Hamming or extended-Hamming code with two rate-1 accumulate codes, then the uniform-interleaver ensemble-average weight enumerator is
14
A union bound gives
15
Asymptotically, if the spectral-shape function
16
satisfies 17 for all 18, then with high probability 19. Numerically, the paper reports 20 for 21AA, 22 for 23AA, 24 for 25AA, 26 for 27AA, 28 for 29AA, and 30 for 31AA (0905.4545).
These results do not define “average minimal Hamming distance” in the same way as 32 or 33. They nevertheless show that neighboring notions of averaging—expectation over a random-code ensemble or over a concatenated-code ensemble—play an important role in minimum-distance analysis.
6. Sample-based average minimal Hamming distance in quantum data
In quantum sampling data, the average minimal Hamming distance is computed from a dataset of 34 unique bit-strings in the measurement basis, with 35. For a target sample size 36, one chooses at random, or by stratified sampling, a subset 37 of size 38, computes the Hamming distances between every pair of elements of 39, records each sample’s nearest-neighbor distance, and averages. Repeating this procedure typically 40–41 times reduces sampling noise (Golubev et al., 3 Jun 2026).
The naive implementation requires 42 bit-operations. The paper notes two concrete optimizations: use bitwise XOR and population-count hardware instructions to compute Hamming distances extremely quickly, and for large 43 use approximate nearest-neighbor methods in Hamming space, such as locality-sensitive hashing or trie-based indexes, to reduce the 44 scaling (Golubev et al., 3 Jun 2026).
Empirically, over several decades in 45, a wide variety of quantum states obey
46
The prefactor satisfies 47, the scaling exponent lies in 48, and the offset obeys 49. In practice, 50 for large Hilbert spaces, although occasionally 51 when the minimal distance saturates at the smallest possible value (Golubev et al., 3 Jun 2026).
The reported examples are specific. For a 24-qubit Dicke state with 52 excitations, fitting over 53 gives 54, with 55, and the fit remains good until saturation at 56 for 57. For the exact ground state of the 58–59 model on a 60 lattice at 61, the reported values are 62 and 63, with 64. For Haar-random 53-qubit Sycamore data, a typical exponent is 65 with prefactor 66. For a D-Wave 67 spin glass at quench time 68, fitting over 69 yields 70, 71, and negligible 72; at 73, one finds 74 and 75 (Golubev et al., 3 Jun 2026).
The interpretation proposed in that work is operational. The prefactor 76 reflects the “typical” nearest-neighbor distance when only one sample is drawn: larger 77 means the wave function is more delocalized in bit-string space. The exponent 78 measures how “connected” the manifold of high-probability bit-strings is: smaller 79 implies that even large numbers of samples rarely find very close neighbors. In the frustrated 80–81 model, 82 exhibits a pronounced maximum in the intermediate regime 83–84, coinciding with the quantum phase transition between Néel and stripe orders. This suggests that changes in 85 and 86 can signal phase boundaries without requiring computation of order parameters (Golubev et al., 3 Jun 2026).
The same paper also states the main practical limitations. To extract 87 reliably, one needs at least 88–89 unique bit-strings. At small 90, 91 has large sample-to-sample variance, so averaging over multiple random subsets is necessary. When the minimal Hamming distance saturates at the theoretical lower bound, such as 92 for balanced Dicke states, one must include 93 in the fit or restrict to 94 below saturation. The parameters 95 and 96 are empirical descriptors and may depend weakly on measurement basis, so comparisons require identical bases and fitting windows (Golubev et al., 3 Jun 2026).
7. Conceptual placement
Taken together, these works place average minimal Hamming distance at the intersection of extremal coding theory, probabilistic minimum-distance analysis, and data-driven characterization of high-dimensional discrete distributions. In coding theory, the central problem is to determine or bound 97, and the Delsarte LP with dual-feasible Krawtchouk polynomials yields explicit nontrivial lower bounds in the regime 98, including the asymptotic identity 99 (0706.3295). In the dense regime 00, the improved LP of Yu and Tan characterizes the asymptotically optimal output of that linear program and connects the problem to Fourier weights of Boolean functions (Yu et al., 2019).
In adjacent settings, “average” may refer instead to averaging over a random-code ensemble or over repeated subset selections from measured bit-strings. The random linear-code results show that linear dependencies have only an 01 effect on the c.d.f. of the minimum distance beyond the identification of proportional codewords (Hao et al., 2019). The quantum-sampling results show that averaging nearest-neighbor distances across unique bit-strings can produce a robust power-law descriptor 02 across experimentally and numerically generated states (Golubev et al., 3 Jun 2026).
A plausible implication is that the phrase “average minimal Hamming distance” should always be read with its precise ambient definition: an extremal average over all code pairs, an expectation of a minimum over a random ensemble, or a nearest-neighbor average over an observed sample set. The cited literature treats all three with technically different objectives, constraints, and asymptotic regimes.