0% found this document useful (0 votes)
20 views43 pages

Channel Coding

This document discusses channel coding techniques including waveform coding, orthogonal signals, error control methods, and linear block codes. It describes antipodal signals, orthogonal signals, correlation detection, orthogonal codes, and their properties. Error control methods like ARQ and FEC are also covered. Finally, the document discusses linear block codes, generator and parity check matrices, and dual codes.

Uploaded by

gary.39462182
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views43 pages

Channel Coding

This document discusses channel coding techniques including waveform coding, orthogonal signals, error control methods, and linear block codes. It describes antipodal signals, orthogonal signals, correlation detection, orthogonal codes, and their properties. Error control methods like ARQ and FEC are also covered. Finally, the document discusses linear block codes, generator and parity check matrices, and dual codes.

Uploaded by

gary.39462182
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 43

CHAPTER 6

CHANNEL CODING
6.1 Waveform Coding

• Waveform coding use coding pattern for better


waveform to reduce detection error
EX :
orthogonal coding for signal design
Sequence coding:use Redundant code for error detection
and error correction
A. Antipodal signal
Two signals with out of phase Fig6.2 p307
: Maximum distance between two signal
: Best performance (minimum error probability)

Figure 6.2 Example of an antipodal signal set.


B. Orthogonal signal

ò ( )s (t )dt = [
T 0 i¹ j
condition: si t j
0 E i= j
E is signal energy
correlation coefficiency
1 T
Z ij = ò si (t )s j (t )dt = {
0 i¹ j

E 0 1 i= j

C. M-ary signal
MPSK ; MFSK ; MPAM→M-Level
D. Correlation detection in digital sequence
NA - ND
Z ij =
NT
NA : number of digit agreements
N D : number of digit disagreements
N T : total number of digit in the sequence

1 i= j
if orthogonal Z ij = {
0 otherwise
E. Orthogonal code
a. Code word matrix of orthogonal code

Data set orthogonal code


0 é 0 0ù
H1 = ê ú
1 ë 0 1 û

Expansion

é H k -1 H k -1 ù
HK = ê
ë H k -1 H k -1 úû
EX: k=2 two bit

data set orthogonal codeword set


0 0 é0 0 0 0ù
0 1 ê0 1 0 1ú
H2 = ê ú
1 0 ê0 0 1 1ú
ê ú
1 1 ë0 1 1 0û
k
M= 2
M: number of bit in orthogonal code word
K: number of data bit
which is orthogonal since (use Bipolar ie: binary 1→ +1
binary → -1)
Ex: 00 00 and 01 01 →(-1, -1, -1, -1),(-1, 1, -1, 1)
note (-1)(-1) + (-1)(1) + (-1)(-1) + (-1)(1) = 1 – 1 + 1-1 = 0
é0 0 0 0 0 0 0 0ù
ê0 1 0 1 0 1 0 1ú
ê ú
ê0 0 1 1 0 0 1 1ú
ê ú
éH 2 H 2 ù ê0 1 1 0 0 1 1 0ú
H3 = ê =
ëH 2 H 2 úû ê0 0 0 0 1 1 1 1ú
ê ú
ê0 1 0 1 1 0 1 0ú
ê0 0 1 1 1 1 0 0ú
ê ú
ë0 1 1 0 1 0 0 1û

b. Symbol/Bit error probability


PE = PE (M ) = (2 k - 1)Q ( Es N 0 ) upper bounded
PB 2 k -1 2 M
1
= k = k ­ PB ¯
PE 2 - 1 M - 1
2k M
but (1). BW↑, =
k k 2k
(2). Data rate 同,transmission rate↑ k
F. Biorthogonal codes
use antipodal waveform
M
use 2 -bit signal to replace M-bit codeword
é H k -1 ù
Bk = ê ú
H
ë k -1 û
1 i= j
M
Z ij = - 1 i¹ j i- j = antipodal
2
0 i¹ j

PB =
1
2
[
(M - 2) Q KEb N 0 + Q 2 KEb N 0 ]
1
better performance than orthogonal BW→ 2
G. Trans orthogonal code →Simplex code
detect first digit of orthogonal set, since it always
Binary 0
there are (M-1) bit codeword
1 i= j
Z ij = { -1
i¹ j
M -1

minimum power since k→k-1 ie: KEb ® (K - 1)Eb


BW↓ than orthogonal
6.2 type of error control

A. Error detection transmission


two way →use ARQ Automatic retransmission query
B. FEC: Forward error correction error detection
and correction one way
6.2-1 Classification of communication
terminal by connectivity

Figure 6.6 Terminal connectivity classifications. (a) Simplex. (b) Half-duplex.


(c) Full-duplex.
6.2-2 ARQ

A. Stop-and wait ARQ Fig 6.7 a


each data need ARQ using half duplex
yes: ACK acknowledgment
no: NAK not acknowledgment (need retransmission)
→ much time
B. Pull back full duplex ARQ Fig 6.7 b
Full duplex but with fixed data length in Ex 4 bit
C. Selective-error bit full duplex ARQ Fig 6.7 c
as (b) but retransmit the error one only
Figure 6.7 Automatic repeat request (ARQ). (a) Stop-and-wait ARQ (half-duplex). (b)
Continuous ARQ with pullback (full-duplex). (c) Continuous ARQ with selective repeat
(full-duplex).
6.3 structure sequence →channel coding

A. DMC ( Discrete Memory less channel )


a. DMC
channel noise is defined to affect each symbol
independently of all other symbols the conditional
probability of given input sequenceU = u1 , u2 ,, um ,, u N
to the corresponding output sequence Z = z1 , z2 ,, zm ,, z N
is expressed as
N
P (Z | U ) = Õ P (z m | um )
m =1
b. Gaussian channel
signal in Gaussion distribution
1 é - (z - uk )2 ù
P (z | uk ) = exp ê ú
s 2p ë 2 s 2
û
uk : Mean of uk -bit
c. BSC Binary symmetric channel
the conditional probability are same
P (1 0) = P (0 1) = p
P (0 0) = P (1 1) = 1 - p
p:error probability
1-p: correct probability
B. Code rate η
in formation Bit sec = k
h=
transmission code Bit sec = n = k + r
r: redundant bit
k k
h= = £1
n k+r

C. Signal parity check code


even bit → coded 0
odd bit → coded 1
Ex:
000 ® 0000
110 ® 0110
100 ® 1100
111 ® 1111
• Signal-bit error can be detected but not be corrected, even
bit error can’t be detected
the undetected error probability
n
2
æ n ö 2j n is even
Pnd = å çç ÷÷ p (1 - p )
n -2 j

j =1 è 2 j ø n is odd→(n-1)/2
D. Rectangular code

Figure 6.8 Parity checks for serial and parallel code structures. (a) Serial
structure. (b) Parallel structure.
N-bit word length → N+1
M codeword → M+1
MN
code rate h =
(M + 1)(N + 1)

can correct one bit error


the block code error probability
n
ænö j
PM = å çç ÷÷ p (1 - p )
n- j

j =t +1 è j ø
in rectangular code t=1, ie j=2
error more than 2-bit → can’t correct
6.4 Linear Block Code

A. Linear block code


V j , Vi are block code
if linear V j Å Vi is also a code word
( n,k ) block n=k + r
B. Generator Matrix
é v1 ù é v11 v12  v1n ù
êv ú êv v22  v2 n ú
G= ê 2ú
= ê 21 ú
êú ê     ú
ê ú ê ú
ë vk û ë vk 1 vk 1  vkn û
m = [m1 m2  mk ] massage code
U = [u1 u2  un ] transmission code

U = mG
= m1v1 Å m2 v2 Å  Å mk vk
= [U1 U 2  U n ] : use in modulo 2 adder
C. Systematic linear block code
[m1 m2  mk ] ¾k¾
¾®[U1 U 2  U n ]
®n

= [C1 C2  Cn - k m1 m2  mk ]

then
G = [P | I k ]
é p11 p12  p1(n - k ) ù
êp p22  p2 ( n - k ) ú
P=ê ú
21

ê     ú
ê ú
ë pk 1 pk 2  pk ( n - k ) û

P is the parity array portion


D. Dual block code
æ n ö dual æ n ö æ n ö
çç ÷÷ ¬¾
¾®çç ÷÷or çç ÷÷
èk ø èn - k ø è r ø
[
H = In -k | PT ]
é In -k ù
H =ê
T
ú
ë P û
H is parity check matrix
E. Parity check matrix
note é p11 p12  p1(n - k ) | 1 0  0ù
êp p22  p2 (n - k ) | 0 1  0ú
G=ê ú
21

ê     |    ú
ê ú
ë pk 1 pk 2  pk (n - k ) | 0 0  1û
U = [U1 U 2  U n ]
m = [m1 m2  mk ]
U = mG
= [C1 C2  Cn - k m1 m2  mk ]
C1 = m1 p11 + m2 p21 +  + mk Pk 1
C2 = m1 p12 + m2 p22 +  + mk pk 2

Cn - k = m1 p1(n - k ) + m2 p2 (n - k ) +  + mk pk (n - k )

since orthogonal é1 0  0 ù
then UH T = 0 ê0 1  0 ú
ê ú
ê     ú
ê ú
0 0  1 ú
where [
H = In -k | PT ] é I ù
H T = ê n -k ú = ê
ë P û ê p11 p12  p1(n - k ) ú
ê ú
ê p21 p22  p2 (n - k ) ú
ê     ú
ê ú
êë pk 1 pk 2  pk (n - k ) úû
F. Syndrome testing
if R is received sequence
R=U+E E: is error pattern
S = RH T
= (U + E ) H T
= UH T + EH T
= EH T
the position of error bit can be determined by the error
pattern
G. Error pattern and error correction
for ( 6 , 3 ) block code with G and H above

Figure 6.11 Example of a standard array for a (6, 3) code.


6.5 coding strength
<A> hamming weight
W(U)à no. of being 1 in u code word
ex. U = 1010110 W(U) = 4
<B> hamming distance d(U,V) , between two code words
d(U,V) = W(U Å V)
ex. U = 1011010 V = 1101011
U Å V = 0110001 W(U ÅV) = 3
<C> minimum hamming distance
Max. likelihood ratio à minimum distance of codeword.
<D> Error correction capability
d min - 1
t =[ ]
2

Fig 6.13 P344 , dmin= 5


received r1 à U …1 bit error correction
r2 à U … 2 bit
r3 à V … 1 bit
M n j
® PM = å ( ) p (1 - p ) n - j
n =t +1 j

1 n n j
® average bit error PB =
n
å
j =t +1
j (
j
) p (1 - p ) n- j
Figure 6.13
Error correction and
detection capability.
(a) Received Vector r1.
(b) Received vector r2.
(c) Received vector r3.
6.7 cyclic code
<A> definition
if U = (U 0 , U1 ,......U n -1 ) is a codeword (code vector)
then U (1) = (U n -1 , U 0 , U1 ,......U n - 2 ) is also a code vector ® cyclic code
The polynomial
U ( x) = U 0 + U1 x + U 2 x 2 + ......U n -1 x n -1
shift 1 bit U (1) ( x) = U n -1 + U 0 x + U1 x 2 + ......U n - 2 x n -1

<B> Algebraic structure of cyclic code


U ( x) = U 0 + U1 x + U 2 x 2 + ......U n -1 x n -1
xU ( x) = U 0 x + U1 x 2 + ......U n -1 x n = U 0 x + U1 x 2 + ......U n -1 ( x n + 1) + U n -1
xU ( x) U n -1 + U 0 x + U1 x 2 + ......U n - 2 x n -1 U (1) ( x)
= U n -1 + = U n -1 + n
x +1
n
x +1
n
x +1
Þ U (1) ( x) = xU ( x)modulo( x n + 1)

and x iU ( x) = p ( x)( x n + 1) + U (i ) ( x)
or U (i ) ( x) = x iU ( x)modulo( x n + 1)

EX : U = (0,1,1) U ( x) = x + x 2
shift two positions
x 2U ( x) = x 3 + x 4 = ( x 3 + 1) + x( x 3 + 1) + 1 + x
U ( 2 ) ( x) = x 2U ( x)modulo( x 3 + 1) = 1 + x
or code ® (1,1,0)
<C> generator matrix of cyclic code

(a) k-bit information polynomial


m( x) = m0 + m1 x + m2 x 2 + ......mk -1 x k -1
or m = ( m0 , m1 , m2 ,......mk -1 )
(b) Generator matrix polynomial
g ( x) = g 0 + g1 x + g 2 x 2 + ......g n - k x n - k
U ( x) = m( x) g ( x) is cyclic code degree of r = n - k
(c) Parity check matrix
xn +1
h( x ) = Þ degree of k
g ( x)
xn +1
\U ( x) = m( x) g ( x) = m( x ) or m( x) = U ( x)h( x)
h( x ) xn +1
EX 6 - 10 P364
EX : g(x) = 1 + x + x 2 + x 4 note n = 7 r = 4 k =3
x7 +1
 g(x)h(x) = x + 1 7
\ h(x) = = 1+ x + x3
g(x)
code word U(x) = m(x)g(x)

EX: 111 m(x) = 1 + x + x 2


U ( x) = m( x) g ( x) = (1 + x + x 2 )(1 + x + x 2 + x 4 )
= 1 + x + x 2 + x 4 + x + x 2 + x3 + x5 + x 2 + x3 + x 4 + x6
= 1 + 0 x + x 2 + 0 x 3 + 0 x 4 + x 5 + x 6 ® (1010011)
U ( x)h( x) = (1 + x 2 + x 5 + x 6 )(1 + x + x 3 )
= 1 + x 2 + x5 + x 6 + x + x3 + x 6 + x 7 + x3 + x5 + x8 + x9
= 1 + x + x 2 + x 7 + x 8 + x 9 = ( x 7 + 1)(1 + x + x 2 )
U ( x ) h( x ) = 1 + x + x 2 ¬ decode ® (111) = m
( x + 1)
7
(d) Dual of cyclic code
(n, k ) ¬¾¾®(n, r )
dual
Þ g ( x ) h( x ) = x n + 1
generator matrix (n, k)
g ( x) ®
parity matrix (n, r)
parity matrix of (n, k) cyclic
h( x ) ®
generator matrix of (n, r) cyclic

<D> systematic cyclic code


(a) Fundamental :
m( x) = m0 + m1 x + m2 x 2 ...... + mk -1 x k -1
U ( x) = U 0 + U1 x + U 2 x 2 + ......U n -1 x n -1
if U ( x) = c0 + c1 x + ...... + cn - k -1 x n - k -1 + m0 x n - k + m1 x n - k +1...... + mk -1 x n -1
it is systematic eg. 6.65 p359 cyclic code
(b) Generator matrix of systematic code
à form same as block code
m( x) = m0 + m1 x + m2 x 2 ...... + mk -1 x k -1
U ( x ) = c ( x ) + x n - k m( x ) º g ( x) p( x)
\ x n - k m( x ) = g ( x ) p ( x ) + c ( x )
即以x n - k m( x)除以g ( x)得商p ( x), 餘數為c( x) ® parity check matrix
• General form for generator matrix
x n - k +i m( x) = g ( x) pi ( x) + ci ( x)
ci ( x) = ci , 0 + ci ,1 x + ......ci ,n - k -1 x n - k -1 i = 0,1,.....k - 1
é c0, 0 c0,1 .... c0,n - k -1 1  0ù
0
êc c1,1 .... c1,n - k -1 0 ú
1 ú
G=ê
1, 0

ê      0ú
ê ú
êëck -1, 0 ck -1,1 .... ck -1,n - k -1 0  0 1úû
EX : for (7,3) cyclic code , if g(x) = 1 + x + x 2 + x 4 systematic code
find G and code word for the systematic code

sol : n = 7, k = 3 r = 7 -3 = 4
x i m(x) = ? i = 0,1,2....k - 1 = 2
for 100 Þ i = 0 x n -k +i m0 = x 4 = p0 ( x) g ( x) + c0 ( x)
Þ p0 ( x ) = 1 c0 ( x) = 1 + x + x 2 ® c0 = (1110)
for 010 Þ i = 1 Þ x 5 = p1 ( x) g ( x) + c1 ( x)
= x(1 + x + x 2 + x 4 ) + x + x 2 + x 3
Þ p1 ( x) = x c1 ( x) = x + x 2 + x 3 ® c1 = (0111)
for 001 Þ i = 2 Þ x 6 = p 2 ( x ) g ( x ) + c2 ( x )
= x 2 (1 + x + x 2 + x 4 ) + (1 + x + x 2 + x 4 ) + 1 + x + x 3
Þ p2 ( x ) = 1 + x 2 c2 ( x) = 1 + x + x 3 ® c2 = (1101)
é1 1 1 0 1 0 0ù
G = êê0 1 1 1 0 1 0úú
êë1 1 0 1 0 0 1úû

m0 m1 m2
0 0 0 0 0 0 0 0 0 0
1 0 0 1 1 1 0 1 0 0
0 1 0 0 1 1 1 0 1 0
0 0 1 1 1 0 1 0 0 1
1 1 0 1 0 0 1 1 1 0
0 1 1 1 0 1 0 0 1 1
1 0 1 0 0 1 1 1 0 1
1 1 1 0 1 0 0 1 1 1
<F> error defector
U(x) = g(x)m(x) U(x)h(x) = m(x) Þ g(x)h(x) = x n + 1
xn +1
correct Û U(x)可整除by g(x)

If received Z(x) = U(x)+e(x)


no error Û Z ( x) g ( x) divisible , no remainder
Error exist : ie Z ( x) = g ( x) p ( x) + s ( x) ¬ symdrome(nonzero)
ref ex.6.10 and Fig 6.19
6.8 Well known block code
<A> Hamming code
a block code
(n, k ) = (2 m - 1,2 m - 1 - m) with d min = 3
m = n-k no. of parity check bits
ex. m=3 (7,4)
m=4 (15,11)
m=5 (31,26)
d min - 1
Correct all single bit error t= =1
2
Bit error n
1 n i 2E C
PB = å i
n i =2 i
( ) p (1 - p ) n -i
where p = Q(
N0
)
<B> Extended Golay code

Perfect code
à parity check bit
à t =3 (24,12)

Fig 6.22
PB versus Eb/No for coherently
demodulated BPSK over a
Gaussian channel for
several block codes.
<C> BCH code (Bose-Chadhuri-Hocquenghem)

à Large block code à generalize:table 6.4 p372


g(x)à octal number
Ex : g(x) = 23 à (010,011)
Fig 6.22 (127,36) t = 15 better
(127,64) t = 10 modified

BCH
Reed-solomon code 8.1
6.6 Usefulness of standard array
code capability/error capability
<A> error detection capability
Maximum detection error bits = (dmin – 1)

<B> error detection and error correct


α : no. of correct bit
d min = a + b + 1
β : no. of detection error bit
a£b
then
error detection ¾¾¾® correct
d min - 1
if a = b = a = t ® error correct capability
2
<C> perfect code
A code with t-error correction bit has all the error pattern of t
Fig 6.11 with t = 1 is perfect but no. for t = 2 à only one
But there are (6) = 15 possible 2-bit error
2
Good code à each codeword is as far as possible with
the added redundant bit
<D> erasure correction
Erasure not know exact (0或1不確定)
d min = r + 1
If correction a d min = 2a + g + 1
decode g ® 000 first decode
g ® 111 second decode

You might also like