
Partial transpose of a tensor product expression
Source:R/047_atoms_affine_partial_transpose.R
partial_transpose.RdAssumes expr is a 2D square matrix representing a Kronecker product
of length(dims) subsystems. Returns the partial transpose with
the transpose applied to the subsystem at index axis (1-indexed).