Hubbry Logo
Cyclic codeCyclic codeMain
Open search
Cyclic code
Community hub
Cyclic code
logo
8 pages, 0 posts
0 subscribers
Be the first to start a discussion here.
Be the first to start a discussion here.
Cyclic code
Cyclic code
from Wikipedia

In coding theory, a cyclic code is a block code, where the circular shifts of each codeword gives another word that belongs to the code. They are error-correcting codes that have algebraic properties that are convenient for efficient error detection and correction.

If 00010111 is a valid codeword, applying a right circular shift gives the string 10001011. If the code is cyclic, then 10001011 is again a valid codeword. In general, applying a right circular shift moves the least significant bit (LSB) to the leftmost position, so that it becomes the most significant bit (MSB); the other positions are shifted by 1 to the right.

Definition

[edit]

Let be a linear code over a finite field (also called Galois field) of block length . is called a cyclic code if, for every codeword from , the word in obtained by a cyclic right shift of components is again a codeword. Because one cyclic right shift is equal to cyclic left shifts, a cyclic code may also be defined via cyclic left shifts. Therefore, the linear code is cyclic precisely when it is invariant under all cyclic shifts.

Cyclic codes have some additional structural constraint on the codes. They are based on Galois fields and because of their structural properties they are very useful for error controls. Their structure is strongly related to Galois fields because of which the encoding and decoding algorithms for cyclic codes are computationally efficient.

Algebraic structure

[edit]

Cyclic codes can be linked to ideals in certain rings. Let be a quotient of a polynomial ring over the finite field . Identify the elements of the cyclic code with polynomials in such that maps to the polynomial : thus multiplication by corresponds to a cyclic shift. Then is an ideal in , and hence principal, since is a principal ideal ring. The ideal is generated by the unique monic element in of minimum degree, the generator polynomial .[1] This must be a divisor of . It follows that every cyclic code is a polynomial code. If the generator polynomial has degree then the rank of the code is .

If is a cyclic code, the dual code is also a cyclic code. The generator polynomial for is also called the parity-check polynomial or simply check polynomial for . It can also be shown that , where denotes the reciprocal polynomial of .[2]

The idempotent of is a codeword such that (that is, is an idempotent element of ) and is an identity for the code, that is for every codeword . If and are coprime such a word always exists and is unique;[3] it is a generator of the code.

An irreducible code is a cyclic code in which the code, as an ideal is irreducible, i.e. is minimal in , so that its check polynomial is an irreducible polynomial.

Examples

[edit]

For example, if and , the set of codewords contained in the cyclic code generated by is precisely

This code corresponds to the ideal in generated by .

The polynomial is irreducible in the polynomial ring, and hence the code is an irreducible code.

The idempotent of this code is the polynomial , corresponding to the codeword .

Trivial examples

[edit]

Trivial examples of cyclic codes are itself and the code containing only the zero codeword. These correspond to generators and respectively: these two polynomials must always be factors of .

Over the parity bit code, consisting of all words of even weight, corresponds to generator . Again over this must always be a factor of .

Other examples

[edit]

Many types of commonly used error-correcting codes can be represented as cyclic codes, including BCH codes, Reed-Solomon codes, and some classes of low-density parity-check codes defined from finite geometries.[4]

For correcting errors

[edit]

Cyclic codes can be used to correct errors, like Hamming codes as cyclic codes can be used for correcting single error. Likewise, they are also used to correct double errors and burst errors. All types of error corrections are covered briefly in the further subsections.

The (7,4) Hamming code has a generator polynomial . This polynomial has a zero in Galois extension field at the primitive element , and all codewords satisfy . Cyclic codes can also be used to correct double errors over the field . Blocklength will be equal to and primitive elements and as zeros in the because we are considering the case of two errors here, so each will represent one error.

The received word is a polynomial of degree given as

where can have at most two nonzero coefficients corresponding to 2 errors.

We define the syndrome polynomial, as the remainder of polynomial when divided by the generator polynomial i.e.

as .

For correcting two errors

[edit]

Let the field elements and be the two error location numbers. If only one error occurs then is equal to zero and if none occurs both are zero.

Let and .

These field elements are called "syndromes". Now because is zero at primitive elements and , so we can write and . If say two errors occur, then

and .

And these two can be considered as two pair of equations in with two unknowns and hence we can write

and .

Hence if the two pair of nonlinear equations can be solved cyclic codes can used to correct two errors.

Hamming code

[edit]

The Hamming(7,4) code may be written as a cyclic code over GF(2) with generator . In fact, any binary Hamming code of the form Ham(r, 2) is equivalent to a cyclic code,[5] and any Hamming code of the form Ham(r,q) with r and q-1 relatively prime is also equivalent to a cyclic code.[6] Given a Hamming code of the form Ham(r,2) with , the set of even codewords forms a cyclic -code.[7]

Hamming code for correcting single errors

[edit]

A code whose minimum distance is at least 3, have a check matrix all of whose columns are distinct and non zero. If a check matrix for a binary code has rows, then each column is an -bit binary number. There are possible columns. Therefore, if a check matrix of a binary code with at least 3 has rows, then it can only have columns, not more than that. This defines a code, called Hamming code.

It is easy to define Hamming codes for large alphabets of size . We need to define one matrix with linearly independent columns. For any word of size there will be columns who are multiples of each other. So, to get linear independence all non zero -tuples with one as a top most non zero element will be chosen as columns. Then two columns will never be linearly dependent because three columns could be linearly dependent with the minimum distance of the code as 3.

So, there are nonzero columns with one as top most non zero element. Therefore, a Hamming code is a code.

Now, for cyclic codes, Let be primitive element in , and let . Then and thus is a zero of the polynomial and is a generator polynomial for the cyclic code of block length .

But for , . And the received word is a polynomial of degree given as

where, or where represents the error locations.

But we can also use as an element of to index error location. Because , we have and all powers of from to are distinct. Therefore, we can easily determine error location from unless which represents no error. So, a Hamming code is a single error correcting code over with and .

For correcting burst errors

[edit]

From Hamming distance concept, a code with minimum distance can correct any errors. But in many channels error pattern is not very arbitrary, it occurs within very short segment of the message. Such kind of errors are called burst errors. So, for correcting such errors we will get a more efficient code of higher rate because of the less constraints. Cyclic codes are used for correcting burst error. In fact, cyclic codes can also correct cyclic burst errors along with burst errors. Cyclic burst errors are defined as

A cyclic burst of length is a vector whose nonzero components are among (cyclically) consecutive components, the first and the last of which are nonzero.

In polynomial form cyclic burst of length can be described as with as a polynomial of degree with nonzero coefficient . Here defines the pattern and defines the starting point of error. Length of the pattern is given by deg. The syndrome polynomial is unique for each pattern and is given by

A linear block code that corrects all burst errors of length or less must have at least check symbols. Proof: Because any linear code that can correct burst pattern of length or less cannot have a burst of length or less as a codeword because if it did then a burst of length could change the codeword to burst pattern of length , which also could be obtained by making a burst error of length in all zero codeword. Now, any two vectors that are non zero in the first components must be from different co-sets of an array to avoid their difference being a codeword of bursts of length . Therefore, number of such co-sets are equal to number of such vectors which are . Hence at least co-sets and hence at least check symbol.

This property is also known as Rieger bound and it is similar to the Singleton bound for random error correcting.

Fire codes as cyclic bounds

[edit]

In 1959, Philip Fire[8] presented a construction of cyclic codes generated by a product of a binomial and a primitive polynomial. The binomial has the form for some positive odd integer .[9] Fire code is a cyclic burst error correcting code over with the generator polynomial

where is a prime polynomial with degree not smaller than and does not divide . Block length of the fire code is the smallest integer such that divides .

A fire code can correct all burst errors of length t or less if no two bursts and appear in the same co-set. This can be proved by contradiction. Suppose there are two distinct nonzero bursts and of length or less and are in the same co-set of the code. So, their difference is a codeword. As the difference is a multiple of it is also a multiple of . Therefore,

.

This shows that is a multiple of , So

for some . Now, as is less than and is less than so is a codeword. Therefore,

.

Since degree is less than degree of , cannot divide . If is not zero, then also cannot divide as is less than and by definition of , divides for no smaller than . Therefore and equals to zero. That means both that both the bursts are same, contrary to assumption.

Fire codes are the best single burst correcting codes with high rate and they are constructed analytically. They are of very high rate and when and are equal, redundancy is least and is equal to . By using multiple fire codes longer burst errors can also be corrected.

For error detection cyclic codes are widely used and are called cyclic redundancy codes.

On Fourier transform

[edit]

Applications of Fourier transform are widespread in signal processing. But their applications are not limited to the complex fields only; Fourier transforms also exist in the Galois field . Cyclic codes using Fourier transform can be described in a setting closer to the signal processing.

Fourier transform over finite fields

[edit]

Fourier transform over finite fields

The discrete Fourier transform of vector is given by a vector where,

= where,

where exp() is an th root of unity. Similarly in the finite field th root of unity is element of order . Therefore

If is a vector over , and be an element of of order , then Fourier transform of the vector is the vector and components are given by

= where,

Here is time index, is frequency and is the spectrum. One important difference between Fourier transform in complex field and Galois field is that complex field exists for every value of while in Galois field exists only if divides . In case of extension fields, there will be a Fourier transform in the extension field if divides for some . In Galois field time domain vector is over the field but the spectrum may be over the extension field .

Spectral description

[edit]

Any codeword of cyclic code of blocklength can be represented by a polynomial of degree at most . Its encoder can be written as . Therefore, in frequency domain encoder can be written as . Here codeword spectrum has a value in but all the components in the time domain are from . As the data spectrum is arbitrary, the role of is to specify those where will be zero.

Thus, cyclic codes can also be defined as

Given a set of spectral indices, , whose elements are called check frequencies, the cyclic code is the set of words over whose spectrum is zero in the components indexed by . Any such spectrum will have components of the form .

So, cyclic codes are vectors in the field and the spectrum given by its inverse fourier transform is over the field and are constrained to be zero at certain components. But every spectrum in the field and zero at certain components may not have inverse transforms with components in the field . Such spectrum can not be used as cyclic codes.

Following are the few bounds on the spectrum of cyclic codes.

BCH bound

[edit]

If be a factor of for some . The only vector in of weight or less that has consecutive components of its spectrum equal to zero is all-zero vector.

Hartmann-Tzeng bound

[edit]

If be a factor of for some , and an integer that is coprime with . The only vector in of weight or less whose spectral components equal zero for , where and , is the all zero vector.

Roos bound

[edit]

If be a factor of for some and . The only vector in of weight or less whose spectral components equal to zero for , where and takes at least values in the range , is the all-zero vector.

Quadratic residue codes

[edit]

When the prime is a quadratic residue modulo the prime there is a quadratic residue code which is a cyclic code of length , dimension and minimum weight at least over .

Generalizations

[edit]

Constacyclic codes

[edit]

A constacyclic code is a linear code with the property that for some constant if is a codeword, then so is . A negacyclic code is a constacyclic code with .[10]

Quasi-cyclic code

[edit]

A quasi-cyclic code (QC code) has the property that for some dividing , any cyclic shift of a codeword by places is again a codeword. That is, for some constant , if is a codeword, then so is , where all subscripts are reduced mod .[11] Such a code is known as an -QC code. A double circulant code is a quasi-cyclic code of even length with .[11]

Shortened cyclic codes

[edit]

An linear code is called a shortened cyclic code if it can be obtained by deleting positions from an cyclic code. Code of this form are not generally cyclic.[12]

In shortened codes, information symbols are deleted to obtain a desired block length smaller than the original block length. While deleting the first symbols is a common approach, in principle any set of information symbols can be deleted. [12] Any cyclic code can be converted to a quasi-cyclic code by dropping every -th symbol, where is a factor of . If the dropped symbols are not check symbols, this cyclic code is also a shortened cyclic code.

Other generalizations

[edit]

Quasi-twisted codes (QT codes) combine the properties of constacyclic and quasi-cyclic codes, with the shift occurring by places and with a multiplier of . That is, for some constants and , if is a codeword, then so is , where all subscripts are reduced mod .[13] Multi-twisted codes are further generalizations of QT codes, which join multiple QT codes end to end.[13][14]

See also

[edit]

Notes

[edit]

References

[edit]

Further reading

[edit]
[edit]
Revisions and contributorsEdit on WikipediaRead on Wikipedia
from Grokipedia
A cyclic code is a subclass of linear in , defined over a Fq\mathbb{F}_q (where qq is a ) with nn, such that any cyclic shift of a codeword is also a codeword. These codes are particularly powerful for error detection and correction in digital communications and data storage due to their algebraic structure, which allows representation as ideals in the polynomial ring Fq/(xn1)\mathbb{F}_q / (x^n - 1). Cyclic codes are generated by a monic generator g(x)g(x) of degree r=nkr = n - k (where kk is the ), which divides xn1x^n - 1, ensuring the code consists of all multiples of g(x)g(x) modulo xn1x^n - 1. This structure enables efficient encoding via linear feedback shift registers (LFSRs) and systematic forms where information bits precede parity bits. Key properties include invariance under cyclic shifts, the ability to detect single errors and bursts of adjacent errors, and decoding methods like computation using check polynomials. Among the earliest practical error-correcting codes, cyclic codes were recognized for their rich algebraic framework by E. Prange in the 1950s, facilitating hardware implementation with shift registers. Notable subclasses include BCH codes for correcting multiple random errors, Reed-Solomon codes for burst error correction (especially when nqn \leq q), and codes for error detection in protocols like Ethernet. These codes maintain a minimum distance related to the roots of g(x)g(x), often bounding the error-correcting capability via the BCH bound for designed distances. Their versatility extends to applications in storage media, satellite communications, and .

Fundamentals

Definition

A cyclic code is a subclass of linear block codes defined over the finite field Fq\mathbb{F}_q (also denoted GF(q)), where qq is a prime power. Specifically, an (n,k)(n, k) cyclic code CC of length nn and dimension kk is a kk-dimensional subspace of Fqn\mathbb{F}_q^n such that if c=(c0,c1,,cn1)\mathbf{c} = (c_0, c_1, \dots, c_{n-1}) is a codeword, then the right cyclic shift c=(cn1,c0,c1,,cn2)\mathbf{c}' = (c_{n-1}, c_0, c_1, \dots, c_{n-2}) is also in CC. This property holds for any number of cyclic shifts, making the code closed under cyclic permutations. Codewords of a cyclic code are conveniently represented using over Fq\mathbb{F}_q. Each codeword c\mathbf{c} corresponds to a c(x)=c0+c1x++cn1xn1c(x) = c_0 + c_1 x + \dots + c_{n-1} x^{n-1} of degree less than nn, and the cyclic shift operation corresponds to by xx xn1x^n - 1. Thus, the set of codeword polynomials forms a in the ring R=Fq/(xn1)R = \mathbb{F}_q / (x^n - 1), which is the of the Fq\mathbb{F}_q by the generated by xn1x^n - 1. This algebraic structure enables efficient encoding and decoding algorithms. Every nonzero cyclic code has a unique monic generator g(x)g(x) of degree nkn - k that divides xn1x^n - 1, and the code consists of all polynomials in RR that are multiples of g(x)g(x). The GG of the code can be expressed in systematic (standard) form as a k×nk \times n matrix [IkP][I_k \mid P], where IkI_k is the k×kk \times k and PP is a k×(nk)k \times (n - k) parity submatrix derived from g(x)g(x). If g(x)=xnk+gnk1xnk1++g1x+g0g(x) = x^{n-k} + g_{n-k-1} x^{n-k-1} + \dots + g_1 x + g_0, then the rows of PP are formed by shifting the coefficients of g(x)g(x) appropriately to ensure the codewords satisfy the cyclic property. The parity-check polynomial is defined as h(x)=(xn1)/g(x)h(x) = (x^n - 1)/g(x), which is a of degree kk that also divides xn1x^n - 1. The corresponding parity-check matrix HH has rows that are cyclic shifts of the coefficients of h(x)h(x). In syndrome computation for error detection, a received vector r\mathbf{r} (polynomial r(x)r(x)) is checked by computing the s(x)=r(x)modg(x)s(x) = r(x) \mod g(x); if s(x)=0s(x) = 0, then r\mathbf{r} is a codeword, as r(x)r(x) is divisible by g(x)g(x) (equivalently, r(α)=0r(\alpha) = 0 for roots α\alpha of g(x)g(x)). This leverages the dual ideal generated by h(x)h(x) in RR.

Algebraic Structure

Cyclic codes over a Fq\mathbb{F}_q (also denoted GF(q)) of length nn are precisely the principal ideals of the R=Fq/(xn1)R = \mathbb{F}_q / (x^n - 1). Since RR is a , each such ideal CC is uniquely generated by a g(x)Fqg(x) \in \mathbb{F}_q of degree r=nkr = n - k, where k=dimCk = \dim C is the of the . The codewords are all multiples of g(x)g(x) in RR, i.e., C=g(x)={p(x)g(x)mod(xn1)degp(x)<k}C = \langle g(x) \rangle = \{ p(x) g(x) \mod (x^n - 1) \mid \deg p(x) < k \}, and g(x)g(x) must divide xn1x^n - 1 exactly in Fq\mathbb{F}_q. The polynomial xn1x^n - 1 factors uniquely into a product of distinct irreducible polynomials over Fq\mathbb{F}_q, provided that gcd(n,q)=1\gcd(n, q) = 1 (ensuring no repeated roots and that RR is semisimple). These irreducible factors are the minimal polynomials of the primitive dd-th roots of unity for divisors dd of nn, grouped according to the cyclotomic cosets modulo nn in the multiplicative group of an extension field. Any generator polynomial g(x)g(x) for a cyclic code is a product of a subset of these minimal polynomials, determining the roots (and thus the parity-check matrix) of the code. Each cyclic code admits a unique idempotent generator e(x)Re(x) \in R satisfying e(x)2e(x)(modxn1)e(x)^2 \equiv e(x) \pmod{x^n - 1} and dege(x)<n\deg e(x) < n, which generates the ideal as C=e(x)RC = e(x) R. This idempotent is the unique element of minimal degree in CC that acts as the identity for multiplication within the code, and it exists under the semisimplicity condition gcd(n,q)=1\gcd(n, q) = 1. The idempotent provides an alternative generator to g(x)g(x), useful for decomposing codes into direct sums of minimal ideals corresponding to primitive idempotents. The dual code CC^\perp of a cyclic code CC is also cyclic. If g(x)g(x) generates CC and h(x)=(xn1)/g(x)h(x) = (x^n - 1)/g(x) is the corresponding parity-check polynomial, then CC^\perp is generated by the reciprocal (or reverse) polynomial h~(x)=xdeghh(x1)\tilde{h}(x) = x^{\deg h} h(x^{-1}), which is monic and divides xn1x^n - 1. This reciprocity preserves the cyclic structure and relates the generator of the dual directly to the parity-check of the original code. The dimension of a cyclic code satisfies k=ndegg(x)k = n - \deg g(x), as the degree of the generator determines the number of parity-check symbols. Cyclic codes are non-catastrophic (i.e., admit faithful shift-register encoding without error propagation) precisely when g(x)g(x) divides xn1x^n - 1 and gcd(g(x),h(x))=1\gcd(g(x), h(x)) = 1, a condition inherently met by the definition of the generator polynomial in the principal ideal structure. This ensures the encoding process is invertible and the code avoids degenerate error patterns in practical implementations.

Examples

Trivial Examples

The trivial cyclic codes provide simple illustrations of the cyclic structure and basic properties without involving complex error-correcting capabilities. The most basic example is the entire space Fqn\mathbb{F}_q^n, which forms a cyclic code of length nn over the finite field Fq\mathbb{F}_q. This code has dimension nn and generator polynomial g(x)=1g(x) = 1, meaning every possible vector is a codeword. Since cyclic shifts of any vector remain within the space, the code satisfies the cyclic property. The minimum distance of this code is d=1d = 1, as single-position changes are possible codewords. Another fundamental example over F2\mathbb{F}_2 is the even-weight code, also known as the even-parity code, which consists of all binary vectors of length nn with even Hamming weight. This is a cyclic code with dimension n1n-1 and generator polynomial g(x)=x+1g(x) = x + 1. The code is cyclic because a cyclic shift preserves the parity (even number of 1s) of any codeword, as the shift merely rearranges the positions without altering the total count. The minimum distance is d=2d = 2, since the lowest-weight nonzero codewords have exactly two 1s, and it can detect but not correct single errors. The binary repetition code of length nn is the cyclic code comprising the all-zero vector and the all-one vector, with dimension 1 and generator polynomial g(x)=1+x++xn1g(x) = 1 + x + \cdots + x^{n-1}. It is cyclic because cyclic shifts of the all-zero codeword remain all-zero, and shifts of the all-one codeword remain all-one. This code achieves the maximum possible minimum distance d=nd = n for its length and dimension, allowing correction of up to (n1)/2\lfloor (n-1)/2 \rfloor errors.

Reed-Solomon Codes

Reed-Solomon codes are a prominent subclass of non-binary cyclic codes defined over finite fields, renowned for their optimal error-correcting capabilities in practical applications. Introduced in 1960 by Irving S. Reed and Gustave Solomon, these codes construct codewords as evaluations of polynomials of degree less than kk at nn distinct points in the finite field Fq\mathbb{F}_q, where nqn \leq q and the evaluation points form a set of nn elements, often the powers of a primitive element αFq\alpha \in \mathbb{F}_q. This evaluation-based construction ensures the code is cyclic, with the generator polynomial g(x)g(x) formed as the least common multiple of the minimal polynomials of αb,αb+1,,αb+d2\alpha^b, \alpha^{b+1}, \dots, \alpha^{b+d-2} over Fq\mathbb{F}_q, where bb is a starting exponent and dd is the designed minimum distance. A defining feature of Reed-Solomon codes is their maximum distance separable (MDS) property, which achieves the Singleton bound with minimum distance d=nk+1d = n - k + 1. This optimality arises from the Vandermonde structure of the parity-check matrix, where any kk columns are linearly independent, guaranteeing that the code can correct up to (d1)/2\lfloor (d-1)/2 \rfloor errors or detect up to d1d-1 errors. Specifically, the generator polynomial takes the explicit form g(x)=i=1d1(xαb+i),g(x) = \prod_{i=1}^{d-1} (x - \alpha^{b+i}), ensuring the code has αb,αb+1,,αb+d2\alpha^{b}, \alpha^{b+1}, \dots, \alpha^{b+d-2} as consecutive roots, which directly enforces the distance property. Encoding in Reed-Solomon codes involves polynomial interpolation: a message of kk symbols corresponds to a polynomial m(x)m(x) of degree less than kk, and the codeword is the vector of its evaluations at the nn points, often realized systematically by appending parity symbols computed via multiplication by g(x)g(x). Decoding leverages syndrome computation, where received symbols are evaluated to form syndromes corresponding to powers of α\alpha, enabling error location and correction through methods like the Berlekamp-Massey algorithm for finding the error locator polynomial. In practice, Reed-Solomon codes have been widely adopted for reliable data storage and transmission, such as in compact disc (CD) systems where they correct errors from scratches and defects in the cross-interleaved Reed-Solomon code (CIRC) configuration, and in QR codes where they provide error correction levels up to 30% data loss as per ISO standards.

BCH Codes

BCH codes form a prominent class of cyclic error-correcting codes capable of correcting multiple random errors, constructed using algebraic constraints on the roots of the generator polynomial. Independently developed by Alexis Hocquenghem in 1959 and by Raj Chandra Bose and Dwijendra Kumar Ray-Chaudhuri in 1960, these codes generalize earlier single-error-correcting cyclic codes by imposing conditions on consecutive powers of a primitive element in a finite field extension. The standard Bose-Chaudhuri-Hocquenghem (BCH) construction defines a cyclic code of length n=qm1n = q^m - 1 over the finite field Fq\mathbb{F}_q, where m1m \geq 1 is the degree of the extension Fqm/Fq\mathbb{F}_{q^m} / \mathbb{F}_q, and α\alpha is a primitive element of Fqm\mathbb{F}_{q^m}. The generator polynomial g(x)g(x) is the least common multiple of the minimal polynomials of α,α2,,αδ1\alpha, \alpha^2, \dots, \alpha^{\delta-1} over Fq\mathbb{F}_q, denoted as g(x)=lcm[m1(x),m2(x),,mδ1(x)],g(x) = \mathrm{lcm} \left[ m_1(x), m_2(x), \dots, m_{\delta-1}(x) \right], where mi(x)m_i(x) is the minimal polynomial of αi\alpha^i. This choice ensures that the code has a designed distance δ\delta, which provides a lower bound on the actual minimum distance dδd \geq \delta, allowing correction of up to t=(δ1)/2t = \lfloor (\delta - 1)/2 \rfloor errors. The dimension kk of the code satisfies knm(δ1)k \geq n - m (\delta - 1), since the degree of g(x)g(x) is at most m(δ1)m (\delta - 1). Primitive BCH codes specifically employ a primitive α\alpha, yielding full-length codes n=qm1n = q^m - 1; in contrast, general BCH codes may use non-primitive elements for shorter lengths and are classified as narrow-sense (roots starting from α1\alpha^1) or wide-sense (starting from αb\alpha^b for b>1b > 1). Binary BCH codes represent a key special case with q=2q = 2, where the field is F2\mathbb{F}_2 and lengths are of the form n=2m1n = 2^m - 1. In this setting, the designed distance δ\delta is typically chosen to be odd for primitive binary BCH codes to optimize the root constraints, while even-designed distances are achieved through extended versions, such as by adding an overall parity-check bit to the primitive code, which increases the minimum distance by one. These binary variants maintain the bound knmtk \geq n - m t and are particularly efficient for hardware implementations due to their operation over F2\mathbb{F}_2. BCH codes, especially binary ones, continue to play a role in modern communications, including systems and media, where their multiple-error-correction capabilities enhance reliability in noisy environments.

Cyclic Redundancy Check (CRC) Codes

Cyclic redundancy check (CRC) codes are a class of primarily used for error detection rather than correction. Introduced by W. Wesley Peterson in 1961, they operate over F2\mathbb{F}_2 with a fixed generator g(x)g(x) of degree rr, which divides xn1x^n - 1 for code length nn. The encoding process treats the message as a m(x)m(x) of degree less than nrn - r, shifts it by xrx^r, and computes the remainder when divided by g(x)g(x); the codeword is then m(x)xrm(x) x^r - remainder, ensuring the entire codeword is divisible by g(x)g(x). This structure allows detection of all single-bit errors, all odd-numbered bit errors, and bursts of errors up to length rr. CRC codes are systematic and efficiently implemented using linear feedback shift registers. CRC codes are ubiquitous in protocols and storage systems due to their simplicity and effectiveness. Common polynomials include CRC-16 (e.g., g(x)=x16+x15+x2+1g(x) = x^{16} + x^{15} + x^2 + 1) used in USB and , and CRC-32 (e.g., x32+x26+[x23](/page/X23)++1x^{32} + x^{26} + [x^{23}](/page/X-23) + \dots + 1) in Ethernet and ZIP files, providing high undetected error probabilities below 10510^{-5} for typical frame sizes.

Error Correction Capabilities

Single Error Correction with Hamming Codes

Hamming codes represent a fundamental class of binary cyclic codes designed for single-error correction. These codes have length n=2m1n = 2^m - 1, where mm is a positive , k=nmk = n - m, and minimum distance d=3d = 3. The generator g(x)g(x) is a primitive of degree mm over GF(2)\mathrm{GF}(2), which is the minimal for a primitive element α\alpha of the extension field GF(2m)\mathrm{GF}(2^m). This construction ensures that the codewords are precisely the polynomials in GF(2)/(xn1)\mathrm{GF}(2) / (x^n - 1) that are divisible by g(x)g(x), with roots α,α2,α4,,α2m1\alpha, \alpha^2, \alpha^4, \dots, \alpha^{2^{m-1}}. Syndrome decoding for Hamming codes leverages the roots of g(x)g(x). For a received word corresponding to polynomial r(x)r(x), the syndrome components are computed as s(β)=r(β)s(\beta) = r(\beta) for each root β\beta of g(x)g(x). If a single error occurs at position ii (where the error polynomial is xix^i), then s(β)=βis(\beta) = \beta^{i} for each root β\beta, and the syndrome values form a vector that corresponds to the binary representation of ii under the vector space isomorphism GF(2m)GF(2)m\mathrm{GF}(2^m) \cong \mathrm{GF}(2)^m, uniquely identifying the error location. This algebraic approach enables efficient correction of any single error. Hamming codes are perfect codes, meaning the spheres of radius 1 centered at each codeword are disjoint and exactly cover the entire space GF(2)n\mathrm{GF}(2)^n. The number of codewords 2k2^k satisfies 2kl=01(nl)=2n2^k \sum_{l=0}^{1} \binom{n}{l} = 2^n, as the volume of each is 1+n=2m1 + n = 2^m, and there are 2nm2^{n-m} such spheres filling 2n2^n vectors without overlap or gap. An extended Hamming code is obtained by appending an overall to each codeword of the binary , resulting in a code of length 2m2^m, 2mm12^m - m - 1, and minimum distance 4. This extension preserves single-error correction while enabling detection of double errors. The parity-check matrix HH for the Hamming code is an m×nm \times n matrix over GF(2)\mathrm{GF}(2) whose columns are the distinct nonzero vectors in GF(2)m\mathrm{GF}(2)^m, specifically the binary representations of 1,2,,n1, 2, \dots, n, or equivalently, the vectors (α0j,α1j,,α(m1)j)T(\alpha^{0 j}, \alpha^{1 j}, \dots, \alpha^{(m-1) j})^T for j=0,1,,n1j = 0, 1, \dots, n-1, where α\alpha is interpreted in its GF(2)\mathrm{GF}(2)-vector space basis. This structure aligns with the cyclic representation and facilitates syndrome computation as HrTH \mathbf{r}^T. Binary Hamming codes correspond to the case t=1t=1 of BCH codes, serving as a foundational example of cyclic error-correcting codes.

Burst Error Correction

A burst error is defined as a sequence of consecutive errors confined to a window of b positions within a codeword of length n. The Reiger bound provides a fundamental limit on the burst error-correcting capability of linear block codes, stating that to correct all burst errors of length up to b, the redundancy r = n - k must satisfy r ≥ 2b. Codes achieving this bound are considered optimal for burst correction. Fire codes represent a prominent class of cyclic codes designed specifically for single burst error correction, constructed with generator polynomial g(x) = (x^{2t} - 1) p(x), where p(x) is an irreducible polynomial of degree m ≥ b over GF(2), and the code length n = 2t \cdot \ord(p(x)), with \ord(p(x)) denoting the order of p(x). This structure ensures the code can correct any single burst of length up to m while detecting bursts up to 2t + m. Fire codes are particularly efficient for channels prone to isolated bursts, such as early data transmission systems, offering high rates for large n. Decoding of Fire codes typically employs an error-trapping method using a feedback shift register to isolate the burst location, followed by syndrome computation to correct the errors within the trapped window. This approach, originally devised by Peterson and refined by Chien, processes the received word sequentially, leveraging the cyclic nature to shift errors into a known short syndrome span. Alternatively, the Berlekamp-Massey can be adapted to locate the burst by finding the minimal matching the syndrome sequence, enabling efficient algebraic decoding for practical implementations. In practical applications, particularly post-1980s storage media like compact discs, interleaved cyclic codes—such as cross-interleaved Reed-Solomon codes—enhance burst correction by distributing errors across multiple codewords, allowing correction of long bursts (up to 3,500 bits) that exceed single-code capabilities. This interleaving transforms consecutive errors into dispersed patterns correctable by component cyclic codes, significantly improving reliability in magnetic and optical recording systems.

Error Correction Bounds

The BCH bound provides a fundamental lower bound on the minimum of a cyclic code based on the consecutive roots of its generator . Specifically, for a cyclic code of length nn over a Fq\mathbb{F}_q with generator g(x)g(x) that has δ1\delta - 1 consecutive roots αb,αb+1,,αb+δ2\alpha^b, \alpha^{b+1}, \dots, \alpha^{b+\delta-2} in an extension field, where α\alpha is a primitive nn-th root of unity, the minimum satisfies dδd \geq \delta. A proof sketch relies on the parity-check matrix HH of the code, which includes δ1\delta - 1 rows corresponding to the syndromes evaluated at these roots. The submatrix formed by any δ1\delta - 1 columns of HH is a with 0i<jδ2(αb+jαb+i)0\prod_{0 \leq i < j \leq \delta-2} (\alpha^{b+j} - \alpha^{b+i}) \neq 0, ensuring full rank. Thus, no nonzero codeword of weight less than δ\delta can satisfy HcT=0H \mathbf{c}^T = \mathbf{0}, implying dδd \geq \delta. This bound is achieved by Reed-Solomon codes, where the minimum distance equals nk+1n - k + 1 and matches the designed δ\delta from consecutive root selection. Similarly, primitive BCH codes are constructed to meet the BCH bound exactly for their designed distance δ\delta, making them optimal in many parameter regimes. The Hartmann-Tzeng bound extends the BCH bound to non-consecutive roots under additional constraints. If the defining set includes δ+a(γ1)\delta + a(\gamma - 1) roots comprising δ1\delta - 1 consecutive roots followed by aa additional blocks of γ1\gamma - 1 roots each, spaced by steps coprime to nn (i.e., gcd(γ,n)=1\gcd(\gamma, n) = 1), then dδ+a(γ1)d \geq \delta + a(\gamma - 1). This generalization allows tighter bounds for codes with structured but gapped root sets. The Roos bound further refines these by incorporating paired root constraints. For a defining set with a core of δ1\delta - 1 consecutive roots, augmented by aa and bb additional roots satisfying certain coprimality and spacing conditions, the minimum distance satisfies dδ+min(a,b)(γ1)d \geq \delta + \min(a, b)(\gamma - 1). Recent computational verifications in the 2020s have confirmed that numerous optimal achieve or exceed these bounds for specific lengths and dimensions, as documented in updated tables of best-known linear codes. For instance, exhaustive searches have identified binary of odd length up to 125 where attain the maximum possible distance except in rare cases.

Spectral Perspective

Fourier Transform over Finite Fields

The discrete Fourier transform (DFT) over finite fields provides a powerful spectral analysis tool for cyclic codes defined over Fq\mathbb{F}_q, where qq is a power of a prime, by transforming codewords from the time domain to the frequency domain. For a cyclic code of length nn over Fq\mathbb{F}_q, assuming gcd(n,q)=1\gcd(n, q) = 1 so that nn is invertible in Fq\mathbb{F}_q, the DFT of a codeword c=(c0,c1,,cn1)c = (c_0, c_1, \dots, c_{n-1}) is the vector c^=(c^(α0),c^(α1),,c^(αn1))\hat{c} = (\hat{c}(\alpha^0), \hat{c}(\alpha^1), \dots, \hat{c}(\alpha^{n-1})), where α\alpha is a primitive nnth root of unity in an extension field Fqm\mathbb{F}_{q^m} containing such an element (with nqm1n \mid q^m - 1), and c^(αj)=i=0n1ci(αj)i\hat{c}(\alpha^j) = \sum_{i=0}^{n-1} c_i (\alpha^j)^i. This transform evaluates the associated polynomial c(x)=i=0n1cixic(x) = \sum_{i=0}^{n-1} c_i x^i at the nnth roots of unity, yielding a spectral representation that simplifies the study of code structure and operations. The inverse DFT recovers the original codeword from its spectrum via ci=n1j=0n1c^(αj)αijc_i = n^{-1} \sum_{j=0}^{n-1} \hat{c}(\alpha^j) \alpha^{-ij} for i=0,,n1i = 0, \dots, n-1, confirming the transform's bijectivity under the invertibility condition on nn. A key property is the convolution theorem, which states that the DFT of the cyclic convolution of two sequences equals the pointwise product of their DFTs: if ei=k=0n1fkg(ik)modne_i = \sum_{k=0}^{n-1} f_k g_{(i-k) \mod n}, then e^j=f^jg^j\hat{e}_j = \hat{f}_j \hat{g}_j. This correspondence underpins efficient encoding and decoding of cyclic codes, as multiplication in the polynomial ring Fq/(xn1)\mathbb{F}_q / (x^n - 1) translates directly to spectral multiplication. In the context of cyclic codes, codewords exhibit zero spectral components at the roots of the generator polynomial g(x)g(x); specifically, if β\beta is a root of g(x)g(x), then c^(β)=0\hat{c}(\beta) = 0 for every codeword c(x)c(x) divisible by g(x)g(x), highlighting how the spectrum encodes the code's defining zero set. The DFT matrix over finite fields possesses orthogonality properties analogous to the complex case, with the inner product of distinct columns satisfying i=0n1αi(jk)=nδj,k\sum_{i=0}^{n-1} \alpha^{i(j-k)} = n \delta_{j,k} (where δ\delta is the ), enabling ici2=n1jc^(αj)2\sum_i |c_i|^2 = n^{-1} \sum_j |\hat{c}(\alpha^j)|^2 (adapted to field trace for non-Archimedean norms). This unitarity up to scaling—where the inverse is n1n^{-1} times the conjugate transpose, but in characteristic not dividing nn, it behaves as a scaled unitary transform—facilitates energy-preserving analyses and bounds on code weights via spectral distributions. These features make the finite-field DFT indispensable for deriving algebraic insights into cyclic code performance without relying on exhaustive enumeration.

Spectral Factorization and Code Properties

In the spectral domain, cyclic codewords exhibit a structured support determined by the generator polynomial. For a cyclic code of length nn over a finite field Fq\mathbb{F}_q generated by g(x)g(x), the discrete Fourier transform (DFT) c^(β)\hat{c}(\beta) of any codeword c(x)c(x) vanishes at all elements β\beta in the zero set Z(g(x))Z(g(x)), the set of roots of g(x)g(x) in the splitting field. Thus, the spectral support of the code—the frequencies where c^(β)\hat{c}(\beta) may be nonzero—comprises the complement of Z(g(x))Z(g(x)) in the multiplicative group of the extension field. This property allows the code to be viewed as a subspace constrained to specific spectral lines, facilitating analysis and design in the frequency domain. Syndrome computation for error detection in cyclic codes leverages the DFT directly: for a received word r(x)=c(x)+e(x)r(x) = c(x) + e(x), the error syndrome components are the evaluations of the DFT r^(β)\hat{r}(\beta) at the check roots, i.e., the nonzero elements of Z(g(x))Z(g(x)), since c^(β)=0\hat{c}(\beta) = 0 there. These syndromes, forming a vector in the dual code's spectral representation, capture the error pattern's frequency content at the parity-check positions without requiring time-domain polynomial division. This approach reduces syndrome calculation to nkn-k DFT evaluations, where kk is the code dimension, and is foundational for algebraic decoding. The Peterson-Gorenstein-Zierler (PGZ) decoder exploits this spectral framework to correct errors up to the code's designed distance. It constructs an error locator polynomial whose roots correspond to the spectral positions of the error frequencies, using the syndromes to form a matrix whose determinant conditions reveal the error multiplicity tt. The decoder solves for the locator coefficients via linear algebra over the syndromes, then finds the roots in the spectral domain to identify error locations, enabling correction by subtracting the error pattern derived from the inverse DFT. This method, applicable to any cyclic code with known designed distance, achieves polynomial-time decoding for small tt. Autocorrelation properties of cyclic codes further illuminate their performance in noisy channels through spectral analysis. The autocorrelation function of a codeword, measuring similarity under shifts, transforms to the power spectral density c^(β)2|\hat{c}(\beta)|^2 via the DFT; for ideal codes, this density concentrates on the spectral support, yielding low out-of-phase autocorrelation for sequence subsets like m-sequences derived from cyclic codes. Such analysis quantifies spectral efficiency and interference resistance, with the code's power spectrum determining peak-to-average ratios in modulated transmissions. For practical implementation of the DFT in cyclic coding when nn is composite or not suited to standard fast algorithms (e.g., not a power of 2 or the field characteristic), Bluestein's algorithm provides an efficient alternative. Introduced in 1970, it reformulates the DFT as a linear convolution via a chirp-like transformation, computable using a standard FFT of length approximately 2n2n over the base field, achieving O(nlogn)O(n \log n) complexity regardless of nn's factorization. This is particularly relevant for hardware realizations of cyclic decoders over arbitrary lengths.

Advanced Bounds

The Hartmann-Tzeng bound refines the minimum distance estimate for cyclic codes by incorporating zeros whose indices form arithmetic progressions in the spectral domain. Specifically, if the defining set of a cyclic code of length nn over Fq\mathbb{F}_q includes δ1\delta - 1 consecutive powers of a primitive nnth root α\alpha, along with additional zeros at positions αi+jb\alpha^{i + j b} for j=1,,sj = 1, \dots, s, where gcd(b,n)=1\gcd(b, n) = 1, then the minimum distance dd satisfies dδ+sd \geq \delta + s. This spectral formulation leverages the structure of root indices in arithmetic progression to achieve tighter bounds than the standard BCH bound, particularly when the zeros are not strictly consecutive. The Roos bound further generalizes this approach by considering unions of cosets in the defining set and refining the distance estimate through their intersections. For a cyclic code whose defining set contains elements from multiple cosets of a subgroup of the multiplicative group, the bound exploits the cardinality of intersections between these cosets to yield dδ+sd \geq \delta + s, where δ\delta relates to the length of progressions within cosets and ss to the number of intersecting cosets. This method provides improved lower bounds for codes with non-consecutive or structured spectral zeros, often surpassing the Hartmann-Tzeng bound in cases involving coset intersections. Quadratic residue (QR) codes represent a prominent class of binary cyclic codes constructed using spectral zeros based on quadratic residues modulo a prime length p±1(mod8)p \equiv \pm 1 \pmod{8}. Defined over F2\mathbb{F}_2 with length pp, the generator polynomial g(x)g(x) is the product (xαi)(x - \alpha^i) over all quadratic residues ii modulo pp, where α\alpha is a primitive ppth root of unity in an extension field F2m\mathbb{F}_{2^m} such that pp divides 2m12^m - 1. These codes have odd minimum distance dd, often achieving d=(p+1)/2d = (\sqrt{p} + 1)/2
Add your contribution
Related Hubs
User Avatar
No comments yet.