Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download

📚 The CoCalc Library - books, templates and other resources

132932 views
License: OTHER
Kernel:
%%html <link href="http://mathbook.pugetsound.edu/beta/mathbook-content.css" rel="stylesheet" type="text/css" /> <link href="https://aimath.org/mathbook/mathbook-add-on.css" rel="stylesheet" type="text/css" /> <style>.subtitle {font-size:medium; display:block}</style> <link href="https://fonts.googleapis.com/css?family=Open+Sans:400,400italic,600,600italic" rel="stylesheet" type="text/css" /> <link href="https://fonts.googleapis.com/css?family=Inconsolata:400,700&subset=latin,latin-ext" rel="stylesheet" type="text/css" /><!-- Hide this cell. --> <script> var cell = $(".container .cell").eq(0), ia = cell.find(".input_area") if (cell.find(".toggle-button").length == 0) { ia.after( $('<button class="toggle-button">Toggle hidden code</button>').click( function (){ ia.toggle() } ) ) ia.hide() } </script>

Important: to view this notebook properly you will need to execute the cell above, which assumes you have an Internet connection. It should already be selected, or place your cursor anywhere above to select. Then press the "Run" button in the menu bar above (the right-pointing arrowhead), or press Shift-Enter on your keyboard.

ParseError: KaTeX parse error: \newcommand{\lt} attempting to redefine \lt; use \renewcommand

Section22.2Polynomial Codes

With knowledge of polynomial rings and finite fields, it is now possible to derive more sophisticated codes than those of Chapter 8. First let us recall that an (n,k)(n, k)-block code consists of a one-to-one encoding function E:Z2kZ2nE:{\mathbb Z}^{k}_{2} \rightarrow {\mathbb Z}^{n}_{2} and a decoding function D:Z2nZ2k.D:{\mathbb Z}^{n}_{2} \rightarrow {\mathbb Z}^{k}_{2}\text{.} The code is error-correcting if DD is onto. A code is a linear code if it is the null space of a matrix HMk×n(Z2).H \in {\mathbb M}_{k \times n}({\mathbb Z}_2)\text{.}

We are interested in a class of codes known as cyclic codes. Let ϕ:Z2kZ2n\phi : {\mathbb Z}_2^k \rightarrow {\mathbb Z}_2^n be a binary (n,k)(n,k)-block code. Then ϕ\phi is a if for every codeword (a1,a2,,an),(a_1, a_2, \ldots, a_n )\text{,} the cyclically shifted nn-tuple (an,a1,a2,,an1)(a_n, a_1, a_2, \ldots, a_{n - 1} ) is also a codeword. Cyclic codes are particularly easy to implement on a computer using shift registers [2, 3].

Example22.14

Consider the (6,3)(6,3)-linear codes generated by the two matrices

G1=(100010001100010001)andG2=(100110111111011001).\begin{equation*} G_1 = \begin{pmatrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \\ 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \end{pmatrix} \quad \text{and} \quad G_2 = \begin{pmatrix} 1 & 0 & 0 \\ 1 & 1 & 0 \\ 1 & 1 & 1 \\ 1 & 1 & 1 \\ 0 & 1 & 1 \\ 0 & 0 & 1 \end{pmatrix}. \end{equation*}

Messages in the first code are encoded as follows:

(000)(000000)(100)(100100)(001)(001001)(101)(101101)(010)(010010)(110)(110110)(011)(011011)(111)(111111).\begin{equation*} \begin{array}{rclccrcl} (000) & \mapsto & (000000) & & & (100) & \mapsto & (100100) \\ (001) & \mapsto & (001001) & & & (101) & \mapsto & (101101) \\ (010) & \mapsto & (010010) & & & (110) & \mapsto & (110110) \\ (011) & \mapsto & (011011) & & & (111) & \mapsto & (111111). \end{array} \end{equation*}

It is easy to see that the codewords form a cyclic code. In the second code, 3-tuples are encoded in the following manner:

(000)(000000)(100)(111100)(001)(001111)(101)(110011)(010)(011110)(110)(100010)(011)(010001)(111)(101101).\begin{equation*} \begin{array}{rclccrcl} (000) & \mapsto & (000000) & & & (100) & \mapsto & (111100) \\ (001) & \mapsto & (001111) & & & (101) & \mapsto & (110011) \\ (010) & \mapsto & (011110) & & & (110) & \mapsto & (100010) \\ (011) & \mapsto & (010001) & & & (111) & \mapsto & (101101). \end{array} \end{equation*}

This code cannot be cyclic, since (101101)(101101) is a codeword but (011011)(011011) is not a codeword.

SubsectionPolynomial Codes

We would like to find an easy method of obtaining cyclic linear codes. To accomplish this, we can use our knowledge of finite fields and polynomial rings over Z2.{\mathbb Z}_2\text{.} Any binary nn-tuple can be interpreted as a polynomial in Z2[x].{\mathbb Z}_2[x]\text{.} Stated another way, the nn-tuple (a0,a1,,an1)(a_0, a_1, \ldots, a_{n - 1} ) corresponds to the polynomial

f(x)=a0+a1x++an1xn1,\begin{equation*} f(x) = a_0 + a_1 x + \cdots + a_{n-1} x^{n - 1}, \end{equation*}

where the degree of f(x)f(x) is at most n1.n - 1\text{.} For example, the polynomial corresponding to the 5-tuple (10011)(10011) is

1+0x+0x2+1x3+1x4=1+x3+x4.\begin{equation*} 1 + 0 x + 0 x^2 + 1 x^3 + 1 x^4 = 1 + x^3 + x^4. \end{equation*}

Conversely, with any polynomial f(x)Z2[x]f(x) \in {\mathbb Z}_2[x] with degf(x)<n\deg f(x) \lt n we can associate a binary nn-tuple. The polynomial x+x2+x4x + x^2 + x^4 corresponds to the 5-tuple (01101).(01101)\text{.}

Let us fix a nonconstant polynomial g(x)g(x) in Z2[x]{\mathbb Z}_2[x] of degree nk.n - k\text{.} We can define an (n,k)(n,k)-code CC in the following manner. If (a0,,ak1)(a_0, \ldots, a_{k - 1}) is a kk-tuple to be encoded, then f(x)=a0+a1x++ak1xk1f(x) = a_0 + a_1 x + \cdots + a_{k - 1} x^{k - 1} is the corresponding polynomial in Z2[x].{\mathbb Z}_2[x]\text{.} To encode f(x),f(x)\text{,} we multiply by g(x).g(x)\text{.} The codewords in CC are all those polynomials in Z2[x]{\mathbb Z}_2[x] of degree less than nn that are divisible by g(x).g(x)\text{.} Codes obtained in this manner are called .

Example22.15

If we let g(x)=1+x3,g(x)= 1 + x^3\text{,} we can define a (6,3)(6,3)-code CC as follows. To encode a 3-tuple (a0,a1,a2),( a_0, a_1, a_2 )\text{,} we multiply the corresponding polynomial f(x)=a0+a1x+a2x2f(x) = a_0 + a_1 x + a_2 x^2 by 1+x3.1 + x^3\text{.} We are defining a map ϕ:Z23Z26\phi : {\mathbb Z}_2^3 \rightarrow {\mathbb Z}_2^6 by ϕ:f(x)g(x)f(x).\phi : f(x) \mapsto g(x) f(x)\text{.} It is easy to check that this map is a group homomorphism. In fact, if we regard Z2n{\mathbb Z}_2^n as a vector space over Z2,{\mathbb Z}_2\text{,} ϕ\phi is a linear transformation of vector spaces (see Exercise 20.4.15, Chapter 20). Let us compute the kernel of ϕ.\phi\text{.} Observe that ϕ(a0,a1,a2)=(000000)\phi ( a_0, a_1, a_2 ) = (000000) exactly when

0+0x+0x2+0x3+0x4+0x5=(1+x3)(a0+a1x+a2x2)=a0+a1x+a2x2+a0x3+a1x4+a2x5.\begin{align*} 0 + 0x + 0x^2 + 0x^3 + 0x^4 + 0 x^5 & = (1 + x^3) ( a_0 + a_1 x + a_2 x^2 )\\ & = a_0 + a_1 x + a_2 x^2 + a_0 x^3 + a_1 x^4 + a_2 x^5. \end{align*}

Since the polynomials over a field form an integral domain, a0+a1x+a2x2a_0 + a_1 x + a_2 x^2 must be the zero polynomial. Therefore, kerϕ={(000)}\ker \phi = \{ (000) \} and ϕ\phi is one-to-one.

To calculate a generator matrix for C,C\text{,} we merely need to examine the way the polynomials 1,1\text{,} x,x\text{,} and x2x^2 are encoded:

(1+x3)1=1+x3(1+x3)x=x+x4(1+x3)x2=x2+x5.\begin{align*} (1 + x^3) \cdot 1 & = 1 + x^3\\ (1 + x^3)x & = x + x^4\\ (1 + x^3)x^2 & = x^2 + x^5. \end{align*}

We obtain the code corresponding to the generator matrix G1G_1 in Example 22.14. The parity-check matrix for this code is

H=(100100010010001001).\begin{equation*} H = \begin{pmatrix} 1 & 0 & 0 & 1 & 0 & 0 \\ 0 & 1 & 0 & 0 & 1 & 0 \\ 0 & 0 & 1 & 0 & 0 & 1 \end{pmatrix}. \end{equation*}

Since the smallest weight of any nonzero codeword is 2, this code has the ability to detect all single errors.

Rings of polynomials have a great deal of structure; therefore, our immediate goal is to establish a link between polynomial codes and ring theory. Recall that xn1=(x1)(xn1++x+1).x^n - 1 = (x - 1)( x^{n-1} + \cdots + x + 1)\text{.} The factor ring

Rn=Z2[x]/xn1\begin{equation*} R_n = {\mathbb Z}_2[x]/ \langle x^n - 1 \rangle \end{equation*}

can be considered to be the ring of polynomials of the form

f(t)=a0+a1t++an1tn1\begin{equation*} f(t) = a_0 + a_1 t + \cdots + a_{n-1} t^{n-1} \end{equation*}

that satisfy the condition tn=1.t^n = 1\text{.} It is an easy exercise to show that Z2n{\mathbb Z}_2^n and RnR_n are isomorphic as vector spaces. We will often identify elements in Z2n{\mathbb Z}_2^n with elements in Z[x]/xn1.{\mathbb Z}[x] / \langle x^n - 1 \rangle\text{.} In this manner we can interpret a linear code as a subset of Z[x]/xn1.{\mathbb Z}[x] / \langle x^n - 1 \rangle\text{.}

The additional ring structure on polynomial codes is very powerful in describing cyclic codes. A cyclic shift of an nn-tuple can be described by polynomial multiplication. If f(t)=a0+a1t++an1tn1f(t) = a_0 + a_1 t + \cdots + a_{n-1} t^{n-1} is a code polynomial in Rn,R_n\text{,} then

tf(t)=an1+a0t++an2tn1\begin{equation*} tf(t) = a_{n-1} + a_0 t + \cdots + a_{n-2} t^{n-1} \end{equation*}

is the cyclically shifted word obtained from multiplying f(t)f(t) by t.t\text{.} The following theorem gives a beautiful classification of cyclic codes in terms of the ideals of Rn.R_n\text{.}

Theorem22.16

A linear code CC in Z2n{\mathbb Z}_2^n is cyclic if and only if it is an ideal in Rn=Z[x]/xn1.R_n = {\mathbb Z}[x] / \langle x^n - 1 \rangle\text{.}

Proof

Let CC be a linear cyclic code and suppose that f(t)f(t) is in C.C\text{.} Then tf(t)t f(t) must also be in C.C\text{.} Consequently, tkf(t)t^k f(t) is in CC for all kN.k \in {\mathbb N}\text{.} Since CC is a linear code, any linear combination of the codewords f(t),tf(t),t2f(t),,tn1f(t)f(t), tf(t), t^2f(t), \ldots, t^{n-1}f(t) is also a codeword; therefore, for every polynomial p(t),p(t)\text{,} p(t)f(t)p(t)f(t) is in C.C\text{.} Hence, CC is an ideal.

Conversely, let CC be an ideal in Z2[x]/xn+1.{\mathbb Z}_2[x]/\langle x^n + 1\rangle\text{.} Suppose that f(t)=a0+a1t++an1tn1f(t) = a_0 + a_1 t + \cdots + a_{n - 1} t^{n - 1} is a codeword in C.C\text{.} Then tf(t)t f(t) is a codeword in C;C\text{;} that is, (a1,,an1,a0)(a_1, \ldots, a_{n-1}, a_0) is in C.C\text{.}

Theorem 22.16 tells us that knowing the ideals of RnR_n is equivalent to knowing the linear cyclic codes in Z2n.{\mathbb Z}_2^n\text{.} Fortunately, the ideals in RnR_n are easy to describe. The natural ring homomorphism ϕ:Z2[x]Rn\phi : {\mathbb Z}_2[x] \rightarrow R_n defined by ϕ[f(x)]=f(t)\phi[f(x)] = f(t) is a surjective homomorphism. The kernel of ϕ\phi is the ideal generated by xn1.x^n - 1\text{.} By Theorem 16.34, every ideal CC in RnR_n is of the form ϕ(I),\phi(I)\text{,} where II is an ideal in Z2[x]{\mathbb Z}_2[x] that contains xn1.\langle x^n - 1 \rangle\text{.} By Theorem 17.20, we know that every ideal II in Z2[x]{\mathbb Z}_2[x] is a principal ideal, since Z2{\mathbb Z}_2 is a field. Therefore, I=g(x)I = \langle g(x) \rangle for some unique monic polynomial in Z2[x].{\mathbb Z}_2[x]\text{.} Since xn1\langle x^n - 1 \rangle is contained in I,I\text{,} it must be the case that g(x)g(x) divides xn1.x^n - 1\text{.} Consequently, every ideal CC in RnR_n is of the form

C=g(t)={f(t)g(t):f(t)Rn and g(x)(xn1) in Z2[x]}.\begin{equation*} C = \langle g(t) \rangle = \{ f(t)g(t) : f(t) \in R_n \text{ and } g(x) \mid (x^n - 1) \text{ in } {\mathbb Z}_2[x] \}. \end{equation*}

The unique monic polynomial of the smallest degree that generates CC is called the of C.C\text{.}

Example22.17

If we factor x71x^7 - 1 into irreducible components, we have

x71=(1+x)(1+x+x3)(1+x2+x3).\begin{equation*} x^7 - 1 = (1 + x)(1 + x + x^3)(1+ x^2 + x^3). \end{equation*}

We see that g(t)=(1+t+t3)g(t) = (1 + t + t^3) generates an ideal CC in R7.R_7\text{.} This code is a (7,4)(7, 4)-block code. As in Example 22.15, it is easy to calculate a generator matrix by examining what g(t)g(t) does to the polynomials 1, t,t\text{,} t2,t^2\text{,} and t3.t^3\text{.} A generator matrix for CC is

G=(1000110001101011010100100001).\begin{equation*} G = \begin{pmatrix} 1 & 0 & 0 & 0 \\ 1 & 1 & 0 & 0 \\ 0 & 1 & 1 & 0 \\ 1 & 0 & 1 & 1 \\ 0 & 1 & 0 & 1 \\ 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 1 \end{pmatrix}. \end{equation*}

In general, we can determine a generator matrix for an (n,k)(n, k)-code CC by the manner in which the elements tkt^k are encoded. Let xn1=g(x)h(x)x^n - 1 = g(x) h(x) in Z2[x].{\mathbb Z}_2[x]\text{.} If g(x)=g0+g1x++gnkxnkg(x) = g_0 + g_1 x + \cdots + g_{n-k} x^{n-k} and h(x)=h0+h1x++hkxk,h(x) = h_0 + h_1 x + \cdots + h_k x^k\text{,} then the n×kn \times k matrix

G=(g000g1g00gnkgnk1g00gnkg100gnk)\begin{equation*} G = \begin{pmatrix} g_0 & 0 & \cdots & 0 \\ g_1 & g_0 & \cdots & 0 \\ \vdots & \vdots &\ddots & \vdots \\ g_{n-k} & g_{n-k-1} & \cdots & g_0 \\ 0 & g_{n-k} & \cdots & g_{1} \\ \vdots & \vdots & \ddots & \vdots \\ 0 & 0 & \cdots & g_{n-k} \end{pmatrix} \end{equation*}

is a generator matrix for the code CC with generator polynomial g(t).g(t)\text{.} The parity-check matrix for CC is the (nk)×n(n-k) \times n matrix

H=(000hkh000hkh00hkh0000).\begin{equation*} H = \begin{pmatrix} 0 & \cdots & 0 & 0 & h_k & \cdots & h_0 \\ 0 & \cdots & 0 & h_k & \cdots & h_0 & 0 \\ \cdots & \cdots & \cdots & \cdots & \cdots & \cdots & \cdots \\ h_k & \cdots & h_0 & 0 & 0 & \cdots & 0 \end{pmatrix}. \end{equation*}

We will leave the details of the proof of the following proposition as an exercise.

Proposition22.18

Let C=g(t)C = \langle g(t) \rangle be a cyclic code in RnR_n and suppose that xn1=g(x)h(x).x^n - 1 = g(x) h(x)\text{.} Then GG and HH are generator and parity-check matrices for C,C\text{,} respectively. Furthermore, HG=0.HG = 0\text{.}

Example22.19

In Example 22.17,

x71=g(x)h(x)=(1+x+x3)(1+x+x2+x4).\begin{equation*} x^7 - 1 = g(x) h(x) = (1 + x + x^3)(1 + x + x^2 + x^4). \end{equation*}

Therefore, a parity-check matrix for this code is

H=(001011101011101011100).\begin{equation*} H = \begin{pmatrix} 0 & 0 & 1 & 0 & 1 & 1 & 1 \\ 0 & 1 & 0 & 1 & 1 & 1 & 0 \\ 1 & 0 & 1 & 1 & 1 & 0 & 0 \end{pmatrix}. \end{equation*}

To determine the error-detecting and error-correcting capabilities of a cyclic code, we need to know something about determinants. If α1,,αn\alpha_1, \ldots, \alpha_n are elements in a field F,F\text{,} then the n×nn \times n matrix

(111α1α2αnα12α22αn2α1n1α2n1αnn1)\begin{equation*} \begin{pmatrix} 1 & 1 & \cdots & 1 \\ \alpha_1 & \alpha_2 & \cdots & \alpha_n \\ \alpha_1^2 & \alpha_2^2 & \cdots & \alpha_n^2 \\ \vdots & \vdots & \ddots & \vdots \\ \alpha_1^{n-1} & \alpha_2^{n-1} & \cdots & \alpha_n^{n-1} \end{pmatrix} \end{equation*}

is called the . The determinant of this matrix is called the . We will need the following lemma in our investigation of cyclic codes.

Lemma22.20

Let α1,,αn\alpha_1, \ldots, \alpha_n be elements in a field FF with n2.n \geq 2\text{.} Then

det(111α1α2αnα12α22αn2α1n1α2n1αnn1)=1j<in(αiαj).\begin{equation*} \det \begin{pmatrix} 1 & 1 & \cdots & 1 \\ \alpha_1 & \alpha_2 & \cdots & \alpha_n \\ \alpha_1^2 & \alpha_2^2 & \cdots & \alpha_n^2 \\ \vdots & \vdots & \ddots & \vdots \\ \alpha_1^{n-1} & \alpha_2^{n-1} & \cdots & \alpha_n^{n-1} \end{pmatrix} = \prod_{1 \leq j \lt i \leq n} (\alpha_i - \alpha_j). \end{equation*}

In particular, if the αi\alpha_i's are distinct, then the determinant is nonzero.

Proof

We will induct on n.n\text{.} If n=2,n = 2\text{,} then the determinant is α2α1.\alpha_2 - \alpha_1\text{.} Let us assume the result for n1n - 1 and consider the polynomial p(x)p(x) defined by

p(x)=det(1111α1α2αn1xα12α22αn12x2α1n1α2n1αn1n1xn1).\begin{equation*} p(x) = \det \begin{pmatrix} 1 & 1 & \cdots & 1 & 1 \\ \alpha_1 & \alpha_2 & \cdots & \alpha_{n-1} & x \\ \alpha_1^2 & \alpha_2^2 & \cdots & \alpha_{n-1}^2 & x^2 \\ \vdots & \vdots & \ddots & \vdots & \vdots \\ \alpha_1^{n-1} & \alpha_2^{n-1} & \cdots & \alpha_{n-1}^{n-1} & x^{n-1} \end{pmatrix}. \end{equation*}

Expanding this determinant by cofactors on the last column, we see that p(x)p(x) is a polynomial of at most degree n1.n-1\text{.} Moreover, the roots of p(x)p(x) are α1,,αn1,\alpha_1, \ldots, \alpha_{n-1}\text{,} since the substitution of any one of these elements in the last column will produce a column identical to the last column in the matrix. Remember that the determinant of a matrix is zero if it has two identical columns. Therefore,

p(x)=(xα1)(xα2)(xαn1)β,\begin{equation*} p(x) = (x - \alpha_1)(x - \alpha_2) \cdots (x - \alpha_{n-1}) \beta, \end{equation*}

where

β=(1)n+ndet(111α1α2αn1α12α22αn12α1n2α2n2αn1n2).\begin{equation*} \beta = (-1)^{n + n} \det \begin{pmatrix} 1 & 1 & \cdots & 1 \\ \alpha_1 & \alpha_2 & \cdots & \alpha_{n-1} \\ \alpha_1^2 & \alpha_2^2 & \cdots & \alpha_{n-1}^2 \\ \vdots & \vdots & \ddots & \vdots \\ \alpha_1^{n-2} & \alpha_2^{n-2} & \cdots & \alpha_{n-1}^{n-2} \end{pmatrix}. \end{equation*}

By our induction hypothesis,

β=(1)n+n1j<in1(αiαj).\begin{equation*} \beta = (-1)^{n+n} \prod_{1 \leq j \lt i \leq n-1} (\alpha_i - \alpha_j). \end{equation*}

If we let x=αn,x = \alpha_n\text{,} the result now follows immediately.

The following theorem gives us an estimate on the error detection and correction capabilities for a particular generator polynomial.

Theorem22.21

Let C=g(t)C = \langle g(t) \rangle be a cyclic code in RnR_n and suppose that ω\omega is a primitive nnth root of unity over Z2.{\mathbb Z}_2\text{.} If ss consecutive powers of ω\omega are roots of g(x),g(x)\text{,} then the minimum distance of CC is at least s+1.s + 1\text{.}

Proof

Suppose that

g(ωr)=g(ωr+1)==g(ωr+s1)=0.\begin{equation*} g( \omega^r) = g(\omega^{r + 1}) = \cdots = g( \omega^{r + s - 1}) = 0. \end{equation*}

Let f(x)f(x) be some polynomial in CC with ss or fewer nonzero coefficients. We can assume that

f(x)=ai0xi0+ai1xi1++ais1xis1\begin{equation*} f(x) = a_{i_0} x^{i_0} + a_{i_1} x^{i_1} + \cdots + a_{i_{s - 1}} x^{i_{s - 1}} \end{equation*}

be some polynomial in C.C\text{.} It will suffice to show that all of the aia_i's must be 0. Since

g(ωr)=g(ωr+1)==g(ωr+s1)=0\begin{equation*} g( \omega^r) = g(\omega^{r + 1}) = \cdots = g( \omega^{r + s - 1}) = 0 \end{equation*}

and g(x)g(x) divides f(x),f(x)\text{,}

f(ωr)=f(ωr+1)==f(ωr+s1)=0.\begin{equation*} f( \omega^r) = f(\omega^{r + 1}) = \cdots = f( \omega^{r + s - 1}) = 0. \end{equation*}

Equivalently, we have the following system of equations:

ai0(ωr)i0+ai1(ωr)i1++ais1(ωr)is1=0ai0(ωr+1)i0+ai1(ωr+1)i2++ais1(ωr+1)is1=0ai0(ωr+s1)i0+ai1(ωr+s1)i1++ais1(ωr+s1)is1=0.\begin{align*} a_{i_0} (\omega^r)^{i_0} + a_{i_1} (\omega^r)^{i_1} + \cdots + a_{i_{s - 1}} (\omega^r)^{i_{s - 1}} & = 0\\ a_{i_0} (\omega^{r + 1})^{i_0} + a_{i_1} (\omega^{r + 1})^{i_2} + \cdots + a_{i_{s-1}} (\omega^{r+1})^{i_{s-1}} & = 0\\ & \vdots \\ a_{i_0} (\omega^{r + s - 1})^{i_0} + a_{i_1} (\omega^{r + s - 1})^{i_1} + \cdots + a_{i_{s - 1}} (\omega^{r + s - 1})^{i_{s - 1}} & = 0. \end{align*}

Therefore, (ai0,ai1,,ais1)(a_{i_0}, a_{i_1}, \ldots, a_{i_{s - 1}}) is a solution to the homogeneous system of linear equations

(ωi0)rx0+(ωi1)rx1++(ωis1)rxn1=0(ωi0)r+1x0+(ωi1)r+1x1++(ωis1)r+1xn1=0(ωi0)r+s1x0+(ωi1)r+s1x1++(ωis1)r+s1xn1=0.\begin{align*} (\omega^{i_0})^r x_0 + (\omega^{i_1})^r x_1 + \cdots + (\omega^{i_{s - 1}})^r x_{n - 1} & = 0\\ (\omega^{i_0})^{r + 1} x_0 + (\omega^{i_1})^{r + 1} x_1 + \cdots + (\omega^{i_{s - 1}})^{r + 1} x_{n - 1} & = 0\\ & \vdots \\ (\omega^{i_0})^{r + s - 1} x_0 + (\omega^{i_1})^{r + s - 1} x_1 + \cdots + (\omega^{i_{s - 1}})^{r + s - 1} x_{n - 1} & = 0. \end{align*}

However, this system has a unique solution, since the determinant of the matrix

((ωi0)r(ωi1)r(ωis1)r(ωi0)r+1(ωi1)r+1(ωis1)r+1(ωi0)r+s1(ωi1)r+s1(ωis1)r+s1)\begin{equation*} \begin{pmatrix} (\omega^{i_0})^r & (\omega^{i_1})^r & \cdots & (\omega^{i_{s-1}})^r \\ (\omega^{i_0})^{r+1} & (\omega^{i_1})^{r+1} & \cdots & (\omega^{i_{s-1}})^{r+1} \\ \vdots & \vdots & \ddots & \vdots \\ (\omega^{i_0})^{r+s-1} & (\omega^{i_1})^{r+s-1} & \cdots & (\omega^{i_{s-1}})^{r+s-1} \end{pmatrix} \end{equation*}

can be shown to be nonzero using Lemma 22.20 and the basic properties of determinants (Exercise). Therefore, this solution must be ai0=ai1==ais1=0.a_{i_0} = a_{i_1} = \cdots = a_{i_{s - 1}} = 0\text{.}

SubsectionBCH Codes

Some of the most important codes, discovered independently by A. Hocquenghem in 1959 and by R. C. Bose and D. V. Ray-Chaudhuri in 1960, are BCH codes. The European and transatlantic communication systems both use BCH codes. Information words to be encoded are of length 231, and a polynomial of degree 24 is used to generate the code. Since 231+24=255=281,231 + 24 = 255 = 2^8-1\text{,} we are dealing with a (255,231)(255, 231)-block code. This BCH code will detect six errors and has a failure rate of 1 in 16 million. One advantage of BCH codes is that efficient error correction algorithms exist for them.

The idea behind BCH codes is to choose a generator polynomial of smallest degree that has the largest error detection and error correction capabilities. Let d=2r+1d = 2r + 1 for some r0.r \geq 0\text{.} Suppose that ω\omega is a primitive nnth root of unity over Z2,{\mathbb Z}_2\text{,} and let mi(x)m_i(x) be the minimal polynomial over Z2{\mathbb Z}_2 of ωi.\omega^i\text{.} If

g(x)=lcm[m1(x),m2(x),,m2r(x)],\begin{equation*} g(x) = \lcm[ m_1(x), m_{2}(x), \ldots, m_{2r}(x)], \end{equation*}

then the cyclic code g(t)\langle g(t) \rangle in RnR_n is called the nn d.d\text{.} By Theorem 22.21, the minimum distance of CC is at least d.d\text{.}

Theorem22.22

Let C=g(t)C = \langle g(t) \rangle be a cyclic code in Rn.R_n\text{.} The following statements are equivalent.

  1. The code CC is a BCH code whose minimum distance is at least d.d\text{.}

  2. A code polynomial f(t)f(t) is in CC if and only if f(ωi)=0f( \omega^i) = 0 for 1i<d.1 \leq i \lt d\text{.}

  3. The matrix

    H=(1ωω2ωn11ω2ω4ω(n1)(2)1ω3ω6ω(n1)(3)1ω2rω4rω(n1)(2r))\begin{equation*} H = \begin{pmatrix} 1 & \omega & \omega^2 & \cdots & \omega^{n-1}\\ 1 & \omega^2 & \omega^{4} & \cdots & \omega^{(n-1)(2)} \\ 1 & \omega^3 & \omega^{6} & \cdots & \omega^{(n-1)(3)} \\ \vdots & \vdots & \vdots & \ddots & \vdots \\ 1 & \omega^{2r} & \omega^{4r} & \cdots & \omega^{(n-1)(2r)} \end{pmatrix} \end{equation*}

    is a parity-check matrix for C.C\text{.}

Proof

(1) \Rightarrow (2). If f(t)f(t) is in C,C\text{,} then g(x)f(x)g(x) \mid f(x) in Z2[x].{\mathbb Z}_2[x]\text{.} Hence, for i=1,,2r,i = 1, \ldots, 2r\text{,} f(ωi)=0f( \omega^i) = 0 since g(ωi)=0.g( \omega^i ) = 0\text{.} Conversely, suppose that f(ωi)=0f( \omega^i) = 0 for 1id.1 \leq i \leq d\text{.} Then f(x)f(x) is divisible by each mi(x),m_i(x)\text{,} since mi(x)m_i(x) is the minimal polynomial of ωi.\omega^i\text{.} Therefore, g(x)f(x)g(x) \mid f(x) by the definition of g(x).g(x)\text{.} Consequently, f(x)f(x) is a codeword.

(2) \Rightarrow (3). Let f(t)=a0+a1t++an1vtn1f(t) = a_0 + a_1 t + \cdots + a_{n - 1}v t^{n - 1} be in Rn.R_n\text{.} The corresponding nn-tuple in Z2n{\mathbb Z}_2^n is x=(a0a1an1)t.{\mathbf x} = (a_0 a_1 \cdots a_{n - 1})^{\rm t}\text{.} By (2),

Hx=(a0+a1ω++an1ωn1a0+a1ω2++an1(ω2)n1a0+a1ω2r++an1(ω2r)n1)=(f(ω)f(ω2)f(ω2r))=0\begin{equation*} H {\mathbf x} = \begin{pmatrix} a_0 + a_1 \omega + \cdots + a_{n-1} \omega^{n-1} \\ a_0 + a_1 \omega^2 + \cdots + a_{n-1} (\omega^2)^{n-1} \\ \vdots \\ a_0 + a_1 \omega^{2r} + \cdots + a_{n-1} (\omega^{2r})^{n-1} \end{pmatrix} = \begin{pmatrix} f(\omega) \\ f(\omega^2) \\ \vdots \\ f(\omega^{2r}) \end{pmatrix} = 0 \end{equation*}

exactly when f(t)f(t) is in C.C\text{.} Thus, HH is a parity-check matrix for C.C\text{.}

(3) \Rightarrow (1). By (3), a code polynomial f(t)=a0+a1t++an1tn1f(t) = a_0 + a_1 t + \cdots + a_{n - 1} t^{n - 1} is in CC exactly when f(ωi)=0f(\omega^i) = 0 for i=1,,2r.i = 1, \ldots, 2r\text{.} The smallest such polynomial is g(t)=lcm[m1(t),,m2r(t)].g(t) = \lcm[ m_1(t),\ldots, m_{2r}(t)]\text{.} Therefore, C=g(t).C = \langle g(t) \rangle\text{.}

Example22.23

It is easy to verify that x151Z2[x]x^{15} - 1 \in {\mathbb Z}_2[x] has a factorization

x151=(x+1)(x2+x+1)(x4+x+1)(x4+x3+1)(x4+x3+x2+x+1),\begin{equation*} x^{15} - 1 = (x + 1)(x^2 + x + 1)(x^4 + x + 1)(x^4 + x^3 + 1)(x^4 + x^3 + x^2 + x + 1), \end{equation*}

where each of the factors is an irreducible polynomial. Let ω\omega be a root of 1+x+x4.1 + x + x^4\text{.} The Galois field GF(24)\gf(2^4) is

{a0+a1ω+a2ω2+a3ω3:aiZ2 and 1+ω+ω4=0}.\begin{equation*} \{ a_0 + a_1 \omega + a_2 \omega^2 + a_3 \omega^3 : a_i \in {\mathbb Z}_2 \text{ and } 1 + \omega + \omega^4 = 0 \}. \end{equation*}

By Example 22.8, ω\omega is a primitive 15th root of unity. The minimal polynomial of ω\omega is m1(x)=1+x+x4.m_1(x) = 1 + x + x^4\text{.} It is easy to see that ω2\omega^2 and ω4\omega^4 are also roots of m1(x).m_1(x)\text{.} The minimal polynomial of ω3\omega^3 is m2(x)=1+x+x2+x3+x4.m_2(x) = 1 + x + x^2 + x^3 + x^4\text{.} Therefore,

g(x)=m1(x)m2(x)=1+x4+x6+x7+x8\begin{equation*} g(x) = m_1(x) m_2(x) = 1 + x^4 + x^6 + x^7 + x^8 \end{equation*}

has roots ω,\omega\text{,} ω2,\omega^2\text{,} ω3,\omega^3\text{,} ω4.\omega^4\text{.} Since both m1(x)m_1(x) and m2(x)m_2(x) divide x151,x^{15} - 1\text{,} the BCH code is a (15,7)(15, 7)-code. If x151=g(x)h(x),x^{15} -1 = g(x)h(x)\text{,} then h(x)=1+x4+x6+x7;h(x) = 1 + x^4 + x^6 + x^7\text{;} therefore, a parity-check matrix for this code is

(000000011010001000000110100010000001101000100000011010001000000110100010000001101000100000011010001000000110100010000000).\begin{equation*} \left( \begin{array}{ccccccccccccccc} 0 & 0 & 0 & 0 & 0 & 0 & 0 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 \\ 0 & 0 & 0 & 0 & 0 & 0 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 0 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 & 0 & 0 \\ 0 & 0 & 0 & 0 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 & 0 & 0 & 0 \\ 0 & 0 & 0 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 \\ 0 & 0 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 \\ 0 & 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 \\ 1 & 1 & 0 & 1 & 0 & 0 & 0 & 1 & 0 & 0 & 0 & 0 & 0 & 0 & 0 \end{array} \right). \end{equation*}