ALPS is a numerical simulation library where numerical methods are implemented such as density matrix renormalization group (DMRG), exact diagonalization (ED), and quantum Monte Carlo (QMC). The extensive tutorials make it relatively easy for those who have not been involved in these techniques.
Here, by using MaterialApps LIVE! (MAL), we introduce the application of the DMRG to the Spin 1/2 Heisenberg model on the square lattice. MAL is a Live Linux system containing a variety of apps for condensed matter physics. With MAL, you can try out ALPS without its installation. The MAL Wiki provides detailed usage information. The version of MAL we used is ver. 2.0.
How to use
Let’s run ALPS on MAL. First, start LXTerminal from the System tools, create and move into the sample directory under the HOME directory.
$ mkdir alps_dmrg $ cd alps_dmrg
Next, you download a Python script “heisenberg2D_dmrg.py” to run the following command on the test directory “alps_dmrg”.
$ wget https://ma.issp.u-tokyo.ac.jp/wp-content/uploads/sites/3/2019/07/heisenberg2D_dmrg.py
This script is based on tutorial8a.py from the tutorial site. Therefore, refer to the tutorial site for a description of the script. Finally, execute the following command to perform the DMRG simulations defined in “heisenberg2D_dmrg.py”.
$ python heisenberg2D_dmrg.py > log
I think this process will finish in about a few minutes.
Running the script above prints the DMRG result in log. On the command line, execute
$ tail log
and then, we’ll see the output as follows:
Finished with everything.
dmrg parm_spin_one_half_heisenbergSquare.in.xml –write-xml
MAXSTATES: 50.0 Energy : -11.1759358521
MAXSTATES: 50.0 Truncation error : 0.0012853192745
MAXSTATES: 100.0 Energy : -11.2199404374
MAXSTATES: 100.0 Truncation error : 0.000698022447203
MAXSTATES: 150.0 Energy : -11.2284831995
MAXSTATES: 150.0 Truncation error : 0.000323024915189
MAXSTATES: 200.0 Energy : -11.2284832024
MAXSTATES: 200.0 Truncation error : 9.02230444447e-05
The exact energy is -11.2284832084, which is obtained by using ED in ALPS. By increasing “MAXSTATES”, the maximum number of states in sweeping process, ”Truncation error” becomes smaller, and the DMRG energy converges to the exact one.
An example of DMRG calculation using ALPS was introduced here. For QMC and ED calculations and other DMRG examples, see the ALPS tutorial site or other reviews on MateriApps site.