TF Ising Magnetization issues

How do I use this algorithm? What does that parameter do?
Post Reply
Qottmann
Posts: 18
Joined: 27 Mar 2019, 09:11
Location: Barcelona

TF Ising Magnetization issues

Post by Qottmann »

Hello,

I am trying to reproduce the phase diagram of the transverse field Ising Model on a 1d chain. I essentially use the example code in d_examples_dmrg.

Code: Select all

from tenpy.networks.mps import MPS
from tenpy.models.tf_ising import TFIChain
from tenpy.algorithms import dmrg

def DMRG_finite(L, g,verbose=False,chi_max = 30):
    model_params = dict(L=L, J=1., g=g, bc_MPS='finite', conserve=None, verbose=0)
    M = TFIChain(model_params)
    psi = MPS.from_product_state(M.lat.mps_sites(), [0] * L, bc='finite')
    dmrg_params = {
        'mixer': None,
        'trunc_params': {
            'chi_max': chi_max,
            'svd_min': 1.e-10
        },
        'lanczos_params' : {"reortho" : True},
        'max_E_err': 1.e-10,
        'verbose': verbose
    }
    dmrg.run(psi, M, dmrg_params)
    E = np.sum(psi.expectation_value(M.H_bond[1:]))
    return E, psi
I added the reortho flag because I was getting the Lanczos poorly conditioned error (although it does not affect my problem below)
I calculate magnetization via

Code: Select all

def magX(psi):
    return np.sum(psi.expectation_value("Sigmax"))/psi.L
(similarly for s_y)

but cannot reproduce the phase diagram. Especially the magnetiazion is essentially 0 everywhere:
Image
(y is magnetization as calculated above, so summed site expectation values divided by length, x is g from 0 to 1.5)

What am I missing?


On another matter: So far I have been using simply the toycode that is provided in the library (toycodes/a_MPS,b_model,d_dmrg). When trying to reproduce the phase diagram there, I find that it actually looks better for smaller bond dimension, which seems counterintuitive to me. See the following examples:
Image
Image
Image
(eps is my threshold from which onwards singular values are neglected. conf is the relative confidence I am trying to achieve in energy convergence. i.e. the sweeping condition is e_before - e_after/ e_after < conf. From looking at the history throughout my sweeps I am fairly convinced it converged in energy.)

This "unsmooth breakdown" can be shifted towards the true critical point (g=1) by increasing the number of sites L. But when trying to do finite size scaling it doesnt look like what is expected, namely, that all curves meet in one point, which should be the true critical point. So what is going wrong here? I dont think it is a convergence problem, at least further sweeping at the points of m=0 but g<1 it doesnt help, i.e. "grow" further magnetiation via sweeping. I also tried with other initial states, i.e. the all zero and all plus product states. The results are essentially the same except for that the magnetization also becomes negative when starting from the zero state.

Help or input of any sort would be much appreciated!
Also thanks for this awesome library!

Best regards,
Korbinian
User avatar
Johannes
Site Admin
Posts: 413
Joined: 21 Jul 2018, 12:52
Location: TU Munich

Re: TF Ising Magnetization issues

Post by Johannes »

Short answer: Try measuring correlation functions, or expectation values of \(|M|\) or \(M^2\) instead of \(M=\sum_i X_i\) ;)

Reason: You try to observe spontaneous symmetry breaking.
By definition, spontaneous symmetry meaking means that you have a degenerate ground state (in the thermodynamic limit): the state with magnetization in positive X direction has the same energy as the one with magnetization in negative X direction (if you consider \( H = X_i X_{i+1} + Z_i\)).
For finite `L`, there is a finite size gap such that the true ground state is a superposition of the positive and negative X.
For large enough L and sufficiently small `chi_max`, DMRG tends to choose one of the two superpositions, because keeping the superposition leads to stronger truncation. (For most models apart from the transverse field ising model, the truncation is strong enough even for large chi_max ~ 1000.)
Qottmann
Posts: 18
Joined: 27 Mar 2019, 09:11
Location: Barcelona

Re: TF Ising Magnetization issues

Post by Qottmann »

Thanks for your quick response!
Johannes wrote: 28 Mar 2019, 11:07 For finite `L`, there is a finite size gap such that the true ground state is a superposition of the positive and negative X.
Okay, so far so good. But I think I miss the point why I would then compute e.g. \(M^2 = <\left(\sum_i s_x^i\right)^2>\). Or to phrase it differently what that would tell me? I have heard this before and actually tested it, it indeed looks nice but \(M^2\) is not the order parameter I am interested in, \(M = <\sum_i s_x^i>\) is?
I also just tested for \(\sum_i |<s_x^i>|\) but it seems the single site magnetizations are truely 0 and do not just cancel each other (if that is what you meant?).

Johannes wrote: 28 Mar 2019, 11:07 For large enough L and sufficiently small `chi_max`, DMRG tends to choose one of the two superpositions, because keeping the superposition leads to stronger truncation. (For most models apart from the transverse field ising model, the truncation is strong enough even for large chi_max ~ 1000.)
Sorry I am not sure if I understand what you are saying: for small \(\chi_{max}\), DMRG keeps the superposition, which is bad? But what I am witnessing above is the opposite, no?
Post Reply