FYS4411/9411 Project 2, Variational Monte Carlo studies of electronic systems. Deadline May 31

Computational Physics II FYS4411/FYS9411
Department of Physics, University of Oslo, Norway

Spring Semester 2023


Introduction

The aim of this project is to use the Variational Monte Carlo (VMC) method to evaluate the ground state energy, onebody densities, expectation values of the kinetic and potential energies and single-particle denisties of quantum dots with \( N=2 \), \( N=6 \), \( N=12 \) and \( N=20 \) electrons. These are so-called closed shell systems.

Theoretical background and description of the physical system

We consider a system of electrons confined in a pure two-dimensional isotropic harmonic oscillator potential, with an idealized total Hamiltonian given by

$$ \begin{equation} \label{eq:finalH} \hat{H}=\sum_{i=1}^{N} \left( -\frac{1}{2} \nabla_i^2 + \frac{1}{2} \omega^2r_i^2 \right)+\sum_{i < j}\frac{1}{r_{ij}}, \end{equation} $$

where natural units (\( \hbar=c=e=m_e=1 \)) are used and all energies are in so-called atomic units a.u. We will study systems of many electrons \( N \) as functions of the oscillator frequency \( \omega \) using the above Hamiltonian. The Hamiltonian includes a standard harmonic oscillator part

$$ \begin{equation*} \hat{H}_0=\sum_{i=1}^{N} \left( -\frac{1}{2} \nabla_i^2 + \frac{1}{2} \omega^2r_i^2 \right), \end{equation*} $$

and the repulsive interaction between two electrons given by

$$ \begin{equation*} \hat{H}_1=\sum_{i < j}\frac{1}{r_{ij}}, \end{equation*} $$

with the distance between electrons given by \( r_{ij}=\vert \boldsymbol{r}_1-\boldsymbol{r}_2\vert \). We define the modulus of the positions of the electrons (for a given electron \( i \)) as \( r_i = \sqrt{r_{i_x}^2+r_{i_y}^2} \).

Project 2 a):

In exercises a-f we will deal only with a system of two electrons in a quantum dot with a frequency of \( \hbar\omega = 1 \). The reason for this is that we have exact closed form expressions for the ground state energy from Taut's work for selected values of \( \omega \), see M. Taut, Phys. Rev. A 48, 3561 (1993). The energy is given by \( 3 \) a.u. (atomic units) when the interaction between the electrons is included. If only the harmonic oscillator part of the Hamiltonian is included, the so-called unperturbed part,

$$ \begin{equation*} \hat{H}_0=\sum_{i=1}^{N} \left( -\frac{1}{2} \nabla_i^2 + \frac{1}{2} \omega^2r_i^2 \right),\end{equation*} $$

the energy is \( 2 \) a.u. The wave function for one electron in an oscillator potential in two dimensions is

$$ \begin{equation*} \phi_{n_x,n_y}(x,y) = A H_{n_x}(\sqrt{\omega}x)H_{n_y}(\sqrt{\omega}y)\exp{(-\omega(x^2+y^2)/2}. \end{equation*} $$

The functions \( H_{n_x}(\sqrt{\omega}x) \) are so-called Hermite polynomials, discussed in connection with project 1 while \( A \) is a normalization constant. For the lowest-lying state we have \( n_x=n_y=0 \) and an energy \( \epsilon_{n_x,n_y}=\omega(n_x+n_y+1) = \omega \). Convince yourself that the lowest-lying energy for the two-electron system is simply \( 2\omega \).

The unperturbed wave function for the ground state of the two-electron system is given by

$$ \begin{equation*} \Phi(\boldsymbol{r}_1,\boldsymbol{r}_2) = C\exp{\left(-\omega(r_1^2+r_2^2)/2\right)}, \end{equation*} $$

with \( C \) being a normalization constant and \( r_i = \sqrt{r_{i_x}^2+r_{i_y}^2} \). Note that the vector \( \boldsymbol{r}_i \) refers to the \( x \) and \( y \) position for a given particle. What is the total spin of this wave function? Find arguments for why the ground state should have this specific total spin.

Project 2 b):

We want to perform a Variational Monte Carlo calculation of the ground state of two electrons in a quantum dot well with different oscillator energies, assuming total spin \( S=0 \) using the Hamiltonian of Eq. \eqref{eq:finalH}. Our trial wave function which has the following form

$$ \begin{equation} \psi_{T}(\boldsymbol{r}_1,\boldsymbol{r}_2) = C\exp{\left(-\alpha\omega(r_1^2+r_2^2)/2\right)} \exp{\left(\frac{ar_{12}}{(1+\beta r_{12})}\right)}, \label{eq:trial} \end{equation} $$

where \( a \) is equal to one when the two electrons have anti-parallel spins and \( 1/3 \) when the spins are parallel. Finally, \( \alpha \) and \( \beta \) are our variational parameters. Note well the dependence on \( \alpha \) for the single-particle part of the trial function. It is important to remember this when you use higher-order Hermite polynomials. Find the analytical expressions for the local energy.

Project 2 c):

Your task is to perform a Variational Monte Carlo calculation using the Metropolis algorithm to compute the integral

$$ \begin{equation} \langle E \rangle = \frac{\int d\boldsymbol{r}_1d\boldsymbol{r}_2\psi^{\ast}_T(\boldsymbol{r}_1,\boldsymbol{r}_2)\hat{H}(\boldsymbol{r}_1,\boldsymbol{r}_2)\psi_T(\boldsymbol{r}_1,\boldsymbol{r}_2)} {\int d\boldsymbol{r}_1d\boldsymbol{r}_2\psi^{\ast}_T(\boldsymbol{r}_1,\boldsymbol{r}_2)\psi_T(\boldsymbol{r}_1,\boldsymbol{r}_2)}. \label{_auto1} \end{equation} $$

Compute the expectation value of the energy using both the analytical expression for the local energy and numerical derivation of the kinetic energy. Compare the time usage between the two approaches. Perform these calculations without importance sampling and also without the Jastrow factor. For the calculations without the Jastrow factor and repulsive Coulomb potential, your energy should equal 2.0 a.u. and your variance should be exactly equal to zero.

Project 2 d):

Add now importance sampling and repeat the calculations from the previous exercise but use only the analytical expression for the local energy. Perform also a blocking analysis in order to obtain the optimal standard deviation. Compare your results with the those without importance sampling and comment your results.

Project 2 e):

Using either the steepest descent method or the conjugate gradient method, find the optimal variational parameters and perform your Monte Carlo calculations using these. In addition, you should parallelize your program using MPI and set it up to run on Smaug.

Project 2 f):

Finally, we wil now analyze and interpret our results for the two-electron systems. Find the energy minimum and discuss your results compared with the analytical solution from Taut's work, see reference [1] below. Compute also the mean distance \( r_{12}=\vert \boldsymbol{r}_1-\boldsymbol{r}_2\vert \) (with \( r_i = \sqrt{r_{i_x}^2+r_{i_y}^2} \)) between the two electrons for the optimal set of the variational parameters. With the optimal parameters for the ground state wave function, compute the onebody density. Discuss your results and compare the results with those obtained with a pure harmonic oscillator wave functions. Run a Monte Carlo calculations without the Jastrow factor as well and compute the same quantities. How important are the correlations induced by the Jastrow factor? Compute also the expectation value of the kinetic energy and potential energy using \( \omega=0.01 \), \( \omega=0.05 \), \( \omega=0.1 \), \( \omega=0.5 \) and \( \omega=1.0 \). Comment your results. Hint, think of the virial theorem.

Project 2 g):

The previous exercises have prepared you for extending your calculational machinery to other systems. Here we will focus on quantum dots with \( N=6 \) and \( N=12 \) electrons.

The new item you need to pay attention to is the calculation of the Slater Determinant. This is an additional complication to your VMC calculations. If we stick to harmonic oscillator like wave functions, the trial wave function for say an \( N=6 \) electron quantum dot can be written as

$$ \begin{equation} \psi_{T}(\boldsymbol{r}_1,\boldsymbol{r}_2,\dots, \boldsymbol{r}_6) = Det\left(\phi_{1}(\boldsymbol{r}_1),\phi_{2}(\boldsymbol{r}_2), \dots,\phi_{6}(\boldsymbol{r}_6)\right) \prod_{i < j}^{6}\exp{\left(\frac{a r_{ij}}{(1+\beta r_{ij})}\right)}, \label{_auto2} \end{equation} $$

where \( Det \) is a Slater determinant and the single-particle wave functions are the harmonic oscillator wave functions for the \( n_x=0,1 \) and \( n_y=0,1 \) orbitals. Similarly, for the \( N=12 \) quantum dot, the trial wave function can take the form

$$ \begin{equation} \psi_{T}(\boldsymbol{r}_1,\boldsymbol{r}_2, \dots,\boldsymbol{r}_{12}) = Det\left(\phi_{1}(\boldsymbol{r}_1),\phi_{2}(\boldsymbol{r}_2), \dots,\phi_{12}(\boldsymbol{r}_{12})\right) \prod_{i < j}^{12}\exp{\left(\frac{ar_{ij}}{(1+\beta r_{ij})}\right)}, \label{_auto3} \end{equation} $$

In this case you need to include the \( n_x=2 \) and \( n_y=2 \) wave functions as well. Observe that \( r_i = \sqrt{r_{i_x}^2+r_{i_y}^2} \). Use the Hermite polynomials defined in project 1. Reference [5] gives benchmark results for closed-shell systems up to \( N=20 \).

Write a function which sets up the Slater determinant. Find the Hermite polynomials which are needed for \( n_x=0,1,2 \) and obviously \( n_y \) as well. Compare the results you obtain with those from project 1. Compute the ground state energies of quantum dots for \( N=6 \) and \( N=12 \) electrons, following the same set up as in the previous exercises for \( \omega=0.01 \), \( \omega=0.05 \), \( \omega=0.1 \), \( \omega=0.5 \), and \( \omega=1.0 \). The calculations should include parallelization, blocking, importance sampling and energy minimization using the conjugate gradient approach or similar approaches. To test your Slater determinant code, you should reproduce the unperturbed single-particle energies when the electron-electron repulsion is switched off. Convince yourself that the unperturbed ground state energies for \( N=6 \) is \( 10\omega \) and for \( N=12 \) we obtain \( 28\omega \). What is the expected total spin of the ground states?

Project 2 h):

With the optimal parameters for the ground state wave function, compute again the onebody density. Discuss your results and compare the results with those obtained with a pure harmonic oscillator wave functions. Run a Monte Carlo calculations without the Jastrow factor as well and compute the same quantities. How important are the correlations induced by the Jastrow factor? Compute also the expectation value of the kinetic energy and potential energy using \( \omega=0.01 \), \( \omega=0.05 \), \( \omega=0.1 \), \( \omega=0.5 \), and \( \omega=1.0 \). Comment your results.

Project 2 i):

The last exercise is a performance analysis of your code(s) for the case of \( N=6 \) electrons. Make a performance analysis by timing your serial code with and without vectorization. Perform several runs with the same number of Monte carlo cycles and compute an average timing analysis with and without vectorization. Comment your results. Use at least \( 10^6 \) Monte Carlo samples.

Compare thereafter your serial code(s) with the speedup you get by parallelizing your code, running either OpenMP or MPI or both. Do you get a near \( 100\% \) speedup with the parallel version? Comment again your results and perform timing benchmarks several times in order to extract an average performance time.

Literature

  1. M. Taut, Phys. Rev. A 48, 3561 - 3566 (1993).
  2. B. L. Hammond, W. A. Lester and P. J. Reynolds, Monte Carlo methods in Ab Initio Quantum Chemistry, World Scientific, Singapore, 1994, chapters 2-5 and appendix B.
  3. B. H. Bransden and C. J. Joachain, Physics of Atoms and molecules, Longman, 1986. Chapters 6, 7 and 9.
  4. A. K. Rajagopal and J. C. Kimball, see Phys. Rev. B 15, 2819 (1977).
  5. M. L. Pedersen, G. Hagen, M. Hjorth-Jensen, S. Kvaal, and F. Pederiva, Phys. Rev. B 84, 115302 (2011)

Introduction to numerical projects

Here follows a brief recipe and recommendation on how to write a report for each project.

Format for electronic delivery of report and programs

The preferred format for the report is a PDF file. You can also use DOC or postscript formats or as an ipython notebook file. As programming language we prefer that you choose between C/C++, Fortran2008 or Python. The following prescription should be followed when preparing the report:

Finally, we encourage you to work two and two together. Optimal working groups consist of 2-3 students. You can then hand in a common report.

© 1999-2023, "Computational Physics II FYS4411/FYS9411":"http://www.uio.no/studier/emner/matnat/fys/FYS4411/index-eng.html". Released under CC Attribution-NonCommercial 4.0 license