A binary linear code of length and rank is a -dimensional vector subspace . Its minimum distance is the least Hamming weight of a nonzero codeword, equivalently the least Hamming distance between distinct codewords.
For binary length- linear codes , their bar product of binary linear codes is
It is a binary linear code of length and dimension .
Write for the all-one column vector. The parity-check extension of a linear code is
The defining map is linear, so is a binary linear code. If is a generator matrix and a parity-check matrix for , then one may take
The punctured code in, say, the last coordinate is
Coordinate deletion is a linear map, so is linear. Its generator matrix is obtained by deleting the last column of . If the minimum distance is at least two, deletion is injective on , and hence has the same dimension as .
For its parity-check matrix, first use invertible row operations on to make its nonzero last column a coordinate vector. The last column is nonzero because otherwise the weight-one word supported there would belong to , contrary to . Delete the pivot row and the last column; the resulting matrix is a parity-check matrix for . Equivalently, is obtained by shortening the dual code at the deleted coordinate.
Finally, the shortened code in the last coordinate is
It is linear whenever is linear, because it is the puncture of the subspace .
For the standard dot product on , the dual code is
It is an intersection of kernels of linear functions, and is therefore a linear code.
Let denote cyclic right shift. If and , then
A cyclic code is closed under both and , so and the right-hand side vanishes. Hence , proving directly that the dual of a cyclic code is cyclic.
Identify words with polynomials in . If the generator polynomial of a cyclic code is the monic divisor and
then the generator polynomial of is the monic reciprocal
Equivalently, the parity-check polynomial of one code becomes, after reversal, the generator polynomial of its dual.
The parity-check matrix has rank , so its kernel has dimension and size ; see linear code. Its columns are precisely the seven distinct nonzero vectors of . Thus no weight-one or weight-two word is in the kernel, while three dependent columns give a weight-three word. Hence .
Tetracode 2026-10-07
The two-dimensional ternary linear code generated by and . Its eight nonzero words have exactly three nonzero entries, with precisely two opposite words for each position of the zero coordinate.
Weight enumerator Created 2026-10-05 Updated 2026-10-07
The homogeneous weight enumerator of a length- linear code is the polynomial
Its coefficients count words of each Hamming weight. In this convention ; some references interchange .