Introduction
Shannon’s source coding theorem guarantees that for any \( > 0\), the atypical set \(B_^{(n)}\) satisfies \((X^n B_^{(n)}) \) for sufficiently large \(n\). All sequences in \(B_^{(n)}\) are mapped to a single error symbol.
We introduce structure by partitioning \(B_^{(n)}\) into \(k 2\) clusters \({C_1, , C_k}\) using a distortion metric (Hamming distance). The encoder now outputs:
1 indicator bit (typical vs.\ atypical),
\(n(H(X) + )\) bits for typical sequences,
\(_2 k\) bits for the cluster label.
The clustering overhead \(\) yields the effective rate \(R = (1 + )(H(X) + )\). When \( 0\), the scheme reduces exactly to classical source coding. For \( > 0\), we obtain a refined rate–error tradeoff that exploits the internal geometry of the atypical set.
Classical Framework
Let \(A_^{(n)} = {x^n : |-{1}{n}_2 P(x^n) - H(X)| }\) be the typical set and \(B_^{(n)}\) its complement. Then \[ (X^n B_^{(n)}) , |B_^{(n)}| 2^{n(H(X)+)}. \] Every \(x^n B_^{(n)}\) satisfies \(P(x^n) 2^{-n(H(X)-)}\).
Structured Clustering and Dominant-Cluster Bound
[Refined Dominant-Error Bound via Structured Clustering (Upper Bound)] Let \(X^n\) be an i.i.d.\ sequence from a discrete memoryless source with entropy \(H(X)\). Partition the atypical set \(B_^{(n)}\) into \(k 2\) clusters \({C_1,,C_k}\) according to any distortion metric. Let \(C_{}\) be the cluster of largest cardinality. Then \[ D (X^n C_{}) (,\ 2^{2n}/k). \] Moreover, when the atypical set possesses geometric structure under the chosen metric, Hamming-distance \(k\)-means clustering empirically achieves a dominant probability \(D\) that is strictly smaller than \(\) in the finite-blocklength regime \[ n < {1}{2}_2(k/). \]
In the worst-case equal-size partition, \(c_{} |B_^{(n)}|/k 2^{n(H(X)+)}/k\). Since each sequence in \(B_^{(n)}\) has probability at most \(2^{-n(H(X)-)}\), we obtain \[ D c_{} 2^{-n(H(X)-)} 2^{2n}/k. \] Combining with the classical bound \((B_^{(n)}) \) yields the stated result. The strict improvement \(D < \) holds precisely when \(k > 2^{2n}/\).
[Matching Lower Bound – Worst-Case Tightness] For any clustering into \(k\) parts, there exist sources (e.g., those for which the atypical mass is nearly uniformly distributed across the support of \(B_^{(n)}\)) such that \[ D (1-o(1)) {2^{2n}}{k}. \] Thus the upper bound of Theorem 1 is tight in the worst case: no clustering scheme can achieve a better dominant-cluster probability than the combinatorial bound when the atypical set has uniform mass distribution.
[Sketch] If the probability mass of \(B_^{(n)}\) is distributed approximately uniformly over its \(|B_^{(n)}|\) elements (possible when atypical types have comparable rate-function values), then any partition into \(k\) clusters satisfies \(_i |C_i| |B_^{(n)}|/k\). Multiplying by the per-sequence probability bound \(2^{-n(H(X)-)}\) yields the stated lower bound on \(D\).
The strict improvement \(D \) therefore occurs only when the source geometry induces cluster concentration: the atypical mass is heavily concentrated in a small number of Hamming-balls (or type classes) near the typical-set boundary, as predicted by Sanov’s theorem for convex rate functions.
[Unequal Cluster Sizes] Let the clusters have arbitrary cardinalities \(c_1 c_2 c_k\). Then \[ D ( ,\ _i c_i 2^{-n(H(X)-)} ). \] When the partition is produced by Hamming-distance \(k\)-means, the largest cluster \(C_{}\) is typically the one nearest the typical-set boundary, yielding the empirical scaling \(D ^{1+}\).
The geometric-structure claim (concentration near the boundary) is verified empirically in Section [sec:simulations].
agraph{Structural refinement (empirical law).} While the cardinality bounds provide worst-case limits, empirical evidence indicates that real sources exhibit strong non-uniformity within the atypical set under natural metrics. In particular, for clustering induced by Hamming distance on i.i.d.\ Bernoulli sources, the dominant-cluster probability empirically satisfies \[ D ^{1+}, \] suggesting that the atypical set decomposes into highly unequal components. This behavior is not implied by the combinatorial bounds and reflects underlying geometric structure in the source distribution.
agraph{Conditional improvement.} If the atypical set exhibits cluster concentration under the chosen metric, i.e., if there exists a partition such that \[ _i (X^n C_i) {}{k}, \] then clustering yields a strictly stronger bound on the dominant error probability than uniform partitioning, and the empirical scaling \(D ^{1+}\) becomes achievable.
Rate–error tradeoff. In regimes where the exponential term dominates, the empirical law above produces the explicit tradeoff curve \[ -_2 D {R}{H(X)+} (-_2 ). \]
Finite-Blocklength Simulations
We performed exhaustive Monte-Carlo simulations on a Bernoulli(\(p=0.3\)) source (\(H(X) 0.881\) bits). For each \((n,k,=0.1)\) we generated up to \(10^6\) sequences, identified atypical ones via the exact information-density test, and applied Hamming-distance \(k\)-means clustering.
Representative result (\(n=30\), \(k=16\)):
Atypical fraction \( 0.319\)
Empirical \(D = 0.0367\)
Classical \( = 0.1\)
Improvement = \(0.0633\) (63% reduction)
\( = 0.136\)
The full parameter sweep (\(n=1550\), \(k=4,8,16,32\)) produces three key figures:
The heatmap reveals a phase transition in $(n,k)$, indicating that clustering must exceed a resolution threshold to exploit structure. The rate–error plot shows an approximately linear relationship between $$ and $-_2 D$, consistent with the predicted scaling law.
These simulations demonstrate that Hamming-distance clustering consistently exploits the natural geometry of the atypical set, achieving \(D\) values significantly below both the classical \(\) and the worst-case combinatorial bound.
Limiting Case: \( 0\)
As \(k\) remains sub-exponential in \(n\) (\(_2 k = o(n)\)), we have \( 0\). Then \(R H(X) + \) and \(D \), recovering classical source coding exactly. Shannon’s theorem is therefore the boundary of a richer, structure-aware paradigm.
Conclusion
By paying a small rate overhead \(\), we convert the monolithic error event of classical source coding into a hierarchy of ambiguity classes. Theorems 1–2 together with the matching lower bound, the empirical law, the conditional improvement, and the simulations show that the dominant probability \(D\) can be made strictly smaller than \(\) in a well-characterized finite-blocklength regime precisely because the atypical set possesses exploitable geometric structure under a distortion metric.
The classical result is recovered in the limit, so there is no contradiction. This framework unifies typicality-based coding with structure-aware techniques and opens practical avenues for finite-blocklength source coding, adaptive clustering, and extensions to non-i.i.d.\ and quantum sources.
Acknowledgment
The author thanks the REAL Institute for support. Reproducible Python simulation scripts are available upon request.
References
- [1]
C. E. Shannon, "A mathematical theory of communication," Bell System Technical Journal, vol. 27, pp. 379–423, 623–656, 1948.
- [2]
T. M. Cover and J. A. Thomas, Elements of Information Theory, 2nd ed., Wiley, 2006.
- [3]
I. Csiszár and J. Körner, Information Theory: Coding Theorems for Discrete Memoryless Systems, 2nd ed., Cambridge University Press, 2011.
- [4]
A. Chawla, "Towards weak source coding," arXiv:2209.04765, 2022.