Partial transpose of a reduced density matrix of type ITensor

Hi,

I wish to ask for advice regarding the problem of partial transposing a reduced density matrix (RDM) when the latter is of ITensor type (and not an MPO). I ask this because I have used the approach described in Is this a correct way to calculate one-site and two-site entanglement spectrum and entropy? to obtain a n-site RDM as I found this approach (among others described in this forum and elsewhere - thanks to the OP of that thread) as the one that I could best imagine and work with (and it has benchmarked correctly with literature on a couple of canonical models), but the RDM thus constructed is of ITensor type as opposed to an MPO… As such, the approach suggested in partial transpose of MPO doesn’t work or at least I am unable to make it work.

I’ve tried a few things but to no avail - I’ve tried printing out the indices and using swapinds directly on the ITensor-typed-RDM but I get shown errors about the Indexes , I’ve also tried converting the ITensor-typed-RDM to first an MPS and then to MPO and then using what Matt suggested in the second link above, and a few related things like that.

I am sure there’s a silly mistake I am doing or a loophole in my thinking, so I would be grateful if someone could suggest me a correct way to partial transpose an Itensor-typed-RDM.

Thanks,
aditya

Hi aditya,

I would like to know if you have resolved this issue. Following the post Is this a correct way to calculate one-site and two-site entanglement spectrum and entropy? , I tried to do partial transpose about the site 5 with the codes,

## partial transpose
oldinds = inds(rho25)
newinds = [oldinds[1],oldinds[2],oldinds[4],oldinds[3]]
rho25T5 = swapinds(rho25,oldinds,newinds)
# the two 4-th order tensors have the same values, but different indices
@show rho25T5
@show rho25
D2, U2 = eigen(rho25T5)
egv2 = real(diag(D2))
@show egv2

Intuitively, I believe it may be correct. However, as I am new to Itensor.jl, my confidence is not high. If you identify any issues with this approach, I would appreciate your feedback.

Sincerely,
Fo-Hong

Hi Fo-Hong,

Yes this is how I eventually did it too. Turns out it was this easy (I thought I’d deleted this post, apparently not).