The ALPS ProjectOpen Source Software forStrongly Correlated Systems

Matthias Troyer, ETH Zürich

for the ALPS co!aboration
Overview and Introduction
Data formats
Future plans

The ALPS collaboration
ETH Zürich, Switzerland• Philippe Corboz• Emanuel Gull
• Munehisa Matsumoto• Lode Pollet• Matthias Troyer
IRRMA Lausanne, Switzerland• Andreas Läuchli
RWTH Aachen, Germany• Ulrich Schollwöck• Ian McCulloch
Universität Marburg, Germany• Reinhard Noack• Salvatore Manmana
Universität Göttingen, Germany• Andreas Honecker• Thomas Pruschke

Universität Stuttgart, Germany• Stefan Wessel
Université de Toulouse, France• Fabien Alet
TU Graz, Austria• Franz Michel
UC Santa Barbara, USA• Adrian Feiguin• Simon Trebst
Columbia University, USA• Philipp Werner
Honk Kong University, China• Siegfried Gürtler
University of Tokyo, Japan• Ryo Igarashi• Synge Todo

The ALPS project
Algorithms and Libraries for Physics Simulations• open source data formats,libraries and simulation codesfor quantum lattice models• download codes from website
http://alps.comp-phys.org

Simulation codes ofquantum lattice models• The status quo• individual codes• model-speciﬁc implementations• growing complexity of methods• ALPS• community codes• generic implementations• simpliﬁed code development• common ﬁle formats

Key Technologies
Generic Programming in C++• ﬂexibility• high-performanceStandard C++ Libraries• fast development
XML / XSLT for Input/Output• portability• self-explanatory
MPI/OpenMP for Parallelization

Three tiers of ALPS
1. Standard data formats and interfaces to facilitate• exchange, archiving and querying of simulation results• exchange of simulation and analysis tools
2. Libraries• to support standard data formats and interfaces• to ease building of parallel simulation programs
3. Applications• to be used also by non-experts• implement modern algorithms for a large class of models

The ALPS project
Algorithms and Libraries for Physics Simulations• The simulation codes include• Classical and Quantum Monte Carlo (path integrals, SSE)
• Exact and Full Diagonalization• Density Matrix Renormalization Group (DMRG)• Motivation• established algorithms• increased demand for reliable simulations from theorists andexperimentalists

Simulations with ALPS
Lattice

Model

Parameters<LATTICEGRAPH name = "square lattice"><FINITELATTICE><LATTICE dimension="2"/><EXTENT dimension="1" size="L"/><EXTENT dimension="2" size="L"/><BOUNDARY type="periodic"/></FINITELATTICE><UNITCELL>...
</UNITCELL></LATTICEGRAPH><BASIS><SITEBASIS name="spin"><PARAMETER name="S" default="1/2"/><QUANTUMNUMBER name="Sz" min="-S" max="S"/></SITEBASIS></BASIS>LATTICE = “square lattice”
L = 100<HAMILTONIAN name="spin"><BASIS ref="spin"/><SITETERM> -h*Sz </SITETERM><BONDTERM source="i" target="j”>
Jxy/2*(Splus(i)*Sminus(j)+Sminus(i)*Splus(j))+ Jz*Sz(i)*Sz(j)</BONDTERM></HAMILTONIAN>

MODEL = “spin”
Jxy = 1
Jz = 1h= 0{ T = 0.1 }{ T = 0.2 }{ T = 0.5 }{ T = 1.0 }quantum system

Quantum Monte Carlo

Exact diagonalization

Results

DMRG

The ALPS lattice library
A lattice<LATTICEGRAPH name = "square lattice"><FINITELATTICE><LATTICE dimension="2"/><EXTENT dimension="1" size="L"/><EXTENT dimension="2" size="L"/><BOUNDARY type="periodic"/></FINITELATTICE><UNITCELL><VERTEX/><EDGE type=“1”><SOURCE vertex="1" offset="0 0"/><TARGET vertex="1" offset="0 1"/></EDGE><EDGE type=“2”><SOURCE vertex="1" offset="0 0"/><TARGET vertex="1" offset="1 0"/></EDGE></UNITCELL></LATTICEGRAPH>

The ALPS model library
A modelH XXZ =

J xz
(Si+ S −j + Si− S +j ) + J z ∑ Siz S zj − h ∑ S1z∑
2 i, ji, ji<BASIS><SITEBASIS name="spin"><PARAMETER name="S" default="1/2"/><QUANTUMNUMBER name="Sz" min="-S" max="S"/></SITEBASIS></BASIS><OPERATOR name="Splus" matrixelement="sqrt(S*(S+1)-Sz*(Sz+1))"><CHANGE quantumnumber="Sz" change="1"/></OPERATOR><OPERATOR name="Sminus" matrixelement="sqrt(S*(S+1)-Sz*(Sz-1))"><CHANGE quantumnumber="Sz" change="-1"/></OPERATOR><OPERATOR name="Sz" matrixelement="Sz"/><HAMILTONIAN name="spin"><BASIS ref="spin"/><SITETERM> -h*Sz </SITETERM><BONDTERM source="i" target="j”>
Jxy/2*(Splus(i)*Sminus(j)+Sminus(i)*Splus(j))+ Jz*Sz(i)*Sz(j)</BONDTERM></HAMILTONIAN>

Current applications• Classical Monte Carlo• local and cluster updates for classical spin systems, M. Troyer• Quantum Monte Carlo• stochastic series expansions (SSE), F. Alet, L. Pollet, M. Troyer• loop code for spin systems, S. Todo
• continuous time worm code, S. Trebst, M. Troyer• extended ensemble simulations, S. Wessel, N. Stoop• Exact diagonalization• full and sparse, A. Honecker, A. Läuchli, M. Troyer• DMRG• single particle, S. Manmana, R. Noack, U. Schollwöck• interacting particles, A. Feiguin

Some applications of ALPS codes• Experimental data ﬁtting• Low-dimensional quantum magnets• Single molecule magnets• Ultracold bosonic atoms in optical traps• Theoretical predictions• How to cool fermionic atoms in optical lattices well below TF ?

Quantum spin laddersχ (10−5 cm 3/mol Cu)

12
SrCu2O3

10

J/kB = 1904 K
8

J'/kB = 929 K

64experiment2

simulation

0

0

200

400
T (K)

➡ compare microscopic models to experiments

600

Mn-84 molecules
Vassilis Tangoulis, in preparation• How can we microscopically model interactions in Mn-84?

ALPS QMC codes
Numerical evaluation of susceptibility for full molecule:Fit of magnetic interaction strength.

WOODWARD, ALBRECHT, WYNN, LANDEE, AND TURNBULL

FIG. 2. View down c axis of (5CAP) 2 CuBr4 showing two adjacent C-centered CuBr2#
4 planes in their eclipsed configuration.

(5MAP) 2 CuBr4 are a!13.715(2) Å, b!8.7162!2" Å, c
!16.013(4) Å, and # !93.79(2)°, reflecting its slightly
larger unit cell. The intraplanar Br•••Br distance is 4.54 Å,which is significantly longer than the corresponding value in(5CAP) 2 CuBr4 of 4.35 Å. The separation between the layers
is also significantly enhanced due to the bulk of the methyl
substituent resulting in a separation of 4.97 Å.

that marked as filled boxes were collected at H!1.0 T. The vertical line in the inset marks the ordering temperature of 5.08 K as
determined by specific-heat measurements !Ref. 11".

have been compared to the theoretical predictions and simulation for the susceptibility of the 2D QHAF !described inSec. IV". The dashed line shown in Fig. 4 represents a curve
fit to the data resulting in an exchange interaction strength
J!8.5(2) K and g a v e !2.11(2). This value of g a v e is ingood agreement with powder and single-crystal roomtemperature EPR measurements. The magnetic-susceptibility
fitting procedure included only data at temperatures greaterthan 5.2 K, since the specific-heat studies11 of(5CAP) 2 CuBr4 show the existence of an ordering transition
at T N !5.08 K. The dashed line shows the model expression
for the ideal 2D QHAF with the same parameters extended
down to T!0. The low-field powder susceptibility shows no
anomaly at the ordering transition, but does break away fromthe model curve at a temperature very close to T N . The datacollected in a field above the spin-flop transition !Sec. IIII E
below", shows a much stronger deviation from the model
curve at T N .
The data for (5MAP) 2 CuBr4 are shown in Fig. 5. The
susceptibility of (5MAP) 2 CuBr4 is qualitatively identical tothat of (5CAP) 2 CuBr4 , with a slightly lower temperature forthe maximum susceptibility (%6 K). Comparison of thesedata to the model curve yields an interaction strength of J
!6.5(2) K and g a v e !2.07(2).

Low-dimensional quantum magnets
C.P. Landee et al., Phys. Rev. B 65, 144412 (2002)

B. Powder susceptibility• How to characterize newly synthesized materials?
The molar magnetic susceptibility ( $ m ) as a function oftemperature for a powder of (5CAP) 2 CuBr4 is shown in Fig.
4. A broad maximum is observed with the maximum value in$ m (18.3"10#3 cm3 /mol) occurring near 8.0 K. The data

C. High-field magnetization

FIG. 3. View down the a axis of (5CAP) 2 CuBr4 showing thecross section of the planes and the orientation of the organic groups.
The dashed lines mark the two sets of interplanar Br•••Br contacts
which cause the interplanar exchange J ! .

The magnetizations as a function of field at T!1.3 K for(5CAP) 2 CuBr4 and (5MAP) 2 CuBr4 are shown in Fig. 6!a"plotted on a normalized scale M /M sat where M sat were determined to be 5980 and 5880 emu/mol, respectively. To ourknowledge, this is the first report of the full magnetization
curve for any 2D QHAF. !A preliminary report has appeared
elsewhere.12" Note the upward curvature present in both data
sets. The saturation fields appear to be close to 19 T and 24
T, respectively. Although these estimates are crude, we do
FIG. 8. Single-crystal % /C versus temperature at H!0.2 T. !a"note that the ratio of saturation fields !19 T/24 T ! 0.79" is(5CAP)
CuBr4 , !b"(5MAP)
quite close to theratio of2exchange
strengths
as determined
2 CuBr4 . %! : filled boxes, H applied "by the susceptibility
data
!6.8
K/8.5
K
!
0.80".
to b, triangles, H applied " to c, % " : filled circles, H applied " to a,

ALPS QMC
codes
and %
: crosses, H!0.1 T. Solid line represents 2D QHAF
model.
Numerical evaluation of susceptibility
for 2D QHAF:
paramagnetic contributions.
Note that the data in Figs. 8!a"Fit of magnetic interaction
strength.
and 8!b" have been scaled by the Curie constant for a spin144412-4

pow

1
2

system, C!0.375(g/2) 2 , where the g value is g a , g b !g c ,

(5
an
ap
c.

fo
pl

BEC in ultracold atomic gases• Ultracold 87Rb atoms form a
Bose-Einstein condensate (BEC).

• ﬁrst observed in 1995
• sympathetic cooling offermionic 40K atoms (2004)• Standing laser waves form
an optical lattice.

T. Esslinger, ETH Zürich

Realization of the Bose-Hubbard model
S. Wessel et al., Phys. Rev. A 70, 053615 (2004)
O. Gygi et al., Phys. Rev. A 73, 063606 (2006)

#
!
!
!
!" †
ni (ni − 1)/2 − µni + Vri2 niH = −tbi bj + h.c. + U
!ij"

i

i

i

local density

suprafluid
coherent BEC

Mott-isolator
incoherent

ALPS QMC codes
Numerical simulation of experimental setup:602 sites and harmonic trapping potential

Ultracold fermionic atoms
S. Trebst et al., Phys. Rev. Lett. 96, 250402 (2006)• How can we cool down fermions to some 0.01 TF ?

adiabatic process

RVB state

ALPS exact diagonalization codes
Excitation spectra of intermediate states.
Time-evolution of proposed adiabatic processes.

Data Formats
XML
HDF-5

Three tiers of ALPS
1. Standard data formats and interfaces to facilitate• exchange, archiving and querying of simulation results• exchange of simulation and analysis tools
2. Libraries• to support standard data formats and interfaces• to ease building of parallel simulation programs
3. Applications• to be used also by non-experts• implement modern algorithms for a large class of models

Common data formats• are the most important part of the ALPS project• Standard formats allow• uniform interface to all codes• exchange of simulation results• ﬁghting data rot (ﬁles can still be understood after many years)• sharing analysis tools• archiving of raw data

Evaluating Monte Carlo data

• Reliable Monte carlo simulations need careful data analysis• equilibration eﬀects• autocorrelation eﬀects (binning analysis)• crosscorrelation eﬀects (jackknife or bootstrap method)• Common formats encourage development and sharing of
good and ﬂexible analysis tools

Archiving Monte Carlo data
• We want the raw Monte Carlo data (time series) to beavailable and accessible even after the PhD student
ﬁnishes his thesis and leaves• Standard data formats will simplify• Archiving of results with data rot in archive server• Easy searching and retrieval• Publication of results with papers, as auxiliary electronic material

Validating applications• Careful and systematic validation simulation programs is
an often overlooked problem (Laughlin, Kadanoﬀ)• Set up a suite of benchmark problems with veriﬁed results• use it manually in debugging phase of your own program• use it automated to run regular validation and regression testing
when

•
•
•

porting to new compilers
porting to new machineschanging library or operating system versions

Monte Carlo data format
standards workshop• Zürich, September 11, 2006
• Agenda• collect experiences• deﬁne standard formats• discuss evaluation and archiving• Conﬁrmed participants:• F.F. Assaad, A. Läuchli, B. Bernu, D. Ceperley, J.N. Kim, D.P.
Landau, T. Schulthess, M. Troyer, S. Wessel, ...

• Your participation is welcome: http://xml.comp-phys.org

New Features
Integration with band structure codes
Dynamical Mean Field Theory framework
Release plansAb-initio simulations ofquantum magnets• Simulate realistic magnetic models instead of toy models• obtain microscopic exchange constants from LDA+U• simulate quantum spin models using these exchange constants• Was done by hand in the past
• CaV2O3, MgV2O3, CaV3O7, CaV4O9• Korotin, Elﬁmov, Anisimov, Troyer and Khomskii, PRL ’99• Can we automate this?

ALPS Interface toband structure codes• ORNL is developing standard XML I/O data formats andhelper libraries for band structure codes• Implementation in Stuttgart TB-LMTO-ASA band
structure code by Anton Kozhevnikov (Ekaterinburg)• Simple helper tool by Anton Kozhevniko creates ALPS
input ﬁle (lattice structure, model Hamiltonian) fromXML output of LDA+U code

• Automated workﬂow from crystal structure to magnetic
properties

Example: SrCu2O3
SrCu O2

0.0001

3

Experiment
LDA+U+ALPS

χ [emu / mol]

8 10-5

6 10-5

4 10-5

2 10-5

0
0

100

200

300

T [K]

400

500

600

Dynamical Mean Field Theory• E. Müller-Hartmann, Z. Phys. B 74 507 (1989).
M. Metzner and D. Vollhard, PRL 62, 324 (1989).
A. Georges and G. Kotliar Phys. Rev. B 45, 6479 (1992).
A. Georges et al., Rev. Mod. Phys. 68, 13 (1996).
T. Maier et al., Rev. Mod. Phys. 77, 1027 (2005).

• is an approximative but successful method for describing
strongly interacting fermions in high dimensions• solves a few - site problem in the presence of a selfconsistent bath provided by the rest of the system

DMFT self-consistency loop
Fourier Transform

ω
(i

G

G

(τ
)

DMFT
Selfconsistency
Loop

SolverHilbert Transform

G

0(

iω

)

)
(τ
G0

Noninteracting
Density of States:
Theory, LDA, ...

Maximum Entropy
Method)Fourier TransformInteracting Densityof States

ALPS DMFT framework• Provides a modular system for solving the DMFT equations• Fourier transforms• Hilbert transforms• Impurity solvers• plug-in based:• can use ALPS components• or user - provided external components written in any language• work in progress on establishing standard data formats• workshop November 2006 in Göttingen, Germany

ALPS DMFT QMC solvers• So far we have implemented three QMC solvers• Hirsch-Fye algorithm (Hirsch, J. E., and R. M. Fye, PRL ‘86)
• Rubtsov et al. continuous time expansion in U (PRB ‘05)
• Werner et al. continuous time expansion in t (PRL, in press)• Performed accuracy tests and performance comparisons• Gull et al, in preparation• see talk by Philipp Werner at the workshop

Solver Comparison• close to Mott transition: Werner et al. solver is• 106 times faster than Hirsch-Fye• 103 times faster then Rubtsov et al. solver
Matrix Sizes
U/t = 4.0, Bethe Lattice

Rubtsov Algorithm
Werner Algorithm
Hirsch Fye, Assaad

Matrix Size

150

100

50

0

0

10

20

30

40
!t

50

60

70

Release plans• Release 1.3, fall 2006
• Translation symmetry in diagonalizaton codes• Custom measurements of static quantities• new application: DMRG

• Release 1.4, summer 2007
• multi-site terms in Hamiltonian and measurements• measurement of dynamic quantities• GUI for lattice construction• support for Cray XT3 and IBM BlueGene/L

Plans for ALPS 2.0• New applications• Full integration of DMFT
• Continuum QMC• New features• Full support for point group symmetries• Interface with band structure codes• Application validation benchmarks• Archiving server• Support for Windows• Scripting using Python

Conclusions• Open source codes for strongly correlated systems
intended for non-experts: what do you need?

• Setting standard for data formats to enable• common input formats• sharing of results• sharing of evaluation tools• archiving of results• validating simulation programs• workshop: Sept. 11, 2006 in Zürich
http://alps.comp-phys.org

Join the ALPS collaboration
ETH Zürich, Switzerland• Philippe Corboz• Emanuel Gull
• Munehisa Matsumoto• Lode Pollet• Matthias Troyer
IRRMA Lausanne, Switzerland• Andreas Läuchli
RWTH Aachen, Germany• Ulrich Schollwöck• Ian McCulloch
Universität Marburg, Germany• Reinhard Noack• Salvatore Manmana
Universität Göttingen, Germany• Andreas Honecker• Thomas Pruschke

Universität Stuttgart, Germany• Stefan Wessel
Université de Toulouse, France• Fabien Alet
TU Graz, Austria• Franz Michel
UC Santa Barbara, USA• Adrian Feiguin• Simon Trebst
Columbia University, USA• Philipp Werner
Honk Kong University, China• Siegfried Gürtler
University of Tokyo, Japan• Ryo Igarashi• Synge Todo