[Math] Computing the partial trace of a matrix

index-notationlinear algebralinear-transformationsmatricestrace

I'm trying to understand the Wikipedia article on the partial trace. I do not understand their notation for the matrix elements of a tensor product of operators; that is, the object $\{a_{k l,ij}\}$ in the first section under the heading "details" at this link.

I think a simple example will make this clear. Let $$A = \left[ \begin{array}{cc}1 & 2\\ 3 & 4 \end{array}\right], \quad B= \left[ \begin{array}{cc}8 & 9\\ 7 & 6 \end{array}\right].$$
And also let these matrices act on vector spaces $V = \mathbf{R}^2$ and $W = \mathbf{R}^2$ respectively.

Then
$$A \otimes B = \left[\begin{array}{cccc}8 & 9 & 16 & 18 \\ 7 & 6 & 14 & 12 \\ 24 & 27 & 32 & 36 \\ 21 & 18 & 28 & 24\end{array} \right] ("=" \{a_{k l,ij}\}).$$
Now clearly from the definitions of $A$ and $B$ we can tell that
$$\operatorname{Tr}_W (A \otimes B ) = \operatorname{Tr}(B)\,A = 14\times \left[ \begin{array}{cc}1 & 2\\ 3 & 4 \end{array}\right] = \left[ \begin{array}{cc}14 & 28\\ 42 & 56 \end{array}\right]("=" \{b_{ki}\})$$

But I would like to see how this could be obtained directly from the matrix representation of $A \otimes B.$ In particular, how am I supposed to interpret the 4-index object $\{a_{k l,ij}\}$ in the wikipedia article here? How do I compute $b_{ki} = \sum_j a_{kj,ij}$?

Thanks!

Edit: I thought the solution was that:

In fact the object $\{a_{kl,ij}\}$ is a two-index object, as we should expect it to be. The subscript contains products of the numbers $k, l$ and $i, j$. The comma separates the two indices.

But this cannot be true. Because using this, we compute the off-diagonal element $b_{12} = a_{12} + a_{24} = 19 \neq 28$. We instead want the off-diagonal element $b_{12} = a_{13} + a_{24} = 28,$ but I do not see how the prescription from wikipedia furnishes this. Perhaps I am making some very simple arithmetic error.

Best Answer

It helps to think of this as a partitioned matrix. We have $$ A \otimes B = \left[\begin{array}{cc|cc} a_{11,11} & a_{11,12} & a_{11,21} & a_{11,22}\\ a_{12,11} & a_{12,12} & a_{12,21} & a_{12,22}\\ \hline a_{21,11} & a_{21,12} & a_{21,21} & a_{21,22}\\ a_{22,11} & a_{22,12} & a_{22,21} & a_{22,22} \end{array}\right] $$ In the pair $ij$, $i$ specifies which block you're in, and $j$ specifies where you are in the block.

Now, we compute (for instance) $$ b_{21} = a_{21,11} + a_{22,12} $$ which you'll recognize as the trace of the lower-left block.

Related Question