How i calculate overlap of two states with different type of quantum numbers?

Hi !
Recent, I would like to perform overlap of the two states.
The two states are Ground states from the different models (MPO) and quantum number types.

For example, one of the MPS has quantum numbers Sz and number of Fermion. The other MPS has quantum numbers Sz and parity of Fermion.
Mathematically, which is <Sz, Nf | Sz, P>

How can i do it?

The simplest strategy for this would be to convert each MPS to “dense” mode i.e. so that all the tensors are now just dense tensors and the quantum number information is removed.

dpsi1 = dense(psi1)
dpsi2 = dense(psi2)
@show inner(psi1,psi2)

An important detail here is that I imagine you must have used distinct site indices to calculate each MPS, since in ITensor the site indices carry the quantum numbers. So after you call dense on both of your MPS, you do the following steps:

  1. call siteinds again to make a new collection of site indices, but with conserve_qns=false (or just leave out the conserve_qns keyword argument since it defaults to false)
  2. for each MPS psi, call psi = replace_siteinds(psi,new_sites) where new_sites is your new site index array

After doing these steps and calling replace_siteinds on each of your MPS (after first converting them to dense) you can safely take their overlap.

1 Like