# Using DMRG to find ground state restricted to a subspace

Hello everyone,

I have a question about the limits and possibilities of the DMRG code in the iTensor Julia library. My ultimate goal is to implement a lattice gauge theory, specifically the Schwinger model. To make the implementation easier, I plan to map the system to a spin chain. Additionally, I only want to consider states that satisfy local constraints, so I will be working with a specific subspace of “physical states” within the entire Hilbert space. Let’s refer to the Hamiltonian of the system as H and the projector onto the physical subspace as P.

To achieve this, I constructed the MPO representation of the Hamiltonian using `OpSum`. I also manually built the MPO representation of the projector P. Now, my question is, how can I find the ground state of H while staying only in the physical subspace? To accomplish this, I obtained the MPO representation of the combined operator PH, which applies the Hamiltonian first and then projects onto the desired subspace. I passed this MPO of PH to the `dmrg` function in `iTensor.jl`.

This procedure works correctly for ground states with energy < 0. However, for ground states with positive energy, it does not work and instead produces a random MPS with energy = 0. This is because, if the ground state (restricted to the physical Hilbert space) has positive energy, the DMRG code will try to minimize the energy by moving the state out of the physical Hilbert space. The projector will then “destroy” the state, resulting in energy = 0. Therefore, for ground state energy > 0, DMRG will always move it into the “forbidden section” of the Hilbert space.

To prevent this, we need to ensure that DMRG does not leave the physical Hilbert space. When we leave the physical Hilbert space, the norm <ψ|ψ> of the state will be preserved, but the norm <ψP | Pψ> (including the projector) will not be preserved.

So my final question is: How can I tell DMRG to preserve this new norm <ψP | Pψ> instead of <ψ|ψ>, in order to stay inside the physical Hilbert space at all times?

Thanks in advance for your help, and apologies for the lengthy question.