How does the partial transpose operation look like in matrix form?

The link here gives a nice description of how partial trace looks in matrix notation. I want a similar explanation for the matrix partial-transposition. How does matrix partial-transposition operation look in the matrix form rather than in Dirac notation?

• Transposition or partial transposition? – Norbert Schuch Dec 6 '18 at 17:25
• I meant partial transposition. I just corrected it. – Zilch Dec 6 '18 at 17:30
• Which of the linked answers you like? The first can be translated 1-to-1 to the transpose. – Norbert Schuch Dec 6 '18 at 19:46
• I like the second one. Where one can write the action of partial tracing as summing to the basis of one party and leaving the other alone (the identity matrix). – Zilch Dec 6 '18 at 19:55

An operator $$M$$ acting on a vector space $$V_A \otimes V_B$$ can be decomposed as: $$M = \sum_{ij} c_{ij} A^{(i)} \otimes B^{(i)}$$ with $$A^{(i)}$$ acting on $$V_A$$ and $$B^{(j)}$$ acting on $$V_B$$. Using matrices to denote $$M$$, $$A^{(i)}$$ and $$B^{(i)}$$: $$M = \sum_{ij} c_{ij} \left( \begin{array}{ccc} a^{(i)}_{11} B^{(i)} & a^{(i)}_{12} B^{(i)} & \cdots \\ a^{(i)}_{21} B^{(i)} & a^{(i)}_{22} B^{(i)} & \cdots \\ \vdots & \vdots & \ddots \\ \end{array} \right)$$
Then, the partial transpositions are: $$M^{T_A} = \sum_{ij} c_{ij} \left( \begin{array}{ccc} a^{(i)}_{11} B^{(i)} & a^{(i)}_{21} B^{(i)} & \cdots \\ a^{(i)}_{12} B^{(i)} & a^{(i)}_{22} B^{(i)} & \cdots \\ \vdots & \vdots & \ddots \\ \end{array} \right) \\ M^{T_B} = \sum_{ij} c_{ij} \left( \begin{array}{ccc} a^{(i)}_{11} (B^{(i)})^T & a^{(i)}_{12} (B^{(i)})^T & \cdots \\ a^{(i)}_{21} (B^{(i)})^T & a^{(i)}_{22} (B^{(i)})^T & \cdots \\ \vdots & \vdots & \ddots \\ \end{array} \right)$$
I'm not sure what you mean by "matrix notation". Using brakets, if the matrix $$M$$ reads $$M=\sum_{ijkl}M_{ik;jl} \lvert i,j\rangle\!\langle k,l\rvert\equiv \sum_{ijkl}M_{ik;jl} \lvert i\rangle\!\langle k\rvert\otimes\lvert j\rangle\!\langle l\rvert,$$ then its partial transpose with respect to the second space is $$M^{T_B}= \sum_{ijkl}M_{ik;jl} \lvert i\rangle\!\langle k\rvert\otimes\lvert l\rangle\!\langle j\rvert.$$
Equivalently, the partial transpose $$M^{T_B}$$ is that matrix with components $$\big(M^{T_B}\big)_{ij;kl}=M_{ij;lk},$$ where again the first (second) pair of indices refers to the first (second) space.