Digital Codes Code:  M0.528    :  6
View general information   Description   The subject within the syllabus as a whole   Professional fields to which it applies   Prior knowledge   Learning objectives and results   Content   View the UOC learning resources used in the subject   Guidelines on assessment at the UOC   View the assessment model  
This is the course plan for the second semester of the academic year 2023/2024. To check whether the course is being run this semester, go to the Virtual Campus section More UOC / The University / Programmes of study section on Campus. Once teaching starts, you'll be able to find it in the classroom. The course plan may be subject to change.

Error control codes are used to detect and correct errors that may occur in data transmission or storage through eventually defective channels or storage devices that can distort the sent or stored information. For example, the atmosphere introduces errors in the transmission of images from the Meteosat satellite to Earth, different interferences in a communication by mobile phone may cause transmission errors, or reading devices need correcting algorithms for handling CDs, DVDs or USB memories. Error control codes are also used in distributed data storage in the clouds to recover lost or damaged chunks of information.

The modus operandi of those codes is sending along with the original information a small amount of redundancy, so that from all the received information, one can deduce what is actually transmitted. The simplest example is adding for every transmitted bit (a 0 or a 1), two identical copies. So if the original bit or one of its copies is wrongly received, we can still correct it from the other two, which we expect to coincide. Note that by adding redundancy, on one side we improve the quality of the received information. But, on the other side, we augment the transmission cost. In the example of repeating bits, the transmission cost is multiplied by three.

Coding Theory aims at designing and implementing codes with good correcting capacity, while maintaining a low transmission cost, as well as designing detection and correction algorithms that allow the receiver to recover the original information.

In this course we will introduce Reed-Solomon codes, nowadays the most used codes, the CRC codes used in mobile cell phone networks, cordless phones, USB memories, Gzip, Bzip2 and other software systems, as well as the LRC codes used by the Microsoft team in their Windows Azure.


This subject is an optative subject of the first semester. It has continuity with the subject of Cryptography of the second semester.


Software engineering, electronic devices and cloud storage systems.


Basic mathematics knowledge (Mathematics or Engineering Bachelor's degree)


- Knowing the notions of divisibility, prime numbers and greatest common divisor. Knowing how to factor an integer and to determine its primality and knowinh how to calculate the greatest common divisor of two integers.

- Knowing how to manipulate integer congruences and the rings Zm. Knowing how to operate with polynomials.

- Knowing how to manipulate finite fields.

- Knowing the basic notions of information theory and the meaning of the discipline.

- Having an idea of the notion of noisy channel, as well as of the problem of error detection and correction.

- Knowing the notions of block code, Hamming distance, code length and error correcting capacity.

- Knowing the notion of linear code and knowing how to manipulate the generator and parity check matrices of a linear code.

- Knowing how to apply error correction by syndromes.

- Knowing cyclic codes and understanding the notion of generator polynomial. Knowing how to do the basic operations of a cyclic code using the generator polynomial.

- Knowing how to build and how to operate with algebraic, Reed Solomon and BCH codes.

- Knowing the CRC and LRC codes.

- Having an idea of other applications.


1. Arithmetic and Finite Fields:

a) Divisibility, prime numbers, greatest common divisor and Euclid's algorithm.

b) Congruences. Rings Zm. Polynomials, divisibility of polynomials, primitive elements.

c) Finite fields.

2. Information coding (classical):

a) Information theory. Noisy channels.

b) Block codes. Length and correction capacity.

c) Linear codes. Generator matrix and parith check matrix. Correction of errors by syndrome.

d) Cyclic codes. Generator polynomial.

e) Algebraic codes. Reed-Solomon and BCH codes.

3. Information coding (advanced)

Diverse applications of the Reed-Solomon codes CRC and LRC codes


Finite arithmetic and error correcting codes PDF


The assessment process is based on students' own work and the assumption that this work is original and has been carried out by them.

In assessment activities, the following irregular behaviours, among others, may have serious academic and disciplinary consequences: someone else being involved in carrying out the student's assessment test or activity, or the work being not entirely original; copying another's work or committing plagiarism; attempting to cheat to obtain better academic results; collaborating in, covering up or encouraging copying; or using unauthorized material, software or devices during assessment.

If students are caught engaging in any of these irregular behaviours, they may receive a fail mark (D/0) for the assessable activities set out in the course plan (including the final tests) or in the final mark for the course. This could be because they have used unauthorized materials, software or devices (e.g. social networking sites or internet search engines) during the tests, because they have copied text fragments from an external source (internet, notes, books, articles, other student's projects or activities, etc.) without correctly citing the source, or because they have engaged in any other irregular conduct.

In accordance with the UOC's academic regulations , irregular conduct during assessment, besides leading to a failing mark for the course, may be grounds for disciplinary proceedings and, where appropriate, the corresponding punishment, as established in the UOC's coexistence regulations.

In its assessment process, the UOC reserves the right to:

  • Ask the student to provide proof of their identity, as established in the university's academic regulations.
  • Request that students provide evidence of the authorship of their work, throughout the assessment process, both in continuous and final assessment, by means of an oral test or by whatever other synchronous or asynchronous means the UOC specifies. These means will check students' knowledge and competencies to verify authorship of their work, and under no circumstances will they constitute a second assessment. If it is not possible to guarantee the student's authorship, they will receive a D grade in the case of continuous assessment or a Fail in the case of final assessment.

    For this purpose, the UOC may require that students use a microphone, webcam or other devices during the assessment process, in which case it will be the student's responsibility to check that such devices are working correctly.


You can only pass the course if you participate in and pass the continuous assessment. Your final mark for the course will be the mark you received in the continuous assessment.