11 Johnson Bound
11.1 Overview
This chapter proves the binary Johnson bound: for a binary code \(C\) of length \(n\) with minimum distance \(d\), if every codeword has weight at most \(w \le J_2(n,d)\) where
then \(|C| \le 2n\).
The proof reduces to a Rankin bound from geometry: a set of unit vectors in \(\mathbb {R}^n\) with pairwise non-positive inner products has size at most \(2n\). Codewords are embedded via a shifted \(\{ \pm 1\} \) map so that the distance and weight constraints force the inner-product condition.
11.2 Johnson bound
\(A_0(n,d,w)\) is the maximum size of an \((n,d,w)\)-admissible code.
Fix integers \(n, d, w\) with \(n \ge 1\), \(1 \le d\), and \(2d \le n\), and suppose that \(w \le J_2(n,d) = \tfrac {1}{2}\bigl(n - \sqrt{n\, (n-2d)}\bigr)\). Then the maximum size \(A_0(n,d,w)\) of an \((n,d,w)\)-admissible binary code — a set of binary words of length \(n\) in which any two distinct words are at Hamming distance at least \(d\) and every word has weight at most \(w\) — satisfies
11.3 Additional declarations
The type of binary words of length \(n\), namely functions \(\mathrm{Fin}\, n \to \mathrm{Bool}\).
Abbreviation for the \(n\)-dimensional real Euclidean space \(\mathbb {R}^n\) with the \(\ell ^2\) inner product, i.e. EuclideanSpace \(\mathbb {R}\) \((\mathrm{Fin}\, n)\).
For a binary word \(x\) of length \(n\), its weight is the number of coordinates where \(x\) takes the value true: \(\mathrm{wt}(x) = \left\lvert \{ \, i : x_i = \texttt{true} \, \} \right\rvert \).
For binary words \(x,y\) of length \(n\), the Hamming distance is the number of coordinates on which they differ: \(\mathrm{hdist}(x,y) = \left\lvert \{ \, i : x_i \neq y_i \, \} \right\rvert \).
The map sending a binary word \(x\) to the real vector in \(\mathbb {R}^n\) whose \(i\)-th coordinate is \(-1\) if \(x_i = \texttt{true}\) and \(+1\) otherwise.
The vector in \(\mathbb {R}^n\) all of whose coordinates equal \(1\).
For a real parameter \(\alpha \) and a binary word \(x\), the vector \(\hat{x}^\alpha = \mathrm{pmOne}(x) - \alpha \cdot \mathbf{1} \in \mathbb {R}^n\).
The rescaling \(u \mapsto \lVert u\rVert ^{-1} \cdot u\) of a vector of \(\mathbb {R}^n\).
Let \(\mathbf{1} \in \mathbb {R}^n\) be the all-ones vector. Then for every index \(i \in \{ 1, \dots , n\} \), the \(i\)-th coordinate satisfies \(\mathbf{1}_i = 1\).
Let \(x\) be a binary word of length \(n\), and let the \(\pm 1\) embedding send \(x\) to the vector in \(\mathbb {R}^n\) whose \(i\)-th coordinate is \(-1\) when \(x_i\) is true and \(+1\) when \(x_i\) is false. If the \(i\)-th entry of \(x\) is false, then the \(i\)-th coordinate of the embedded vector equals \(1\).
Let \(x\) be a binary word of length \(n\), and let \(s(x) \in \mathbb {R}^n\) denote its \(\pm 1\) embedding, whose \(i\)-th coordinate is \(-1\) when \(x_i\) is true and \(+1\) when \(x_i\) is false. Then for every index \(i\) with \(x_i\) true, the \(i\)-th coordinate of \(s(x)\) equals \(-1\).
The real quantity
The real quantity
A finite set \(C\) of binary words of length \(n\) is \((n,d,w)\)-admissible when any two distinct elements of \(C\) are at Hamming distance at least \(d\) and every element of \(C\) has weight at most \(w\).
Let \(x, y\) be binary words of length \(n\), and encode each as a \(\pm 1\) vector in \(\mathbb {R}^n\) by sending its \(i\)-th bit to \(-1\) when that bit is true and to \(+1\) when it is false. Then for every coordinate \(i\), the product of the \(i\)-th entries of these two embeddings equals \(1\) if \(x_i = y_i\) and \(-1\) if \(x_i \ne y_i\).
For any two binary words \(x, y\) of length \(n\), let \(\phi (x), \phi (y) \in \mathbb {R}^n\) be their \(\pm 1\) embeddings, whose \(i\)-th coordinates are \(-1\) when the corresponding bit is true and \(+1\) otherwise. Then their Euclidean inner product is
where \(d(x,y)\) is the Hamming distance, the number of coordinates on which \(x\) and \(y\) differ.
Let \(x\) be a binary word of length \(n\), and let \(s(x) \in \mathbb {R}^n\) denote its \(\pm 1\) embedding, the vector whose \(i\)-th coordinate is \(-1\) at each position where \(x_i\) is set and \(+1\) elsewhere. Writing \(\mathbf{1}\) for the all-ones vector and \(\mathrm{wt}(x)\) for the Hamming weight of \(x\) (the number of positions at which \(x\) is set), the \(\ell ^2\) inner product satisfies
Let \(\mathbf{1} \in \mathbb {R}^n\) denote the vector all of whose coordinates equal \(1\). Then, with respect to the standard \(\ell ^2\) inner product, \(\langle \mathbf{1}, \mathbf{1} \rangle = n\).
Let \(\alpha \in \mathbb {R}\), let \(x, y\) be binary words of length \(n\), and write \(\mathbf{1}\) for the all-ones vector in \(\mathbb {R}^n\) and \(s(x), s(y) \in \mathbb {R}^n\) for the \(\pm 1\) embeddings of \(x\) and \(y\) (with \(i\)-th coordinate \(-1\) where the corresponding bit is true and \(+1\) otherwise). Form the shifted vectors \(\hat{x}^\alpha = s(x) - \alpha \mathbf{1}\) and \(\hat{y}^\alpha = s(y) - \alpha \mathbf{1}\). Then their Euclidean inner product expands as
Let \(x\) and \(y\) be binary words of length \(n\), and let \(\alpha \ge 0\). Suppose \(d\) and \(w\) are natural numbers for which the Hamming distance between \(x\) and \(y\) is at least \(d\) and the Hamming weights of \(x\) and \(y\) are each at most \(w\). Writing \(\hat{x}^\alpha \) and \(\hat{y}^\alpha \) for the corresponding shifted vectors in \(\mathbb {R}^n\) — the \(\pm 1\) embedding of the word minus \(\alpha \) times the all-ones vector — their Euclidean inner product satisfies
For all natural numbers \(n\) and \(d\), the shift parameter \(\alpha (n,d) = \sqrt{(n - 2d)/n}\) satisfies \(0 \le \alpha (n,d)\).
Let \(n\) and \(d\) be natural numbers with \(n \gt 0\) and \(2d \le n\). Then the shift parameter \(\alpha (n,d)\) satisfies
Let \(n\) and \(d\) be natural numbers with \(n \ge 1\), \(d \ge 1\), and \(2d \le n\). Then the shift parameter satisfies
Let \(n\), \(d\), and \(w\) be natural numbers with \(n \gt 0\) and \(2d \le n\), and write \(\alpha = \alpha (n,d)\) for the shift parameter and \(J_2(n,d)\) for the binary Johnson radius. If \(w \le J_2(n,d)\), then
Let \(V\) be a real inner product space, let \(u \in V\) be a unit vector, and let \(x, y \in V\) satisfy \(\langle x, u\rangle \le 0\), \(\langle y, u\rangle \le 0\), and \(\langle x, y\rangle \le 0\). Then the components of \(x\) and \(y\) orthogonal to \(u\) again have nonpositive inner product:
Let \(V\) be a real inner product space, let \(u \in V\) be a unit vector, so \(\lVert u\rVert = 1\), and let \(x \in V\) be arbitrary. Then
Let \(V\) be a real inner product space, and let \(u, x \in V\) be unit vectors, \(\lVert u\rVert = 1\) and \(\lVert x\rVert = 1\), with \(\langle x, u\rangle \le 0\) and \(x \neq u\), \(x \neq -u\). Then the component of \(x\) orthogonal to \(u\) is nonzero, that is, \(x - \langle x, u\rangle \, u \neq 0\).
Let \(V\) be a real inner product space, and let \(u \in V\) be a unit vector. Let \(S \subseteq V\) be a set of unit vectors each of which makes a non-positive inner product with \(u\); that is, \(\lVert x\rVert = 1\) and \(\langle x, u\rangle \le 0\) for every \(x \in S\). Then the map \(x \mapsto x - \langle x, u\rangle \, u\), which subtracts from each vector its component along \(u\), is injective on \(S\).
For \(u,v\) in a real inner product space, \(\mathrm{orthProj}(u,v) = v - \langle u,v\rangle u\), the projection of \(v\) onto the orthogonal complement of \(\mathrm{span}\{ u\} \).
Let \(V\) be a real inner product space, and let \(u,v \in V\) with \(\lVert u\rVert = 1\). Then the vector \(v - \langle u,v\rangle \, u\) lies in the orthogonal complement \((\mathrm{span}_{\mathbb {R}}\{ u\} )^{\perp }\) of the line spanned by \(u\).
Let \(u\) and \(v\) be unit vectors in a real inner product space, and suppose that \(v \neq u\) and \(v \neq -u\). Then the projection of \(v\) onto the orthogonal complement of \(\mathrm{span}\{ u\} \), namely \(v - \langle u,v\rangle \, u\), is nonzero.
Let \(V\) be a real inner product space, and let \(u,v,w \in V\) with \(\lVert u\rVert = 1\). Suppose the three pairwise inner products \(\langle v,w\rangle \), \(\langle v,u\rangle \), and \(\langle w,u\rangle \) are all nonpositive. For a vector \(x \in V\), write \(x - \langle u,x\rangle \, u\) for the projection of \(x\) onto the orthogonal complement of \(\mathrm{span}\{ u\} \). Then the projections of \(v\) and \(w\) again have nonpositive inner product:
Let \(u,v,w\) be unit vectors in a real inner product space satisfying \(\langle v,u\rangle \le 0\), \(\langle w,u\rangle \le 0\), and \(\langle v,w\rangle \le 0\), and suppose that neither \(v\) nor \(w\) equals \(u\) or \(-u\) and that \(v \neq w\). For \(x\) in the space write \(\pi (x) = x - \langle u,x\rangle \, u\) for the projection of \(x\) onto the orthogonal complement of \(\mathrm{span}\{ u\} \). Then the two normalized projections \(\lVert \pi (v)\rVert ^{-1}\, \pi (v)\) and \(\lVert \pi (w)\rVert ^{-1}\, \pi (w)\) cannot be equal.
Let \(u,v\) be unit vectors in a real inner product space, with \(v \neq u\) and \(v \neq -u\), and set \(w = v - \langle u,v\rangle \, u\), the projection of \(v\) onto the orthogonal complement of \(\mathrm{span}\{ u\} \). Then the rescaled vector \(\lVert w\rVert ^{-1}\, w\) has norm \(1\).
Let \(u,v,w\) be vectors in a real inner product space with \(\lVert u\rVert =1\), and suppose the three inner products \(\langle v,w\rangle \), \(\langle v,u\rangle \), and \(\langle w,u\rangle \) are all nonpositive. For a vector \(x\), write \(x^{\perp }=x-\langle u,x\rangle \, u\) for its component orthogonal to \(u\), and assume that both \(v^{\perp }\) and \(w^{\perp }\) are nonzero. Then their normalizations still have nonpositive inner product:
Let \(V\) be a finite-dimensional real inner product space, and let \(u \in V\) be a unit vector, so that \(\lVert u\rVert = 1\). Then the orthogonal complement of the line \(\mathrm{span}_{\mathbb {R}}\{ u\} \) has dimension one less than that of \(V\):
Let \(S\) be a finite subset of an additive group \(V\), and let \(u \in S\). Then
Given a unit vector \(u\), this packages the normalized projection \(\lVert \mathrm{orthProj}(u,v)\rVert ^{-1}\mathrm{orthProj}(u,v)\) together with its membership proof as an element of the subspace \((\mathrm{span}_{\mathbb {R}}\{ u\} )^{\perp }\).
Let \(V\) be a real inner product space, let \(u \in V\) be a unit vector, and let \(v \in V\). Write \(w = v - \langle u, v\rangle \, u\) for the component of \(v\) orthogonal to \(u\). The normalized vector \(\lVert w\rVert ^{-1} w\), regarded as an element of the orthogonal complement \((\mathrm{span}_{\mathbb {R}}\{ u\} )^{\perp }\) of the line spanned by \(u\), has underlying vector in \(V\) equal to \(\lVert w\rVert ^{-1} w\).
Let \(V\) be a finite-dimensional real inner product space, and let \(S\) be a finite set of vectors in \(V\), each of norm \(1\), such that any two distinct vectors of \(S\) have non-positive inner product. Then \(\left\lvert S\right\rvert \le 2 \dim _{\mathbb {R}} V\).
Let \(S\) be a finite set of vectors in the Euclidean space \(\mathbb {R}^n\), each of norm \(1\), such that any two distinct vectors \(u, v \in S\) satisfy \(\langle u, v\rangle \le 0\). Then \(\left\lvert S\right\rvert \le 2n\).
Let \(n \ge 1\) and let \(\alpha \) be a real number with \(0 \le \alpha \lt 1\). Then for every binary word \(x\) of length \(n\), the shifted vector \(\hat{x}^\alpha \in \mathbb {R}^n\) — obtained from the \(\pm 1\) embedding of \(x\) by subtracting \(\alpha \) times the all-ones vector — is nonzero.
Let \(n \ge 1\), let \(d, w\) be natural numbers, and let \(C\) be a finite set of binary words of length \(n\) such that any two distinct words of \(C\) are at Hamming distance at least \(d\), and every word of \(C\) has weight at most \(w\). Suppose \(\alpha \ge 0\) is a real parameter for which the shifted \(\pm 1\) vector \(\hat{x}^\alpha \) is nonzero for every \(x \in C\), and for which
Then \(\left\lvert C\right\rvert \le 2n\).
Let \(n \ge 1\) and let \(d\) be an integer with \(1 \le d\) and \(2d \le n\). Suppose \(C\) is a finite set of binary words of length \(n\) such that any two distinct words of \(C\) are at Hamming distance at least \(d\), and every word of \(C\) has Hamming weight at most \(w\). If \(w \le J_2(n,d)\), where \(J_2(n,d) = \tfrac {1}{2}\bigl(n - \sqrt{n(n-2d)}\bigr)\) is the binary Johnson radius, then \(\left\lvert C\right\rvert \le 2n\).
Let \(n \ge 1\), \(d \ge 1\), and suppose \(2d \le n\). If \(C\) is an \((n,d,w)\)-admissible code — a finite set of binary words of length \(n\) in which any two distinct words are at Hamming distance at least \(d\) and every word has weight at most \(w\) — and the weight bound satisfies \(w \le J_2(n,d)\), where \(J_2(n,d) = \tfrac {1}{2}\bigl(n - \sqrt{n(n-2d)}\bigr)\), then \(\left\lvert C\right\rvert \le 2n\).
Fix natural numbers \(n\), \(d\), \(w\) and \(K\). If every \((n,d,w)\)-admissible code \(C\) satisfies \(\left\lvert C\right\rvert \le K\), then the maximum size of an \((n,d,w)\)-admissible code satisfies \(A_0(n,d,w) \le K\).