Math 342 Homework Assignment #5 (Due Thursday, March 24)

advertisement
Math 342
Homework Assignment #5 (Due Thursday, March 24)
1. For each linear code C, over GF (q), defined by the following generator matrices, find
a parity check matrix for C and generator and parity check matrices for C ⊥ .
(a) q = 3


1 0 0 0 1 2
G= 0 1 0 2 0 2 
0 0 1 2 0 0
(b) q = 4


0 1 0 1 a b
G= b 0 0 1 1 0 
a a a a b 1
Solution:
a. G is already in standard form I3 A . So,

 

0
−2
−2
1
0
0
0
1
1
1
0
0
0
0 0 1 0 = 2 0 0 0 1 0 
H = −AT I3 =  −1
−2 −2
0 0 0 1
1 1 0 0 0 1
H is a generator matrix for C ⊥ , and G is a parity check matrix for C ⊥ .
b. First, transform G to standard form, using reduction to RRE form:


0 1 0 1 a b
 b 0 0 1 1 0 
a a a a b 1


b 0 0 1 1 0
 0 1 0 1 a b 
a a a a b 1


b 0 0 1 1 0
 0 1 0 1 a b 
0 a a 1 0 1


b 0 0 1 1 0
 0 1 0 1 a b 
0 0 a b b 0


1 0 0 a a 0
 0 1 0 1 a b  = [I3 |A]
0 0 1 a a 0
where


a a 0
A= 1 a b 
a a 0
1
Then H = [B|I3 ] where


a 1 a
B = −AT =  a a a 
0 b 0
So,


a 1 a 1 0 0
H= a a a 0 1 0 
0 b 0 0 0 1
And H is a generator matrix for C ⊥ and G is a parity check matrix for C ⊥ .
2. Find the minimum distance of the linear codes over GF (q) defined by each of the
following parity check matrices.
(a) q = 3
H=
2 2 2 1
1 0 2 2
(b) q = 4


a b 1 1
H= b b a 0 
1 a a b
a. No column is the zero vector. Columns 1 and 4 form a linearly dependent set since
column 4 is 2× column 1. Thus, d(C) = 2.
b. Since the row space of a matrix is preserved under row equivalence and the dual
code uniquely determines the original code, it suffices to compute the minimum distance
using the RRE of H, which we compute as follows:


a b 1 1
 b b a 0 
1 a a b


a b 1 1
 0 a 0 a 
0 0 1 0


1 a b b
 0 1 0 1 
0 0 1 0


1 0 0 1
 0 1 0 1  = RRE
0 0 1 0
Since no column is all zero and since no pair of columns is linearly independent, d(C) ≥
3. But clearly the 1st, 2nd and 4th columns comprise a linearly dependent set. Thus,
d(C) = 3.
2
3. Let C be the linear code with parity check matrix


1 1 1 1 0 0
H= 0 1 1 0 1 0 
1 1 0 0 0 1
(a) Construct a syndrome decoding table, i.e., for each coset of C find a coset leader
and the corresponding syndrome.
(b) Decode each of the following received vectors
i. 110010
ii. 111111
Solution:
a. Since no column is all zero and since no pair of columns is linearly independent,
d(C) ≥ 3. And columns 3,4 and 5 form a linearly dependent set and so d(C) = 3.
Thus, C can correct 1 error and so each vector of weight 1 is a coset leader, with
corresponding syndrome equal to a single column of H. And 0̄ is a coset leader with
syndrome 0̄. This accounts for 7 cosets.
The number of cosets is 26 /23 = 23 = 8 and so there is one more coset. The syndrome
for this coset is the nonzero 3-bit vector which does not occur as a column of H,
namely, s = [0, 1, 1]. Checking weight two vectors we see that the vector [0, 0, 0, 0, 1, 1]
has syndrome s. Since all of the vectors of weight ≤ 1 have been used up, a coset
leader for this coset must have weight ≥ 2. Thus, [0, 0, 0, 0, 1, 1] is a coset leader. In
summary, a syndrome table is:
coset leader
000000
100000
010000
001000
000100
000010
000001
000011
syndrome
000
101
111
110
100
010
001
011
If one were to use incomplete syndrome decoding, then the bottom part of the syndrome
decoding table consists of only the last row (since [0, 1, 0, 1, 0, 0] also has syndrome = s
and could have been chosen as a coset leader).
b. We decode using complete syndrome decoding.
S(110010) = 000 and so we decode 110010 to itself, a codeword.
S(111111) = 011 and so we decode 111111 to 111111 − 000011 = 111100 which is a
codeword. If we were to use incomplete syndrome decoding, we would declare an error.
4. Let C and D be linear codes in V (n, q).
Let C + D = {x + y : x ∈ C, y ∈ D}.
3
(a) Show that C + D is a linear code.
(b) Show that (C + D)⊥ = C ⊥ ∩ D⊥
(c) Show that (C ∩ D)⊥ = C ⊥ + D⊥
a. Closure under addition:
Let x1 , x2 ∈ C and y1 , y2 ∈ C. Now, x1 + x2 ∈ C since C is a linear code. Similarly,
y1 + y2 ∈ D since D is a linear code. Thus, (x1 + y1 ) + (x2 + y2 ) = (x1 + x2 ) + (y1 + y2 ) ∈
C + D,
Closure under scalar multiplication:
Let x ∈ C, y ∈ D and α ∈ GF (q). Then since C is a linear code, we have αx ∈ C.
Similarly, αx ∈ D, and so α(x + y) = αx + αy ∈ C + D.
b. (C + D)⊥ ⊆ C ⊥ ∩ D⊥ :
Since C + D ⊇ C, (C + D)⊥ ⊆ C ⊥ . Similarly, (C + D)⊥ ⊆ D⊥ . Thus, (C + D)⊥ ⊆
C ⊥ ∩ D⊥ .
(C + D)⊥ ⊇ C ⊥ ∩ D⊥ :
Let z ∈ C ⊥ ∩ D⊥ . Let x ∈ C and y ∈ D. Then z · x = 0 and z · y = 0. Thus,
z · (x + y) = 0. Thus, z ∈ (C + D)⊥ . So, (C + D)⊥ ⊇ C ⊥ ∩ D⊥ .
c. apply part b) to C 0 = C ⊥ and D0 = D⊥ and use the fact that for any linear code
F , (F ⊥ )⊥ = F . Then,
(C ⊥ +D⊥ )⊥ = (C ⊥ )⊥ ∩(D⊥ )⊥ = C ∩D. Now, take the ⊥ of both sides of this equation
to get (C ⊥ + D⊥ ) = (C ∩ D)⊥ .
4
Download