# Obtaining hermitian matrix using Knill and Laflamme condition?

Let $$E$$ be the set of all correctable errors and $$E_a, E_b \in E$$. Let $$\lbrace \vert c_1\rangle, \vert c_2\rangle, \ldots \vert c_k\rangle\rbrace$$ be the basis of codewords in the codespace. It is necessary that $$\langle c_i \vert E^{\dagger}_{a}E_b \vert c_j\rangle = 0, \tag{1}$$ for all $$i, j \in \lbrace 1, 2, \ldots, k \rbrace \;\land i \neq j$$. This is equivalent to $$\langle c_i \vert E^{\dagger}_{a}E_b \vert c_i\rangle = \langle c_j \vert E^{\dagger}_{a}E_b \vert c_j\rangle, \tag{2}$$ for all $$i, j \in \lbrace 1, 2, \ldots, k \rbrace$$. Equation $$(1)$$ and $$(2)$$ can be combined as (Knill and Laflamme) $$\langle c_i \vert E^{\dagger}_{a}E_b \vert c_j\rangle = C_{ab} \delta_{ij},$$ where $$C_{ab} \in \mathbb{C}$$ and $$\delta_{ij} = \begin{cases} 1 \text{ if }\, i = j, \\0 \text{ if }\, i \neq j. \end{cases}$$

Furthermore, since $$\langle c_i \vert E^{\dagger}_{a}E_b \vert c_i\rangle = (\langle c_i \vert E^{\dagger}_{b}E_a \vert c_i\rangle)^*,$$ for all the codewords in the codespace, we can write $$C_{ab}$$ as a Hermitian matrix.

The source of the above can be found in 2.1.3 Criteria for quantum error correction (page 11).

Questions

1. I cannot figure out how equations $$(1)$$ and $$(2)$$ are equivalent. My humble explanation suggests that for $$(1)$$, they are equivalent since $$E^{\dagger}_a E_b$$ would cancel out to $$I$$ and we are left with $$\langle c_i\vert c_j \rangle = 0$$, since they are orthogonal. For $$(2)$$ we have $$E^{\dagger}_a E_b$$ would cancel out to $$I$$ and we are left with $$\langle c_i\vert c_i \rangle = \langle c_j\vert c_j \rangle = 1$$, since we are projecting a state on itself.
2. How can we convert $$C_{ab}$$ to matrix, what is the matrix dimension and what is the nature of the elements in the cells of this matrix (a binary matrix or elements in $$\mathbb{C}$$ or something else)?
3. Links to questions two, how would $$\delta_{ij}$$ affect the matrix?

I am certainly not looking for complete answers, I am trying to understand this myself. I am open to any suggestions and scholarly articles that helps. Any hints and tips are appreciated :).

1. I cannot figure out how equations $$(1)$$ and $$(2)$$ are equivalent. My humble explanation suggests that for $$(1)$$, they are equivalent since $$E^{\dagger}_a E_b$$ would cancel out to $$I$$ and we are left with $$\langle c_i\vert c_j \rangle = 0$$, since they are orthogonal. For $$(2)$$ we have $$E^{\dagger}_a E_b$$ would cancel out to $$I$$ and we are left with $$\langle c_i\vert c_i \rangle = \langle c_j\vert c_j \rangle = 1$$, since we are projecting a state on itself.

Eq. $$1$$ and $$2$$ are not necessarily equivalent, they are just both necessary for a QECC. Eq. $$1$$ states that orthogonality between codewords is preserved, even if one error $$E_{a}$$ acts upon one of the codewords, and some other error $$E_{b}$$ acts upon the other - that way we can always tell two error apart, regardless of what exactly the state encoded in the subspace is. Eq. $$2$$ takes care of something else: whatever the state encoded in the subspace is, errors occurring on this state must not reveal anything about the state (otherwise we could learn something about the state, thereby destroying quantum information). In other words, the 'symmetric' inner product cannot depend on what exactly the 'current' codeword (or superposition thereof) is!

You can also check out Gottesman's introduction to QECC's (check section $$2.2$$ on page $$5$$ and specifically Eq. $$(26)$$) - he has what I believe to be a clear explanation on why we have these conditions exactly.

1. How can we convert $$C_{ab}$$ to matrix, what is the matrix dimension and what is the nature of the elements in the cells of this matrix (a binary matrix or elements in $$\mathbb{C}$$ or something else)?

We say that we get a $$|E|\times |E|$$ matrix $$C$$, where the $$(a,b)$$-th element is the inner product $$\langle c_{i}|E_{a}^{\dagger}E_{b}|c_{i}\rangle$$ - Eq. $$2$$ tells us that it does not matter what codeword $$|c_{i}\rangle$$ we use, as every codeword should give the same result. Generally this matrix is in $$C^{|E|\times |E|}$$, but if $$\{E_{1}...E_{|E|}\}$$ is the set of correctable errors, you can view this set as a basis for the space $$\mathcal{E}$$ of correctable errors. As $$C$$ is Hermitian, there exist a basis of $$\mathcal{E}$$ such that $$C$$ becomes diagonal with real entries. These entries are not necessarily $$1$$ (they will be $$\geq 0$$ though, and generally speaking they are $$\leq 1$$). However, these scaling factors are relatively meaningless, and for additive (i.e. stabilizer) codes, in this particular basis the entries are normally $$1$$.

So, if our set of correctable errors is $$\{E_{1}...E_{|E|}\}$$, we get for our matrix $$C$$: $$C = \begin{bmatrix} \langle c_{i*}|E_{1}^{\dagger}E_{1} | c_{i*}\rangle & \langle c_{i*}|E_{1}^{\dagger}E_{2} | c_{i*}\rangle & \cdots & \langle c_{i*}|E_{1}^{\dagger}E_{|E|} | c_{i*}\rangle \\ \langle c_{i*}|E_{2}^{\dagger}E_{1} | c_{i*}\rangle & \langle c_{i*}|E_{2}^{\dagger}E_{2} | c_{i*}\rangle & \cdots & \langle c_{i*}|E_{2}^{\dagger}E_{|E|} | c_{i*}\rangle \\ \vdots & \vdots & \ddots & \vdots \\ \langle c_{i*}|E_{|E|}^{\dagger}E_{1} | c_{i*}\rangle & \langle c_{i*}|E_{|E|}^{\dagger}E_{2} | c_{i*}\rangle & \dots & \langle c_{i*}|E_{|E|}^{\dagger}E_{|E|} | c_{i*}\rangle \\ \end{bmatrix}$$ Note that this is slightly different than your comment, since I do not use two separate codewords - if we use different codewords all entries become zero per the first QECC condition. Of course, per the second condition, the codeword $$|c_{i*}\rangle$$ is completely arbitrary.

1. Links to questions two, how would $$\delta_{ij}$$ affect the matrix?

$$\delta_{ij}$$ is there to 'take care' of your equation $$1$$ - without it, orthogonality between different codewords would not be preserved. All information about what error has happened is encoded into $$C$$.

• Thank you for the detailed explanation and the reference you provided! I have another follow-up question regarding the hermitian matrix. I expanded it out as follows: Sep 14, 2020 at 20:44
• $C_{{ab}_{| E | \times | E |}} = \begin{bmatrix} \langle c_i | E^{\dagger}_{1}E_1 | c_j\rangle & \langle c_i | E^{\dagger}_{1}E_2 | c_j \rangle&\cdots & \langle c_i | E^{\dagger}_{1}E_{| E |}| c_j\rangle\\ \langle c_i | E^{\dagger}_{2}E_1 | c_j\rangle & \langle c_i | E^{\dagger}_{2}E_2 | c_j \rangle&\cdots & \langle c_i | E^{\dagger}_{2}E_{| E |}| c_j\rangle\\ \vdots & \vdots &\ddots & \vdots\\ \langle c_i | E^{\dagger}_{| E |}E_1 | c_j\rangle & \langle c_i | E^{\dagger}_{| E |}E_2 | c_j \rangle&\cdots & \langle c_i | E^{\dagger}_{| E |}E_{| E |}| c_j\rangle\\ \end{bmatrix}$ Sep 14, 2020 at 20:44
• and the codewords $\vert c_j\rangle$ and $\vert c_j\rangle$ can be any arbitrary codewords in the codeword basis, $i, j \in \lbrace 1, 2, \ldots , k \rbrace$. This is because the matrix is codeword independent. Would that be a valid thought? Sep 14, 2020 at 20:46
• @M.AlJumaily I added some small stuff about the matrix - note that it is not completely the same as what you wrote down, since you actually have two different arbitrary codewords, whereas I have only one (arbitrary) codeword.
– JSdJ
Sep 14, 2020 at 21:26
• It is the same for any codeword, so for any element of the basis, or a linear combination from the basis. See again the second condition.
– JSdJ
Sep 14, 2020 at 21:50