mirror of
https://github.com/TREX-CoE/qmc-lttc.git
synced 2025-01-03 01:56:20 +01:00
deploy: f40a737b96
This commit is contained in:
parent
18d529e80c
commit
6c5f51527e
407
index.html
407
index.html
@ -3,7 +3,7 @@
|
|||||||
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
||||||
<head>
|
<head>
|
||||||
<!-- 2021-02-02 Tue 16:05 -->
|
<!-- 2021-02-02 Tue 21:49 -->
|
||||||
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
<title>Quantum Monte Carlo</title>
|
<title>Quantum Monte Carlo</title>
|
||||||
@ -329,153 +329,153 @@ for the JavaScript code in this tag.
|
|||||||
<h2>Table of Contents</h2>
|
<h2>Table of Contents</h2>
|
||||||
<div id="text-table-of-contents">
|
<div id="text-table-of-contents">
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgf35fcfa">1. Introduction</a>
|
<li><a href="#org23a1413">1. Introduction</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgff4a500">1.1. Energy and local energy</a></li>
|
<li><a href="#org705f291">1.1. Energy and local energy</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#orge5391c1">2. Numerical evaluation of the energy of the hydrogen atom</a>
|
<li><a href="#org39b8649">2. Numerical evaluation of the energy of the hydrogen atom</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgc557da6">2.1. Local energy</a>
|
<li><a href="#org64bc099">2.1. Local energy</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orga4e6b54">2.1.1. Exercise 1</a>
|
<li><a href="#org957f24b">2.1.1. Exercise 1</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org801cff3">2.1.1.1. Solution</a></li>
|
<li><a href="#org00d98c2">2.1.1.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org4677e85">2.1.2. Exercise 2</a>
|
<li><a href="#org0803c94">2.1.2. Exercise 2</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgbc257d9">2.1.2.1. Solution</a></li>
|
<li><a href="#org20ccc64">2.1.2.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#orgc8a1a2b">2.1.3. Exercise 3</a>
|
<li><a href="#orgab4e595">2.1.3. Exercise 3</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org46a48e1">2.1.3.1. Solution</a></li>
|
<li><a href="#org25b6eae">2.1.3.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org49b162e">2.1.4. Exercise 4</a>
|
<li><a href="#org06544d4">2.1.4. Exercise 4</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org11b7ba8">2.1.4.1. Solution</a></li>
|
<li><a href="#org044a7e2">2.1.4.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#orgea20a4d">2.1.5. Exercise 5</a>
|
<li><a href="#orgba0d5bf">2.1.5. Exercise 5</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orga8ca1f7">2.1.5.1. Solution</a></li>
|
<li><a href="#orgdbac137">2.1.5.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org1aceedb">2.2. Plot of the local energy along the \(x\) axis</a>
|
<li><a href="#orgf55ff90">2.2. Plot of the local energy along the \(x\) axis</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgfdfeaeb">2.2.1. Exercise</a>
|
<li><a href="#org0c2d915">2.2.1. Exercise</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org7b8e758">2.2.1.1. Solution</a></li>
|
<li><a href="#org12d0a95">2.2.1.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#orgb878d1c">2.3. Numerical estimation of the energy</a>
|
<li><a href="#org28ecc47">2.3. Numerical estimation of the energy</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orga3c04f6">2.3.1. Exercise</a>
|
<li><a href="#org21ff2e3">2.3.1. Exercise</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org3ff01c5">2.3.1.1. Solution</a></li>
|
<li><a href="#orgfa5b635">2.3.1.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org61a9a5a">2.4. Variance of the local energy</a>
|
<li><a href="#org3357076">2.4. Variance of the local energy</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org3a9cd19">2.4.1. Exercise (optional)</a>
|
<li><a href="#org65d3fe0">2.4.1. Exercise (optional)</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orge49d691">2.4.1.1. Solution</a></li>
|
<li><a href="#org4209e53">2.4.1.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#orgc95b8fc">2.4.2. Exercise</a>
|
<li><a href="#org22a1d92">2.4.2. Exercise</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org0cf5abe">2.4.2.1. Solution</a></li>
|
<li><a href="#orgf7c310b">2.4.2.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org03c7717">3. Variational Monte Carlo</a>
|
<li><a href="#orgc1159c2">3. Variational Monte Carlo</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org7092837">3.1. Computation of the statistical error</a>
|
<li><a href="#orgf056ac8">3.1. Computation of the statistical error</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgd7c44e9">3.1.1. Exercise</a>
|
<li><a href="#org98dc313">3.1.1. Exercise</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org7408e00">3.1.1.1. Solution</a></li>
|
<li><a href="#org2405a78">3.1.1.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org05b64e8">3.2. Uniform sampling in the box</a>
|
<li><a href="#org83cdcfd">3.2. Uniform sampling in the box</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org5169b03">3.2.1. Exercise</a>
|
<li><a href="#org8d3b2eb">3.2.1. Exercise</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org57eabbc">3.2.1.1. Solution</a></li>
|
<li><a href="#org9f00468">3.2.1.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org4ee2da0">3.3. Metropolis sampling with \(\Psi^2\)</a>
|
<li><a href="#orgd33cfda">3.3. Metropolis sampling with \(\Psi^2\)</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org521c913">3.3.1. Optimal step size</a></li>
|
<li><a href="#org81b01e4">3.3.1. Optimal step size</a></li>
|
||||||
<li><a href="#org50b36aa">3.3.2. Exercise</a>
|
<li><a href="#org71a312e">3.3.2. Exercise</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org9783fbe">3.3.2.1. Solution</a></li>
|
<li><a href="#org4dba89d">3.3.2.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#orgf7e192c">3.4. Generalized Metropolis algorithm</a>
|
<li><a href="#org9a41389">3.4. Generalized Metropolis algorithm</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org868c86a">3.4.1. Gaussian random number generator</a></li>
|
<li><a href="#org267d6c4">3.4.1. Gaussian random number generator</a></li>
|
||||||
<li><a href="#org3da25b4">3.4.2. Exercise 1</a>
|
<li><a href="#org3a1bc00">3.4.2. Exercise 1</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgdaf9219">3.4.2.1. Solution</a></li>
|
<li><a href="#orgbedbe5e">3.4.2.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org5a4e90b">3.4.3. Exercise 2</a>
|
<li><a href="#orgd524514">3.4.3. Exercise 2</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgb2b31bc">3.4.3.1. Solution</a></li>
|
<li><a href="#orgd930b45">3.4.3.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#orgefd778a">4. Diffusion Monte Carlo</a>
|
<li><a href="#orgd485152">4. Diffusion Monte Carlo</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org481ff44">4.1. Schrödinger equation in imaginary time</a></li>
|
<li><a href="#org1b239e1">4.1. Schrödinger equation in imaginary time</a></li>
|
||||||
<li><a href="#orgc28941f">4.2. Diffusion and branching</a></li>
|
<li><a href="#org3dbb265">4.2. Relation to diffusion</a></li>
|
||||||
<li><a href="#org19f6b36">4.3. Importance sampling</a>
|
<li><a href="#org295d821">4.3. Importance sampling</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#orgd63eaab">4.3.1. Appendix : Details of the Derivation</a></li>
|
<li><a href="#orgd2e16c4">4.3.1. Appendix : Details of the Derivation</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org498bc42">4.4. Pure Diffusion Monte Carlo (PDMC)</a></li>
|
<li><a href="#org929363f">4.4. Pure Diffusion Monte Carlo (PDMC)</a></li>
|
||||||
<li><a href="#org82aee19">4.5. Hydrogen atom</a>
|
<li><a href="#orgc31115c">4.5. Hydrogen atom</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org28fd5e4">4.5.1. Exercise</a>
|
<li><a href="#org5a87685">4.5.1. Exercise</a>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="#org89b211a">4.5.1.1. Solution</a></li>
|
<li><a href="#orgb894c1f">4.5.1.1. Solution</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#org3cb42a6">4.6. <span class="todo TODO">TODO</span> H<sub>2</sub></a></li>
|
<li><a href="#orgecf180f">4.6. <span class="todo TODO">TODO</span> H<sub>2</sub></a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#orgb2c8cf6">5. <span class="todo TODO">TODO</span> <code>[0/3]</code> Last things to do</a></li>
|
<li><a href="#org3878dc4">5. <span class="todo TODO">TODO</span> <code>[0/3]</code> Last things to do</a></li>
|
||||||
<li><a href="#org43d0643">6. Schedule</a></li>
|
<li><a href="#org6887311">6. Schedule</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgf35fcfa" class="outline-2">
|
<div id="outline-container-org23a1413" class="outline-2">
|
||||||
<h2 id="orgf35fcfa"><span class="section-number-2">1</span> Introduction</h2>
|
<h2 id="org23a1413"><span class="section-number-2">1</span> Introduction</h2>
|
||||||
<div class="outline-text-2" id="text-1">
|
<div class="outline-text-2" id="text-1">
|
||||||
<p>
|
<p>
|
||||||
This website contains the QMC tutorial of the 2021 LTTC winter school
|
This website contains the QMC tutorial of the 2021 LTTC winter school
|
||||||
@ -515,8 +515,8 @@ coordinates, etc).
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgff4a500" class="outline-3">
|
<div id="outline-container-org705f291" class="outline-3">
|
||||||
<h3 id="orgff4a500"><span class="section-number-3">1.1</span> Energy and local energy</h3>
|
<h3 id="org705f291"><span class="section-number-3">1.1</span> Energy and local energy</h3>
|
||||||
<div class="outline-text-3" id="text-1-1">
|
<div class="outline-text-3" id="text-1-1">
|
||||||
<p>
|
<p>
|
||||||
For a given system with Hamiltonian \(\hat{H}\) and wave function \(\Psi\), we define the local energy as
|
For a given system with Hamiltonian \(\hat{H}\) and wave function \(\Psi\), we define the local energy as
|
||||||
@ -599,8 +599,8 @@ energy computed over these configurations:
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orge5391c1" class="outline-2">
|
<div id="outline-container-org39b8649" class="outline-2">
|
||||||
<h2 id="orge5391c1"><span class="section-number-2">2</span> Numerical evaluation of the energy of the hydrogen atom</h2>
|
<h2 id="org39b8649"><span class="section-number-2">2</span> Numerical evaluation of the energy of the hydrogen atom</h2>
|
||||||
<div class="outline-text-2" id="text-2">
|
<div class="outline-text-2" id="text-2">
|
||||||
<p>
|
<p>
|
||||||
In this section, we consider the hydrogen atom with the following
|
In this section, we consider the hydrogen atom with the following
|
||||||
@ -629,8 +629,8 @@ To do that, we will compute the local energy and check whether it is constant.
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgc557da6" class="outline-3">
|
<div id="outline-container-org64bc099" class="outline-3">
|
||||||
<h3 id="orgc557da6"><span class="section-number-3">2.1</span> Local energy</h3>
|
<h3 id="org64bc099"><span class="section-number-3">2.1</span> Local energy</h3>
|
||||||
<div class="outline-text-3" id="text-2-1">
|
<div class="outline-text-3" id="text-2-1">
|
||||||
<p>
|
<p>
|
||||||
You will now program all quantities needed to compute the local energy of the H atom for the given wave function.
|
You will now program all quantities needed to compute the local energy of the H atom for the given wave function.
|
||||||
@ -657,8 +657,8 @@ to catch the error.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orga4e6b54" class="outline-4">
|
<div id="outline-container-org957f24b" class="outline-4">
|
||||||
<h4 id="orga4e6b54"><span class="section-number-4">2.1.1</span> Exercise 1</h4>
|
<h4 id="org957f24b"><span class="section-number-4">2.1.1</span> Exercise 1</h4>
|
||||||
<div class="outline-text-4" id="text-2-1-1">
|
<div class="outline-text-4" id="text-2-1-1">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -703,8 +703,8 @@ and returns the potential.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org801cff3" class="outline-5">
|
<div id="outline-container-org00d98c2" class="outline-5">
|
||||||
<h5 id="org801cff3"><span class="section-number-5">2.1.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org00d98c2"><span class="section-number-5">2.1.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-1-1-1">
|
<div class="outline-text-5" id="text-2-1-1-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -745,8 +745,8 @@ and returns the potential.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org4677e85" class="outline-4">
|
<div id="outline-container-org0803c94" class="outline-4">
|
||||||
<h4 id="org4677e85"><span class="section-number-4">2.1.2</span> Exercise 2</h4>
|
<h4 id="org0803c94"><span class="section-number-4">2.1.2</span> Exercise 2</h4>
|
||||||
<div class="outline-text-4" id="text-2-1-2">
|
<div class="outline-text-4" id="text-2-1-2">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -781,8 +781,8 @@ input arguments, and returns a scalar.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgbc257d9" class="outline-5">
|
<div id="outline-container-org20ccc64" class="outline-5">
|
||||||
<h5 id="orgbc257d9"><span class="section-number-5">2.1.2.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org20ccc64"><span class="section-number-5">2.1.2.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-1-2-1">
|
<div class="outline-text-5" id="text-2-1-2-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -809,8 +809,8 @@ input arguments, and returns a scalar.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgc8a1a2b" class="outline-4">
|
<div id="outline-container-orgab4e595" class="outline-4">
|
||||||
<h4 id="orgc8a1a2b"><span class="section-number-4">2.1.3</span> Exercise 3</h4>
|
<h4 id="orgab4e595"><span class="section-number-4">2.1.3</span> Exercise 3</h4>
|
||||||
<div class="outline-text-4" id="text-2-1-3">
|
<div class="outline-text-4" id="text-2-1-3">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -891,8 +891,8 @@ Therefore, the local kinetic energy is
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org46a48e1" class="outline-5">
|
<div id="outline-container-org25b6eae" class="outline-5">
|
||||||
<h5 id="org46a48e1"><span class="section-number-5">2.1.3.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org25b6eae"><span class="section-number-5">2.1.3.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-1-3-1">
|
<div class="outline-text-5" id="text-2-1-3-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -933,8 +933,8 @@ Therefore, the local kinetic energy is
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org49b162e" class="outline-4">
|
<div id="outline-container-org06544d4" class="outline-4">
|
||||||
<h4 id="org49b162e"><span class="section-number-4">2.1.4</span> Exercise 4</h4>
|
<h4 id="org06544d4"><span class="section-number-4">2.1.4</span> Exercise 4</h4>
|
||||||
<div class="outline-text-4" id="text-2-1-4">
|
<div class="outline-text-4" id="text-2-1-4">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -993,8 +993,8 @@ are calling is yours.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org11b7ba8" class="outline-5">
|
<div id="outline-container-org044a7e2" class="outline-5">
|
||||||
<h5 id="org11b7ba8"><span class="section-number-5">2.1.4.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org044a7e2"><span class="section-number-5">2.1.4.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-1-4-1">
|
<div class="outline-text-5" id="text-2-1-4-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -1025,8 +1025,8 @@ are calling is yours.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgea20a4d" class="outline-4">
|
<div id="outline-container-orgba0d5bf" class="outline-4">
|
||||||
<h4 id="orgea20a4d"><span class="section-number-4">2.1.5</span> Exercise 5</h4>
|
<h4 id="orgba0d5bf"><span class="section-number-4">2.1.5</span> Exercise 5</h4>
|
||||||
<div class="outline-text-4" id="text-2-1-5">
|
<div class="outline-text-4" id="text-2-1-5">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -1036,8 +1036,8 @@ Find the theoretical value of \(a\) for which \(\Psi\) is an eigenfunction of \(
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orga8ca1f7" class="outline-5">
|
<div id="outline-container-orgdbac137" class="outline-5">
|
||||||
<h5 id="orga8ca1f7"><span class="section-number-5">2.1.5.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="orgdbac137"><span class="section-number-5">2.1.5.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-1-5-1">
|
<div class="outline-text-5" id="text-2-1-5-1">
|
||||||
\begin{eqnarray*}
|
\begin{eqnarray*}
|
||||||
E &=& \frac{\hat{H} \Psi}{\Psi} = - \frac{1}{2} \frac{\Delta \Psi}{\Psi} -
|
E &=& \frac{\hat{H} \Psi}{\Psi} = - \frac{1}{2} \frac{\Delta \Psi}{\Psi} -
|
||||||
@ -1057,8 +1057,8 @@ equal to -0.5 atomic units.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org1aceedb" class="outline-3">
|
<div id="outline-container-orgf55ff90" class="outline-3">
|
||||||
<h3 id="org1aceedb"><span class="section-number-3">2.2</span> Plot of the local energy along the \(x\) axis</h3>
|
<h3 id="orgf55ff90"><span class="section-number-3">2.2</span> Plot of the local energy along the \(x\) axis</h3>
|
||||||
<div class="outline-text-3" id="text-2-2">
|
<div class="outline-text-3" id="text-2-2">
|
||||||
<p>
|
<p>
|
||||||
The program you will write in this section will be written in
|
The program you will write in this section will be written in
|
||||||
@ -1089,8 +1089,8 @@ In Fortran, you will need to compile all the source files together:
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgfdfeaeb" class="outline-4">
|
<div id="outline-container-org0c2d915" class="outline-4">
|
||||||
<h4 id="orgfdfeaeb"><span class="section-number-4">2.2.1</span> Exercise</h4>
|
<h4 id="org0c2d915"><span class="section-number-4">2.2.1</span> Exercise</h4>
|
||||||
<div class="outline-text-4" id="text-2-2-1">
|
<div class="outline-text-4" id="text-2-2-1">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -1184,8 +1184,8 @@ plot './data' index 0 using 1:2 with lines title 'a=0.1', \
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org7b8e758" class="outline-5">
|
<div id="outline-container-org12d0a95" class="outline-5">
|
||||||
<h5 id="org7b8e758"><span class="section-number-5">2.2.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org12d0a95"><span class="section-number-5">2.2.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-2-1-1">
|
<div class="outline-text-5" id="text-2-2-1-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -1262,8 +1262,8 @@ plt.savefig(<span style="color: #8b2252;">"plot_py.png"</span>)
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgb878d1c" class="outline-3">
|
<div id="outline-container-org28ecc47" class="outline-3">
|
||||||
<h3 id="orgb878d1c"><span class="section-number-3">2.3</span> Numerical estimation of the energy</h3>
|
<h3 id="org28ecc47"><span class="section-number-3">2.3</span> Numerical estimation of the energy</h3>
|
||||||
<div class="outline-text-3" id="text-2-3">
|
<div class="outline-text-3" id="text-2-3">
|
||||||
<p>
|
<p>
|
||||||
If the space is discretized in small volume elements \(\mathbf{r}_i\)
|
If the space is discretized in small volume elements \(\mathbf{r}_i\)
|
||||||
@ -1293,8 +1293,8 @@ The energy is biased because:
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="outline-container-orga3c04f6" class="outline-4">
|
<div id="outline-container-org21ff2e3" class="outline-4">
|
||||||
<h4 id="orga3c04f6"><span class="section-number-4">2.3.1</span> Exercise</h4>
|
<h4 id="org21ff2e3"><span class="section-number-4">2.3.1</span> Exercise</h4>
|
||||||
<div class="outline-text-4" id="text-2-3-1">
|
<div class="outline-text-4" id="text-2-3-1">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -1365,8 +1365,8 @@ To compile the Fortran and run it:
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org3ff01c5" class="outline-5">
|
<div id="outline-container-orgfa5b635" class="outline-5">
|
||||||
<h5 id="org3ff01c5"><span class="section-number-5">2.3.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="orgfa5b635"><span class="section-number-5">2.3.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-3-1-1">
|
<div class="outline-text-5" id="text-2-3-1-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -1483,8 +1483,8 @@ a = 2.0000000000000000 E = -8.0869806678448772E-002
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org61a9a5a" class="outline-3">
|
<div id="outline-container-org3357076" class="outline-3">
|
||||||
<h3 id="org61a9a5a"><span class="section-number-3">2.4</span> Variance of the local energy</h3>
|
<h3 id="org3357076"><span class="section-number-3">2.4</span> Variance of the local energy</h3>
|
||||||
<div class="outline-text-3" id="text-2-4">
|
<div class="outline-text-3" id="text-2-4">
|
||||||
<p>
|
<p>
|
||||||
The variance of the local energy is a functional of \(\Psi\)
|
The variance of the local energy is a functional of \(\Psi\)
|
||||||
@ -1511,8 +1511,8 @@ energy can be used as a measure of the quality of a wave function.
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org3a9cd19" class="outline-4">
|
<div id="outline-container-org65d3fe0" class="outline-4">
|
||||||
<h4 id="org3a9cd19"><span class="section-number-4">2.4.1</span> Exercise (optional)</h4>
|
<h4 id="org65d3fe0"><span class="section-number-4">2.4.1</span> Exercise (optional)</h4>
|
||||||
<div class="outline-text-4" id="text-2-4-1">
|
<div class="outline-text-4" id="text-2-4-1">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -1523,8 +1523,8 @@ Prove that :
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orge49d691" class="outline-5">
|
<div id="outline-container-org4209e53" class="outline-5">
|
||||||
<h5 id="orge49d691"><span class="section-number-5">2.4.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org4209e53"><span class="section-number-5">2.4.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-4-1-1">
|
<div class="outline-text-5" id="text-2-4-1-1">
|
||||||
<p>
|
<p>
|
||||||
\(\bar{E} = \langle E \rangle\) is a constant, so \(\langle \bar{E}
|
\(\bar{E} = \langle E \rangle\) is a constant, so \(\langle \bar{E}
|
||||||
@ -1543,8 +1543,8 @@ Prove that :
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div id="outline-container-orgc95b8fc" class="outline-4">
|
<div id="outline-container-org22a1d92" class="outline-4">
|
||||||
<h4 id="orgc95b8fc"><span class="section-number-4">2.4.2</span> Exercise</h4>
|
<h4 id="org22a1d92"><span class="section-number-4">2.4.2</span> Exercise</h4>
|
||||||
<div class="outline-text-4" id="text-2-4-2">
|
<div class="outline-text-4" id="text-2-4-2">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -1620,8 +1620,8 @@ To compile and run:
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org0cf5abe" class="outline-5">
|
<div id="outline-container-orgf7c310b" class="outline-5">
|
||||||
<h5 id="org0cf5abe"><span class="section-number-5">2.4.2.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="orgf7c310b"><span class="section-number-5">2.4.2.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-2-4-2-1">
|
<div class="outline-text-5" id="text-2-4-2-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -1760,8 +1760,8 @@ a = 2.0000000000000000 E = -8.0869806678448772E-002 s2 = 1.8068814
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org03c7717" class="outline-2">
|
<div id="outline-container-orgc1159c2" class="outline-2">
|
||||||
<h2 id="org03c7717"><span class="section-number-2">3</span> Variational Monte Carlo</h2>
|
<h2 id="orgc1159c2"><span class="section-number-2">3</span> Variational Monte Carlo</h2>
|
||||||
<div class="outline-text-2" id="text-3">
|
<div class="outline-text-2" id="text-3">
|
||||||
<p>
|
<p>
|
||||||
Numerical integration with deterministic methods is very efficient
|
Numerical integration with deterministic methods is very efficient
|
||||||
@ -1777,8 +1777,8 @@ interval.
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org7092837" class="outline-3">
|
<div id="outline-container-orgf056ac8" class="outline-3">
|
||||||
<h3 id="org7092837"><span class="section-number-3">3.1</span> Computation of the statistical error</h3>
|
<h3 id="orgf056ac8"><span class="section-number-3">3.1</span> Computation of the statistical error</h3>
|
||||||
<div class="outline-text-3" id="text-3-1">
|
<div class="outline-text-3" id="text-3-1">
|
||||||
<p>
|
<p>
|
||||||
To compute the statistical error, you need to perform \(M\)
|
To compute the statistical error, you need to perform \(M\)
|
||||||
@ -1818,8 +1818,8 @@ And the confidence interval is given by
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgd7c44e9" class="outline-4">
|
<div id="outline-container-org98dc313" class="outline-4">
|
||||||
<h4 id="orgd7c44e9"><span class="section-number-4">3.1.1</span> Exercise</h4>
|
<h4 id="org98dc313"><span class="section-number-4">3.1.1</span> Exercise</h4>
|
||||||
<div class="outline-text-4" id="text-3-1-1">
|
<div class="outline-text-4" id="text-3-1-1">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -1859,8 +1859,8 @@ input array.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org7408e00" class="outline-5">
|
<div id="outline-container-org2405a78" class="outline-5">
|
||||||
<h5 id="org7408e00"><span class="section-number-5">3.1.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org2405a78"><span class="section-number-5">3.1.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-3-1-1-1">
|
<div class="outline-text-5" id="text-3-1-1-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -1921,8 +1921,8 @@ input array.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org05b64e8" class="outline-3">
|
<div id="outline-container-org83cdcfd" class="outline-3">
|
||||||
<h3 id="org05b64e8"><span class="section-number-3">3.2</span> Uniform sampling in the box</h3>
|
<h3 id="org83cdcfd"><span class="section-number-3">3.2</span> Uniform sampling in the box</h3>
|
||||||
<div class="outline-text-3" id="text-3-2">
|
<div class="outline-text-3" id="text-3-2">
|
||||||
<p>
|
<p>
|
||||||
We will now perform our first Monte Carlo calculation to compute the
|
We will now perform our first Monte Carlo calculation to compute the
|
||||||
@ -1983,8 +1983,8 @@ compute the statistical error.
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org5169b03" class="outline-4">
|
<div id="outline-container-org8d3b2eb" class="outline-4">
|
||||||
<h4 id="org5169b03"><span class="section-number-4">3.2.1</span> Exercise</h4>
|
<h4 id="org8d3b2eb"><span class="section-number-4">3.2.1</span> Exercise</h4>
|
||||||
<div class="outline-text-4" id="text-3-2-1">
|
<div class="outline-text-4" id="text-3-2-1">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -2086,8 +2086,8 @@ well as the index of the current step.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org57eabbc" class="outline-5">
|
<div id="outline-container-org9f00468" class="outline-5">
|
||||||
<h5 id="org57eabbc"><span class="section-number-5">3.2.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org9f00468"><span class="section-number-5">3.2.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-3-2-1-1">
|
<div class="outline-text-5" id="text-3-2-1-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -2193,8 +2193,8 @@ E = -0.48084122147238995 +/- 2.4983775878329355E-003
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org4ee2da0" class="outline-3">
|
<div id="outline-container-orgd33cfda" class="outline-3">
|
||||||
<h3 id="org4ee2da0"><span class="section-number-3">3.3</span> Metropolis sampling with \(\Psi^2\)</h3>
|
<h3 id="orgd33cfda"><span class="section-number-3">3.3</span> Metropolis sampling with \(\Psi^2\)</h3>
|
||||||
<div class="outline-text-3" id="text-3-3">
|
<div class="outline-text-3" id="text-3-3">
|
||||||
<p>
|
<p>
|
||||||
We will now use the square of the wave function to sample random
|
We will now use the square of the wave function to sample random
|
||||||
@ -2313,8 +2313,8 @@ All samples should be kept, from both accepted <i>and</i> rejected moves.
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="outline-container-org521c913" class="outline-4">
|
<div id="outline-container-org81b01e4" class="outline-4">
|
||||||
<h4 id="org521c913"><span class="section-number-4">3.3.1</span> Optimal step size</h4>
|
<h4 id="org81b01e4"><span class="section-number-4">3.3.1</span> Optimal step size</h4>
|
||||||
<div class="outline-text-4" id="text-3-3-1">
|
<div class="outline-text-4" id="text-3-3-1">
|
||||||
<p>
|
<p>
|
||||||
If the box is infinitely small, the ratio will be very close
|
If the box is infinitely small, the ratio will be very close
|
||||||
@ -2349,8 +2349,8 @@ the same variable later on to store a time step.
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="outline-container-org50b36aa" class="outline-4">
|
<div id="outline-container-org71a312e" class="outline-4">
|
||||||
<h4 id="org50b36aa"><span class="section-number-4">3.3.2</span> Exercise</h4>
|
<h4 id="org71a312e"><span class="section-number-4">3.3.2</span> Exercise</h4>
|
||||||
<div class="outline-text-4" id="text-3-3-2">
|
<div class="outline-text-4" id="text-3-3-2">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -2459,8 +2459,8 @@ Can you observe a reduction in the statistical error?
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org9783fbe" class="outline-5">
|
<div id="outline-container-org4dba89d" class="outline-5">
|
||||||
<h5 id="org9783fbe"><span class="section-number-5">3.3.2.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="org4dba89d"><span class="section-number-5">3.3.2.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-3-3-2-1">
|
<div class="outline-text-5" id="text-3-3-2-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -2607,8 +2607,8 @@ A = 0.50762633333333318 +/- 3.4601756760043725E-004
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgf7e192c" class="outline-3">
|
<div id="outline-container-org9a41389" class="outline-3">
|
||||||
<h3 id="orgf7e192c"><span class="section-number-3">3.4</span> Generalized Metropolis algorithm</h3>
|
<h3 id="org9a41389"><span class="section-number-3">3.4</span> Generalized Metropolis algorithm</h3>
|
||||||
<div class="outline-text-3" id="text-3-4">
|
<div class="outline-text-3" id="text-3-4">
|
||||||
<p>
|
<p>
|
||||||
One can use more efficient numerical schemes to move the electrons by choosing a smarter expression for the transition probability.
|
One can use more efficient numerical schemes to move the electrons by choosing a smarter expression for the transition probability.
|
||||||
@ -2729,8 +2729,8 @@ The algorithm of the previous exercise is only slighlty modified as:
|
|||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org868c86a" class="outline-4">
|
<div id="outline-container-org267d6c4" class="outline-4">
|
||||||
<h4 id="org868c86a"><span class="section-number-4">3.4.1</span> Gaussian random number generator</h4>
|
<h4 id="org267d6c4"><span class="section-number-4">3.4.1</span> Gaussian random number generator</h4>
|
||||||
<div class="outline-text-4" id="text-3-4-1">
|
<div class="outline-text-4" id="text-3-4-1">
|
||||||
<p>
|
<p>
|
||||||
To obtain Gaussian-distributed random numbers, you can apply the
|
To obtain Gaussian-distributed random numbers, you can apply the
|
||||||
@ -2794,8 +2794,8 @@ In Python, you can use the <a href="https://numpy.org/doc/stable/reference/rando
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="outline-container-org3da25b4" class="outline-4">
|
<div id="outline-container-org3a1bc00" class="outline-4">
|
||||||
<h4 id="org3da25b4"><span class="section-number-4">3.4.2</span> Exercise 1</h4>
|
<h4 id="org3a1bc00"><span class="section-number-4">3.4.2</span> Exercise 1</h4>
|
||||||
<div class="outline-text-4" id="text-3-4-2">
|
<div class="outline-text-4" id="text-3-4-2">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -2837,8 +2837,8 @@ Write a function to compute the drift vector \(\frac{\nabla \Psi(\mathbf{r})}{\P
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgdaf9219" class="outline-5">
|
<div id="outline-container-orgbedbe5e" class="outline-5">
|
||||||
<h5 id="orgdaf9219"><span class="section-number-5">3.4.2.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="orgbedbe5e"><span class="section-number-5">3.4.2.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-3-4-2-1">
|
<div class="outline-text-5" id="text-3-4-2-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -2871,8 +2871,8 @@ Write a function to compute the drift vector \(\frac{\nabla \Psi(\mathbf{r})}{\P
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org5a4e90b" class="outline-4">
|
<div id="outline-container-orgd524514" class="outline-4">
|
||||||
<h4 id="org5a4e90b"><span class="section-number-4">3.4.3</span> Exercise 2</h4>
|
<h4 id="orgd524514"><span class="section-number-4">3.4.3</span> Exercise 2</h4>
|
||||||
<div class="outline-text-4" id="text-3-4-3">
|
<div class="outline-text-4" id="text-3-4-3">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -2968,8 +2968,8 @@ Modify the previous program to introduce the drift-diffusion scheme.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgb2b31bc" class="outline-5">
|
<div id="outline-container-orgd930b45" class="outline-5">
|
||||||
<h5 id="orgb2b31bc"><span class="section-number-5">3.4.3.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="orgd930b45"><span class="section-number-5">3.4.3.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-3-4-3-1">
|
<div class="outline-text-5" id="text-3-4-3-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -3157,12 +3157,26 @@ A = 0.62037333333333333 +/- 4.8970160591451110E-004
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgefd778a" class="outline-2">
|
<div id="outline-container-orgd485152" class="outline-2">
|
||||||
<h2 id="orgefd778a"><span class="section-number-2">4</span> Diffusion Monte Carlo   <span class="tag"><span class="solution">solution</span></span></h2>
|
<h2 id="orgd485152"><span class="section-number-2">4</span> Diffusion Monte Carlo   <span class="tag"><span class="solution">solution</span></span></h2>
|
||||||
<div class="outline-text-2" id="text-4">
|
<div class="outline-text-2" id="text-4">
|
||||||
|
<p>
|
||||||
|
As we have seen, Variational Monte Carlo is a powerful method to
|
||||||
|
compute integrals in large dimensions. It is often used in cases
|
||||||
|
where the expression of the wave function is such that the integrals
|
||||||
|
can't be evaluated (multi-centered Slater-type orbitals, correlation
|
||||||
|
factors, etc).
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
Diffusion Monte Carlo is different. It goes beyond the computation
|
||||||
|
of the integrals associated with an input wave function, and aims at
|
||||||
|
finding a near-exact numerical solution to the Schrödinger equation.
|
||||||
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div id="outline-container-org481ff44" class="outline-3">
|
|
||||||
<h3 id="org481ff44"><span class="section-number-3">4.1</span> Schrödinger equation in imaginary time</h3>
|
<div id="outline-container-org1b239e1" class="outline-3">
|
||||||
|
<h3 id="org1b239e1"><span class="section-number-3">4.1</span> Schrödinger equation in imaginary time</h3>
|
||||||
<div class="outline-text-3" id="text-4-1">
|
<div class="outline-text-3" id="text-4-1">
|
||||||
<p>
|
<p>
|
||||||
Consider the time-dependent Schrödinger equation:
|
Consider the time-dependent Schrödinger equation:
|
||||||
@ -3230,59 +3244,38 @@ system.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgc28941f" class="outline-3">
|
<div id="outline-container-org3dbb265" class="outline-3">
|
||||||
<h3 id="orgc28941f"><span class="section-number-3">4.2</span> Diffusion and branching</h3>
|
<h3 id="org3dbb265"><span class="section-number-3">4.2</span> Relation to diffusion</h3>
|
||||||
<div class="outline-text-3" id="text-4-2">
|
<div class="outline-text-3" id="text-4-2">
|
||||||
<p>
|
<p>
|
||||||
The imaginary-time Schrödinger equation can be explicitly written in terms of the kinetic and
|
The <a href="https://en.wikipedia.org/wiki/Diffusion_equation">diffusion equation</a> of particles is given by
|
||||||
potential energies as
|
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
\[
|
\[
|
||||||
\frac{\partial \psi(\mathbf{r}, \tau)}{\partial \tau} = \left(\frac{1}{2}\Delta - [V(\mathbf{r}) -E_{\rm ref}]\right) \psi(\mathbf{r}, \tau)\,.
|
\frac{\partial \psi(\mathbf{r},t)}{\partial t} = D\, \Delta \psi(\mathbf{r},t)
|
||||||
\]
|
\]
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
We can simulate this differential equation as a diffusion-branching process.
|
where \(D\) is the diffusion coefficient. When the imaginary-time
|
||||||
</p>
|
Schrödinger equation is written in terms of the kinetic energy and
|
||||||
|
potential,
|
||||||
|
|
||||||
<p>
|
|
||||||
To see this, recall that the <a href="https://en.wikipedia.org/wiki/Diffusion_equation">diffusion equation</a> of particles is given by
|
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
\[
|
\[
|
||||||
\frac{\partial \psi(\mathbf{r},t)}{\partial t} = D\, \Delta \psi(\mathbf{r},t).
|
\frac{\partial \psi(\mathbf{r}, \tau)}{\partial \tau} =
|
||||||
|
\left(\frac{1}{2}\Delta - [V(\mathbf{r}) -E_{\rm ref}]\right) \psi(\mathbf{r}, \tau)\,,
|
||||||
\]
|
\]
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
Furthermore, the <a href="https://en.wikipedia.org/wiki/Reaction_rate">rate of reaction</a> \(v\) is the speed at which a chemical reaction
|
it can be identified as the combination of:
|
||||||
takes place. In a solution, the rate is given as a function of the
|
|
||||||
concentration \([A]\) by
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
|
||||||
\[
|
|
||||||
v = \frac{d[A]}{dt},
|
|
||||||
\]
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
|
||||||
where the concentration \([A]\) is proportional to the number of particles.
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
|
||||||
These two equations allow us to interpret the Schrödinger equation
|
|
||||||
in imaginary time as the combination of:
|
|
||||||
</p>
|
</p>
|
||||||
<ul class="org-ul">
|
<ul class="org-ul">
|
||||||
<li>a diffusion equation with a diffusion coefficient \(D=1/2\) for the
|
<li>a diffusion equation (Laplacian)</li>
|
||||||
kinetic energy, and</li>
|
<li>an equation whose solution is an exponential (potential)</li>
|
||||||
<li>a rate equation for the potential.</li>
|
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
@ -3294,16 +3287,12 @@ The diffusion equation can be simulated by a Brownian motion:
|
|||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
where \(\chi\) is a Gaussian random variable, and the rate equation
|
where \(\chi\) is a Gaussian random variable, and the potential term
|
||||||
can be simulated by creating or destroying particles over time (a
|
can be simulated by creating or destroying particles over time (a
|
||||||
so-called branching process).
|
so-called branching process) or by simply considering it as a
|
||||||
|
cumulative multiplicative weight along the diffusion trajectory.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p>
|
|
||||||
In <i>Diffusion Monte Carlo</i> (DMC), one onbtains the ground state of a
|
|
||||||
system by simulating the Schrödinger equation in imaginary time via
|
|
||||||
the combination of a diffusion process and a branching process.
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
We note that the ground-state wave function of a Fermionic system is
|
We note that the ground-state wave function of a Fermionic system is
|
||||||
@ -3319,7 +3308,8 @@ For the systems you will study, this is not an issue:
|
|||||||
|
|
||||||
<ul class="org-ul">
|
<ul class="org-ul">
|
||||||
<li>Hydrogen atom: You only have one electron!</li>
|
<li>Hydrogen atom: You only have one electron!</li>
|
||||||
<li>Two-electron system (\(H_2\) or He): The ground-wave function is antisymmetric in the spin variables but symmetric in the space ones.</li>
|
<li>Two-electron system (\(H_2\) or He): The ground-wave function is
|
||||||
|
antisymmetric in the spin variables but symmetric in the space ones.</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<p>
|
<p>
|
||||||
@ -3328,15 +3318,14 @@ Therefore, in both cases, you are dealing with a "Bosonic" ground state.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org19f6b36" class="outline-3">
|
<div id="outline-container-org295d821" class="outline-3">
|
||||||
<h3 id="org19f6b36"><span class="section-number-3">4.3</span> Importance sampling</h3>
|
<h3 id="org295d821"><span class="section-number-3">4.3</span> Importance sampling</h3>
|
||||||
<div class="outline-text-3" id="text-4-3">
|
<div class="outline-text-3" id="text-4-3">
|
||||||
<p>
|
<p>
|
||||||
In a molecular system, the potential is far from being constant
|
In a molecular system, the potential is far from being constant
|
||||||
and, in fact, diverges at the inter-particle coalescence points. Hence, when the
|
and, in fact, diverges at the inter-particle coalescence points. Hence,
|
||||||
rate equation is simulated, it results in very large fluctuations
|
it results in very large fluctuations of the term associated with
|
||||||
in the numbers of particles, making the calculations impossible in
|
the potental, making the calculations impossible in practice.
|
||||||
practice.
|
|
||||||
Fortunately, if we multiply the Schrödinger equation by a chosen
|
Fortunately, if we multiply the Schrödinger equation by a chosen
|
||||||
<i>trial wave function</i> \(\Psi_T(\mathbf{r})\) (Hartree-Fock, Kohn-Sham
|
<i>trial wave function</i> \(\Psi_T(\mathbf{r})\) (Hartree-Fock, Kohn-Sham
|
||||||
determinant, CI wave function, <i>etc</i>), one obtains
|
determinant, CI wave function, <i>etc</i>), one obtains
|
||||||
@ -3366,8 +3355,8 @@ Defining \(\Pi(\mathbf{r},\tau) = \psi(\mathbf{r},\tau) \Psi_T(\mathbf{r})\), (s
|
|||||||
The new "kinetic energy" can be simulated by the drift-diffusion
|
The new "kinetic energy" can be simulated by the drift-diffusion
|
||||||
scheme presented in the previous section (VMC).
|
scheme presented in the previous section (VMC).
|
||||||
The new "potential" is the local energy, which has smaller fluctuations
|
The new "potential" is the local energy, which has smaller fluctuations
|
||||||
when \(\Psi_T\) gets closer to the exact wave function. This term can be simulated by
|
when \(\Psi_T\) gets closer to the exact wave function.
|
||||||
changing the number of particles according to \(\exp\left[ -\delta t\,
|
This term can be simulated by t particles according to \(\exp\left[ -\delta t\,
|
||||||
\left(E_L(\mathbf{r}) - E_{\rm ref}\right)\right]\)
|
\left(E_L(\mathbf{r}) - E_{\rm ref}\right)\right]\)
|
||||||
where \(E_{\rm ref}\) is the constant we had introduced above, which is adjusted to
|
where \(E_{\rm ref}\) is the constant we had introduced above, which is adjusted to
|
||||||
the running average energy to keep the number of particles
|
the running average energy to keep the number of particles
|
||||||
@ -3425,8 +3414,8 @@ energies computed with the trial wave function.
|
|||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-orgd63eaab" class="outline-4">
|
<div id="outline-container-orgd2e16c4" class="outline-4">
|
||||||
<h4 id="orgd63eaab"><span class="section-number-4">4.3.1</span> Appendix : Details of the Derivation</h4>
|
<h4 id="orgd2e16c4"><span class="section-number-4">4.3.1</span> Appendix : Details of the Derivation</h4>
|
||||||
<div class="outline-text-4" id="text-4-3-1">
|
<div class="outline-text-4" id="text-4-3-1">
|
||||||
<p>
|
<p>
|
||||||
\[
|
\[
|
||||||
@ -3487,8 +3476,8 @@ Defining \(\Pi(\mathbf{r},t) = \psi(\mathbf{r},\tau)
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org498bc42" class="outline-3">
|
<div id="outline-container-org929363f" class="outline-3">
|
||||||
<h3 id="org498bc42"><span class="section-number-3">4.4</span> Pure Diffusion Monte Carlo (PDMC)</h3>
|
<h3 id="org929363f"><span class="section-number-3">4.4</span> Pure Diffusion Monte Carlo (PDMC)</h3>
|
||||||
<div class="outline-text-3" id="text-4-4">
|
<div class="outline-text-3" id="text-4-4">
|
||||||
<p>
|
<p>
|
||||||
Instead of having a variable number of particles to simulate the
|
Instead of having a variable number of particles to simulate the
|
||||||
@ -3564,13 +3553,13 @@ code, so this is what we will do in the next section.
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org82aee19" class="outline-3">
|
<div id="outline-container-orgc31115c" class="outline-3">
|
||||||
<h3 id="org82aee19"><span class="section-number-3">4.5</span> Hydrogen atom</h3>
|
<h3 id="orgc31115c"><span class="section-number-3">4.5</span> Hydrogen atom</h3>
|
||||||
<div class="outline-text-3" id="text-4-5">
|
<div class="outline-text-3" id="text-4-5">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org28fd5e4" class="outline-4">
|
<div id="outline-container-org5a87685" class="outline-4">
|
||||||
<h4 id="org28fd5e4"><span class="section-number-4">4.5.1</span> Exercise</h4>
|
<h4 id="org5a87685"><span class="section-number-4">4.5.1</span> Exercise</h4>
|
||||||
<div class="outline-text-4" id="text-4-5-1">
|
<div class="outline-text-4" id="text-4-5-1">
|
||||||
<div class="exercise">
|
<div class="exercise">
|
||||||
<p>
|
<p>
|
||||||
@ -3669,8 +3658,8 @@ energy of H for any value of \(a\).
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org89b211a" class="outline-5">
|
<div id="outline-container-orgb894c1f" class="outline-5">
|
||||||
<h5 id="org89b211a"><span class="section-number-5">4.5.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
<h5 id="orgb894c1f"><span class="section-number-5">4.5.1.1</span> Solution   <span class="tag"><span class="solution">solution</span></span></h5>
|
||||||
<div class="outline-text-5" id="text-4-5-1-1">
|
<div class="outline-text-5" id="text-4-5-1-1">
|
||||||
<p>
|
<p>
|
||||||
<b>Python</b>
|
<b>Python</b>
|
||||||
@ -3888,8 +3877,8 @@ A = 0.98788066666666663 +/- 7.2889356133441110E-005
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="outline-container-org3cb42a6" class="outline-3">
|
<div id="outline-container-orgecf180f" class="outline-3">
|
||||||
<h3 id="org3cb42a6"><span class="section-number-3">4.6</span> <span class="todo TODO">TODO</span> H<sub>2</sub></h3>
|
<h3 id="orgecf180f"><span class="section-number-3">4.6</span> <span class="todo TODO">TODO</span> H<sub>2</sub></h3>
|
||||||
<div class="outline-text-3" id="text-4-6">
|
<div class="outline-text-3" id="text-4-6">
|
||||||
<p>
|
<p>
|
||||||
We will now consider the H<sub>2</sub> molecule in a minimal basis composed of the
|
We will now consider the H<sub>2</sub> molecule in a minimal basis composed of the
|
||||||
@ -3910,8 +3899,8 @@ the nuclei.
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="outline-container-orgb2c8cf6" class="outline-2">
|
<div id="outline-container-org3878dc4" class="outline-2">
|
||||||
<h2 id="orgb2c8cf6"><span class="section-number-2">5</span> <span class="todo TODO">TODO</span> <code>[0/3]</code> Last things to do</h2>
|
<h2 id="org3878dc4"><span class="section-number-2">5</span> <span class="todo TODO">TODO</span> <code>[0/3]</code> Last things to do</h2>
|
||||||
<div class="outline-text-2" id="text-5">
|
<div class="outline-text-2" id="text-5">
|
||||||
<ul class="org-ul">
|
<ul class="org-ul">
|
||||||
<li class="off"><code>[ ]</code> Give some hints of how much time is required for each section</li>
|
<li class="off"><code>[ ]</code> Give some hints of how much time is required for each section</li>
|
||||||
@ -3925,8 +3914,8 @@ the H\(_2\) molecule at $R$=1.4010 bohr. Answer: 0.17406 a.u.</li>
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="outline-container-org43d0643" class="outline-2">
|
<div id="outline-container-org6887311" class="outline-2">
|
||||||
<h2 id="org43d0643"><span class="section-number-2">6</span> Schedule</h2>
|
<h2 id="org6887311"><span class="section-number-2">6</span> Schedule</h2>
|
||||||
<div class="outline-text-2" id="text-6">
|
<div class="outline-text-2" id="text-6">
|
||||||
<table border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
<table border="2" cellspacing="0" cellpadding="6" rules="groups" frame="hsides">
|
||||||
|
|
||||||
@ -3990,7 +3979,7 @@ the H\(_2\) molecule at $R$=1.4010 bohr. Answer: 0.17406 a.u.</li>
|
|||||||
</div>
|
</div>
|
||||||
<div id="postamble" class="status">
|
<div id="postamble" class="status">
|
||||||
<p class="author">Author: Anthony Scemama, Claudia Filippi</p>
|
<p class="author">Author: Anthony Scemama, Claudia Filippi</p>
|
||||||
<p class="date">Created: 2021-02-02 Tue 16:05</p>
|
<p class="date">Created: 2021-02-02 Tue 21:49</p>
|
||||||
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
<p class="validation"><a href="http://validator.w3.org/check?uri=referer">Validate</a></p>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
|
Loading…
Reference in New Issue
Block a user