# Implementing quantum number and symmetry

+1 vote

Hi Miles,

I am using itensor to run DMRG for Heisenberg chain with some long range Heisenberg interactions. Basically, I am using the first code sample on the itensor homepage. I can run up to about 28 spins without implementing any symmetry. However, there are strong finite size effect, so I would like to utilize total s^2 and momentum quantum number. I am having trouble using IQtensor properly. It would be very helpful if you can provide a simple example for DMRG using IQMPO and IQMPS. Thanks.

Sincerely,
Po-Hao

+1 vote

Hi Po-Hao,
The good news about using symmetries (conserving Abelian quantum numbers) with ITensor is that it usually requires minimal changes to your code. If you have a look at the iqdmrg sample code (the file sample/iqdmrg.cc) that is a good example of how to set up DMRG for a spin model which conserves Sz.

The way the initial total Sz value is set is through the initial state given to DMRG. The InitState object helps you with this; in the sample code the total Sz is zero, but you could flip one of the spins to access another sector. Let me know if you still have some questions after looking at that code.

Unfortunately we don't offer non-Abelian symmetries, so you can't use S^2 as a quantum number (this is much more technical to implement than Abelian quantum numbers). Momentum conservation is also tricky; as far as I know it's not really known how to conserve momentum with DMRG in 1d systems. For narrow 2d systems one can work in a momentum-space basis in the y-direction to conserve momentum that way. But working in a momentum-space basis in the x-direction would lead to a huge increase in entanglement and ruin much of the usefulness of DMRG. For infinite DMRG perhaps there is a clever way to implement momentum conservation but that would require further research (and would make a nice paper if one figured it out!).

Best,
Miles

commented by (130 points)
Thank you.
So if I want to know those quantum numbers for a few lower energy states, I should use the corresponding operators to obtain them.  Obtaining momentum quantum number seems to require a little work but it is still doable.
commented by (70.1k points)
Yes, that is correct. Of course for momentum you will need to have a translation invariant system for it to be well defined, so either infinite or periodic.