Shortened Generator Matrix

389 Views Asked by At

goodmorning, could someone tell me if the following code has been handled correctly?

I have this generator matrix (which I should modify in order to have it correct): $$G=\begin {bmatrix} 1&0&0&1&0&1&1&0\\ 0&1&0&1&1&1&1&1\\ 0&1&1&0&1&1&0&1\\ \end{bmatrix}$$

I added line2 and line3 and I replaced line3 with this result

$$G'=\begin{bmatrix} 1&0&0&1&0&1&1&0\\ 0&1&0&1&1&1&1&1\\ 0&0&1&1&0&0&1&0\\ \end{bmatrix}$$

my main question, however, is this: I've been asked to protect from errors the source code of four words (same probability). For this I have to use a shortened code of $\mathcal C(8,3)$. I then should encode those words with the code I obtained.

Four possible words with equal probabilities could be $\{00, 01, 10, 11\}$, right? Then I started with reducing the $G'$ matrix getting a $G"= (n-1, k-1)$ and deleted the last row and last column.

got

$$G''=\begin{bmatrix} 1&0&0&1&0&1&1\\ 0&1&0&1&1&1&1\\ \end{bmatrix}$$

I then encoded the 4 words and got: $$00 = 000000\\ 01 = 010111\\ 10 = 100101\\ 11 = 110010$$

Now, since I can't check if what I did is correct or not, could someone tell me if I did something wrong and point me out to that? Thanks in advance and sorry for my english.

EDIT

I think that the shortening of the matrix could be done more correctly by removing a column and a row in a better way. What if I remove the last column of the identity matrix and the first row in order to keep the length of redundancy the same? $$G''=\begin{bmatrix} 1&0&1&1&1&1&1\\ 0&1&1&0&0&1&0\\ \end{bmatrix}$$