[Jump to code hierarchy]

Perfect quantum code

Description

A type of block quantum code whose parameters satisfy the quantum Hamming bound with equality.

A code constructed out of \(q\)-dimensional qudits and having parameters \(((n,K,2t+1))\) is perfect if \(n\), \(K\), \(t\), and \(q\) are such that the quantum Hamming bound [1], \begin{align} \sum_{j=0}^{t}(q^2-1)^{j}{n \choose j}\leq q^{n}/K\tag*{$(1)$} \end{align}becomes an equality for such codes. For example, for a qubit \(q=2\) code with one logical qubit (\(K=2\)) and \(t=1\), the bound becomes \(3n+1 \leq 2^{n-1}\). The bound can be saturated only at certain \(n\).

For qubit codes with \(K=2^k\), one can work out an asymptotic Hamming bound in the large-\(n,k,t\) limit, \begin{align} \frac{k}{n}\leq 1-\frac{t}{n}\log_{2}3-h(t/n),\tag*{$(2)$} \end{align}where \(h\) is the binary entropy function.

The standard counting proof of the bound assumes a non-degenerate code [2]. All \(((n,K,d))\) codes with \(K>1\) on qudits of any integer dimension \(q\geq 2\), including impure and non-stabilizer codes, satisfy the quantum Hamming bound [2–4]. Qubit stabilizer codes correcting up to two errors [5] and qudit stabilizer codes correcting two errors [6] do not violate the bound. The same holds for qudit CSS codes of qudit dimension \(q\geq 5\) along with certain other codes [7] and for qubit codes of distance \(d<127\) [8]. A quantum Hamming-like bound exists for degenerate qubit stabilizer codes [9].

Protection

Pure perfect codes have been classified. For qubits (\(q=2\)), the only nontrivial pure perfect codes are the stabilizer code family \([[(4^r-1)/3, (4^r-1)/3 - 2r, 3]]\) for \(r \geq 2\), obtained from Hamming codes over \(\mathbb{F}_4\) via the Hermitian construction [10,11]. These codes are related to partial spreads in projective geometry [12]. For qudits, the corresponding family is the \([[\frac{q^{2r}-1}{q^{2}-1},\frac{q^{2r}-1}{q^{2}-1}-2r,3]]_q\) family of quantum twisted codes [13,14].

For codes of distance \(2t+1+\sigma\) with \(t\geq 1\) and \(\sigma\in\{0,1\}\), the quantum Hamming-Singleton bounds [15; Thm. 1] \begin{align} K\,q^{4e+2\sigma}\sum_{j=0}^{t-e}(q^2-1)^{j}{n-2e-\sigma \choose j}\leq q^{n}\qquad(0\leq e\leq t)\tag*{$(3)$} \end{align}reduce to the quantum Hamming bound for \(e=\sigma=0\) and to the quantum Singleton bound for \(e=t\). The strengthened quantum Hamming bounds [15; Thm. 2] read \(Kg(0)\leq q^{n}\,\mathbb{E}g(X)\) for \(X\sim\mathrm{Bin}(n,1-q^{-2})\), where \(g(x)=\binom{n-x}{2e+\sigma}\prod_{\xi}(x-\lfloor\xi\rfloor)(x-\lfloor\xi\rfloor-1)\) [4; Sec. 2.1]. Here, \(\xi\) runs over the zeros of the degree-\((t-e)\) Lloyd polynomial at length \(n-2e-\sigma\) over an alphabet of size \(q^2\). In other words, each zero is rounded to a pair of adjacent integers. Each strengthened bound is strictly stronger than its Hamming-Singleton counterpart exactly when some Lloyd zero is not an integer [4; Sec. 5.1]. The strengthened bounds hold for all codes with \(K>1\) [4; Thm. 2.1], proving a conjecture of Ref. [15].

Rate

\(k/n\to 1\) asymptotically with \(n\).

Notes

Cousins

  • Perfect code— A classical (quantum) perfect code saturates the classical (quantum) Hamming bound.
  • Hermitian qubit code— For qubits (\(q=2\)), the only nontrivial pure perfect codes are the stabilizer code family \([[(4^r-1)/3, (4^r-1)/3 - 2r, 3]]\) for \(r \geq 2\), obtained from Hamming codes over \(\mathbb{F}_4\) via the Hermitian construction [10,11]. These codes are related to partial spreads in projective geometry [12].
  • \(q\)-ary Hamming code— For qubits (\(q=2\)), the only nontrivial pure perfect codes are the stabilizer code family \([[(4^r-1)/3, (4^r-1)/3 - 2r, 3]]\) for \(r \geq 2\), obtained from Hamming codes over \(\mathbb{F}_4\) via the Hermitian construction [10,11]. These codes are related to partial spreads in projective geometry [12].
  • Random quantum code— Haar random codes achieve the quantum Hamming bound [16].
  • \([[2^r, 2^r-r-2, 3]]\) Gottesman code— \([[2^r, 2^r-r-2, 3]]\) Gottesman codes saturate the asymptotic quantum Hamming bound.
  • \([[15, 7, 3]]\) quantum Hamming code— The \([[15, 7, 3]]\) quantum Hamming code is perfect as a CSS code, i.e., the number of its \(Z\)-type syndromes matches the number of \(X\)-type Pauli errors up to weight one [17].
  • Quantum data-syndrome (QDS) code— The quantum Hamming bound can be extended to QDS codes [18].
  • Modular-qudit CWS code— Generalized concatenations of modular-qudit CWS codes yield a family of codes that have larger logical dimension than stabilizer codes and that asymptotically approach the modular-qudit Hamming bound [19].
  • Modular-qudit GKP code— The modular-qudit GKP code is not a block code, but it is perfect in the sense that each correctable error maps the logical space into a distinct error space.
  • Modular-qudit shift-resistant code— The modular-qudit shift-resistant code is not a block code, but it is perfect in the sense that each correctable error maps the logical space into a distinct error space [20].
  • Quantum twisted code— The \([[\frac{q^{2r}-1}{q^{2}-1},q^{n-2r},3]]_q\) family of quantum twisted codes are the only pure perfect Galois-qudit codes [13,14].

Primary Hierarchy

Parents
All non-trivial pure perfect codes have distance three.
Perfect quantum code
Children
The five-qubit code is the smallest perfect code and is a member of the perfect qubit code family \([[(4^r-1)/3, (4^r-1)/3 - 2r, 3]]\) for \(r = 2\).

References

  1. [1]

    A. Ekert and C. Macchiavello, “Error Correction in Quantum Communication”, (1996) arXiv:quant-ph/9602022

  2. [2]

    Y.-X. Zhang and J.-L. Chen, “Degeneracy Cannot Violate the Quantum Hamming Bound”, (2026) arXiv:2606.15558

  3. [3]

    Y.-X. Zhang and J.-L. Chen, “The Quantum Hamming Bound in Arbitrary Local Dimension”, (2026) arXiv:2606.22538

  4. [4]

    Valery, Grishin, and A. L. Zabokritskiy, “The strengthened quantum Hamming bound of Yu, Lai, and Oh”, (2026) arXiv:2610.30088

  5. [5]

    D. Gottesman, “Stabilizer Codes and Quantum Error Correction”, (1997) arXiv:quant-ph/9705052

  6. [6]

    S. A. Aly, “A Note on Quantum Hamming Bound”, (2007) arXiv:0711.4603

  7. [7]

    D. W. Kribs, A. Pasieka, and K. Zyczkowski, “Entropy of a quantum error correction code”, (2008) arXiv:0811.1621

  8. [8]

    E. Dallas, F. Andreadakis, and D. Lidar, “No \(((n,K,d&lt; 127))\) Code Can Violate the Quantum Hamming Bound”, IEEE BITS the Information Theory Magazine 2, 33 (2022) arXiv:2208.11800 DOI

  9. [9]

    A. Nemec and T. Tansuwannont, “A Hamming-Like Bound for Degenerate Stabilizer Codes”, (2023) arXiv:2306.00048

  10. [10]

    D. Gottesman, “Pasting Quantum Codes”, (1996) arXiv:quant-ph/9607027

  11. [11]

    A. R. Calderbank, E. M. Rains, P. W. Shor, and N. J. A. Sloane, “Quantum Error Correction via Codes over GF(4)”, (1997) arXiv:quant-ph/9608006

  12. [12]

    J. Bierbrauer, G. Faina, M. Giulietti, S. Marcugini, and F. Pambianco, “The geometry of quantum codes”, Innovations in Incidence Geometry: Algebraic, Topological and Combinatorial 6, 53 (2008) DOI

  13. [13]

    Z. Li and L. Xing, “No More Perfect Codes: Classification of Perfect Quantum Codes”, (2009) arXiv:0907.0049

  14. [14]

    J. Bierbrauer and Y. Edel, “Quantum twisted codes”, Journal of Combinatorial Designs 8, 174 (2000) DOI

  15. [15]

    S. Yu, C. H. Lai, and C. H. Oh, “Strengthened quantum Hamming bound”, (2010) arXiv:1005.4758

  16. [16]

    F. Ma, X. Tan, and J. Wright, “Haar random codes attain the quantum Hamming bound, approximately”, (2025) arXiv:2510.07158

  17. [17]

    R. Chao and B. W. Reichardt, “Fault-tolerant quantum computation with few qubits”, npj Quantum Information 4, (2018) arXiv:1705.05365 DOI

  18. [18]

    A. Ashikhmin, C.-Y. Lai, and T. A. Brun, “Quantum Data-Syndrome Codes”, IEEE Journal on Selected Areas in Communications 38, 449 (2020) arXiv:1907.01393 DOI

  19. [19]

    M. Grassl, P. Shor, G. Smith, J. Smolin, and B. Zeng, “Generalized concatenated quantum codes”, Physical Review A 79, (2009) arXiv:0901.1319 DOI

  20. [20]

    S. Pirandola, S. Mancini, S. L. Braunstein, and D. Vitali, “Minimal qudit code for a qubit in the phase-damping channel”, Physical Review A 77, (2008) arXiv:0705.1099 DOI

Page edit log

Your contribution is welcome!

report an error or suggest a change

edit & pull request on github.com

— see instructions

Zoo Code ID: quantum_perfect

Cite as:
“Perfect quantum code”, The Error Correction Zoo (V. V. Albert & P. Faist, eds.), 2026. https://errorcorrectionzoo.org/c/quantum_perfect, arXiv:2606.11484
BibTeX:
@incollection{eczoo_quantum_perfect,
title={Perfect quantum code},
booktitle={The Error Correction Zoo},
year={2026},
editor={Albert, Victor V. and Faist, Philippe},
eprint={2606.11484},
doi={10.48550/arXiv.2606.11484},
url={https://errorcorrectionzoo.org/c/quantum_perfect}
}
Share via:
Twitter | Mastodon |  | E-mail
Permanent link:
https://errorcorrectionzoo.org/c/quantum_perfect

Cite as:

“Perfect quantum code”, The Error Correction Zoo (V. V. Albert & P. Faist, eds.), 2026. https://errorcorrectionzoo.org/c/quantum_perfect, arXiv:2606.11484

Github: https://github.com/errorcorrectionzoo/eczoo_data/edit/main/codes/quantum/properties/block/quantum_perfect.yml.