CSE5313 Coding and information theory for data science (Lecture 8)
Review on Linear codes
| The code | Dimension (effective message length) | Minimum distance | Dual code | Minimum distance of dual code |
|---|---|---|---|---|
| Parity code | Repetition code | |||
| Hamming code | Punctured Hadamard code |
More on linear codes
Extended Hamming code
Consider the Hamming code .
Extend it to a cod eof length by adding a parity bit.
Recall the hamming code .
The extended Hamming code is:
The minimum distance of the extended Hamming code is 4.
Proof for minimum distance
It is sufficient to show that every 3 columns are linearly independent.
Using the lemma for minimum distance, we have that the minimum distance is 4.
Notice that in , multiplication is equivalent to AND operation.
By simple observations, we know that every 2 columns are linearly independent.
Consider the following linear combination:
Therefore, every 3 columns are linearly independent since the top row will always be 1. if are .
Therefore, the minimum distance is 4.
For the dimension of this code, we have , with total code length .
Augmented Hadamard code
Consider what is generated by the parity check matrix of the extended Hamming code.
Let
- If , then , where is the punctured hadamard codeword.
- If , then , where is the punctured hadamard codeword.
Therefore, the code generated by is given by:
Let be the hadamard code.
Let be its shift by the all 1’s vector (flip all bits of all words).
– Augmented Hadamard code = .
The length of the code is .
The dimension of the code is .
Since the code is still linear, the minimum distance is the minimum weight of the codewords.
So minimum distance of is .
Summary for simple linear codes
| The code | Dimension (effective message length) | Minimum distance | Dual code | Minimum distance of dual code |
|---|---|---|---|---|
| Parity code | Repetition code | |||
| Hamming code | (length ) | Punctured Hadamard code | ||
| Extended Hamming code | (length ) | Augmented Hadamard code |
Boundary of linear codes
Natural questions:
- Can we extend the table of linear codes infinitely?
- What set of configuration are impossible?
- What set of configuration are possible, even if we don’t know how to construct them?
Boundary I: Singleton bound
Singleton is a name for the person who discovered this bound.
Theorem: For any linear code , we have .
Proof
Idea: Using the Pigeonhole principle.
Assume an code exists.
Pigeons: All possible code word of .
Holes: All values of the first entries of a codeword (for some ).
If , then by Pigeonhole principle, there exists two codewords in that agrees on the first entries.
So .
So the largest value for which this arguments works is .
Definition of Maximum Distance Separable (MDS) code
A code with is called a Maximum Distance Separable (MDS) code.
Examples for singleton bound
: any .
- Attains with equality!
Parity: any .
- Attains with equality!
Hamming: .
.
This creates some trade-off between and .
Boundary II: The Sphere Packing Bound
Let , then .
Proof
Let , and let for some .
Computer .
.
.
So, .
Recall that of minimum distance if and only if .
Therefore, let , we have .
Definition for perfect code
A code is called a perfect code if .
Examples for sphere packing bound
Let .
: any .
- .
- .
- Attained with equality!
Parity: any .
-
.
-
.
-
NOT attained with equality.
Exercise: Equality is attained for the repetition code (dual of parity) for odd .
Hamming: .
- .
- .
- .
- Attained with equality!
• Attained with equality!
Fortunately, there are only 4 types of binary linear perfect codes:
- Repetition code
- Hamming code
- Golay code
Boundary III: The Gilbert-Varshamov Bound
Let such that , then there exists an code.
Singleton, sphere-packing provide necessary conditions for existence of codes.
Are there sufficient conditions?
Recall:
- Lemma: The minimum distance of is the maximum integer such that every columns of the parity-check matrix are linearly independent.
Idea:
- Construct column by column, ensuring that no dependencies occur.
Idea:
Construct column by column, ensuring that no dependencies occur.
Algorithm:
- Begin with identity matrix.
- Assume we choose columns (each is in )
- Then next column must not be in the space of any previous columns.
- cannot be written as for of Hamming weight at most .
- So the ineligible candidates for is:
- .
- , denoted by .
- So the candidates for is:
- Out of which are ineligible.
- Need columns overall, so we need .