# Error-correcting codes used in real life

I am very interested in coding theory and I wonder if there is a particular kind of codes used in practice. For example I read that Reed-Solomon codes are often used for encoding data on a compact disc.

In particular I would like to know which kind of code is mostly used in real life and in which contest. I know that it is not a specific question but I'm really curious to know how coding theory is used in current technology.

Moreover I'm also interested in knowing which is more or less the usual length of a code used in practice.

Thanks a lot for the answer

• Thanks for asking this! I always like seeing interesting applications of error correction. Hopefully others will post answers as well. – Snowball Oct 15 '14 at 3:42
• The QuickResponse codes were not listed yet. They are just Reed-Solomon codes over $GF(256)$, but have become popular lately because there are apps allowing smartphones to use them. As you see from Snowball's comprehensive list (and my old answer) wireless apps use either LDPC or Turbo codes (or when the blocks are quite short convolutional codes). That's because soft decoding is a must for those applications, and algebraic codes don't handle that very well. Algebra shows its power when soft information is not available. – Jyrki Lahtonen Oct 24 '14 at 19:59

Here are a few:

• The 10GBASE-T standard for 10 Gbit/s Ethernet over copper uses a $[2048,1723]_2$ LDPC code constructed from a generalized Reed-Solomon code.

• RAID 6 implementations often use generalized Reed-Solomon codes to correct erasures caused by failed disks. I believe the Linux implementation of RAID 6 uses codes like $[n,k]_{2^8}$ where $0 \le k < n \le 255$; typically something like $k \approx 3$ and $n \approx 5$.

• The object storage system Ceph supports a generalized Reed-Solomon code so that data is accessible even if several of the storage nodes are unavailable (erasure coding). I haven't looked into it carefully, but I believe the parameters are around the same order as those of RAID 6.

• Error correcting memory often uses a modified Hamming code. According to an unknown Wikipedia contributor, $[72,64]_2$ and $[127,120]_2$ are popular parameters.

• The McEliece cryptosystem is based on a $[1632,1269,69]_2$ Goppa code. Supposedly this cryptosystem is a candidate for post-quantum cryptography (cryptography that isn't broken by quantum computers).

• ITU OTN uses a $[255,239]_{2^8}$ Reed-Solomon code for error correction on fiber optic networks.

• In machine learning, BCH and (more commonly) 1-of-n codes are used to implement non-binary classification of data using a support vector machine. There's a wide range of parameters here depending on the application, but I'd estimate it's typically around length 10-1000.

• In cryptography, Shamir's secret sharing scheme is a special case of Reed-Solomon erasure coding. I don't know what secret sharing is typically used for, so I don't know what the typical parameters would be.

See also Jyrki's answer to my question from a while back. He covers several telecommunications applications and their typical parameters.

Example in practice: In European Railway Business (Signalling) we have to follow specific Safety Standards (according to CENELEC). An important aspect is the data transfer in closed transmission systems. One out of many techniques/measurements to avoid failures resp. detect failures in order to mitigate consequences is the usage of CRC codes.

The challenge was to find CRC codes which are with respect to their error detection properties appropriate for the specific application and which also follow the requirements of the Standard (EN 50159-1), namely to be a proper resp. good CRC code.

Note: A CRC code is proper if the undetected error probability $$P_{ud}(C,\varepsilon)$$ of the Code is an increasing function of the bit-error probability $$\varepsilon$$ for $$\varepsilon \in [0,\frac{1}{2}]$$. It can therefore be estimated by

$$P_{ud}(C,\varepsilon)\leq P_{ud}(C,\frac{1}{2})$$

which makes it suitable for further calculations. Goodness of a CRC is a somewhat weaker property.

Some important aspects:

• Message data length: The block length of the input data on which the CRC is calculated is crucial for the quality of the error detection capabilities. It turns out that the minimum Hammingdistance $$d_{min}(n)$$ of data with block length $$n$$ should be maximised (see e.g. Optimum Cyclic Redundancy-Check Codes with 16-Bit Redundancy (1990) from Castagnoli etal.

• Properness, Goodness: are properties of the CRC code which are also dependent on the message data length

• Usage of Standard CRCs is not always the best choice.

Some CRCs were designed for a specific usage and therefore appropriate for a small range of applications only. The internet community has sometimes adopted such a CRC and so it became a standard or de facto standard. Research starting in the $$90$$s has revealed some better alternatives. This was also possible due to the increasing computer power. See e.g. the paper Undetected error probability performance of cyclic redundancy-check codes of 16-bit redundancy (2000) from Baicheva, etal.

Koopman presented some interesting papers (e.g. Cyclic Redundancy Code (CRC) Polynomial Selection For Embedded Networks (2004).

Here's a nice tutorial Techniques for aviation from Koopman ($$2012$$) regarding this theme.

Note: In fact we've studied many papers (and other sources) in order to make finally a suitable choice.

Note: Some time ago I've posted a different checksum problem. But, maybe it's too simple and not the type of cryptographic info you are looking for.

• @Snowball: Hi, Snowball! Thanks for granting the bounty! :-) – Markus Scheuer Dec 6 '14 at 7:09

To give a totally different example, codes have also been used for betting systems that guarantee at least one bet with many matches while placing relatively few bets