Example: bankruptcy

Chapter 10 Error Detection and Correction

Chapter 10 Error Detection and The McGraw-Hill Companies, Inc. Permission required for reproduction or can be corrupted Notepduring applications require that errors be detected and correctederrors be detected and 1 INTRODUCTIONINTRODUCTIONLetLetusus firstfirstdiscussdiscusssomesome issuesissues related,related, directlydirectlyororindirectly,indirectl y, toto errorerror detectiondetection andand discussed in this section:Topics discussed in this section:Type s of E r ror sRedundancyD t tiVCtiDetection Versus CorrectionForward Error Correction Versus RetransmissionCodingCodingModular a single-bit Error , only 1 bit in the data it hhdunit has Single-bit burst Error means that 2 or more bits ithdtithhdin the data unit have Burst Error of length detect or correct errors, we need to dt( ddt) bitith d tsend extra (redundant) bits with The structure of encoder and this book, we concentrate on block dlltidcodes; we leave convolution codes to advanced modulo-N arithmetic, we use only the iti th0tN1iliintegers in the range 0 to N 1, XORing of two single bits or two 2 BLOCK CODINGBLOCK CODI

The Hamming distance between two word i th b f diffds is the number of differences between corresponding bits. 10.25. Example 10.4 Let us find the Hamming distance between two pairs of words. 1. The Hamming distance d(000, 011) is2because 2. The HiHamming distance d(10101, 11110) is 3 because

Tags:

  Distance, Hamming, Hamming distance

Information

Domain:

Source:

Link to this page:

Please notify us if you found a problem with this document:

Other abuse

Transcription of Chapter 10 Error Detection and Correction

1 Chapter 10 Error Detection and The McGraw-Hill Companies, Inc. Permission required for reproduction or can be corrupted Notepduring applications require that errors be detected and correctederrors be detected and 1 INTRODUCTIONINTRODUCTIONLetLetusus firstfirstdiscussdiscusssomesome issuesissues related,related, directlydirectlyororindirectly,indirectl y, toto errorerror detectiondetection andand discussed in this section:Topics discussed in this section:Type s of E r ror sRedundancyD t tiVCtiDetection Versus CorrectionForward Error Correction Versus RetransmissionCodingCodingModular a single-bit Error , only 1 bit in the data it hhdunit has Single-bit burst Error means that 2 or more bits ithdtithhdin the data unit have Burst Error of length detect or correct errors, we need to dt( ddt) bitith d tsend extra (redundant) bits with The structure of encoder and this book, we concentrate on block dlltidcodes.

2 We leave convolution codes to advanced modulo-N arithmetic, we use only the iti th0tN1iliintegers in the range 0 to N 1, XORing of two single bits or two 2 BLOCK CODINGBLOCK CODINGInInblockblockcodingcodingwewedivi dedivideourourmessagemessageintointobloc ksblocksInInblockblockcoding,coding,wewe dividedivideourourmessagemessageintointo blocks,blocks,eacheach ofof kk bits,bits, W eWe a ddadd rr redundantredundantbitsbitstotoeacheachbl ockblocktotomakemakethethelengthlengthnn ==kk++ ++ nn--bitbit blocksblocks areare DetectionTopics discussed in this section:Topics discussed in this section: Error CorrectionHamming DistanceMinimum hamming hamming DistanceFigure Datawords and codewords in block 4B/5B block coding discussed in Chapter 4 is a goodexampleof this typeof this codingscheme,k=4andn= ,wehave2k= 16 datawordsdddh6fand2n= that16outof32codewords are used for message transfer and the rest areihdfhdeitherusedforotherpurposes Process of Error Detection in block us assume that k = 2 and n = 3.

3 Table shows thelistof datawords and , wewillseehow to derive a codeword from a thesenderencodes thedataword01as011andsends it to the receiver. Consider the following receiver receives 011. It is a valid codeword. Theihdd01fireceiverextracts (continued) codeword is corrupted during transmission, and111 is is nota valid codeword and codeword is corrupted during transmission, extracts the dataword 00. Two corruptedbihdhdblbitshave madethe A code for Error Detection (Example ) Error -detecting code can detect lthtffhihitionly the types of errors for which it is designed; other types of errors may remain Structure of encoder and decoder in Error us add more redundant bits to Example to see ifthe receivercan correctan errorwithoutknowingwhatwas actually sent.

4 We add 3 redundant bits to the 2-bitddkbiddblhhdatawordto thedatawords and codewords. Assume the dataword is during transmission, and 01001 is dhhidddiFirst, the receiverfindsthatthereceivedcodewordisno tin the table. This means an Error has occurred. Theiihhil1bidreceiver, assumingthatthereisonly1bitcorrupted,use sthe following strategy to guess the correct (continued) received codeword with thefirstcodeword in the table (01001 versus 00000), thereceiverdecides thatthefirstcodeword is notthe onethat was sent because there are two different the same reasoning, the original codeword cannotbe the third orfourth one in the original codeword mustbe thesecond one in thetablebecausethisistheonlyonethatdiffe rsfromthereceived codeword receiverreplaces01001 with 01011 and consults the table to find A code for Error Correction (Example )

5 hamming distance between two d i thbf diffwords is the number of differences between corresponding us find the hamming distance between two pairs () (000, 011)is2because2 ThHidid(1010111110) (10101,11110) minimum hamming distance is the ll t Hidi tb tsmallest hamming distance betweenall possible pairs in a set of the minimum hamming distance of the codingscheme in Table first find all hamming dminin this case is the minimum hamming distance of the codingscheme in Table first find all the hamming dminin this case is guarantee the Detection of up to s illth iierrors in all cases, the minimumHamming distance in a block code must be dmin= s + minimum hamming distance for our first codescheme(Table )is codeguarantees detectionof only a single Error .

6 For example, if the third codeword()idhiddd(101)issentandone erroroccurs, the receivedcodeworddoes not match any valid codeword. If two errors occur,hhidddhlidhowever, the receivedcodewordmaymatchavalidcodeword and the errors are not second block code scheme (Table ) has dmin= codecan detectup to two , weseethatwhen any of the valid codewords is sent, two errors createddhi receiver cannot be , some combinations of three errors change alidddhlidddThivalidcodewordto the received codeword and the errors Geometric concept for finding dminin Error Geometric concept for finding dminin Error guarantee Correction of up to terrors illth iiH iin all cases, the minimum hamming distance in a block code must be dmin= 2t+ code scheme has a hamming distance dmin= and Correction capabilityof thisscheme?

7 SolutionSolutionThis code guarantees the Detection of up tothreeerrors(s=3)butitcancorrectuptoone errorInotherwords(s3), ,if this code is used for Error Correction , part of its distance (3, 5, 7, .. ). 3 LINEAR BLOCK CODESLINEAR BLOCK CODESA lmostAlmostallallblockblockcodescodesuse dusedtodaytodaybelongbelongtotoaasubsets ubsetAlmostAlmostallallblockblockcodesco desusedusedtodaytodaybelongbelongtotoaas ubsetsubsetcalledcalledlinearlinear blockblock AAlinearlinear blockblock codecode isis aa codecodeininwhichwhichthetheexclusiveexc lusiveOROR(addition(additionmodulomodulo 22))ofoftwotwoininwhichwhichthetheexclus iveexclusiveOROR(addition(additionmodulo modulo--22))ofoftwotwovalidvalid codewordscodewords createscreates anotheranother validvalid distance for Linear Block CodesTopics discussed in this section:Topics discussed in this section.

8 Some Linear Block a linear block code, the exclusive OR (XOR) ftliddd(XOR) of any two valid codewords creates another valid us see if the two codes we defined in Table andTable the class of the result of XORing any codeword with , theXORing of the second and third codewords creates can create all four codewords by XORing our first code (Table ), the numbers of 1s in thenonzero codewords are 2, 2, and the minimumHamming distance is dmin= 2. In our second code (Table) ),thenumbers of1sinthenonzerocodewordsare3,3, and 4. So in this code we have dmin= simple parity-check code is a ilbitdt tisingle-bit Error -detecting code in which n= k+ 1 with dmin= Simple parity-check code C(5, 4) Encoder and decoder for simple parity-check us look at some transmission scenarios.

9 Assume thesendersends the dataword codeword createdfrom this dataword is 10111, which is sent to the examinefive Error occurs; the received codeword is 10111. Thesyndrome is 0. The dataword 1011 is single-bit Error changes a1 . The receivedcodeword is 10011. The syndrome is 1. No datawordidis single-bit Error changes r0 . The received 10110. The syndrome is 1. No dataword is created. Example (continued)4. An Error changes r0and a second Error changes a3 .The received codeword is 00110. The syndrome is dataword 0011 is created at the receiver. Note thathhddildd hhere the dataword is wrongly created due to thesyndrome value. hbidhdb5. Three bits a3, a2, and a1 are changed by received codeword is 01011. The syndrome is dd id ThihhhilThe dataword is not created.

10 This shows that the simpleparity check, guaranteed to detect one single Error , canlfidddb falso find any odd number of simple parity-check code can detect ddbfan odd number of hamming codes discussed in thisNoteAll hamming codes discussed in this book have dmin= relationship between mand nin thdi21these codes is n= 2m Two-dimensional parity-check Two-dimensional parity-check Two-dimensional parity-check hamming code C(7, 4) The structure of the encoder and decoder for a hamming Logical decision made by the Correction logic us trace the path of three datawords from the sender to the dataword 0100 becomes the codeword diidhdiThe codeword 0100011 is received. The syndrome is000, the final dataword is dataword 0111 becomes the codeword syndrome is 011.


Related search queries