Upload
paksmiler
View
232
Download
0
Embed Size (px)
Citation preview
7/24/2019 F8 error correcting codes.ppt
1/43
Lecture 8: Coding
Anders Vstberg
!"ides are a se"ection #ro$ the s"ides #ro$
cha%ter 8 #ro$:htt%:&&'i""ia$sta""ings.co$&(ire"ess&(ire"ess)e.ht$"
mailto:[email protected]:[email protected]7/24/2019 F8 error correcting codes.ppt
2/43
Co%ing 'ith *ata
+rans$ission ,rrors ,rror detection codes
*etects the %resence o# an error
Auto$atic re%eat re/uest A123 %rotoco"s "ock o# data 'ith error is discarded
+rans$itter retrans$its that b"ock o# data
,rror correction codes5 or #or'ard
correction codes 6,C3 *esigned to detect and correct errors
7/24/2019 F8 error correcting codes.ppt
3/43
,rror *etection
robabi"ities *e#initions
Pb: robabi"it o# sing"e bit error ,13
P9: robabi"it that a #ra$e arrives 'ith no bit
errors
P): (hi"e using error detection5 the %robabi"it that
a #ra$e arrives 'ith one or $ore undetected errors
P:: (hi"e using error detection5 the %robabi"it that
a #ra$e arrives 'ith one or $ore detected biterrors but no undetected bit errors
7/24/2019 F8 error correcting codes.ppt
4/43
,rror *etection
robabi"ities (ith no error detection
6 ;
7/24/2019 F8 error correcting codes.ppt
5/43
Error Detection Process
7/24/2019 F8 error correcting codes.ppt
6/43
arit Check
arit bit a%%ended to a b"ock o# data
,ven %aritAdded bit ensures an even nu$ber o# s
=dd %aritAdded bit ensures an odd nu$ber o# s
,>a$%"e5 7-bit character ?000 ,ven %arit ?0000
=dd %arit ?000
7/24/2019 F8 error correcting codes.ppt
7/43
Cc"ic 1edundanc Check
C1C3 +rans$itter
6or a k-bit b"ock5 trans$itter generates ann-k3-bit #ra$e check se/uence 6C!3
1esu"ting #ra$e o# nbits is e>act" divisib"e b%redeter$ined nu$ber
1eceiver
*ivides inco$ing #ra$e b %redeter$inednu$ber
# no re$ainder5 assu$es no error
7/24/2019 F8 error correcting codes.ppt
8/43
C1C using Bodu"o )
Arith$etic ,>c"usive-=1 =13 o%eration
ara$eters: T ; n-bit #ra$e to be trans$itted
D ; k-bit b"ock o# dataD the #irst k bits o# T
F ; (n k3-bit 6C!D the "ast (n k3 bits o# T
P ; %attern o# nkE bitsD this is the %redeter$ineddivisor
Q; 2uotient R; 1e$ainder
7/24/2019 F8 error correcting codes.ppt
9/43
CRC using Modulo 2
Arithmetic For T/Pto have no remainder start !ith
Divide 2n"k
D#$ Pgives %uotient andremainder
&se remainder as FC'
FDT kn += 2
P
RQ
P
Dkn+=
2
RDT kn += 2
7/24/2019 F8 error correcting codes.ppt
10/43
C1C using Bodu"o )
Arith$etic *oes R cause T&P have no re$ainderF
!ubstituting5
act" divisib"e b P
P
R
P
D
P
RD
P
T knkn
+=+
=
22
Q
P
RRQ
P
R
P
RQ
P
T=
++=++=
7/24/2019 F8 error correcting codes.ppt
11/43
C1C using o"no$ia"s
A"" va"ues e>%ressed as %o"no$ia"s
*u$$ variab"eX'ith binar coe##icients
( )( )
( ) ( )( )
( ) ( ) ( )XRXDXXT
XPXRXQ
XPXDX
kn
kn
+=
+=
7/24/2019 F8 error correcting codes.ppt
12/43
C1C using o"no$ia"s
(ide" used versions o#P(X)
C1C)
) E E E ) E E
C1CG G E E ) E
C1C CC++
G E ) E E
C1C ) ) E )G E ) E ))E G E ) E E 0 E8 E 7 E E4 E
) E E
7/24/2019 F8 error correcting codes.ppt
13/43
C1C using *igita" Logic
*ividing circuit consisting o#:
=1 gates
H% to n k =1 gates
resence o# a gate corres%onds to the %resence o#
a ter$ in the divisor %o"no$ia" PX3
A shi#t register
!tring o# -bit storage devices 1egister contains n k bits5 e/ua" to the "ength o#
the 6C!
7/24/2019 F8 error correcting codes.ppt
14/43
Digital (ogic CRC
7/24/2019 F8 error correcting codes.ppt
15/43
(ire"ess +rans$ission
,rrors ,rror detection re/uires retrans$ission
*etection inade/uate #or 'ire"ess
a%%"ications
,rror rate on 'ire"ess "ink can be high5 resu"ts
in a "arge nu$ber o# retrans$issions
Long %ro%agation de"a co$%ared to
trans$ission ti$e
7/24/2019 F8 error correcting codes.ppt
16/43
"ock ,rror Correction
Codes +rans$itter
6or'ard error correction 6,C3 encoder $a%s
each k-bit b"ock into an n-bit b"ock code'ord
Code'ord is trans$ittedD ana"og #or 'ire"ess
trans$ission
1eceiver
nco$ing signa" is de$odu"ated
"ock %assed through an 6,C decoder
7/24/2019 F8 error correcting codes.ppt
17/43
For!ard Error Correction
Process
7/24/2019 F8 error correcting codes.ppt
18/43
6,C *ecoder =utco$es
7/24/2019 F8 error correcting codes.ppt
19/43
"ock Code rinci%"es
Ia$$ing distance #or ) n-bit binar
se/uences5 the nu$ber o# di##erent bits
,.g.5 v9;00D v);000D dv5 v)3;
1edundanc ratio o# redundant bits to data bits Code rate ratio o# data bits to tota" bits
Coding gain the reduction in the re/uired Eb&N0
to achieve a s%eci#ied ,1 o# an error-correctingcoded sste$
7/24/2019 F8 error correcting codes.ppt
20/43
Io' Coding $%roves
er#or$ance
7/24/2019 F8 error correcting codes.ppt
21/43
Ia$$ing Code
*esigned to correct sing"e bit errors
6a$i" o# n5 k3 b"ock error-correcting codes 'ith%ara$eters:
"ock "ength: n ; )m
7/24/2019 F8 error correcting codes.ppt
22/43
Ia$$ing Code rocess
,ncoding: kdata bits E n -k3 check bits
*ecoding: co$%ares received n -k3 bits
'ith ca"cu"ated n -k3 bits using =1
1esu"ting n -k3 bits ca""ed syndrome word
!ndro$e range is bet'een 0 and )n-k3-
,ach bit o# sndro$e indicates a $atch 03 or
con#"ict 3 in that bit %osition
7/24/2019 F8 error correcting codes.ppt
23/43
Cc"ic Codes
Can be encoded and decoded using "inear
#eedback shi#t registers L6!1s3
6or cc"ic codes5 a va"id code'ord c05 c95 J5 cn-
935 shi#ted right one bit5 is a"so a va"id code'ordcn-95 c05 J5 cn-)3
+akes #i>ed-"ength in%ut k3 and %roduces #i>ed-
"ength check code n-k3 n contrast5 C1C error-detecting code acce%tsarbitrar "ength in%ut #or #i>ed-"ength check code
7/24/2019 F8 error correcting codes.ppt
24/43
CI Codes
6or %ositive %air o# integers m and t5 a n5k3 CI code has %ara$eters: "ock "ength: n ; )m
7/24/2019 F8 error correcting codes.ppt
25/43
1eed-!o"o$on Codes
!ubc"ass o# nonbinar CI codes
*ata %rocessed in chunks o# m bits5 ca""eds$bo"s
An n5 k3 1! code has %ara$eters: !$bo" "ength: m bits %er s$bo"
"ock "ength: n ; )m s$bo"s ; m)m 3 bits
*ata "ength: k s$bo"s
!iMe o# check code: n k ; 2t s$bo"s ; m2t3 bits Bini$u$ distance: d$in; 2t E s$bo"s
7/24/2019 F8 error correcting codes.ppt
26/43
)loc* +nterleaving
Data !ritten to and read ,rom memor$ in di,,erentorders
Data #its and corres-onding chec* #its are
inters-ersed !ith #its ,rom other #loc*s At receiver data are deinterleaved to recover original
order
A #urst error that ma$ occur is s-read out over a
num#er o, #loc*s ma*ing error correction -ossi#le
7/24/2019 F8 error correcting codes.ppt
27/43
)loc* +nterleaving
7/24/2019 F8 error correcting codes.ppt
28/43
Convolutional Codes
.enerates redundant #its continuousl$
Error chec*ing and correcting carried outcontinuousl$
0n k K code +n-ut -rocesses k#its at a time
ut-ut -roduces n#its ,or ever$ kin-ut #its
K3 constraint ,actor
kand ngenerall$ ver$ small
n"#it out-ut o, 0n k K code de-ends on4 Current #loc* o, kin-ut #its
Previous K"1 #loc*s o, kin-ut #its
7/24/2019 F8 error correcting codes.ppt
29/43
Convolutional Encoder
7/24/2019 F8 error correcting codes.ppt
30/43
*ecoding
+re""is diagra$ e>%anded encoder diagra$
Viterbi code error correction a"gorith$ Co$%ares received se/uence 'ith a"" %ossib"e
trans$itted se/uencesA"gorith$ chooses %ath through tre""is 'hose codedse/uence di##ers #ro$ received se/uence in the#e'est nu$ber o# %"aces
=nce a va"id %ath is se"ected as the correct %ath5 the
decoder can recover the in%ut data bits #ro$ theout%ut code bits
7/24/2019 F8 error correcting codes.ppt
31/43
+re""is *iagra$
7/24/2019 F8 error correcting codes.ppt
32/43
+re""is *iagra$
7/24/2019 F8 error correcting codes.ppt
33/43
+re""is diagra$
7/24/2019 F8 error correcting codes.ppt
34/43
Viterbi a"gorith$
7/24/2019 F8 error correcting codes.ppt
35/43
Auto$atic 1e%eat
1e/uest Bechanis$ used in data "ink contro" and
trans%ort %rotoco"s
1e"ies on use o# an error detection code
such as C1C3
6"o' Contro"
,rror Contro"
7/24/2019 F8 error correcting codes.ppt
36/43
6"o' Contro"
Assures that trans$itting entit does notover'he"$ a receiving entit 'ith data
rotoco"s 'ith #"o' contro" $echanis$ a""o'
$u"ti%"e *Hs in transit at the sa$e ti$e *Hs arrive in sa$e order theNre sent
!"iding-'indo' #"o' contro" +rans$itter $aintains "ist 'indo'3 o# se/uence
nu$bers a""o'ed to send 1eceiver $aintains "ist a""o'ed to receive
7/24/2019 F8 error correcting codes.ppt
37/43
6"o' Contro"
1easons #or breaking u% a b"ock o# data
be#ore trans$itting:
Li$ited bu##er siMe o# receiver
1etrans$ission o# *H due to error re/uires
s$a""er a$ounts o# data to be retrans$itted
=n shared $ediu$5 "arger *Hs occu%
$ediu$ #or e>tended %eriod5 causing de"asat other sending stations
7/24/2019 F8 error correcting codes.ppt
38/43
Flo! Control
7/24/2019 F8 error correcting codes.ppt
39/43
,rror Contro"
Bechanis$s to detect and correct
trans$ission errors
+%es o# errors:
Lost *H : a *H #ai"s to arrive
*a$aged *H : *H arrives 'ith errors
7/24/2019 F8 error correcting codes.ppt
40/43
,rror Contro"
1e/uire$ents ,rror detection
1eceiver detects errors and discards *Hs
ositive ackno'"edge$ent
*estination returns ackno'"edg$ent o# received5error-#ree *Hs
1etrans$ission a#ter ti$eout !ource retrans$its unackno'"edged *H
7/24/2019 F8 error correcting codes.ppt
41/43
Oo-back-< A12
Ackno'"edg$ents
11 ; receive read no errors occur3
1,P ; reQect error detected3
Contingencies
*a$aged *H
*a$aged 11
*a$aged 1,P
7/24/2019 F8 error correcting codes.ppt
42/43
Oo-back < A12
7/24/2019 F8 error correcting codes.ppt
43/43
Io$e'ork e#ore 6
+a reda %R vad #S"Qande begre%% betder
och gSr en kort beskring #Sr varQe.
O,=
B,=
L,=
hSQdvinke"