HU-EP-13/69 SFB/CPP-13-98 DESY 13-225 Applicability of Quasi-Monte Carlo for lattice systems arxiv:1311.4726v1 [hep-lat] 19 ov 2013, a,b Tobias Hartung, c Karl Jansen, b Hernan Leovey, Anreas Griewank an Michael Müller-Preussker a a Humbolt-University Berlin, Department of Physics Unter en Linen 6, D-10099 Berlin, Germany b IC, DESY Zeuthen Platanenallee 6, D-15738 Zeuthen, Germany c King s College Lonon, Department of Mathematics Stran, Lonon WC2R 2LS, Unite Kingom Humbolt-University Berlin, Department of Mathematics Unter en Linen 6, D-10099 Berlin, Germany E-mail: Anreas.Ammon@esy.e, tobias.hartung@kcl.ac.uk, Karl.Jansen@esy.e, leovey@math.hu-berlin.e, griewank@math.hu-berlin.e, mmp@physik.hu-berlin.e This project investigates the applicability of quasi-monte Carlo methos to Eucliean lattice systems in orer to improve the asymptotic error scaling of observables for such theories. The error of an observable calculate by averaging over ranom observations generate from orinary Monte Carlo simulations scales like 1/2, where is the number of observations. By means of quasi- Monte Carlo methos it is possible to improve this scaling for certain problems to 1, or even further if the problems are regular enough. We aapte an applie this approach to simple systems like the quantum harmonic an anharmonic oscillator an verifie an improve error scaling of all investigate observables in both cases. 31st International Symposium on Lattice Fiel Theory - LATTICE 2013 July 29 - August 3, 2013 Mainz, Germany Speaker. c Copyright owne by the author(s) uner the terms of the Creative Commons Attribution-onCommercial-ShareAlike Licence. http://pos.sissa.it/
1. Motivation The quasi-monte Carlo (QMC) metho an their ranomizations (RQMC) are highly interesting for the omain of lattice fiel theory. It offers the possibility to improve tremenously the asymptotic error scaling of observables obtaine from Monte Carlo (MC) simulations of lattice path integrals. Substantial reuctions in computing time coul be achieve if the QMC approach coul eventually be applie to lattice-qcd (quantum chromoynamics in its lattice regularize form). A mathematical review of the QMC approach can be foun in [1]. The major part of this contribution is base on our paper [2] (cf. also [3]). The reaer intereste in more etails is referre to this reference at any point of the following iscussion. In orer to better unerstan the point where the QMC approach sets in with its improvement, we want to outline the typical workflow uring the treatment of a general lattice problem with conventional methos. Such a lattice system might be escribe by the partition function Z = Dx e S[x] given the action S. An observable O coul be calculate by O = Z 1 Dx e S[x] O[x]. Dx stans for the path integral measure of all ynamic fiels relevant to the moel uner consieration. This coul be for example the gauge fiel measure for lattice gauge theories or simply a particle path measure for quantum mechanical problems. It is originate in the high imensionality of the lattice path integral that it can naturally only be treate by means of MC methos, provie that analytic solutions are missing. Within the variety of MC approaches the Markov chain-monte Carlo (Mc-MC) approach turns out to be the most efficient, as it allows for importance sampling. During a Mc-MC simulation a number of fiel configurations (x i ) i=1... is generate successively, each of them base on its preecessor an istribute (after the thermalization) accoring to the Boltzmann weight. Then for each sample x i the observable O is measure, leaing to samples O i. Often, these samples are istribute normal, at least to a goo approximation in most cases. Then, the asymptotic error of the mean Ō = 1 i=1 O i scales like 1 2. A fixe-factor increase of the error often arises from correlations between successive observations O i, which originates in the nature of Mc-MC methos. Both features, the crue asymptotic error scaling an the possibly strong auto-correlation, lea to a necessity to generate a large amount of samples to reach a given error level. In many cases it is even impossible to reach the target accuracy ue to the lack of sufficient computing resources. The QMC approach provies the potential to circumvent the aforementione problems, as it exhibits certain favorable properties. Most importantly, it is able to improve the error scaling to 1, given that certain conitions are met (see [2]). It is further encouraging to realize that the QMC technique has alreay been applie successfully in other fiels like financial mathematics [4] for example. But before coming to specific emonstrations of this fascinating approach, we want to take a closer look to a prominent feature of QMC samples. 2. Quasi-Monte Carlo point sets are more uniform Most point sets constructe through QMC techniques fulfill a so-calle low-iscrepancy property (see [2], sections 3 an 4) also referre to uniformity or more uniform (than conventional Monte Carlo point sets). This property can be illustrate through a simple example in two imensions, but whose results can be generalize to arbitrary many imensions. For this experiment the unit square [0,1] [0,1], subivie into 8 8 small squares of equal size, shoul be consiere. ow, 512 points are generate pseuo-ranomly 1 an uniformly in this unit square. Then, for each of the 8 8 = 64 little squares the number of containe points are counte. An example of the outcome of such an experiment is shown in the upper iagram of figure 1. 1 We use the Mersenne Twister pseuo ranom number generator [5]. 2
Pseuo ranom 2 point set Histogram of counts count frequency 4 6 8 10 12 14 0 2 4 6 8 10 8 Figure 1: The pseuo-ranom sampling of 512 points in a unit square (upper plot). For each little square the number of containing points is counte an inicate through a colour coe. The meaning of each color coe can be seen from the lower iagram, where a histogram of the counts is shown. The color of each square correspons to the number of points it contains. In the lower part of this figure we have plotte a histogram of the counts. We can clearly see that the istribution of counts is rather broa. This means in practice that many squares contain significantly more or less samples than one woul expect on average, namely 8. If this set of points (x i,y i ) i=1...512 woul be use for a Monte Carlo approximation of a two-imensional integral 1 0 1 0 f (x,y)xy 1 512 512 i=1 f (x i,y i ) function values in squares with very many or very few points contribute too much or too less respectively to the overall average. This can be seen as a possibly avoiable source of extraneous fluctuations which have nothing to o with the nature of the problem, the integral of f. Hence, it is highly esirable if the filling of squares with samples woul happen more evenly. We will see in the following repetition of the experiment with QMC samples, that this is exactly what can be provie by the QMC metho. We want to mention, that the istribution on the bottom of figure 1 can be escribe theoretically by the Poisson istribution, in the limit of infinitely many little squares keeping the average count per little square fixe (at 8). We repeat now the experiment with exactly the same parameters but instea of a pseuo-ranom number generator we employ the Sobol approach [6], a special QMC metho, for the generation of points. The result is shown in figure 2. As can be seen in the upper plot, the filling of squares in fact happens completely even. Each little square contains exactly 8 points, an this leas to a elta histogram (shown on the lower part of figure 2). If again the points are use in the approximation of a two-imensional integral the function values from each square contributing to the average are represente much better with respect to the area they cover, an hence, smaller stochastic fluctuations are expecte, leaing very likely to smaller errors of this approximation. Through this illustration we might get an unerstaning on how the more evenly istribute samples from QMC methos coul help to ecrease the natural statistical fluctuations of stochastic approximations. 3. Lattice harmonic an anharmonic oscillator We want to briefly introuce the quantum mechanical harmonic an anharmonic oscillator quantize through the lattice path integral, which we will investigate numerically later on. These systems have been investigate in etail alreay in [7] using the Metropolis algorithm, which is consiere as a Markov chain-monte Carlo metho. The unerlying action S = a i=1 ( M0 2 (x i+1 x i ) 2 a 2 + µ2 2 x2 i + λx 4 i ) (3.1) 3
with the perioic bounary conition x +1 = x 1 is obtaine from the iscretization of the classical mechanical action of a particle with mass M 0 passing along the path x(t) consiere in Eucliean time on an equiistant finite time lattice with lattice spacing a an lattice points (extent T = a). RQMC point set Histogram of counts count frequency 4 6 8 10 12 14 0 20 40 60 8 Figure 2: Distribution of 512 Sobol points generate uniformly in the unit square (upper plot) an histogram of counts (lower plot). See also escription of figure 1. The time erivative ẋ(t) is replace by the forwar finite ifference 1 a (x i+1 x i ). λ controls the strength of the anharmonic term x 4 i. Hence, the harmonic oscillator is obtaine for λ = 0 an a spring constant µ 2 > 0. This conition has to be met for a convergent path integral. The anharmonic oscillator can be simulate with λ > 0 an µ 2 R, both being finite. The case µ 2 < 0, to which we restrict ourselves in the following, is particularly interesting, as the potential exhibits two minima in this case (cf. ouble-well potential). The quantization is performe through the partition function Z = e S(x) x 1...x. An observable O of the so quantize system can be expresse as O = Z 1 O(x) e S(x) x 1...x. The primary physical observables are X 2 = 1 i=1x 2 i, X 4 = 1 i=1x 4 i, an Γ(τ) = 1 i=1 x i x i+ τ a. (3.2) The groun state energy E 0 = µ 2 X 2 + 3λX 4 + µ2 16 an the energy gap E = E 1 E 0 between the groun an first excite state can be erive from them. The latter is etermine from a non-linear regression of the moel Γ(τ) C 0 1 2 ( e Eτ + e E(T τ)) to the ata for the correlator Γ(τ), efine in (3.2), in a range of times τ where the influence of higher-than-the-first excite states is negligible. 4. Gaussian Sampling As the action of the harmonic oscillator is at most quaratic in the variables x i, the corresponing partition function can be expresse as a multivariate Gaussian integral Z = exp ( 1 2 xt C 1 x ), where the components of C 1 are given by (C 1 ) i, j = 2M 0 a ((1 + a2 µ 2 2M 0 )δ i, j 1 2 (δ i, j+1 + δ i+1, j ) ) (obtaine from comparing: 1 2 xt C 1 x = S(x)). C is calle the covariance matrix. For such a case, the sampling of lattice paths x is particularly straightforwar, an can be base on samples z, which are generate uniformly in the -imensional unit cube. This is particularly useful, as most RQMC methos provie samples in this form. Hence, our algorithm aiming at the generation of properly istribute samples x starts in the first step with 1. the generation of a uniform sample z = (z 1,...,z ) t [0,1]. This is either, as mentione above, a RQMC sample stemming from a scramble (ranomize) Sobol point set, using irection numbers from F. Kuo s page http://web.maths.unsw.eu.au/~fkuo/sobol/inex.html, or a sample obtaine from a separate uniform sampling of each imension with a pseuoranom number generator. The latter case will be referre to as (conventional) Monte Carlo (MC) sampling in the following. 2. In the next step, univariate Gaussian samples w = (w 1,...,w ) t are generate by applying the inverse stanar normal istribution function Φ 1 to the z i an multiplying the result with 4
the square root of the eigenvalues λ i of C: w i = ( ) λ i Φ 1 z π 1 (i). (4.1) ( ) The eigenvalues are given in a close form as λ i = 2M0 1. a (u cos(2πi/) As inicate through the (inverse of the) permutation π, the orer of imensions in z has to be moifie such that the component z 1 comes upon the largest eigenvalue, z 2 comes upon the secon largest eigenvalue an so on, until the last component z meets the smallest eigenvalue. This can be achieve by etermining a permutation π which brings the eigenvalues in ecreasing orer (λ π(1) λ π(2)... λ π() ) an calculating π 1 as the inverse of this permutation (fulfilling π 1 (π(i)) = i). 3. Finally, the multivariate Gaussian variables x i are generate from the orthonormal transformation x = Gw, where G = R(F) + I(F) is the iscrete Hartley transform an F k,l = 1 e 2πikl/ the iscrete Fourier transform. 5. Results The algorithm we just iscusse was use to generate lattice paths an corresponing samples of the observable X 2 for a harmonic oscillator with the parameters M 0 = 0.5, a = 0.5, µ 2 = 2.0, an = 100 for a fixe number of samples = 2 7,10,13,16,19. For each the experiment is repeate with 300 scramblings (see section 5 in [2]) of the Sobol sequence in the RQMC simulation to allow the approximation of the error an the variance of the error. For the MC simulation 300 ifferent sees have been use to initialize the iniviual runs. A fit of the moel X 2 C α to the etermine errors of X 2 yiels an exponent α = 1.008(15) for the RQMC simulation case an α = 0.49(1) for the MC simulation. A plot illustrating the results is shown in figure 3. The outcome of this investigation basically proofs the full functioning of the (R)QMC metho for a real, even though trivial, physical moel. To stuy the scaling for a less trivial moel, we passe on to the anharmonic oscillator with the parameters λ = 1.0, M 0 = 0.5, µ 2 = 16, a = 1.5/. The experiment was performe for = 100 an 1000 imensions. The sampling of lattice paths is less straightforwar in the present case, but can be realize on the basis of the sampling metho we use before for the harmonic oscillator. This happens with the ai of the reweighting approach (cf. section 7 in [2]), which was first use in [8]. Aitionally to the physical action S, escribing the anharmonic oscillator, an artificial action S is introuce, which is constructe exactly as a harmonic oscillator action with a ifferent set of parameters M 0, a an µ. Then, harmonic oscillator paths (x i ) i=1... are generate corresponing to this unphysical action S. Approximations of observables O of the anharmonic oscillator (escribe by the physical action S) are obtaine from the weighte mean O ( i=1 O(x i)w(x i ) ) / ( i=1 W(x i) ), where the weight function W is given by W(x) = exp( S(x) + S (x)). ow, it remains to fin reasonable parameters with the objective of reucing the fluctuations of the weights W(x i ) as much as possible, leaing most likely to the smallest possible error of the observables. We foun that only the moification of the parameter µ leas alreay to satisfying results, such that M 0 = M 0 an a = a coul be left unchange. A heuristic optimization approach le to a value of µ = 0.176. We aopte the proceure for the error etermination as well as the regression (fits) for the exponents of the error scaling from the harmonic oscillator experiment. The results are shown in table 1. Plots showing the fits for 1000 imensions are shown in figure 4. From table 1 we can observe that the error scaling of the observables X 2, X 4 an E 0 is significantly improve, although less than in the harmonic oscillator 5
Error of <x 2 > for the Harmonic Oscillator Fit QMC, α = 1.007799 + 0.01490616 Error of <x 2 > 1e 07 1e 05 1e 03 MC QMC 10 i 10 i i = 5 : 5 2 7 2 10 2 13 2 16 2 19 umber of samples log( <X 2 >) 15 14 13 12 11 10 9 χ 2 = 0.06955923; of = 2 2 10 2 13 2 16 2 19 Figure 3: Error of X 2 for the RQMC an MC simulation of the harmonic oscillator (left). The right plot shows the fit of the asymptotic error scaling for the RQMC simulation. O α logc χ 2 /of X 2-0.763(8) 2.0(1) 7.9 / 6 = 100 X 4-0.758(8) 4.0(1) 13.2 / 6 E 0-0.737(9) 4.0(1) 8.3 / 6 X 2-0.758(14) 2.0(2) 5.0 / 4 = 1000 X 4-0.755(14) 4.0(2) 5.7 / 4 E 0-0.737(13) 4.0(2) 4.0 / 4 Table 1: Results for the error scaling of the observalbes X 2, X 4 an E 0 for the moel of the anharmonic oscillator, simulate through reweighting. Observable errors were fitte to the moel O C α. case. More specifically, we can conclue that, within statistical uncertainties, the error scaling is of O( 3 4 ) in all consiere cases. In a further effort we investigate also the energy gap. In orer to be able to measure this quantity, we increase µ 2 from 16 to 4 (keeping the other parameters fixe), leaing theoretically (in the limit T an a 0) to a change of E from 0.0015 to 1.576 [9]. For = 100 imensions an sample sizes of = 2 5,8,11,14 we obtain an exponent of α = 0.735(13). These results are very interesting in that the imporve error scaling seems to be rather inepenent of the observable uner consieration. 6. Outlook & conclusions In this contribution we showe a first successful application of one specific RQMC metho to Eucliean lattice moels. We verifie a perfect error scaling of O( 1 ) for the harmonic oscillator an a strongly improve error scaling of O( 3 4 ) for the anharmonic oscillator with a ouble-well potential. The latter investigation also inclue the energy gap, which can be consiere as a rather non-trivial observable, as it is obtaine from the correlator using a non-linear proceure. A better 6
Error of <X 2 >, = 1000 Error of <X 4 >, = 1000 Error of E 0, = 1000 <X 2 > 5e 04 2e 03 2 13 2 16 2 19 <X 4 > 0.002 0.010 0.050 2 13 2 16 2 19 E 0 0.005 0.020 2 13 2 16 2 19 Figure 4: Double-log plot of the error scaling of the observables X 2 (left), X 4 (mile) an E 0 (right) with the number of samples in the RQMC approach. The ashe line shows the fit of the moel O C α to the ata. umerical results can be seen in table 1. unerstaning of this in-between behavior of 3 4 is planne for the future, an shoul lea to a better theoretical unerstaning on how the QMC metho behaves when applie to non-trivial problems. Further improvements in the sampling of the anharmonic oscillator are assume when an optimally tune, more generalize covariance matrix is use in the Gaussian sampling step. Furthermore, other promising non-gaussian sampling approaches, like inverse sampling [10], are investigate at the moment, aiming at a better escription of the anharmonic action an probably involving the potential to be applicable to a much broaer class of lattice problems; though, it will be interesting to see in the future how efficient these techniques are in practice. As a next step towars lattice gauge theories we are currently consiering a one-imensional spin like moel, escribe by the action S = ai i=1 1 cos(φ a 2 i+1 φ i ), where I is the moment of inertia, a the lattice spacing, an φ i are angular variables with perioic bounary conitions (φ = φ 0 ). This moel exhibits topological features, visible through the non-vanishing of the wining number a feature not present in the previously consiere oscillator moels but in other lattice gauge theories like QCD. Having manage this moel with generalizable methos it coul be envisage that also generic gauge theories coul be aresse in the future. References [1] F. Kuo, C. Schwab an I. Sloan, AZIAM Journal, 53 (01) (2012). [2] K. Jansen, H. Leovey, A. Ammon, A. Griewank, an M. Müller-Preussker, Comput.Phys.Commun. (2013), http://x.oi.org/10.1016/j.cpc.2013.10.011, arxiv:1302.6419 [hep-lat]. [3] K. Jansen, H. Leovey, A. ube, A. Griewank an M. Müller-Preussker J. Phys.: Conf. Ser. 454 (2013) 012043, arxiv:1211.4388 [hep-lat]. [4] P. Glasserman, Springer-Verlag, ew-york 2004. [5] M. Matsumoto an T. ishimura, ACM Trans. Moel. Comput. Simul., 8 no. 1 (1998) 3 30. [6] I. M. Sobol, U.S.S.R. Comput. Math. an Math. Phys., 7 no. 4 (1967) 86 112. [7] M. Creutz an B. Freeman, Annals Phys., 132 (1981) 427. [8] A.M. Ferrenberg an R.H. Swensen, Phys. Rev. Lett., 61 no. 23 (1988) 2635 2638. [9] R. Blankenbecler an T. A. DeGran, Thomas A. an R. L. Sugar, Phys.Rev., D21 (1980) 1055. [10] L. Devroye, Springer-Verlag, ew-york 1986. 7