Variational Monte Carlo to find Ground State Energy for Helium

Similar documents
MATH325 - QUANTUM MECHANICS - SOLUTION SHEET 11

Computational Physics Lectures: Variational Monte Carlo methods

Homework 2 Computational Chemistry (CBE 60553)

Metropolis/Variational Monte Carlo. Microscopic Theories of Nuclear Structure, Dynamics and Electroweak Currents June 12-30, 2017, ECT*, Trento, Italy

( ) = 9φ 1, ( ) = 4φ 2.

Test 2 Solutions - Python Edition

Harmonic Oscillator with raising and lowering operators. We write the Schrödinger equation for the harmonic oscillator in one dimension as follows:

DM534 - Introduction to Computer Science

Quantum Variational Monte Carlo. QVMCApp

Approximation Methods in QM

only two orbitals, and therefore only two combinations to worry about, but things get

Chm 331 Fall 2015, Exercise Set 4 NMR Review Problems

Problem Set 7: Solutions

Lorenz Equations. Lab 1. The Lorenz System

Ch 125a Problem Set 1

Brief review of Quantum Mechanics (QM)

PH 253 Final Exam: Solution

Write a simple 1D DFT code in Python

Exercise 5 Release: Due:

Quantum Mechanics Solutions

5.1 Classical Harmonic Oscillator

Dimensional analysis

Variational Methods for Electronic Structure

Problem 1: A 3-D Spherical Well(10 Points)

Outline Python, Numpy, and Matplotlib Making Models with Polynomials Making Models with Monte Carlo Error, Accuracy and Convergence Floating Point Mod

Electronic structure, plane waves and pseudopotentials

Pseudopotential generation and test by the ld1.x atomic code: an introduction

PHY4604 Introduction to Quantum Mechanics Fall 2004 Final Exam SOLUTIONS December 17, 2004, 7:30 a.m.- 9:30 a.m.

Homework 5 Computational Chemistry (CBE 60547)

TF Mutiple Hidden Layers: Regression on Boston Data Batched, Parameterized, with Dropout

Physics 137A Quantum Mechanics Fall 2012 Midterm II - Solutions

7.1 Variational Principle

where A and α are real constants. 1a) Determine A Solution: We must normalize the solution, which in spherical coordinates means

Exercise_set7_programming_exercises

1 Commutators (10 pts)

Educreator Research Journal (ERJ) ISSN :

Problem Set 5: Solutions

Physics 342 Lecture 23. Radial Separation. Lecture 23. Physics 342 Quantum Mechanics I

Introduction to Quantum Mechanics (Prelude to Nuclear Shell Model) Heisenberg Uncertainty Principle In the microscopic world,

For a system with more than one electron, we can t solve the Schrödinger Eq. exactly. We must develop methods of approximation, such as

Python Programs.pdf. University of California, Berkeley. From the SelectedWorks of David D Nolte. David D Nolte. April 22, 2019

If electrons moved in simple orbits, p and x could be determined, but this violates the Heisenberg Uncertainty Principle.

Lab 1: Iterative Methods for Solving Linear Systems

Lecture 9: Molecular Orbital theory for hydrogen molecule ion

r R A 1 r R B + 1 ψ(r) = αψ A (r)+βψ B (r) (5) where we assume that ψ A and ψ B are ground states: ψ A (r) = π 1/2 e r R A ψ B (r) = π 1/2 e r R B.

Test 2 - Python Edition

20 The Hydrogen Atom. Ze2 r R (20.1) H( r, R) = h2 2m 2 r h2 2M 2 R

P3317 HW from Lecture 15 and Recitation 8

ψ s a ˆn a s b ˆn b ψ Hint: Because the state is spherically symmetric the answer can depend only on the angle between the two directions.

1 Planck-Einstein Relation E = hν

would represent a 1s orbital centered on the H atom and φ 2px )+ 1 r 2 sinθ

2 2 mω2 x 2 ψ(x) = Eψ(x),

Qualifying Exam. Aug Part II. Please use blank paper for your work do not write on problems sheets!

Chapter 7. Bound Systems are perhaps the most interesting cases for us to consider. We see much of the interesting features of quantum mechanics.

Chapter 1: Chemical Bonding

Potential energy, from Coulomb's law. Potential is spherically symmetric. Therefore, solutions must have form

Physics 202 Laboratory 5. Linear Algebra 1. Laboratory 5. Physics 202 Laboratory

Joel Broida UCSD Fall 2009 Phys 130B QM II. Homework Set 4

Lecture Unconstrained optimization. In this lecture we will study the unconstrained problem. minimize f(x), (2.1)

The Schrödinger Equation

Lecture-XXVI. Time-Independent Schrodinger Equation

Rotations in Quantum Mechanics

P3317 HW from Lecture and Recitation 7

The Northern California Physics GRE Bootcamp

Further Quantum Mechanics Problem Set

The Shooting Method for Boundary Value Problems

Numerical Solution of a Potential Final Project

Physics 351 Monday, April 23, 2018

4πε. me 1,2,3,... 1 n. H atom 4. in a.u. atomic units. energy: 1 a.u. = ev distance 1 a.u. = Å

Problem Set 9: Solutions

Error, Accuracy and Convergence

Physics 70007, Fall 2009 Answers to Final Exam

We now turn to our first quantum mechanical problems that represent real, as

Physics 43 Exam 2 Spring 2018

6. Qualitative Solutions of the TISE

1. For the case of the harmonic oscillator, the potential energy is quadratic and hence the total Hamiltonian looks like: d 2 H = h2

( r) = 1 Z. e Zr/a 0. + n +1δ n', n+1 ). dt ' e i ( ε n ε i )t'/! a n ( t) = n ψ t = 1 i! e iε n t/! n' x n = Physics 624, Quantum II -- Exam 1

8.05 Quantum Physics II, Fall 2011 FINAL EXAM Thursday December 22, 9:00 am -12:00 You have 3 hours.

Lecture 12. The harmonic oscillator

r 2 dr h2 α = 8m2 q 4 Substituting we find that variational estimate for the energy is m e q 4 E G = 4

Chemistry 532 Practice Final Exam Fall 2012 Solutions

Physics 228 Today: Ch 41: 1-3: 3D quantum mechanics, hydrogen atom

Linear Classification

The Hydrogen Atom. Dr. Sabry El-Taher 1. e 4. U U r

The Central Force Problem: Hydrogen Atom

Notes on excitation of an atom or molecule by an electromagnetic wave field. F. Lanni / 11feb'12 / rev9sept'14

Quantum Mechanics FKA081/FIM400 Final Exam 28 October 2015

Introduction to Electronic Structure Theory

GES 554 PDE MEMO. Memo: GES554-Project-2. REF: Ext:

MAS212 Scientific Computing and Simulation

Energy loss of alpha particles - Prelab questions

Announcements. Please check for errors now

11 Perturbation Theory

Quantum Monte Carlo methods

1. Hydrogen atom in a box

Introduction to Computational Chemistry

Tutorial Three: Loops and Conditionals

P3317 HW from Lecture and Recitation 10

EXAM INFORMATION. Radial Distribution Function: B is the normalization constant. d dx. p 2 Operator: Heisenberg Uncertainty Principle:

Chemistry 3502/4502. Exam III. March 28, ) Circle the correct answer on multiple-choice problems.

Transcription:

Variational Monte Carlo to find Ground State Energy for Helium Chris Dopilka December 2, 2011 1 Introduction[1][2] The variational principle from quantum mechanics gives us a way to estimate the ground state energy of complicated potentials since we don t have to actually know the exact form the of wave function for the ground state. The variational principle states that for an arbitrary normalized wavefunction, ψ, E gs ψ H ψ that is the expectation value of H will overestimate the ground state energy. So by guessing the form of the wavefunction and varying the wavefunction, you can look at the minimum of the expectation value of H of the varying wavefunction, and conclude that it must be closest to the ground state energy. Computationally, this reduces the problem to finding the expectation value of H for some wavefunction with an adjustable parameter. In other words, we need to evaluate the integral: ψ H ψ = ψ Hψ dr The easiest way to evaluate integrals computationally, over any number of dimensions is by using Monte Carlo techniques. In this paper, points to be used in evaluating the integral are found using the Metropolis algorithm, which works as follows. First, assuming ψ is real, we can rewrite the integral above as: ψhψ dr = dr (ψψ) 1 ψ Hψ = dr p(r)e L (r) where p(r) = ψψ and E L (r) = 1 ψ Hψ. E L is known as the local energy. Then using the Monte Carlo method, dr p(r)e L (r) 1 N N E L (r i ) where {r 1,..., r N } are points chosen according to the probability distribution p(r), and N is the total number of points used. In order to come up with the points used, start with an initial point r, then r new = r + dr where dr is a random point in the hypercube, whose length is determined by the simulator. Define, p = p(r new) p(r) then if p 1 we always accept the new point, but if p < 1 we accept the new point with probability p. This algorithm is repeated many times until it has thermalized to the distribution. Once this has happened, points are taken so many steps after a point is accepted so as to avoid the points from being too correlated. The amount of steps it takes to thermalize to the distribution and how many steps to run in between each point taken needs to be determined by the simulator. By doing this process several times, you should end up with enough points with enough randomness to be able to evaluate the integral. Note that normalizing the wavefunction is unnecessary, since any normalization constant divides out in evaluating p and E L. i=1 1

2 One Dimension Harmonic Oscillator In order to test this method, choosing a system with known analytic solutions is good. For this case, the one dimension harmonic oscillator is used. The hamiltonian for this system is: and the ground state wave function is: with energy, d 2 H = h2 2m dx 2 + 1 2 mω2 x 2 ψ 0 = ( mω ) 1/4 e mω 2 h x2 π h E 0 = 1 2 hω In this case, take h = m = ω = 1, and consider trial wavefunctions of the from ψ a (x) = e ax2. Then, p(x) = e 2ax2, and E L = 1 ψ a (x) Hψ a(x) = a + x 2 ( 1 2 2a2 ) Then solving for the expectation value of H for the trial wavefunction becomes the sum 1 N N i=1 E L(r i ), where the r i are picked by the algorithm above. Doing this computationally, for different values of a we see that when a = 1/2 the expectation value of H reaches a minimum, and at this point E = 1/2, which is exactly the analytical result. A graph of E versus a is seen below. 2

3 Helium Helium is a three body system consisting of two electrons orbiting a nucleus. If we assume that the nucleus remains fixed, we can write the hamiltonian, in atomic units, as [ Hψ(r 1, r 2 ) = 1 2 ( 2 r 1 + 2 r 2 ) 2 2 + 1 ] ψ(r 1, r 2 ) r 1 r 2 r 12 Where r 1, r 2 are the distances of the two electrons from the nucleus and r 12 is the distance between them. The ground state energy has been experimentally determined to be 2.90372 hartrees [3]. 3.1 First Trial Function For the first trial wavefunction of Helium, the product of two electrons in the ground state of Hydrogen is taken, while varying the radius of the atom. The wavefunction looks like: Then the local energy of this trial wavefunction is: ψ(r 1, r 2 ) = e α(r1+r2) E L (r 1, r 2 ) = α 2 + α r 1 + α r 2 2 r 1 2 r 2 + 1 r 12 The variational method was applied with 60 walkers doing 60000 steps, waiting 10000 steps to thermalize and taking points every 600 steps, for different values of α. This resulted in a minimum energy found at 2.8575 hartrees. This is within 1.6% of the experimental value for the ground state of Helium. A graph of the energies found with respect to the variational parameter α is seen below. The minimum was taken directly from the minimum that was determined as seen in the graph. 3

3.2 Second Trial Function The previous trial function does not account for any electron-electron interactions that happen. To account for this interaction it is clear at least two variational parameters must be used. The trial wavefunction that will be used is: ψ(r 1, r 2 ) = e αr1 e βr2 + e βr1 e αr2 The local energy is found to be: E L (r 1, r 2 ) = 1 2 (α2 + β 2 ) + 1 [ 1 (αe αr1 e βr2 + βe βr1 e αr2 ) + 1 ] (βe αr1 e βr2 + αe βr1 e αr2 ) V ψ r 1 r 2 The variational method was applied with 50 walkers doing 60000 steps, waiting 10000 steps to thermalize and taking points every 600 steps, for different values of α and β. A minimum is found when energy is 2.8904, which is 0.46% off of the actual value. A graph of the energy versus both parameters is seen below. The minimum was again taken from the lowest point measured. 4 Analysis While the graphs for either trial wavefunction for helium are not as smooth as the one for the harmonic oscillator, they both show that the energy reaches a minimum, and this minimum is above the actual value, as expected by the variational principle. The primary issue with using this method is the statistical errors associated with it. It is clear from looking at the harmonic oscillator that these errors are less the closer the trial wavefunction is to the actual wavefunction. In the case of the harmonic oscillator, the exact form of the wavefunction was 4

picked and gives the exact answer when the exact wavefunction is used. In the case of the Helium atom, you can t write the exact wavefunction down, due to the fact that this is a three-body problem. This means that the statistical error can t be eliminated, only be reduced. By simply generating more points, whether by increasing the number of walkers or increasing the number of points taken per walker, would reduce the statistical errors. The issue is the computing time needed to perform these calculations. A standard Monte-Carlo method converges at a rate of 1/ N, meaning quadrupling the number of samples will halve the error. The method used here should converge better than that, but it is clear that much computing time will be needed to reduce the statistical errors significantly. 5 Conclusion This method for determining the ground state energy of systems is shown to be effective. The second trial wavefunction gave a ground state energy for Helium was within 0.46% of the experimental value. Three things could improve this result using this method. The first is using a method that actually minimizes the parameter instead of picking values around where the minimum might be. This wouldn t be too difficult to implement, but would depend on very small amount of statistical error. The second is to use more complicated trial wavefunctions. The primary issue with this is not computational; it is in doing the math to evaluate the local energy function. The issue comes from having to evaluate 2 r 1 + 2 r 2 of wavefunctions that might contain terms containing r 12, which is not a trivial problem. The third is to just take more points for the Monte-Carlo integration. This is the easiest to implement, but would increase computation time drastically. Also, it would be useful to investigate the statistical errors created by this method. Having a better understanding of these would allow fits to be put to the data points to determine a statistically sound minimum energy value and be able to know what sort of error this value has. Overall, this method is effective, but more research needs to be done in regards to the error associated with this method to provide better results. References [1] G. Wysin, Numerical Quantum Mechanics Techniques, 2000, http://www.phys.ksu.edu/personal/ wysin/quantum/index.html [2] D. Martin, Computing the ground state energy of helium, 2007, http://www.daniel-martin.co.uk/ files/qmc.pdf [3] Five Trial Wavefunctions for two-electron Atoms and Ions, http://www.users.csbsju.edu/~frioux/ stability/heatom.pdf 6 Code ## Variational Monte-Carlo Method by Chris Dopilka December 2, 2011 ## Determines ground state energy of Helium Atom for trial wavefunction ## Code in place for 1 or 2 variation parameters and the plots ## Python 2.7.2 used # Libraries needed: # Requires numpy, matplotlib # http://numpy.scipy.org/ # http://matplotlib.sourceforge.net/ import math import random import matplotlib.pyplot as plt 5

import numpy as np from mpl_toolkits.mplot3d import Axes3D random.seed() # paramaters for simulation number_walkers = 50 steps = 60000 therm_step = 600 therm = 10000 trials1 = 10 trials2 = 12 dr = 1 # the paramaters to be varied # Paramaters are later described in list A = [alpha, beta] A1 = 0.9 da1 = 0.05 A2 = 1.9 da2 = 0.05 # Used for generating initial position and the next step DIST = 2 def ran_pos(): return DIST * (2*random.random()-1) def rand(): return random.random()*2-1 ## Used for plotting 3d Z = np.empty((trials1,trials2)) X = np.empty((trials1,trials2)) Y = np.empty((trials1,trials2)) for i in range(0,trials1): for j in range(0,trials2): X[i][j] = A1+i*dA1 Y[i][j] = A2+j*dA2 ## Used for plotting 2d # Y = [] # X = [] # for i in range(0,trials1): # X.append(A1+i*dA1) ## Describes both vectors r_1, r_2 ## Provides methods for finding their norm ## the distance between them ## and the dot product with the vector r_12 class Position: def init (self,r): self.r = R 6

def norm(self,i): return math.sqrt(self.r[i][0]**2+self.r[i][1]**2+self.r[i][2]**2) def dist(self): sum = 0 for i in range(0,3): sum += (self.r[1][i] - self.r[0][i])**2 return math.sqrt(sum) def dot(self,i): sum = 0 for j in range(0,3): sum += self.r[i][j]*(self.r[0][j] - self.r[1][j]) return sum / (self.norm(i)*self.dist()) # Picks new point def step(self): R_new = [[0,0,0],[0,0,0]] for i in range(0,2): for j in range(0,3): R_new[i][j] = self.r[i][j] + rand()*dr return R_new ## Probability distribution # Is wavefunction squared def prob(r,a): r1 = R.norm(0) r2 = R.norm(1) ## Trial Wavefunction #1 #return (math.exp(-a[0]*(r.norm(0) + R.norm(1))))**2 ## Trial Wavefunction #2 return (math.exp(-a[0]*r1 - A[1]*r2)+math.exp(-A[1]*r1 - A[0]*r2))**2 ## Local Energy function def energy(r,a): r = R.dist() r1 = R.norm(0) r2 = R.norm(1) V = (2/r1+2/r2-1 / r) ## trial wavefunction #1 #return -A[0]**2 + A[0]/r1 + A[0]/r2 - V ## trial wavefunction #2 wave = math.exp(-a[0]*r1 - A[1]*r2)+math.exp(-A[1]*r1 - A[0]*r2) return -0.5*(A[0]**2+A[1]**2) + ((A[0]*math.exp(-A[0]*r1 -A[1]*r2) +A[1]*math.exp(-A[1]*r1 -A[0] ##Used to extract minimum value B = [0,0] min = [0,B] ## Actual simulation 7

# one loop for each paramater varried for j in range(0,trials1): for l in range(0,trials2): avg = 0 A = [A1+j*dA1, A2+l*dA2] # loop over for mulltiple walkers for k in range(0,number_walkers): # creates initial point Ri = [[ran_pos(),ran_pos(),ran_pos()], [ran_pos(),ran_pos(),ran_pos()]] R = Position(Ri) #for storred monte-carlo points points = [] for i in range(0,steps): # generate new point R_new = Position(R.step()) # determine probability of acceptance # catch division by zero for debugging try: p = prob(r_new,a)/prob(r,a) except ZeroDivisionError: print R,A # check if we should accept new position if p >= random.random(): R = R_new # if we ve termalized, take every therm_step points if i > therm: if (i-therm) % therm_step == 0: points.append(r) # Evaluate integral sum = 0 for i in range(0,len(points)): sum += energy(points[i],a) avg += sum/len(points) # average together value of integral # for different walkers # and keep minimum del points if avg/number_walkers < min[0]: min[0] = avg/number_walkers min[1] = A #prints energy value for each set of paramaters A #print A, avg/number_walkers # for plotting 3d 8

Z[j][l] = avg/number_walkers # for plotting 2d #Y.append(avg/number_walkers) # Report minimum energy found and parameters used print min ## Make 2d Plot # plt.xlabel( Alpha ) # plt.ylabel( Energy ) # plt.plot(x,y, bo,x,y) # plt.grid(true) # plt.show() ## Make 3d Plot fig = plt.figure() ax = fig.add_subplot(111, projection= 3d ) ax.set_xlabel( Alpha ) ax.set_ylabel( Beta ) ax.set_zlabel( Energy ) ax.plot_wireframe(x,y,z) plt.show() 9