Exited state with fixed QN

Hi, I’m trying to prepare an excited state that satisfies a certain quantum number at a flavour sector. Normally, I use conserve_qns=True with the hamiltonian

ampo = AutoMPO()
sites = siteinds("Fermion", nsites*nflavour*2; conserve_qns=True)
for isite in 1:2:nsites*nflavour*2
    q1::Int = isite
    q2::Int = isite + 1
    ampo .-= 0.5im / a, "cdag", q1, "c", q2
    ampo .+= 0.5im / a, "cdag", q2, "c", q1
    # + interaction + mass term etc
end
H = MPO(ampo, sites)

where the for loop is going over two nflavour sectors for a fermion. Using a reference state [0,1,0,1,0,1...], I can prepare ground state and the excited state (hadron state, for instance), where the total charge is zero.

psi1_init = randomMPS(sites, reference_state)
energy_h, psi_h = dmrg(H, [psi_gs], psi1_init; nsweeps, maxdim, cutoff, noise, weight, observer=obs)

which directly prepares the n-th excited state instead of the 1st by conserving the charge. But I want to prepare the excited state, which has charge 1 for one sector and zero for the other. I was thinking about changing the reference state to [1,1,0,1,0,1...], for instance, but since DMRG does not have the notion of flavour sectors, it will create a superposition of any such state, I believe. Is there a way to maybe modify the expectation loss with a Q operator that is acting on part of the lattice such that H’ = H + (Q_sector - 1)^2?

Thanks
Best regards

The good news is that this sort of operator tends to be low bond dimension if it is all to all. See the discussion for S^2 here: Total spin operator for Electron sites system

I found the OpSum system quite slow so I built a similar MPO by hand (ala Jan’s post Optimizing dmrg results for expected values of observables - #6 by JanReimers), but you may find better results with e.g. GitHub - ITensor/ITensorMPOConstruction.jl: Alternative backends for constructing MPOs from sums of operators.

On a separate note, I’m not sure how the old function names keep popping up since I think we’ve updated all of the docs and examples at this point, but AutoMPO is deprecated in favor of OpSum and randomMPS is deprecated in favor of random_mps.

1 Like