Presentation is loading. Please wait.

Presentation is loading. Please wait.

III. Cyclic Codes.

Similar presentations


Presentation on theme: "III. Cyclic Codes."— Presentation transcript:

1 III. Cyclic Codes

2 Description of Cyclic Codes
Cyclic Shift: v=(v0,v1,v2,…, vn-1) Cyclic shift of v: v(1)=(vn-1,v0,v1,…,vn-2) It means cyclically shifting the components of v one place to the right v(i)=(vn-i, vn-i+1,…, vn-1,v0,v1,…,vn-i-1): cyclically shifting v i places to the right Definition of Cyclic Codes: An (n,k) linear code C is called a cyclic code if every cyclic shift of a codeword in C is also a codeword in C

3 Code Polynomials Each codeword corresponds to a polynomial of degree n-1 or less: For a codeword v=(v0,v1,v2,…, vn-1) the corresponding code polynomial is: v(X)= v0+v1X+v2X2+…+vn-1Xn-1 Code polynomial for v(i): v(i)(X)=vn-i+vn-i+1X+…+vn-1Xi-1+v0Xi+v1Xi+1+…+vn-i-1Xn-1

4 Example: (7,4) cyclic code
Information Message Codeword Code Polynomial ( ) ( ) ( ) ( ) 1+X+X3 ( ) ( ) X+X2+X4 ( ) ( ) 1+X2+X3+X4 ( ) ( ) X2+X3+X5 ( ) ( ) 1+X+X2+X5 ( ) ( ) X+X3+X4+X5 ( ) ( ) 1+X4+X5 ( ) ( ) X3+X4+X6 ( ) ( ) 1+X+X4+X6 ( ) ( ) X+X2+X3+X6 ( ) ( ) 1+X2+X6 ( ) ( ) X2+X4+X5+X6 ( ) ( ) 1+X+X2+X3+X4+X5+X6 ( ) ( ) X+X5+X6 ( ) ( ) 1+X3+X5+X6

5 Algebraic Relation between v(X) and v(i)(X)
Xiv(X)=v0Xi+v1Xi+1+…+vn-i-1Xn-1+…+vn-1Xn+i-1 Add (vn-i+vn-i+1X+…+vn-1Xi-1) twice Xiv(X)= vn-i+vn-i+1X+…+vn-1Xi-1+ v0Xi+v1Xi+1+…+vn-i-1Xn-1+…+vn-1Xn+i-1+ vn-i+vn-i+1X+…+vn-1Xi-1 Xiv(X)= vn-i+vn-i+1X+…+vn-1Xi-1+v0Xi+v1Xi+1+…+vn-i-1Xn-1+ vn-iXn+vn-i+1Xn+1+…+vn-1Xn+i-1+vn-i+vn-i+1X+…+vn-1Xi-1 =v(i)(X)+(Xn+1)(vn-i+vn-i+1X+…+vn-1Xi-1) v(i)(X) is the remainder of dividing Xiv(X) by (Xn+1) Xiv(X)=v(i)(X)+(Xn+1)q(X)

6 Theorem 1 The nonzero code polynomial of minimum degree in a cyclic code is unique Proof: Let g(X)=g0+ g1X+…+gr-1Xr-1+Xr be a non-zero code polynomial of minimal degree in C If g(X) is not unique, there a exists a code polynomial g’(X) such that: g’(X)=g’0+ g’1X+…+g’r-1Xr-1+Xr For C to be linear g(X)+g’(X) is…… a Codeword. The corresponding code polynomial is: (g0+ g’0)+(g1+ g’1)X+…+(gr-1+ g’r-1)Xr-1 with degree<r THIS CONTRADICTS THE DEFINITION THAT g(X) IS THE NON-ZERO CODE POLYNOMIAL OF MINIMUM DEGREE

7 Theorem 2 Let g(X)=g0+ g1X+…+gr-1Xr-1+Xr be a non-zero code polynomial of minimal degree in an (n,k) cyclic code C. Then g0 must be equal to 1 Proof: Suppose g0=0 g(X)=g1X+…+gr-1Xr-1+Xr If we cyclically shift g(X) 1 place to the left we get another code polynomial g’(X)=g1+g2X…+Xr-2+Xr-1 with degree<r THIS CONTRADICTS THE DEFINITION THAT g(X) IS THE NON-ZERO CODE POLYNOMIAL OF MINIMUM DEGREE Therefore g0=1

8 From Theorems 1 & 2 The non-zero code polynomial of minimal degree in an (n,k) cyclic code C has the form: g(X)=1+ g1X+g2X2+…+gr-1Xr-1+Xr In the table for the (7,4) cyclic code in slide 4 g(X)=1+X+X3

9 Cyclic Shifts of the Minimal Degree Polynomial g(X)
The polynomials Xg(X), X2g(X),…,Xn-r-1g(X) are cyclic shifts of g(X) where: Xg(X) = g(1)(X) X2g(X) = g(2)(X) : : Xn-r-1g(X) = g(n-r-1)(X) They are code polynomials Given that Xg(X), X2g(X),…, Xn-r-1g(X) are code polynomials in a linear code v(X)= [u0+u1X+u2X2+…+un-r-1Xn-r-1]g(X) is also a code polynomial in C

10 Theorem 3 Let g(X)=1+ g1X+g2X2+…+gr-1Xr-1+Xr be the minimal degree polynomial in an (n,k) cyclic code C. A binary polynomial of degree n-1 or less is a code polynomial if and only if it is a multiple of g(X) Proof: Let v(X) be a binary polynomial of degree n-1 or less such that v(X) is a multiple of g(x). Then: v(X)= [a0+a1X+a2X2+…+an-r-1Xn-r-1]g(X). v(X) is a linear combination of code polynomials, g(X), Xg(X), …Xn-r-1g(X) Let v(X) be a code polynomial in C v(X)=a(X)g(X)+b(X) where the degree of b(X)<r b(X)=v(x)+a(X)g(X) v(X) is a code polynomial, a(X)g(X) are code polynomials b(X) is also a code polynomial of degree<r g(X) is the minimal degree nonzero polynomial b(X)=0 v(X) is a code polynomial in C v(X) is a multiple of g(X)

11 The Number of Code Polynomials
From Theorem 3: A code polynomial must be a multiple of g(X) & Any multiple of g(X) is a code polynomial The number of multiples of g(X) of degree<n-1 are: n-r The number of code polynomials are 2n-r k=n-r where k is the number of information bits in the code word, r is the number of parity check bits in the codeword g(X)=1+g1X+g2X2+…+gn-k-1Xn-k-1+Xn-k

12 Theorem 4 In an (n,k) cyclic code, there exists one and only one code polynomial of degree n-k g(X)=1+g1X+g2X2+…+gn-k-1Xn-k-1+Xn-k 1. Every code polynomial is a multiple of g(X) 2. Every binary polynomial of degree n-1 or less that is multiple of g(X) is a code polynomial

13 Generator Polynomial From Theorem 4:
Every code polynomial v(X) in an (n,k) cyclic code could be expressed as: v(X)= u(X)g(X) =(u0+ u1X+…+uk-1Xk-1 )g(X) If (u0, u1,…,uk-1) is the information message, v(X) represents the corresponding codeword An (n,k) cyclic code is completely specified by its non zero minimal degree code polynomial g(X) g(X) is called the generator polynomial

14 Theorem 5 The generator polynomial g(X) of an (n,k) cyclic code is a factor of Xn+1 Proof: Multiply g(X) by Xk Xkg(X) has a degree n. By dividing Xkg(X) by Xn+1 Xkg(X)=(Xn+1)+g(k)(X) g(k)(X) is a cyclic shift of g(X) and therefore is a code polynomial g(k)(X) is a multiple of g(X) g(k)(X)=a(X)g(X) Xkg(X)=(Xn+1)+a(X)g(X) (Xn+1)=[XK+a(X)]g(X) Therefore g(X) is a factor of Xn+1

15 Theorem 6 If g(X) is a polynomial of degree n-k and is a factor of Xn+1, then g(X) generates an (n,k) cyclic code Proof: It is possible to generate 2k polynomials from linear combinations of the polynomials g(X), Xg(X), …,Xk-1g(X) v(X)=(u0+ u1X+…+uk-1Xk-1)g(X)WE HAVE A LINEAR BLOCK CODE IS THIS CODE CYCLIC? Xv(X)=vn-1(Xn+1)+v(1)(X) Since BOTH Xv(X) and (Xn+1) are divisible by g(X), v(1)(X) must be also be divisible by g(X) Therefore v(1)(X) must be a linear combination of g(X), Xg(X), …,Xk-1g(X) Therefore v(1)(X) must be a code polynomial in the (n,k) linear block code

16 Example (X7+1)=(1+X)(1+X+X3)(1+X2+X3)
There are two factors of degree 3 Each factor could be used to generate a (7,4) cyclic code


Download ppt "III. Cyclic Codes."

Similar presentations


Ads by Google