<< Chapter < Page Chapter >> Page >

In effect, at the end of every calculation, the answer is taken modulo 2.For instance, in standard arithmetic, x 4 G = 11112 . The correct code word c 4 is found by reducing each calculation modulo 2. In M atlab , this is done with mod(x4*g,2) where x4=[1,1] and g is defined as in [link] . In modulo 2 arithmetic, 1 represents any odd number and0 represents any even number. This is also true for negative numbers so that, for instance, - 1 = + 1 and - 4 = 0 .

After transmission, the received signal y is multiplied by H T . If there were no errors in transmission, then y is equal to one of the four code words c i . With H defined as in [link] , c 1 H T = c 2 H T = c 3 H T = c 4 H T = 0 , where the arithmetic is binary, and where 0 means thezero vector of size 1 by 3 (in general, 1 by ( n - k ) ). Thus y H T = 0 and the received signal is one of the code words.

However, when there are errors, y H T 0 , and the value can be used to determine the most likely errorto have occurred. To see how this works, rewrite

y = c + ( y - c ) c + e ,

where e represents the error(s) that have occurred in the transmission. Note that

y H T = ( c + e ) H T = c H T + e H T = e H T ,

since c H T = 0 . The value of e H T is used by looking in the syndrome [link] . For example, suppose that the symbol x 2 = 01 is transmitted using the code c 2 = 01011 . But an error occurs in transmission so that y = 11011 is received. Multiplication by the parity check matrix gives y H T = e H T = 101 . Looking this up in the syndrome table shows that the most likely error was 10000.Accordingly, the most likely code word to have been transmitted was y - e = 11011 - 10000 = 01011 , which is indeed the correct code word c 2 .

Syndrome Table for the binary ( 5 , 2 ) code with generator matrix [link] and parity check matrix [link]
Syndrome e H T Most lik Most likely error e
000 00000
001 00001
010 00010
011 01000
100 00100
101 10000
110 11000
111 10010

On the other hand, if more than one error occurred in a single symbol, then the (5,2) code cannot necessarilyfind the correct code word. For example, suppose that the symbol x 2 = 01 is transmitted using the code c 2 = 01011 but that two errors occur in transmission so that y = 00111 is received. Multiplication by the parity check matrix gives y H T = e H T = 111 . Looking this up in the syndrome table shows that the most likely error was 10010.Accordingly, the most likely symbol to have been transmitted was y - e = 00111 + 10010 = 10101 , which is the code word c 3 corresponding to the symbol x 3 , and not c 2 .

The syndrome table can be built as follows. First, take each possible single error pattern, that is, each ofthe n = 5 e 's with exactly one 1, and calculate e H T for each. As long as the columns of H are nonzero and distinct, each error pattern corresponds to a different syndrome.To fill out the remainder of the table, take each of the possible double errors (each of the e 's with exactly two 1's) and calculate e H T . Pick two that correspond to the remaining unused syndromes.Since there are many more possible double errors n ( n - 1 ) = 20 than there are syndromes ( 2 n - k = 8 ), these are beyond the ability of the code to correct.

The M atlab program blockcode52.m shows details of how this encoding and decoding proceeds. The first part defines the relevantparameters of the ( 5 , 2 ) binary linear block code: the generator g , the parity check matrix h , and the syndrome table syn . The rows of syn are ordered so that the binary digits of e H T can be used to directly index into the table.

Get Jobilize Job Search Mobile App in your pocket Now!

Get it on Google Play Download on the App Store Now




Source:  OpenStax, Software receiver design. OpenStax CNX. Aug 13, 2013 Download for free at http://cnx.org/content/col11510/1.3
Google Play and the Google Play logo are trademarks of Google Inc.

Notification Switch

Would you like to follow the 'Software receiver design' conversation and receive update notifications?

Ask