Professional Documents
Culture Documents
Navin Kashyap
Notation:
I An [n, k] linear code over F is a code of blocklength n and
dimension k.
I An [n, k]q linear code is a code of blocklength n and
dimension k over Fq .
(Contrast this with the (n, M) notation for block codes.)
Number of Codewords
Proposition: An [n, k] linear code C over Fq has q k codewords.
Remarks:
I An [n, k] linear code over Fq is an (n, M = q k ) block code.
I The rate of an [n, k] linear code over Fq is
1 k
R= logq (q k ) = .
n n
Minimum Distance
Recall that the minimum distance of a block code C is defined as
dmin (C) = min dH (x, y).
x,y∈C
x6=y
Minimum Distance
Recall that the minimum distance of a block code C is defined as
dmin (C) = min dH (x, y).
x,y∈C
x6=y
Example:
The repetition code of blocklength n: {00 . . . 0}, 11
| {z . . . 1}}
| {z
n 0s n 1s
dim(C) = n − rank(H) = n − 1.
dmin (C) = 2.
Example: The Single Parity-Check Code
The length-n single parity-check code over F2 :
dim(C) = n − rank(H) = n − 1.
dmin (C) = 2.
x4
is in the Hamming code iff
x2 x3
x1 + x2 + x4 + x5 ≡ 0 (mod 2)
x7 x1 + x3 + x4 + x6 ≡ 0 (mod 2)
x2 + x3 + x4 + x7 ≡ 0 (mod 2)
Example: The Length-7 Hamming Code
A binary word
x1
x1 x2 x3 x4 x5 x6 x7
x5 x6
x4
is in the Hamming code iff
x2 x3
x1 + x2 + x4 + x5 ≡ 0 (mod 2)
x7 x1 + x3 + x4 + x6 ≡ 0 (mod 2)
x2 + x3 + x4 + x7 ≡ 0 (mod 2)
G = [ Ik | B ],
For example,
C = {0000, 0011, 1100, 1111}
is a [4, 2, 2] binary linear code.
I In every codeword, the 1st coordinate is the same as the 2nd.
I So, it is not possible to have a generator matrix of the form
1 0 ∗ ∗
G=
0 1 ∗ ∗
Row Operations and Column Permutations
Two codes are equivalent if one can be obtained from the other by
a permutation of coordinates.
For example,
C C
0000 0000
exchange 2nd and 3rd coords
0011 ←→ 0101
1100 1010
1111 1111
G = [ Ik | −AT ]
G = [ Ik | −AT ]
Hence,
1 0 0 0 1 1 0
0 1 0 0 1 0 1
G =
0
,
0 1 0 0 1 1
0 0 0 1 1 1 1
| {z } | {z }
I4 −AT
C ⊥ = {x ∈ Fn : x · c = 0 for all c ∈ C}
x ∈ C ⊥ ⇐⇒ x · cj = 0 for j = 1, 2, . . . , k
Dual Codes
x ∈ C ⊥ ⇐⇒ x · cj = 0 for j = 1, 2, . . . , k
C ⊥ = {x ∈ Fn : G xT = 0}.
C ⊥ = {x ∈ Fn : G xT = 0}.
C ⊥ = {x ∈ Fn : G xT = 0}.
Hence,
E(y) = {y + c : c ∈ C} =: y + C.
The Set of Error Vectors
Hence,
E(y) = {y + c : c ∈ C} =: y + C.
a ∼ b ⇐⇒ a − b ∈ C
a ∼ b ⇐⇒ a − b ∈ C
The coset leaders are precisely the error patterns that get corrected
by the standard array implementation of decoding.
The coset leaders are precisely the error patterns that get corrected
by the standard array implementation of decoding.
Some facts:
1. s is a (column) vector belonging to Fq n−k
=⇒ there are q n−k possible syndromes.
2. The syndrome of y ∈ Fq n is 0 iff y ∈ C.
Syndromes
Let H be an (n − k) × n parity-check matrix for C.
Definition: The syndrome of a vector y ∈ Fq n is s = HyT .
Some facts:
1. s is a (column) vector belonging to Fq n−k
=⇒ there are q n−k possible syndromes.
2. The syndrome of y ∈ Fq n is 0 iff y ∈ C.
Some facts:
1. s is a (column) vector belonging to Fq n−k
=⇒ there are q n−k possible syndromes.
2. The syndrome of y ∈ Fq n is 0 iff y ∈ C.
Proof:
I LHS = no. of error vectors of weight ≤ t
I RHS = no. of cosets
The Hamming Bound for Linear Codes
Proposition 2 (The Hamming bound for linear codes):
If an [n, k] linear code over Fq is t-error-correcting, then
t
X n
(q − 1)i ≤ q n−k .
i
i=0
Proof:
I LHS = no. of error vectors of weight ≤ t
I RHS = no. of cosets
H = [h1 h2 · · · hn ],
H = [h1 h2 · · · hn ],
H = [h1 h2 · · · hn ],
H = [h1 h2 · · · hn ],
H = [h1 h2 · · · h2r −1 ],
H = [h1 h2 · · · h2r −1 ],
qr − 1 qr − 1
In summary, Hr is a , − r , 3 linear code over Fq .
q−1 q−1
The fact that there are no other perfect codes was proved by
Tietäväinen (1973), building on the work of van Lint (early 1970s).
What Next?