Path: blob/main/course-contents/2024-02-14--notes-ECC--intro.md
909 views
------\newcommand{\F}{\mathbb{F}} \newcommand{\Z}{\mathbb{Z}} \newcommand{\e}{\mathbf{e}} \newcommand{\bb}{\mathbf{b}} \newcommand{\Null}{\operatorname{Null}}
The idea
We want to transmit information over a potentially noisy channel. So we want to encode our information in some way that permits us to later decode it even in the presence of transmission errors.
We want to exploit algebra to create our codes. We will use as our alphabet a finite field ParseError: KaTeX parse error: Undefined control sequence: \F at position 5: K = \̲F̲_q
Some recollections about finite fields
We pause to recall some information about finite fields. We plan to return to this topic.
First of all, any finite field contains a copy of the field ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_p = \Z/p\Z for some prime number . Moreover, can then be viewed as a finite-dimensional vector space over ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_p; as such, if ParseError: KaTeX parse error: Undefined control sequence: \F at position 11: d = \dim_{\̲F̲_p} K we see that .
Thus every finite field has order a power of some prime number .
On the other hand, for any prime power there is a finite field ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_q which is unique up to isomorphism.
For example, ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_9 = \F_3[i] = … where ParseError: KaTeX parse error: Undefined control sequence: \F at position 18: …2 = -1 = 2 \in \̲F̲_3. In fact, ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_9 \simeq \F_3[… (quotient of the polynomial ring ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_3[T] by the principal ideal generated by the minimal polynomial of the element ParseError: KaTeX parse error: Undefined control sequence: \F at position 7: i \in \̲F̲_9. This isomorphism identifies with the coset ).
Codewords as vectors
We are going to study what are known as linear codes . A linear code is a linear subspace ParseError: KaTeX parse error: Undefined control sequence: \F at position 13: C \subseteq \̲F̲_q^n for some natural number .
Thus a code word is a vector , and we can write for elements in our alphabet ParseError: KaTeX parse error: Undefined control sequence: \F at position 5: k = \̲F̲_q.
We write for the dimension of ; i.e. ParseError: KaTeX parse error: Undefined control sequence: \F at position 11: k = \dim_{\̲F̲_q} C. We say that is an -code, or more precisely an -code.
Specifying a code via a generator matrix.
Let be an -code, and choose a basis for as ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_q-vector space.
Since ParseError: KaTeX parse error: Undefined control sequence: \F at position 11: C \subset \̲F̲_q^n = \F_q^{1 …, we view elements of as row vectors.
Now form the matrix matrix whose rows are the vectors :
is known as a generator matrix for the code .
Notice that we recover from as the image of the linear transformation ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_q^k \to \F_q^n determined by right-multiplication with :
ParseError: KaTeX parse error: Undefined control sequence: \F at position 42: …\mathbf{x} \in \̲F̲_q^{1 \times n}…Standard form
Let us write ParseError: KaTeX parse error: Undefined control sequence: \e at position 1: \̲e̲_1,\e_2,\cdots,… for the standard basis for ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_q^n.
Lemma: : Let be an -code, and let be a generator matrix for .
Proof of the Lemma: : a. By construction, has linearly independent rows (its rows are a basis for ). Since is it follows that the rank of is equal to .
We say that a () generator matrix for the -code is in standard form if it has the form for some matrix ; thus the Lemma asserts that (after possibly changing the ordering of the coordinates on ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_q^n) every code has a generator matrix in standard form.
Check matrices
The preceding discussion described the subspace by giving generators for the vector space. In contrast, we may also specify a subspace using linear equations.
So: let be an -code.
Consider the quotient linear mapping : ParseError: KaTeX parse error: Undefined control sequence: \F at position 1: \̲F̲_q^n \to \F_q^n…
There is an matrix which represents this linear mapping; then ParseError: KaTeX parse error: Undefined control sequence: \F at position 24: …l(H) = \{x \in \̲F̲_q^{1 \times n}… i.e. we see that is the null space for some matrix .
We say that such a matrix is a check matrix for . For a vector ParseError: KaTeX parse error: Undefined control sequence: \F at position 7: x \in \̲F̲_q^{1 \times n}, we can check membership in using : we have .
Proposition: : Suppose that is an -code and that is a generator matrix for in standard form. Then the matrix is a check matrix for .
Proof: : We observe that
Weights and distance
For a vector ParseError: KaTeX parse error: Undefined control sequence: \F at position 31: …cdots,v_n) \in \̲F̲_q^n = \F_q^{1 … we define to be the number of non-zero entries; i.e.
For two vectors ParseError: KaTeX parse error: Undefined control sequence: \F at position 9: v,w \in \̲F̲_q^n the distance between and is defined to be
Thus represents the number of coordinates in which and differ.
For a subspace ParseError: KaTeX parse error: Undefined control sequence: \F at position 11: C \subset \̲F̲_q^n - i.e. a code - we define the minimal distance of to be
The following lemma is immediate:
Lemma: :
If is the minimal distance of the code , we say that is an -code.
Example
We investigate an example using SageMath.
Let's create the field k having 3 elements, and the standard vector space V=k^9
Now let's create a certain 3 dimensional subspace C of V -- a code -- essentially by giving its generator matrix.
In order to manipulate the generator matrix as a matrix, we create the MatrixSpace of the right dimensions, and coerce the basis of C into a matrix:
We investigate the weights of non-zero vectors in C:
This shows that is a -code.
Notice that the generator matrix G is in standard form. Let's extract from G the matrix A which is the 3 x 6 matrix for which G = [ I₃| A ]
We can now form the 6 × 9 check matrix H = [ -A.T | I₆] as above.\
We can confirm that H * G.T == 0 and that H has rank 6:
And indeed, if we use SAGE to check the right_kernel of the matrix H, we get exactly the subspace C.
So H is indeed a check-matrix for the code C.
Bibliography
::: {.refs} :::