Você está na página 1de 6
forcement of the concepts of phase and phase difference; an improvement in oscillosocpe technique; and, through the audio output of the synthesizer, an appreciation that the human ear is sensitive to amplitude and frequency but not at all sensitive to phase differences between the constituent harmonics of a sound. ‘The students find this a valuable experiment and enjoy doing it. Musicians taking part in extension courses have derived considerable benefit and enjoyment from attempt- ing to simulate various instrumental tonal qualities with the synthesizer. ACKNOWLEDGMENT The authors gratefully acknowledge the contribution of E. R, Hodgson in the development of this experiment. "RW. Hamming, Numerical Methods for Scientists and Engineers (McGraw-Hill New York, 1973), 2nd ed. pp. SOS-S15, 71, H. Lynch, Electronics 80, 115 (1977. AR J. Higgins, Am. J. Phys. 4, 76 1976) Evaluation of Feynman path integrals by Monte Carlo methods P.K, MacKeown Department of Physics, University of Hong Kong, Hong Kong (Received 22 May 1984; accepted for publication 8 September 1984) Details of a project suitable for an advanced undergraduate course in computational physics, involving the evaluation of functional integrals, are presented. The square of the ground state wavefunction for a simple system may be formulated as a Feynman path integral, and such path integrals evaluated using Monte Carlo methods on a microcomputer. Appli jon to a system interacting through a Morse potential or through a simple harmonic potential is described, while the possible employment of over-relaxation in the latter case is explained. I, INTRODUCTION One of the most noticeable aspects of the application of computers in physics is the explosion in the literature! over the past few years, of papers based on the application of Monte Carlo methods in quantum field theory calcula- tions. Because the topic is at the forefront of research— ‘most papers are exploring the possibility of the confine- ‘ment of quarks in quantum chromodynamics—it is not easy for undergraduates to appreciate it, the more so as they generally lack experience in use of the Monte Carlo method, Such calculations, however, are evaluations essen- tially of Feynman path integrals; by using this technique to focus on a much simpler problem both the content of the formalism and the details of the computing method can be introduced at the undergraduate level. In this article we describe a project, used in a final year undergraduate course on computational physics, on the application of the Feynman method toa problem in elementary quantum me- chanics; the students are not assumed to be familiar with functional integration beforehand. This concerns the eva~ lation of the square of the ground state wavefunction and its energy, of a particle in a specified potential in one di- ‘mension; the cases of simple harmonic motion and motion in a Morse potential are described explicitly The feasibility of this method was originally described in two rather long papers.” Here we aim at as simple a presen- tation as possible. The Monte Carlo method has often been discussed previously in the context of problems in statisti- 880 Am J. Phys. $3 (0), September 1985 cal mechanics, ata level similar to that in this article. Al- though in principle its application here is not significantly different, the relative unfamiliarity of summing over paths ‘warrants a brief introduction. In Sec. II we briefly outline the necessary background in quantum mechanics and the extension of the formalism to imaginary time, while in Sec. III we describe the application of the Metropolis algorithm for the evaluation of the sum over histories. In Sec. IV we describe its application to the Morse potential and in Sec. V present some results for this, as well as for the simple har- ‘monic oscillator, obtained using a Commodore CBM3032 microcomputer. Il, THE PATH INTEGRAL FORMALISM ‘The path integral formalism is described in several places,** with Ref. 6 giving a useful introduction based on physical considerations. Even so, a concise presentation directed towards its immediate application in the project seems necessary for the students. This we attempt in the following. ‘Guided by considerations like the motion of an electron in the double-slit experiment, and an idea of Dirac, Feyn- ‘man postulated an amplitude to be associated with any vi- sualizable trajectory of a particle’s motion. The amplitude for the overall resulting motion is then the sum of the tra- jectory amplitudes over all “permissible” trajectories. For ‘motion in one dimension the amplitude associated with a trajectory X () between points X (tq) = x9 and X(t) = x is © 1985 American Association of Physics Teachers 880, assumed to equal exp{iS[X (¢)]/A}, where S[X (t}] is the classical action along the trajectory, i.c., s=f Laknde, where L. is the Lagrangian. The total amplitude for the motion from (x, foto (x, 1) is given by Kisnred=Zew(Lstxel) mt 2 ‘sum over all trajectories X, linking the points. Among several of the formal ways of writing this quantity one fre~ quently encounters Klett) = if DB XI 'yexp (is (xe) 22) Here J X(t’) is a measure of the number of infinitesimal segments at ' of complete paths linking (x, fo) to (x,t); in fact, the expression is no more helpful than (2.1) in telling us how to calculate the sum. If the initial state at fis itself a distribution character- ‘ized by a probability density |¥ (xo, f9)|?, the total ampli- tude to beat x at time is just the weighted sum of trajectory amplitudes from all initial points, West) = fag Mt) K Us f+ 23) an expression which also explains why the sum of ampli- ‘tudes in 2.1) is often called a propagator; it represents the strength with which the value of the wavefunction at any point xo, fo influences its value at a specific point x ata later time, In Born’sinterpretation of Schrédinger’s wave equation, the wavefunction Vis related to the probability amplitude, i.e. W(x, #), with the appropriate initial conditions, alsosat- isfies Schrdinger’s equation: aw mp Poth (2.4) AY (x, th= In most introductory texts on quantum mechanics” itis shown how a solution of (2.4) can be written formally as an expansion, with time-dependent coefficients, in the time- independent eigenstates ¥, ( of the operator H, ie., ¥5,t)= Se exp] — (4) 2,¢] eal) (23) The coefficients c, here are given by J e505 0) v8 Us) 26) Inserting these coefficients into the expression (2.5) and comparing the resulting expression for ¥ (x, t) with (2.3) Teads to the identity K(x, 65 Xo 0) = DOF (Xo) Ha) exp — We now assume that the validity of this relation extends to imaginary values ofr; writing t= — ir, r real, it becomes Kes, SF bse Yale ext — As some reassurance for the validity of this extension we note that such a continuation of Schrédinger’s equation, (2.4), toimaginary time gives rise to the same time-indepen- dent eigenvalue problem as the original equation. The iE, 1/8). — xy 0)= E,7/#) (27) 881 Am.J. Phys, Vol. $3, No. 9, September 1985 right-hand side of (2.7) poses no problem. In particular tak- ing x = x, and assuming that the ground-state energy Ep is not degenerate, then, provided the relation >A E, — Ep) (2.8) holds, where £, is the energy of the first excited state, the first term in the summation |Yo(x)|? exp( — Eyr/A) will dominate. In other words, we have Ib]? = ira, exp(Ear/A) K by This is the starting point for our project. It means that we can find the square of the ground-state wavefunction for a system if we can sum over the paths in (2.1) evaluated at an imaginary time — ir (the potential of course occurring in the action $), with r sufficiently large, as dictated by (2.8) Since the £, will not in general be known if the wavefunc- tion is not, this explicit condition will not be of direct help. Sufficiently large 7 can be determined only by searching for convergence® as a function of r. Requiring normalization of 2.9), ie, fies d=, wwe find in conjunction with (2.1) Io)? = lim K(x, —irsx, of” dx K(x, —i75x,0). (2.10) =i5x,0). (29) TIL. EVALUATION OF THE SUM OVER PATHS ‘We return tothe general expression (2.3), and consider the particular path shown in Fig. 1. For any t, <¢ we can write Besse) = fds, Pit) KOs F804) However, ¥/(x,, f;)may also be expressed in terms of values at an earlier time, Peet = feo Pot) K be tot Fig. 1. Am arbitrary path inking (x 6) 0 (8 ¢) P.K.MacKeown 881 so we can write West) = fag Wnt) f 2K (6 Xt) K By 15 Xo fo) ‘Thus on comparison with (2.3), we have the group property Ket xt) = fd K 6 6.851) XK (yf Xoo) > Obviously, arbitrarily many successive times t, may be in- terposed in this way, at each of which time integration of the product of propagators over the space variable, denoted by x,, must be carried out. With NV intervening times, spaced evenly by € = (t — fa)/N + 1, we have the following expression, with xy. K (6, 5%) = lim far wy dity XP Klien ticsiants where the propagators in the multiple integral are to be evaluated for infinitesimal time differences. At least for ‘systems where the potential does not depend on velocity® it ccan be shown that as far as significant contributions to this ‘multiple integral are concerned we can write Rite +6 Xt) =A exp [WA S(x,.1,%)], where 4 is a constant which depends on ¢ and S is the stationary classical action between x, and x,,.. In this way we can write the overall propagator as K 655%) = him # fd. dey Keap [(/H) Slo, xy -- » Xv» X)] - B.1) ‘The sum has been converted into a multiply infinite multi- ple integral, and we can use it to evaluate (2.10) For such potentials @ (x) which do not involve time de- rivatives we can write the Lagrangian for a particle as enum (ay Lexn=@(£)_o, (4% 1) m(e) ) which in terms of r becomes: - [2 (2) +2ei=-am0, where His the Hamiltonian, Hence the action may be writ- ten as "Horde and (2.10) takes the form Iolall? [fen vndy ex 4 ff nar) |/z..3.2) ‘The denominator Z has the form aml ax fey sdeyemp(4 f ster). ‘The label X, on the integral means that the integration [Her 882 _Am.J. Phys, Vol. 53, No.9, eptember 1985 Su is carried out along the trajectory X,, linking the points [x(0) =x, x4(r), + Xw(Twh 27) = x] - By taking these segments as straight lines, equally spaced in by e=7/N + 1, we have 1 EX [m (x, 7 4 fe 5 [F CY +08] a £54, and we associate an energy E [X (r|] with a given trajectory. ‘Equation (3.2) then assumes the form Was =~" fen sy Xexp [ —(€/A) BX) oy ys Ave1 =H) tis helpful to write x = x9 and integrate over xp with a delta function included, i WWoal2=Z- Jared, diy (3.3) XO (xo — x) Expl — (€/A) E (Xo X15 Xyy all 5 4) where z= [de ony dy eXpL — (€/F) E iio Xo Xe Rall» (5) Expression (3.4) is of the general form: 3.6) fasten where nr) is a normalized probability distribution, aieldr = Z~' exp{ — (¢/A) Ee] de 37) and f(r) = 5 (x, — x). We now describe the evaluation of such integrals. IV. THE MONTE CARLO METHOD Because of the large number of dimensions in the inte- gral (3.6), (we will take N = 32 below), the Monte Carlo method strongly suggests itself as a method of evaluation. An estimate of its values is just the average of the function f(t) over a series of M values r, of its argument, where these ‘values are selected at random from the distribution zt). This is the method of importance sampling, The probabil- ity distribution 7(r), however, contains the horrendous nor- rmalizing quantity Z, (3.5); in the absence of knowledge of this the only way to select variates from the distribution is by the use of Markov chains. For this the algorithm of ‘Metropolis er al.* is most popular; we outline it in the con- text of a specific project below. We investigate a pair of atoms interacting through a po- tential, for which the ground-state wavefunction and ener- gy are known, namely the Morse potential”: Dir) = Ve — 20-2"), If we write o==a(2Vo/p)", £?mxfia(2uVo)~"'?, where p is the reduced mass of the pair, and take as our unit of length (f/yoo)", Le, writing x=={r — ro) (uo/)"”, it takes the form: D(x) = (feo/25| (e*** — 20) If, further, we take «o~? as our unit of time, Eq, (3.3) takes P.K.MacKeown 882 Fig. 2. segmented path inking x 0}t0 (x 7},oneof theinfnity of such contributing to (34). A possible step x,—rx{, on the Markov chain is shown the form €F (xy... Xy 41), Where Elo tve1) $31€ x ferol = 265.) -2e7 5). 111] an) The use of Markov chains to select configurations or paths is described in Ref. 10; we outline the popular version due to Metropolis ef ai.® Starting with an arbitrary path (Gio » iv 1 = Xo) Successive paths are chosen a step at a time such that they differ at most in the coordinate of one node, say x,—>x,. This step is chosen with a probability Weg, =min (1, e~ 87), where AE = E (toy 4 Xh5 m5 883 Am.J. Phys, Vol.$3, No. 9, September 1985 not) — Eloy oo Hs os 9 Xn 4 1 ier if AE < Othe coordi- nate is altered to x;; otherwise it is altered if e~ ** >, where £ is a random variate from the uniform distribution on (0, I). After a sufficient number of steps to erase the influence ofthe initial path, the trajectories so selected will bedistributed as (3.7); after this the integral may be evaluat- ed as explained above. ‘Any one path contributes to the wavefunction at all space points on it, e.g., the solid path in Fig. 2 contributes not only to Yxo), but also to Yx,) because x, can also be thought of as the beginning and terminating points on a path containing thesame segments, with its last one, shown dashed in Fig. 2 just a repetition of the first segment. In practice a node x; is selected at random, replaced by x; where.x; will have one of the values x, + 5 or x,, where 5 is an arbitrary amount, with the probability W¥,,, de- scribed above. This contributes unity to the integral (3.4) for x =x,. If is fixed, and thus the possible values of x, discrete, bins are associated with each of these possible val- ues of x; and the one corresponding to the revised x, aug- ‘mented at each step on the walk. If isitself allowed to vary. cach bin will embrace a range of values of x. The value of |¥4x,)|? is then just the number accumulated in the corre- sponding bin divided by the total number of steps M. V. THE PROGRAM A program was written in Basic!” and run on a Commo- dore CBM3032 microcomputer, taking {= 1. Paths are confined to segments linking discrete points in = 3.2

Você também pode gostar