Algorithm keeping more states than physically allowed in svd?

+1 vote
asked May 9, 2016 by emkajot (170 points)
edited May 9, 2016 by emkajot

I'm running a spin chain simulations for tests, open boundary conditions. The dimension of local Hilbert space is N. On the "backwards" part of the sweep, it seems like the algorithm is keeping many more states than physically (or by Schmidt decomposition theorem, allowed).
For instance, for N=3, it claims to keep 69 states on bond (1,2), whereas the left part of the Hilbert space, consisting of a single spin, has dimension 3 only. This does not happen on the "forward" part of the sweep, where 3 states are kept.

Is this departure from the optimal Schmidt number of states correct?

Is this perhaps the effect of the noise term?

commented May 9, 2016 by miles (16,920 points)
Hi, thanks for the report. If this is really happening (or if the printout is incorrectly reporting the number of states) then either way it would definitely be a bug.

Could you please post some more information, such as:
* A few lines of the printout that reported keeping 69 states
* What cutoff and maxm values you had set for this sweep
commented May 10, 2016 by emkajot (170 points)
Hi,
Here is a bit of an output, the last few bonds of sweep no.5 and the same bonds on the beginning of sweep no.6.

Sweep=5, HS=2, Bond=(2,3)
I 0 q 1E-06 E -6.0000000000
I 1 q 7E-07 E -6.0000000000
    Truncated to Cutoff=1.0E-14, Min_m=20, Max_m=400
    Trunc. err=0.0E+00, States kept=m=81
Sweep=5, HS=2, Bond=(1,2)
I 0 q 7E-07 E -6.0000000000
I 1 q 6E-07 E -6.0000000000
    Truncated to Cutoff=1.0E-14, Min_m=20, Max_m=400
    Trunc. err=5.2E-17, States kept=m=69
    Largest m during sweep 5 was 81
    Largest truncation error: 5.1704e-16
    Energy after sweep 5 is -6.000000000000
Sweep=6, HS=1, Bond=(1,2)
I 0 q 6E-07 E -6.0000000000
I 1 q 3E-07 E -6.0000000000
    Truncated to Cutoff=1.0E-14, Min_m=20, Max_m=400
    Trunc. err=0.0E+00, States kept=m=3
Sweep=6, HS=1, Bond=(2,3)
I 0 q 3E-07 E -6.0000000000
I 1 q 3E-07 E -6.0000000000
    Truncated to Cutoff=1.0E-14, Min_m=20, Max_m=400
    Trunc. err=0.0E+00, States kept=m=9


This keeping of too many states on the "backwards" run seems to disappear in the last sweep, when the noise term is put to zero, btw.
commented May 11, 2016 by miles (16,920 points)
Ok thanks - I was able to reproduce this issue on my computer and it is indeed weird behavior! I am looking into it; hopefully it will be something small and harmless but thanks for this helpful bug report. When I find the fix I will post an answer below.

1 Answer

0 votes
answered May 13, 2016 by miles (16,920 points)

Hi Maciek,
So I looked a little closer and this is actually not a bug, but the intended behavior, basically.

The reason is that the density matrix diagonalized for the last bond as you are sweeping left is the density matrix for the right side of the system. So it is a matrix whose size is much bigger than the maximum number of non-zero eigenvalues possible when it is formed from a wavefunction. Since it does come from an actual wavefunction it will just have a lot of zero eigenvalues.

However, the noise term step makes a somewhat ad-hoc change to the density matrix that makes it slightly "unphysical" in the narrow sense of possibly having more non-zero eigenvalues than could be possible for any such density matrix coming from a wavefunction.

But this is ok because keeping a few more states in the MPS can't really hurt. The MPS can just use the ones it needs and ignore the ones it doesn't.

However, I will think more about whether maybe we could and should put in a check to strictly limit the number of states to the theoretical limit when truncating.

Thanks for pointing this out though - it is a little surprising at first!

Welcome to ITensor Support Q&A, where you can ask questions and receive answers from other members of the community.

Formatting Tips:
  • To format code, indent by four spaces
  • To format inline LaTeX, surround it by @@ on both sides
  • To format LaTeX on its own line, surround it by $$ above and below
  • For LaTeX, it may be necessary to backslash-escape underscore characters to obtain proper formatting. So for example writing \sum\_i to represent a sum over i.
If you cannot register due to firewall issues (e.g. you cannot see the capcha box) please email Miles Stoudenmire to ask for an account.

To report ITensor bugs, please use the issue tracker.
...