Assistance Professor Dr. Mahmood F. Mosleh
Assistance Professor Dr. Mahmood F. Mosleh
Assistance Professor
Dr. Mahmood F. Mosleh
Block Codes
• Dataword length k = 4
• Codeword length n = 7
Dataword Codeword
0 0 0 0 0 0 0
0 0 1 0 0 1 1
0 1 0 0 1 0 1
0 1 1 0 1 1 0
1 0 0 1 0 0 1
1 0 1 1 0 1 0
1 1 0 1 1 0 0
1 1 1 1 1 1 1
Linear Block Codes
• As seen from the Parity Code, it is possible to use a
table to hold all the codewords for a code and to
look-up the appropriate codeword based on the
supplied dataword
• Alternatively, it is possible to create codewords by
addition of other codewords. This has the
advantage that there is now no longer the need to
held every possible codeword in the table.
Linear Block Codes
Linearity: If m1 c1 and m 2 c2
then m1 m 2 c1 c2
c=(c1 c2……..cn)
Linear Block Codes
• For example for a (7,4) code, only four codewords are
required, e.g.,
1 0 0 0 1 1 0
0 1 0 0 1 0 1
0 0 1 0 0 1 1
0 0 0 1 1 1 1
𝐼𝑛−𝑘
𝐻𝑇 = −−
𝑃
It can be test whether a received vector is a valid member of the codeword set, such that U is a
codeword generated by matrix G if, and only if 𝑈 × 𝐻𝑇 = 0
Syndrome testing
Let 𝑟 = 𝑟1 , 𝑟2 , … … . , 𝑟𝑛 be a received vector resulting from the transmission of 𝑈 = 𝑢1 , 𝑢2 , … . , 𝑢𝑛 . It can
describe r as:
𝑟=𝑈+𝑒
where 𝑒 = 𝑒1 , 𝑒2 , … . . , 𝑒𝑛 is an error vector introduced by the channel. The syndrome of r is defined as:
𝑆 = 𝑟 × 𝐻𝑇
So 𝑆 = 𝑈 + 𝑒 𝐻𝑇 = (𝑈𝐻𝑇 + 𝑒𝐻𝑇 )
However 𝑈𝐻𝑇 = 0 for all member of cpdeword set, therefor
𝑆 = 𝑒𝐻𝑇
The parity check matrix have two required properties:
1. No column of H can all zeros.
2. All columns of H must be unique.
Example for syndrome testing
Therefor the codeword for the message vector [1 1 0] is [1 0 1 1 1 0]
The received vector is 𝑟 = [0 0 1 1 1 0]
Now if the resulted syndrome is not zero, the received vector is corrupted:
𝑆 = 0 0 1 1 1 0 𝐻𝑇 = [1 0 0]
Which is indicate that an error in the received vector.
Not that:
1 0 0
0 1 0
𝐼𝑛−𝑘
0 0 1
𝐻𝑇 = − − =
1 1 0
𝑃
0 1 1
1 0 1
Locating the Error Pattern
First determine the syndrome corresponding to each of the
one-bit correctable error sequences by computing
𝑒𝑗 𝐻 𝑇 as follow:
1 0 0
0 1 0
0 0 1
S= 𝑒𝑗
1 1 0
0 1 1
1 0 1
The results are listed in the table
Example of Correcting Error
Assume the received codeword is 𝑟 = [0 0 1 1 1 0]. The syndrome of r is
computed 𝑆 = 0 0 1 1 1 0 𝐻 𝑇 = [1 0 0]. Using the previous table, the error
pattern corresponding to the syndrome is estimated to be
𝑒Ƹ = 1 0 0 0 0 0
The corrected vector is then estimated by
= 𝑟 + 𝑒Ƹ
𝑈
=001110+100000
=101110
Decoder Implementation
We can write an expression of each of the syndrome
digits in term of received codeword digits as:
𝑆 = 𝑒𝐻 𝑇
1 0 0
0 1 0
0 0 1
S= [𝑟1 𝑟2 𝑟3 𝑟4 𝑟5 𝑟6 ]
1 1 0
0 1 1
1 0 1
and
Circuit Diagram of (6,3) SLBC