Correlation function for 1d Heisenberg hamiltonian

+1 vote

Hey,
I am currently using ubuntu and I know python a little and was made a program for Eigenvalus and eigen function for 1d Heisenberg hamiltonian in python using numpy and sympy.
But now I want to make a program for spin correlation function for same hamiltonian.
Am not sure how to make in python.
I never used Julia before. What to do....
I already installed DMRGpy but this is not working some import error it showing.

+1 vote
answered by (64.6k points)

Hi, so I could see two answers to your question. Could you clarify which one you are interested in discussing further?

(1) if your question is about how to use DMRGpy (i.e. regarding the error you got), you should contact the maintainer or DMRGpy, Jose Lado. Another Python package for DMRG is TeNPy which you might want to try if you are staying with Python.

(2) if you are willing to learn Julia, which is not too hard to learn especially if you start from example codes for DMRG and correlation functions which we provide in the ITensor documentation, then you could certainly use ITensor to compute spin correlation functions of the Heisenberg model.

For the case of (2), please see the following examples of how to do (a) DMRG of the Heisenberg model and (b) compute a spin correlation function using the ITensor function called correlation_matrix