You are on page 1of 59

Raj

Large class of powerful random error correcting


cyclic codes
Discovered by
(1) Hocquenghem in 1059
(2) Bose in 1960
(3) Chaudhuri in 1960


For any positive integer m (m>3) and t (t<2
m-1
)
Block length : n= 2
m
- 1
No. of parity check digits : n-k s mt
Minimum Distance : d
min
= 2t + 1
Capable of correcting t or fewer errors in a block
of length 2
m
- 1

Specified in terms of roots from GF(2
m
)
g(X) is lowest degree polynomial over GF(2)
which has o, o
2
, o
3
, .. , o
2t
as roots
g(o
i
)=0 for 1 s i

s 2t
Let |

i
(X) be the minimal polynomial of o
i
g(X) = LCM{|

1
(X), |

2
(X), .. , |

2t
(X)}


If is even then o
i
=(o
i
)
2l
i is odd and l > 1
o
i
is the conjugate of o
i
Every even powers of o is the conjugate of
some odd power of o

Even powers of o and some odd power of o
has the same |(X)
|
i
(X)= |
i
(X)
g(X)=LCM{|
1
(X), |
3
(X), |
5
(X).,. |
2t - 1
(X)}
Maximum degree of |
i
(X) is m.
There are t such polynomials
Degree of g(X) = tm
Code defined for ms10
n=2
m
-1, m>3, t=1, d
min
=2t+1=3
o is the primitive element of GF(2
m
)
o is the only root (t=1)
g(X)= |
1
(X)
|
1
(X) is the primitive polynomial of degree 3
Single Error correcting BCH code with length
n=2
m
-1 is the Hamming Code



n=2
m
-1, m>3, t=1, d
min
=2t+1=3
o is the primitive element of GF(2
m
)
o is the only root (t=1)
g(X)= |
1
(X)
|
1
(X) is the primitive polynomial of degree 3
Single Error correcting BCH code with length
n=2
m
-1 is the Hamming Code



m=4, n=2
m
-1=15
o is the primitive element of GF(2
4
)
minimal polynomials are
o : |
1
(X) = 1 + X + X
4

o
3
: |
3
(X) = 1 + X + X
2
+ X
3
+ X
4

o
5
: |
5
(X) = 1 + X + X
2

Double Error Correcting Code t=2
o , o
3
are the roots (2t-1=2x2-1=3)
g(X)= LCM{|
1
(X), |
3
(X)} = |
1
(X). |
3
(X)
g(X)= 1 + X
4
+ X
6
+ X
7
+ X
8

n-k smt =(4 x 2) = 8
k = n-(n-k)=15-8=7
(15, 7) Code
d
min
=2t+1=2x2+1=5
Triple Error Correcting Code t=3
o , o
3
, o
5
are the roots (2t-1=2x3-1=5)
g(X)= LCM{|
1
(X), |
3
(X) , |
5
(X)} = |
1
(X) . |
3
(X) . |
5
(X)
g(X)= 1 X + X
2
+ X
4
+ X
5
+ X
8
+ X
10
n-k = 10
k = n-(n-k)=15-10=5
(15, 5) Code
d
min
=2t+1=2x3+1=7
v(X)=v
0
+ v
1
X

+ + v
n-1
X
n-1
if v(X) has o, o
2
, o
3
, o
2t
as roots v(X) is
divisible by |
1
(X), |
2
(X), |
3
(X), .. , |
2t
(X)
v(X) divisible g(X) and it is a code polynomial
Let v(X) be a code polynomial
v(o
i
)= v
0
+ v
1
(o
i
)

+ + v
n-1
(o
i
)
n-1
for 1s i s2t
v(o
i
)= v
0
+ v
1
(o
i
)

+ v
2
(o
i
)
2
+ v
n-1
(o
i
)
n-1
for 1sis2t
v(o
i
)= v
0
+ v
1
o
i

+ v
2
o
2
i
+ v
n-1
o

(n-1)
i

( ) ( ) ( ) ( )
( ) ( ) ( ) ( )
( ) ( ) ( ) ( )
2 3 n 1
2 3 n 1
2 2 2 2
2 3 n 1
3 3 3 3
2 3 n 1
2t 2t 2t 2t
1
1
H
1
1

(
o o o o
(
(
o o o o
(
(
=
o o o o
(
(
(
(
o o o o

Conjugate roots can be omitted
( ) ( ) ( ) ( )
( ) ( ) ( ) ( )
2 3 n 1
2 3 n 1
3 3 3 3
2 3 n 1
2t 1 2t 1 2t 1 2t 1
1
1
H
1


(
o o o o
(
(
o o o o
(
=
(
(
( o o o o

n - columns
t

-

r
o
w
s

T
v.H 0 =
m=4, t=1, d
min
=2t+1=5, n=15, k=7
H contain elements from GF(2
4
)
GF(2
4
) tuples 4-tuples
o, o
3
are the roots


2 3 4 5 6 7 8 9 10 11 12 13 14
3 6 9 12 15 18 21 24 27 30 33 36 39 42
1
H
1
(
o o o o o o o o o o o o o o
=
(
o o o o o o o o o o o o o o

power tuple
o 0000
o
1
1000
o
2
0100
o
3
1100
o
4
0010
o
5
1010
o
6
0110
o
7
1110
power tuple
o
8
0001
o
9
1001
o
10
0101
o
11
1101
o
12
0011
o
13
1011
o
14
0111
o
15
1111
Parameter 2t+1 is called designed distance
d
min
of BCH code may or may not be equal to
designed distance
Multiple error correction capability
Syndrome may be many components
i
th
component of syndrome
s
i
=r(o
i
)= r
0
+ r
1
(o
i
)

+ r
2
(o
i
)
2
+ r
n-1
(o
i
)
n-1
1sis2t
Syndrome components are elements in GF(2
m
)
There are 2t syndrome components
Dividing r(X) by polynomial |
i
(X)
r(X) = a

i
(X)+|
i
(X)+b
i
(X)
|
i
(o
i
)=0
s
i
=r(o
i
)= b
i
(o
i
)
Syndrome component s
i
is obtained by
evaluating b
i
(X) with X= o
i

Double error correcting BCH Code, t=2
r = ( 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0 )
r(X) = 1 + X
8
s=(s
1
, s
2
, s
3
, s
4
)
minimal polynomials are
o : |
1
(X) = 1 + X + X
4

o
2
: |
2
(X) = 1 + X + X
4
o
3
: |
3
(X) = 1 + X + X
2
+ X
3
+ X
4

o
4
:

|
4
(X) = 1 + X + X
4

b
1
(X)=b
2
(X)=b
4
(X) = rem(r(X) / |
1
(X) ) = X
2
b
3
(X) = rem(r(X) / |
3
(X) ) = 1+X
3
s
1
=b
1
(o)= (o
1
)
2
= o
4

s
2
=b
1
(o)= (o
2
)
2
= o
4
s
3
=b
3
(o)= 1+(o
3
)
3
=1+o
9
=1+ o +o
3
= o
7

s
4
=b
1
(o)= (o
4
)
2
= o
8
s=(o
2
, o
4
, o
7
, o
8
)





r(X)=v(X)+e(X)
s

i
=r(o

i
)=v(o

i
)+e(o

i
)=e(o

i
) 1 s i s 2t
Let e(X)= X
j1
+ X
j2
+ . + X
jv

0 s j1 s j1 s . s j1 s n
s
1
= o
j1
+ o
j2
+ .. + o
jv
s
2
= (o
j1
)
2
+ (o
j2
)
2
+ .. + (o
jv
)
2
s
3
= (o
j1
)
3
+ (o
j2
)
3
+ .. + (o
jv
)
3

...
s
2t
= (o
j1
)
2t
+ (o
j2
)
2t
+ .. + (o
jv
)
2t
o
j1
, o
j2
, . , o
jv
are unknown







Let e(X)= X
j1
+ X
j2
+ . + X
jv

0 s j1 s j1 s . s j1 s n
s
1
= o
j1
+ o
j2
+ .. + o
jv
s
2
= (o
j1
)
2
+ (o
j2
)
2
+ .. + (o
jv
)
2
.........................
s
2t
= (o
j1
)
2t
+ (o
j2
)
2t
+ .. + (o
jv
)
2t
o
j1
, o
j2
, . , o
jv
are unknown
Any method of solving above equations is the
decoding algorithm.
Solutions yields the smallest number of errors is
the right solution.
This is the most probable error pattern e(X)
caused by channel.

Let |
l
= o

j
i 1 s l s v
s
1
= |
1
+ |
2
+ .. + |
v

s
2
= (|
1
)
2
+ (|
2
)
2
+ .. + (|
v
)
2
...
s
2t
= (|
1
)
2t
+ (|
2
)
2t
+ .. + (|
v
)
2t
Above 2t equations are called power sum
symmetric functions
|
1
, |
2
, .. , |
v
are error location numbers

Define (X) = (1+ |
1
X) (1+ |
2
X).. (1+ |
v
X)
(X) =
0
+
1
X +
2
X + +
v
X
V
Roots are |
1
-1
, |
2
-1
, .. , |
v
-1
(X) is the unknown polynomial whose
coefficients must be determined
(X) is know as error location polynomial
Define (X) = (1+ |
1
X) (1+ |
2
X).. (1+ |
v
X)

0
= 1

1
= |
1
+ |
2
+ ..+|
v

2
= |
1
|
2
+ |
2
|
3
++|
V-1
|
v

..

v
=

|
1
|
2
. |
v

i
s

are knows are elementary symmetric
functions of |
i

s.


Newtons Identities
s
1
+
1
=0
s
2
+
1
s
1
+ 2
2
=0
s
3
+
1
s
2
+
2
s
1
+ 3
3
=0
..
s
v
+
1
s
v-1
+ +
v-1
s
1
+ v
v
=0
s
v+1
+
1
s
v
+ +
v-1
s
2
+
v
s
1
=0
i
i
=
i
for a odd i i
i
= 0 for even i
Solutions that yield (X) of minimal degree give
information about most probable error pattern
if vst (X)will give the actual error pattern e(X).
Compute the syndrome s=(s
1
, s
2
,,s
2t
) from r(X)
Determine error location polynomial (X) from
the syndrome components s
1
, s
2
,,s
2t
Determine the error location numbers
|
1
, |
2
, .. , |
v
by finding the roots of the (X)
and correct the errors in r(X)

Compute the syndrome s=(s
1
, s
2
,,s
2t
) from r(X)
Determine error location polynomial (X) from
the syndrome components s
1
, s
2
,,s
2t
Determine the error location numbers
|
1
, |
2
, .. , |
v
by finding the roots of the (X)
and correct the errors in r(X)

Berlekamp iterative algorithm
Find minimum degree polynomial
(1)

(X) whose
coefficients satisfy the first Newtons identity
s
1
+
1
=0
Next step is to test whether the coefficients of

(1)

(X) satisfy the second Newtons identity
s
2
+
1
s
1
+ 2
2
=0
If the coefficients of
(1)

(X) satisfy second
Newtons identity we set

(2)

(X)=
(1)

(X)

If the coefficients of
(1)

(X) does not satisfy
second Newtons identity a correction term is
added to
(1)

(X) to form
(2)

(X) such that
(2)

(X)
has minimum degree and its coefficients satisfy
first two Newton's identities
There are at the end of second step we obtain a
minimum degree polynomial
(2)

(X) whose
coefficients satisfy first two Newtons identifies

The third step is to find the minimal polynomial

(3)

(X) from
(2)

(X) such that
(3)

(X) coefficients
satisfy first three Newtons identities
Again we test
(2)

(X) satisfy third Newton's
identity s
3
+
1
s
2
+
2
s
1
+ 3
3
=0
If they do not, a correction term is added to

(2)

(X) to from
(3)

(X)
Iteration continues until
(2t)

(X) is obtained
The
(2t)

(X) is taken to be error location
polynomial

(X)


(X) =
(2t)

(X)
Let
()

(X) =1 +
1
()
X +
2
()
X
2
+ .+
l

()
X
l

be the minimum polynomial determined at the
th step of iteration whose coefficients satisfy
Newtons identities
To determine
(+1)

(X) we compute the
following quantity
d

= s
+1
+
1
()
s
+1
+
2
()
s
-1
+..+
l

()
s
+1l

The d

is called discrepancy
If d

=0 the coefficients of
()

(X) satisfy
(+1)
th
Newton's identity and
(+1)

(X) =
()

(X)
If d

=0 the coefficients of
()

(X) do not satisfy
(+1)
th
Newton's identity and a correction term
must be added to
()

(X) to obtain
(+1)

(X)
Go back to the steps prior to
th
step and
determine a polynomial
()

(X) such that the
th discrepancy d

=0 and ( - l

)

[l

is the
degree of
()

(X)] has the largest value.

(+1)

(X)=
()

(X) + d

-1
X
(-)

()

(X)
To carry out iteration of finding
()

(X) we begin
with following table and proceed to fill out the
table where l

is the degree
()

(X)
The (+1)
th
is can be fill out as follows
If d

=0 then
(+1)

(X)=
()

(X) and l
+1
=l

If d

=0, find another row prior to the th row


such that d

= 0 and the number (-l

) in the last
column of the table has the largest value.

(+1)

(X)=
()

(X) + d

-1
X
(-)

()

(X)
l
+1
= max(l

, l

+ - )

()

(X) d


l

-l


-1 1 1 0 -1
0 1 s
1
0 0
1
2

2t
Consider a (15,5) triple error correcting code.
v = ( 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 )
r = ( 0 0 0 1 0 1 0 0 0 0 0 0 1 0 0 )
r(X)= X
3
+ X
5
+ X
12
Minimal Polynomials
o : |
1
(X) = 1 + X + X
4

o
2
: |
2
(X) = 1 + X + X
4
o
3
: |
3
(X) = 1 + X + X
2
+ X
3
+ X
4

o
4
:

|
4
(X) = 1 + X + X
4
o
5
:

|
5
(X) = 1 + X + X
2
o
6
:

|
6
(X) = 1 + X + X
2
+ X
3
+ X
4



Dividing r(X) by |
1
(X), |
3
(X) and |
5
(X)
We obtain the following remainders
b
1
(X) = 1
b
3
(X) = 1+X
2
+X
3
b
5
(X) = X
2
Syndrome Components are
s
1
=s
2
=s
4
=1
s
3
=1 +
6
+
9
=
10
and s
6
=1 +
12
+
18
=
5
s
5
=
10
s
1
= 1
s
2
= 1
s
3
=
10

s
4
= 1
s
5
=
10

s
6
=
5

()

(X) d


l

-l

Remarks
-1 1 1 0 -1
0 1 1

0 0
s
1
= 1
s
2
= 1
s
3
=
10

s
4
= 1
s
5
=
10

s
6
=
5

()

(X) d


l

-l

Remarks
-1 1 1 0 -1
0 1 1

0 0
1 1 + X 0 1 0 take = -1
s
1
= 1
s
2
= 1
s
3
=
10

s
4
= 1
s
5
=
10

s
6
=
5

()

(X) d


l

-l

Remarks
-1 1 1 0 -1
0 1 1

0 0
1 1 + X 0 1 0 take = -1
2 1 + X
5
1 1
s
1
= 1
s
2
= 1
s
3
=
10

s
4
= 1
s
5
=
10

s
6
=
5

()

(X) d


l

-l

Remarks
-1 1 1 0 -1
0 1 1

0 0
1 1 + X 0 1 0 take = -1
2 1 + X
5
1 1
3 1 + X +
5
X
2
0 2 1 take = 0
s
1
= 1
s
2
= 1
s
3
=
10

s
4
= 1
s
5
=
10

s
6
=
5

()

(X) d


l

-l

Remarks
-1 1 1 0 -1
0 1 1

0 0
1 1 + X 0 1 0 take = -1
2 1 + X
5
1 1
3 1 + X +
5
X
2
0 2 1 take = 0
4 1 + X +
5
X
2

10
2 2
s
1
= 1
s
2
= 1
s
3
=
10

s
4
= 1
s
5
=
10

s
6
=
5

()

(X) d


l

-l

Remarks
-1 1 1 0 -1
0 1 1

0 0
1 1 + X 0 1 0 take = -1
2 1 + X
5
1 1
3 1 + X +
5
X
2
0 2 1 take = 0
4 1 + X +
5
X
2

10
2 2
5 1 + X +
5
X
3
0 3 2 take = 2
s
1
= 1
s
2
= 1
s
3
=
10

s
4
= 1
s
5
=
10

s
6
=
5

()

(X) d


l

-l

Remarks
-1 1 1 0 -1
0 1 1

0 0
1 1 + X 0 1 0 take = -1
2 1 + X
5
1 1
3 1 + X +
5
X
2
0 2 1 take = 0
4 1 + X +
5
X
2

10
2 2
5 1 + X +
5
X
3
0 3 2 take = 2
6 1 + X +
5
X
3
- - 2


(X)=

(6)
(X) = 1 + X +
5
X
3
roots of

(X) are
3
,
10
,
12

There inverses are
12
,
5
,
3
|
3
=
3

,
|
5
=
5
,
|
12
=
12
j3=3, j5=4, j12=12
e(X)=X
j1
+ X
j2
+ . + X
jv
Therefore error pattern is
e(X)=X
3
+ X
5
+ X
12
Adding e(X) to v(X) we obtain all zero code
vector



If p is prime number and q is a any power of p
there are codes with symbols from Galois field
GF(q)
Codes are called q - ary codes
Concepts and properties developed for binary
codes apply q - ary codes with little
modifications
An (n, k) linear code with symbols from GF(q) is
a k dimensional subspace of vector space of all
n-tuples over GF(q)
A q-ary (n, k) cyclic code generated by a
polynomial of degree (n k) with coefficients
from GF(q) which is a factor X
n
+ 1
Encoding and decoding are similar to that of a
binary cods
In binary BCH codes defined can be generalized
to non-binary codes in a straight forward
manner.
For any choice of positive integer s and t, there
exists a q-ary BCH code of length n=q
s
-1 which is
capable of correcting any combination of t or
fewer errors and requires no more than 2st
parity check digits
Let o be a t-error correcting q-ary BCH code is
the polynomial of lower degree with coefficient
form GF(q) for which o, o
2
, .. ,o
2t
are the roots
Let |
i
(X) be the minimal polynomial of o
i
then
g=(X) = LCM{|
1
(X), |
2
(X), .. ,|
2t
(X)}
Degree of each minimal polynomial is s or less
Therefore degree of g(X) is at most 2st.
Hence number of parity check digits of code
generated by g(X) is no more than 2st
For q=2 we obtain BCH codes
Special subclass of q-ary BCH code for which s=1
A t-error correcting Reed-Solomon code with
symbols from GF(q) has the following
parameters
Block length: n = q 1
No. parity check digits n-k = 2t
Minimum distance d
min
= 2t + 1

Length of the code is one less than the size of
code symbols (q-1) and minimum distance is
one greater than the no: of parity check digits
(2t + 1)
Codes with code symbols from Galois field
GF(2
m
), q=2
m
A (n, k) RS-code have d
min
> (n-k+1) and it
belongs to maximum distance separable code
category of LBC
RS code are particularly useful in situations
where errors tends to happen in bursts rather
than randomly


Let o be the primitive element in GF(2
m
)
The generator polynomial g(X)
g(X)= (X+o) (X+ o
2
) .. (X+ o
2t
)
g(X)=g
0
+ g
1
X +.. + g
2t-1
X
2t-1
+ X
2t
g(X) has o, o
2
, .. ,o
2t
as all roots and has
coefficients form GF(2
m
)
k=n-(n-k)=n-2t
Code generated by g(X) is an (n, n t)


Cyclic code which consists of those polynomials
of degree (n 1) or less with coefficients from
GF(2
m
) that are multiples of g(X)


Similar to binary case
Encoder operates on multiple bits rather than
individual bits
Let message, a(X) = a
0
+ a
1
X +.. + a
k-1
X
k-1
Where k=n 2t
In systematic form the 2t parity check digits are
the coefficients of remainder b(X) resulting from
dividing message polynomial X
2t
a(X) by
generator polynomial g(X)
b(X) = rem(X
2t
a(X)/g(X))= b
0
+ b
1
X +.. + b
2t-1
X
2t-1



Incoming data stream bits are grouped into
blocks of m symbols GF(2
m
) of block length
n=2
m
-1
Each block is treated as k symbols with each
symbol having m bits
Encoding algorithm expands a block of k
symbols to a n symbols by adding n k parity
check digits


Similar to binary code

You might also like