diff --git a/doc/pub/week4/html/._week4-bs001.html b/doc/pub/week4/html/._week4-bs001.html index e8f97181..df8a64f5 100644 --- a/doc/pub/week4/html/._week4-bs001.html +++ b/doc/pub/week4/html/._week4-bs001.html @@ -291,8 +291,8 @@

Overview of week 6, diff --git a/doc/pub/week4/html/week4-reveal.html b/doc/pub/week4/html/week4-reveal.html index b867617f..34cf7d0c 100644 --- a/doc/pub/week4/html/week4-reveal.html +++ b/doc/pub/week4/html/week4-reveal.html @@ -211,8 +211,8 @@

Overview of week 6, February 5-9,

diff --git a/doc/pub/week4/html/week4-solarized.html b/doc/pub/week4/html/week4-solarized.html index deaf9462..f48ab72e 100644 --- a/doc/pub/week4/html/week4-solarized.html +++ b/doc/pub/week4/html/week4-solarized.html @@ -266,8 +266,8 @@

Overview of week 6, February 5-9,

diff --git a/doc/pub/week4/html/week4.html b/doc/pub/week4/html/week4.html index 98fc85de..e6c68412 100644 --- a/doc/pub/week4/html/week4.html +++ b/doc/pub/week4/html/week4.html @@ -343,8 +343,8 @@

Overview of week 6, February 5-9,

diff --git a/doc/pub/week4/ipynb/ipynb-week4-src.tar.gz b/doc/pub/week4/ipynb/ipynb-week4-src.tar.gz index cacc39a6..3e81616a 100644 Binary files a/doc/pub/week4/ipynb/ipynb-week4-src.tar.gz and b/doc/pub/week4/ipynb/ipynb-week4-src.tar.gz differ diff --git a/doc/pub/week4/ipynb/week4.ipynb b/doc/pub/week4/ipynb/week4.ipynb index c63e28ad..799aa5ff 100644 --- a/doc/pub/week4/ipynb/week4.ipynb +++ b/doc/pub/week4/ipynb/week4.ipynb @@ -2,8 +2,10 @@ "cells": [ { "cell_type": "markdown", - "id": "ce64a9f7", - "metadata": {}, + "id": "73b04bf5", + "metadata": { + "editable": true + }, "source": [ "\n", @@ -12,8 +14,10 @@ }, { "cell_type": "markdown", - "id": "dabd2f3d", - "metadata": {}, + "id": "2cb54026", + "metadata": { + "editable": true + }, "source": [ "# Week 6: Importance Sampling and Metropolis-Hastings' algorithm\n", "**Morten Hjorth-Jensen Email morten.hjorth-jensen@fys.uio.no**, Department of Physics and Center fo Computing in Science Education, University of Oslo, Oslo, Norway and Department of Physics and Astronomy and Facility for Rare Ion Beams, Michigan State University, East Lansing, Michigan, USA\n", @@ -23,8 +27,10 @@ }, { "cell_type": "markdown", - "id": "8e9af184", - "metadata": {}, + "id": "7509c5f6", + "metadata": { + "editable": true + }, "source": [ "## Overview of week 6, February 5-9, 2024\n", "**Topics.**\n", @@ -37,15 +43,17 @@ "\n", "* These lecture notes\n", "\n", - "* [Video of lecture TBA](https://youtu.be/)\n", + "* [Video of lecture](https://youtu.be/eNYuDXArIvE)\n", "\n", - "* [Handwritten notes tba](https://github.com/CompPhysics/ComputationalPhysics2/blob/gh-pages/doc/HandWrittenNotes/2024/NotesFebruary9.pdf)" + "* [Whiteboard notes](https://github.com/CompPhysics/ComputationalPhysics2/blob/gh-pages/doc/HandWrittenNotes/2024/NotesFebruary9.pdf)" ] }, { "cell_type": "markdown", - "id": "a3804f2a", - "metadata": {}, + "id": "939185ab", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling and overview of what needs to be coded, reminder from last week\n", "\n", @@ -55,8 +63,10 @@ }, { "cell_type": "markdown", - "id": "f87b1a38", - "metadata": {}, + "id": "0f1e2e10", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial P}{\\partial t} = D\\frac{\\partial }{\\partial x}\\left(\\frac{\\partial }{\\partial x} -F\\right)P(x,t),\n", @@ -65,16 +75,20 @@ }, { "cell_type": "markdown", - "id": "2ff1271c", - "metadata": {}, + "id": "c2a8834d", + "metadata": { + "editable": true + }, "source": [ "where $F$ is a drift term and $D$ is the diffusion coefficient." ] }, { "cell_type": "markdown", - "id": "2db37bad", - "metadata": {}, + "id": "387846fa", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling\n", "The new positions in coordinate space are given as the solutions of the Langevin equation using Euler's method, namely,\n", @@ -83,8 +97,10 @@ }, { "cell_type": "markdown", - "id": "c320fc8a", - "metadata": {}, + "id": "49a6c7c7", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial x(t)}{\\partial t} = DF(x(t)) +\\eta,\n", @@ -93,8 +109,10 @@ }, { "cell_type": "markdown", - "id": "8fa30830", - "metadata": {}, + "id": "118d7292", + "metadata": { + "editable": true + }, "source": [ "with $\\eta$ a random variable,\n", "yielding a new position" @@ -102,8 +120,10 @@ }, { "cell_type": "markdown", - "id": "b9c42fba", - "metadata": {}, + "id": "8849d161", + "metadata": { + "editable": true + }, "source": [ "$$\n", "y = x+DF(x)\\Delta t +\\xi\\sqrt{\\Delta t},\n", @@ -112,8 +132,10 @@ }, { "cell_type": "markdown", - "id": "ccb6df0f", - "metadata": {}, + "id": "de8ad46c", + "metadata": { + "editable": true + }, "source": [ "where $\\xi$ is gaussian random variable and $\\Delta t$ is a chosen time step. \n", "The quantity $D$ is, in atomic units, equal to $1/2$ and comes from the factor $1/2$ in the kinetic energy operator. Note that $\\Delta t$ is to be viewed as a parameter. Values of $\\Delta t \\in [0.001,0.01]$ yield in general rather stable values of the ground state energy." @@ -121,8 +143,10 @@ }, { "cell_type": "markdown", - "id": "ae927137", - "metadata": {}, + "id": "9f7f1037", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling\n", "The process of isotropic diffusion characterized by a time-dependent probability density $P(\\mathbf{x},t)$ obeys (as an approximation) the so-called Fokker-Planck equation" @@ -130,8 +154,10 @@ }, { "cell_type": "markdown", - "id": "89b696ea", - "metadata": {}, + "id": "acc4f274", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial P}{\\partial t} = \\sum_i D\\frac{\\partial }{\\partial \\mathbf{x_i}}\\left(\\frac{\\partial }{\\partial \\mathbf{x_i}} -\\mathbf{F_i}\\right)P(\\mathbf{x},t),\n", @@ -140,16 +166,20 @@ }, { "cell_type": "markdown", - "id": "11eba608", - "metadata": {}, + "id": "87cd1739", + "metadata": { + "editable": true + }, "source": [ "where $\\mathbf{F_i}$ is the $i^{th}$ component of the drift term (drift velocity) caused by an external potential, and $D$ is the diffusion coefficient. The convergence to a stationary probability density can be obtained by setting the left hand side to zero. The resulting equation will be satisfied if and only if all the terms of the sum are equal zero," ] }, { "cell_type": "markdown", - "id": "7f809761", - "metadata": {}, + "id": "ade2e926", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial^2 P}{\\partial {\\mathbf{x_i}^2}} = P\\frac{\\partial}{\\partial {\\mathbf{x_i}}}\\mathbf{F_i} + \\mathbf{F_i}\\frac{\\partial}{\\partial {\\mathbf{x_i}}}P.\n", @@ -158,8 +188,10 @@ }, { "cell_type": "markdown", - "id": "7f5694e7", - "metadata": {}, + "id": "e35107f9", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling\n", "The drift vector should be of the form $\\mathbf{F} = g(\\mathbf{x}) \\frac{\\partial P}{\\partial \\mathbf{x}}$. Then," @@ -167,8 +199,10 @@ }, { "cell_type": "markdown", - "id": "38df8785", - "metadata": {}, + "id": "87f3fe7a", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial^2 P}{\\partial {\\mathbf{x_i}^2}} = P\\frac{\\partial g}{\\partial P}\\left( \\frac{\\partial P}{\\partial {\\mathbf{x}_i}} \\right)^2 + P g \\frac{\\partial ^2 P}{\\partial {\\mathbf{x}_i^2}} + g \\left( \\frac{\\partial P}{\\partial {\\mathbf{x}_i}} \\right)^2.\n", @@ -177,16 +211,20 @@ }, { "cell_type": "markdown", - "id": "d7960a46", - "metadata": {}, + "id": "f360d093", + "metadata": { + "editable": true + }, "source": [ "The condition of stationary density means that the left hand side equals zero. In other words, the terms containing first and second derivatives have to cancel each other. It is possible only if $g = \\frac{1}{P}$, which yields" ] }, { "cell_type": "markdown", - "id": "db0508c4", - "metadata": {}, + "id": "7b1acc99", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\mathbf{F} = 2\\frac{1}{\\Psi_T}\\nabla\\Psi_T,\n", @@ -195,16 +233,20 @@ }, { "cell_type": "markdown", - "id": "e13452f5", - "metadata": {}, + "id": "b87e2a5f", + "metadata": { + "editable": true + }, "source": [ "which is known as the so-called *quantum force*. This term is responsible for pushing the walker towards regions of configuration space where the trial wave function is large, increasing the efficiency of the simulation in contrast to the Metropolis algorithm where the walker has the same probability of moving in every direction." ] }, { "cell_type": "markdown", - "id": "dabf4d7b", - "metadata": {}, + "id": "2c40bbab", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling\n", "The Fokker-Planck equation yields a (the solution to the equation) transition probability given by the Green's function" @@ -212,8 +254,10 @@ }, { "cell_type": "markdown", - "id": "55040417", - "metadata": {}, + "id": "e2160f4e", + "metadata": { + "editable": true + }, "source": [ "$$\n", "G(y,x,\\Delta t) = \\frac{1}{(4\\pi D\\Delta t)^{3N/2}} \\exp{\\left(-(y-x-D\\Delta t F(x))^2/4D\\Delta t\\right)}\n", @@ -222,16 +266,20 @@ }, { "cell_type": "markdown", - "id": "ff312f3b", - "metadata": {}, + "id": "1928a65f", + "metadata": { + "editable": true + }, "source": [ "which in turn means that our brute force Metropolis algorithm" ] }, { "cell_type": "markdown", - "id": "2a28ac22", - "metadata": {}, + "id": "c9f25814", + "metadata": { + "editable": true + }, "source": [ "$$\n", "A(y,x) = \\mathrm{min}(1,q(y,x))),\n", @@ -240,16 +288,20 @@ }, { "cell_type": "markdown", - "id": "7d3a69db", - "metadata": {}, + "id": "f69c91aa", + "metadata": { + "editable": true + }, "source": [ "with $q(y,x) = |\\Psi_T(y)|^2/|\\Psi_T(x)|^2$ is now replaced by the [Metropolis-Hastings algorithm](http://scitation.aip.org/content/aip/journal/jcp/21/6/10.1063/1.1699114) as well as [Hasting's article](http://biomet.oxfordjournals.org/content/57/1/97.abstract)," ] }, { "cell_type": "markdown", - "id": "0067790a", - "metadata": {}, + "id": "e3b15444", + "metadata": { + "editable": true + }, "source": [ "$$\n", "q(y,x) = \\frac{G(x,y,\\Delta t)|\\Psi_T(y)|^2}{G(y,x,\\Delta t)|\\Psi_T(x)|^2}\n", @@ -258,8 +310,10 @@ }, { "cell_type": "markdown", - "id": "770cc9c6", - "metadata": {}, + "id": "9b394f86", + "metadata": { + "editable": true + }, "source": [ "## Code example for the interacting case with importance sampling\n", "\n", @@ -269,8 +323,11 @@ { "cell_type": "code", "execution_count": 1, - "id": "38f242bb", - "metadata": {}, + "id": "0f60b346", + "metadata": { + "collapsed": false, + "editable": true + }, "outputs": [], "source": [ "# Common imports\n", @@ -304,8 +361,10 @@ }, { "cell_type": "markdown", - "id": "1739b4fb", - "metadata": {}, + "id": "be3e08ba", + "metadata": { + "editable": true + }, "source": [ "we move on to the set up of the trial wave function, the analytical expression for the local energy and the analytical expression for the quantum force." ] @@ -313,8 +372,11 @@ { "cell_type": "code", "execution_count": 2, - "id": "f068a564", - "metadata": {}, + "id": "80af5e0a", + "metadata": { + "collapsed": false, + "editable": true + }, "outputs": [], "source": [ "%matplotlib inline\n", @@ -364,8 +426,10 @@ }, { "cell_type": "markdown", - "id": "d140a0b6", - "metadata": {}, + "id": "3adc0d07", + "metadata": { + "editable": true + }, "source": [ "The Monte Carlo sampling includes now the Metropolis-Hastings algorithm, with the additional complication of having to evaluate the **quantum force** and the Green's function which is the solution of the Fokker-Planck equation." ] @@ -373,8 +437,11 @@ { "cell_type": "code", "execution_count": 3, - "id": "d692717a", - "metadata": {}, + "id": "3f3db187", + "metadata": { + "collapsed": false, + "editable": true + }, "outputs": [], "source": [ "# The Monte Carlo sampling with the Metropolis algo\n", @@ -452,8 +519,10 @@ }, { "cell_type": "markdown", - "id": "b56d1285", - "metadata": {}, + "id": "7dc1e360", + "metadata": { + "editable": true + }, "source": [ "The main part here contains the setup of the variational parameters, the energies and the variance." ] @@ -461,8 +530,11 @@ { "cell_type": "code", "execution_count": 4, - "id": "5fe47d5a", - "metadata": {}, + "id": "b054ff4f", + "metadata": { + "collapsed": false, + "editable": true + }, "outputs": [], "source": [ "#Here starts the main program with variable declarations\n", @@ -497,8 +569,10 @@ }, { "cell_type": "markdown", - "id": "38f11438", - "metadata": {}, + "id": "3ffab92d", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -517,8 +591,10 @@ }, { "cell_type": "markdown", - "id": "9b6ae1e9", - "metadata": {}, + "id": "f6d27a2a", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -530,8 +606,10 @@ }, { "cell_type": "markdown", - "id": "12eb4d17", - "metadata": {}, + "id": "825c1fc8", + "metadata": { + "editable": true + }, "source": [ "$$\n", "Y_X (t) = f(X, t).\n", @@ -540,8 +618,10 @@ }, { "cell_type": "markdown", - "id": "26e92505", - "metadata": {}, + "id": "cf8e8a4d", + "metadata": { + "editable": true + }, "source": [ "The quantity $Y_X (t)$ is called a random function,\n", "or, since $t$ often is time, a stochastic process. A stochastic\n", @@ -552,8 +632,10 @@ }, { "cell_type": "markdown", - "id": "3944168c", - "metadata": {}, + "id": "81accf95", + "metadata": { + "editable": true + }, "source": [ "$$\n", "y(t) = f (x, t),\n", @@ -562,8 +644,10 @@ }, { "cell_type": "markdown", - "id": "15946380", - "metadata": {}, + "id": "7dc70785", + "metadata": { + "editable": true + }, "source": [ "is a function of $t$, called a\n", "sample function or realization of the process. In physics one\n", @@ -573,8 +657,10 @@ }, { "cell_type": "markdown", - "id": "aee62e91", - "metadata": {}, + "id": "c66fdca9", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -586,8 +672,10 @@ }, { "cell_type": "markdown", - "id": "f515bb9e", - "metadata": {}, + "id": "6164efd4", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(y\\rightarrow y')w(y ) = W(y'\\rightarrow y)w_0 (y),\n", @@ -596,8 +684,10 @@ }, { "cell_type": "markdown", - "id": "64881fda", - "metadata": {}, + "id": "ff434436", + "metadata": { + "editable": true + }, "source": [ "where $W(y'\\rightarrow y)$ is the probability, per unit time, that the\n", "system changes from a state $|y\\rangle$ , characterized by the value\n", @@ -610,8 +700,10 @@ }, { "cell_type": "markdown", - "id": "3961251e", - "metadata": {}, + "id": "a62d883b", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -623,8 +715,10 @@ }, { "cell_type": "markdown", - "id": "e596f386", - "metadata": {}, + "id": "88307e95", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(0\\rightarrow 1)\\exp{-(\\epsilon_0/kT)} = W(1\\rightarrow 0)\\exp{-(\\epsilon_1/kT)}.\n", @@ -633,16 +727,20 @@ }, { "cell_type": "markdown", - "id": "15b5ecec", - "metadata": {}, + "id": "4b697dc7", + "metadata": { + "editable": true + }, "source": [ "We get then" ] }, { "cell_type": "markdown", - "id": "9405eab5", - "metadata": {}, + "id": "dd6571da", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{W(1\\rightarrow 0)}{W(0 \\rightarrow 1)}=\\exp{-(\\Delta E/kT)},\n", @@ -651,16 +749,20 @@ }, { "cell_type": "markdown", - "id": "c8e8faf4", - "metadata": {}, + "id": "081dc674", + "metadata": { + "editable": true + }, "source": [ "which goes to zero when $T$ tends to zero." ] }, { "cell_type": "markdown", - "id": "eb6fe742", - "metadata": {}, + "id": "cd3a4ddc", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -671,8 +773,10 @@ }, { "cell_type": "markdown", - "id": "14b84a89", - "metadata": {}, + "id": "71fa7be9", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w_i(0) = \\delta_{i,0},\n", @@ -681,16 +785,20 @@ }, { "cell_type": "markdown", - "id": "b6d47e48", - "metadata": {}, + "id": "195b5d3d", + "metadata": { + "editable": true + }, "source": [ "and its time-development after a given time step $\\Delta t=\\epsilon$ is" ] }, { "cell_type": "markdown", - "id": "c959168a", - "metadata": {}, + "id": "1fa9e871", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w_i(t) = \\sum_{j}W(j\\rightarrow i)w_j(t=0).\n", @@ -699,16 +807,20 @@ }, { "cell_type": "markdown", - "id": "3b55f84f", - "metadata": {}, + "id": "aa84edbb", + "metadata": { + "editable": true + }, "source": [ "The continuous analog to $w_i(0)$ is" ] }, { "cell_type": "markdown", - "id": "8b1cf5a3", - "metadata": {}, + "id": "12eb32af", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{x})\\rightarrow \\delta(\\mathbf{x}),\n", @@ -717,8 +829,10 @@ }, { "cell_type": "markdown", - "id": "af9d1ea3", - "metadata": {}, + "id": "2accc675", + "metadata": { + "editable": true + }, "source": [ "where we now have generalized the one-dimensional position $x$ to a generic-dimensional \n", "vector $\\mathbf{x}$. The Kroenecker $\\delta$ function is replaced by the $\\delta$ distribution\n", @@ -727,8 +841,10 @@ }, { "cell_type": "markdown", - "id": "c5538edb", - "metadata": {}, + "id": "012b2b2d", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -740,8 +856,10 @@ }, { "cell_type": "markdown", - "id": "59725279", - "metadata": {}, + "id": "c2de6788", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{y},t+\\Delta t)= \\int W(\\mathbf{y},t+\\Delta t| \\mathbf{x},t)w(\\mathbf{x},t)d\\mathbf{x},\n", @@ -750,16 +868,20 @@ }, { "cell_type": "markdown", - "id": "d46ebfd9", - "metadata": {}, + "id": "581d25a9", + "metadata": { + "editable": true + }, "source": [ "and after $m$ time steps we have" ] }, { "cell_type": "markdown", - "id": "15131e1b", - "metadata": {}, + "id": "69e4c236", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{y},t+m\\Delta t)= \\int W(\\mathbf{y},t+m\\Delta t| \\mathbf{x},t)w(\\mathbf{x},t)d\\mathbf{x}.\n", @@ -768,16 +890,20 @@ }, { "cell_type": "markdown", - "id": "c08966e7", - "metadata": {}, + "id": "1b44b92c", + "metadata": { + "editable": true + }, "source": [ "When equilibrium is reached we have" ] }, { "cell_type": "markdown", - "id": "aa8cb364", - "metadata": {}, + "id": "cfa88ba4", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{y})= \\int W(\\mathbf{y}|\\mathbf{x}, t)w(\\mathbf{x})d\\mathbf{x},\n", @@ -786,16 +912,20 @@ }, { "cell_type": "markdown", - "id": "71bd3bc0", - "metadata": {}, + "id": "136d1fd1", + "metadata": { + "editable": true + }, "source": [ "that is no time-dependence. Note our change of notation for $W$" ] }, { "cell_type": "markdown", - "id": "fd01ca91", - "metadata": {}, + "id": "d6bd3321", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -807,8 +937,10 @@ }, { "cell_type": "markdown", - "id": "0d145c26", - "metadata": {}, + "id": "e719ac6b", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{x},t) = \\int_{-\\infty}^{\\infty}d\\mathbf{k} \\exp{(i\\mathbf{kx})}\\tilde{w}(\\mathbf{k},t),\n", @@ -817,8 +949,10 @@ }, { "cell_type": "markdown", - "id": "45659b4a", - "metadata": {}, + "id": "83132d73", + "metadata": { + "editable": true + }, "source": [ "and using the definition of the \n", "$\\delta$-function" @@ -826,8 +960,10 @@ }, { "cell_type": "markdown", - "id": "c78dbd1b", - "metadata": {}, + "id": "f7166f96", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\delta(\\mathbf{x}) = \\frac{1}{2\\pi} \\int_{-\\infty}^{\\infty}d\\mathbf{k} \\exp{(i\\mathbf{kx})},\n", @@ -836,16 +972,20 @@ }, { "cell_type": "markdown", - "id": "2f11b169", - "metadata": {}, + "id": "ed101b2e", + "metadata": { + "editable": true + }, "source": [ "we see that" ] }, { "cell_type": "markdown", - "id": "75abc8fb", - "metadata": {}, + "id": "f41972e0", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\tilde{w}(\\mathbf{k},0)=1/2\\pi.\n", @@ -854,8 +994,10 @@ }, { "cell_type": "markdown", - "id": "86abb296", - "metadata": {}, + "id": "9faadb5f", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -864,8 +1006,10 @@ }, { "cell_type": "markdown", - "id": "cc673061", - "metadata": {}, + "id": "b9b57b0d", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial \\tilde{w}(\\mathbf{k},t)}{\\partial t} = -D\\mathbf{k}^2\\tilde{w}(\\mathbf{k},t),\n", @@ -874,16 +1018,20 @@ }, { "cell_type": "markdown", - "id": "f8990bcc", - "metadata": {}, + "id": "07676f35", + "metadata": { + "editable": true + }, "source": [ "with the obvious solution" ] }, { "cell_type": "markdown", - "id": "8b878f24", - "metadata": {}, + "id": "18e1646a", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\tilde{w}(\\mathbf{k},t)=\\tilde{w}(\\mathbf{k},0)\\exp{\\left[-(D\\mathbf{k}^2t)\\right)}=\n", @@ -893,8 +1041,10 @@ }, { "cell_type": "markdown", - "id": "e8300c57", - "metadata": {}, + "id": "75f1e5de", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -903,8 +1053,10 @@ }, { "cell_type": "markdown", - "id": "bf60212d", - "metadata": {}, + "id": "2bdb1cb3", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{x},t)=\\int_{-\\infty}^{\\infty}d\\mathbf{k} \\exp{\\left[i\\mathbf{kx}\\right]}\\frac{1}{2\\pi}\\exp{\\left[-(D\\mathbf{k}^2t)\\right]}=\n", @@ -914,16 +1066,20 @@ }, { "cell_type": "markdown", - "id": "cecaa195", - "metadata": {}, + "id": "893d1847", + "metadata": { + "editable": true + }, "source": [ "with the normalization condition" ] }, { "cell_type": "markdown", - "id": "b5ea8f5a", - "metadata": {}, + "id": "56ed10fc", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\int_{-\\infty}^{\\infty}w(\\mathbf{x},t)d\\mathbf{x}=1.\n", @@ -932,8 +1088,10 @@ }, { "cell_type": "markdown", - "id": "57a9ed03", - "metadata": {}, + "id": "dd4ed3c0", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -950,8 +1108,10 @@ }, { "cell_type": "markdown", - "id": "ab00a5a4", - "metadata": {}, + "id": "cf4cdabf", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(il-jl,n\\epsilon)\\rightarrow W(\\mathbf{y},t+\\Delta t|\\mathbf{x},t)=\n", @@ -961,8 +1121,10 @@ }, { "cell_type": "markdown", - "id": "e2329412", - "metadata": {}, + "id": "147b1608", + "metadata": { + "editable": true + }, "source": [ "and that it satisfies the normalization condition and is itself a solution\n", "to the diffusion equation." @@ -970,8 +1132,10 @@ }, { "cell_type": "markdown", - "id": "55d847e9", - "metadata": {}, + "id": "9ffcb60b", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -982,8 +1146,10 @@ }, { "cell_type": "markdown", - "id": "cf7dcd7d", - "metadata": {}, + "id": "70b7c9e9", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{x},t)= \\int_{-\\infty}^{\\infty} W(\\mathbf{x}.t|\\mathbf{x}'.t')w(\\mathbf{x}',t')d\\mathbf{x}',\n", @@ -992,16 +1158,20 @@ }, { "cell_type": "markdown", - "id": "55774304", - "metadata": {}, + "id": "c7c8aa0a", + "metadata": { + "editable": true + }, "source": [ "and" ] }, { "cell_type": "markdown", - "id": "ce84af12", - "metadata": {}, + "id": "4d2b0ebf", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{x},t)= \\int_{-\\infty}^{\\infty} W(\\mathbf{x}.t|\\mathbf{x}_0.t_0)w(\\mathbf{x}_0,t_0)d\\mathbf{x}_0,\n", @@ -1010,16 +1180,20 @@ }, { "cell_type": "markdown", - "id": "65a56246", - "metadata": {}, + "id": "1d1d7f45", + "metadata": { + "editable": true + }, "source": [ "and" ] }, { "cell_type": "markdown", - "id": "effebe52", - "metadata": {}, + "id": "587a73c3", + "metadata": { + "editable": true + }, "source": [ "$$\n", "w(\\mathbf{x}',t')= \\int_{-\\infty}^{\\infty} W(\\mathbf{x}'.t'|\\mathbf{x}_0,t_0)w(\\mathbf{x}_0,t_0)d\\mathbf{x}_0.\n", @@ -1028,8 +1202,10 @@ }, { "cell_type": "markdown", - "id": "ded4bf38", - "metadata": {}, + "id": "c9619bd4", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -1038,8 +1214,10 @@ }, { "cell_type": "markdown", - "id": "955cabc9", - "metadata": {}, + "id": "2f7c5524", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(\\mathbf{x}t|\\mathbf{x}_0t_0) = \\int_{-\\infty}^{\\infty} W(\\mathbf{x},t|\\mathbf{x}',t')W(\\mathbf{x}',t'|\\mathbf{x}_0,t_0)d\\mathbf{x}'.\n", @@ -1048,8 +1226,10 @@ }, { "cell_type": "markdown", - "id": "9e5e2006", - "metadata": {}, + "id": "e07260a6", + "metadata": { + "editable": true + }, "source": [ "We can replace the spatial dependence with a dependence upon say the velocity\n", "(or momentum), that is we have" @@ -1057,8 +1237,10 @@ }, { "cell_type": "markdown", - "id": "14cd8679", - "metadata": {}, + "id": "25a2ab05", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(\\mathbf{v},t|\\mathbf{v}_0,t_0) = \\int_{-\\infty}^{\\infty} W(\\mathbf{v},t|\\mathbf{v}',t')W(\\mathbf{v}',t'|\\mathbf{v}_0,t_0)d\\mathbf{x}'.\n", @@ -1067,8 +1249,10 @@ }, { "cell_type": "markdown", - "id": "4dba6fff", - "metadata": {}, + "id": "1bf0c6e5", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -1078,8 +1262,10 @@ }, { "cell_type": "markdown", - "id": "98b7b355", - "metadata": {}, + "id": "0499f0c6", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(\\mathbf{x},t|\\mathbf{x}_0,t_0) = \\int_{-\\infty}^{\\infty} W(\\mathbf{x},t|\\mathbf{x}',t')W(\\mathbf{x}',t'|\\mathbf{x}_0,t_0)d\\mathbf{x}'.\n", @@ -1088,16 +1274,20 @@ }, { "cell_type": "markdown", - "id": "5e7a7e36", - "metadata": {}, + "id": "9b1a7976", + "metadata": { + "editable": true + }, "source": [ "Define $s=t'-t_0$, $\\tau=t-t'$ and $t-t_0=s+\\tau$. We have then" ] }, { "cell_type": "markdown", - "id": "126985ee", - "metadata": {}, + "id": "9362509a", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(\\mathbf{x},s+\\tau|\\mathbf{x}_0) = \\int_{-\\infty}^{\\infty} W(\\mathbf{x},\\tau|\\mathbf{x}')W(\\mathbf{x}',s|\\mathbf{x}_0)d\\mathbf{x}'.\n", @@ -1106,8 +1296,10 @@ }, { "cell_type": "markdown", - "id": "fc3b537a", - "metadata": {}, + "id": "c3bd80ba", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -1116,8 +1308,10 @@ }, { "cell_type": "markdown", - "id": "5340c79d", - "metadata": {}, + "id": "853d4a71", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(\\mathbf{x},s|\\mathbf{x}_0)+\\frac{\\partial W}{\\partial s}\\tau +O(\\tau^2) = \\int_{-\\infty}^{\\infty} W(\\mathbf{x},\\tau|\\mathbf{x}-\\xi)W(\\mathbf{x}-\\xi,s|\\mathbf{x}_0)d\\mathbf{x}'.\n", @@ -1126,16 +1320,20 @@ }, { "cell_type": "markdown", - "id": "6b5a2879", - "metadata": {}, + "id": "f8b41b93", + "metadata": { + "editable": true + }, "source": [ "We assume that $W(\\mathbf{x},\\tau|\\mathbf{x}-\\xi)$ takes non-negligible values only when $\\xi$ is small. This is just another way of stating the Master equation!!" ] }, { "cell_type": "markdown", - "id": "5191088d", - "metadata": {}, + "id": "db01e4f9", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -1146,8 +1344,10 @@ }, { "cell_type": "markdown", - "id": "66d73948", - "metadata": {}, + "id": "e1993a27", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(\\mathbf{x},\\tau|\\mathbf{x}-\\xi)W(\\mathbf{x}-\\xi,s|\\mathbf{x}_0) =\n", @@ -1158,8 +1358,10 @@ }, { "cell_type": "markdown", - "id": "c25b2c7b", - "metadata": {}, + "id": "eecac169", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -1168,8 +1370,10 @@ }, { "cell_type": "markdown", - "id": "b89a6be9", - "metadata": {}, + "id": "df15f690", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial W}{\\partial s}\\tau=-W(\\mathbf{x},s|\\mathbf{x}_0)+\n", @@ -1180,8 +1384,10 @@ }, { "cell_type": "markdown", - "id": "d603a02d", - "metadata": {}, + "id": "bc9ad87f", + "metadata": { + "editable": true + }, "source": [ "We have neglected higher powers of $\\tau$ and have used that for $n=0$ \n", "we get simply $W(\\mathbf{x},s|\\mathbf{x}_0)$ due to normalization." @@ -1189,8 +1395,10 @@ }, { "cell_type": "markdown", - "id": "a3cfddd0", - "metadata": {}, + "id": "cab3cf27", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "\n", @@ -1201,8 +1409,10 @@ }, { "cell_type": "markdown", - "id": "0fba931d", - "metadata": {}, + "id": "ed1f42c0", + "metadata": { + "editable": true + }, "source": [ "$$\n", "W(\\mathbf{x},\\tau|\\mathbf{x}-\\xi)W(\\mathbf{x}-\\xi,s|\\mathbf{x}_0) =\n", @@ -1213,8 +1423,10 @@ }, { "cell_type": "markdown", - "id": "43aac8ac", - "metadata": {}, + "id": "2af8f5ed", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "We can then rewrite the ESKC equation as" @@ -1222,8 +1434,10 @@ }, { "cell_type": "markdown", - "id": "7713e50e", - "metadata": {}, + "id": "2e8e4cb5", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial W(\\mathbf{x},s|\\mathbf{x}_0)}{\\partial s}\\tau=-W(\\mathbf{x},s|\\mathbf{x}_0)+\n", @@ -1234,8 +1448,10 @@ }, { "cell_type": "markdown", - "id": "8c23e877", - "metadata": {}, + "id": "f306d0f1", + "metadata": { + "editable": true + }, "source": [ "We have neglected higher powers of $\\tau$ and have used that for $n=0$ \n", "we get simply $W(\\mathbf{x},s|\\mathbf{x}_0)$ due to normalization." @@ -1243,8 +1459,10 @@ }, { "cell_type": "markdown", - "id": "eea965c7", - "metadata": {}, + "id": "06918b84", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "We simplify the above by introducing the moments" @@ -1252,8 +1470,10 @@ }, { "cell_type": "markdown", - "id": "e604807e", - "metadata": {}, + "id": "6a01656b", + "metadata": { + "editable": true + }, "source": [ "$$\n", "M_n=\\frac{1}{\\tau}\\int_{-\\infty}^{\\infty} \\xi^nW(\\mathbf{x}+\\xi,\\tau|\\mathbf{x})d\\xi=\n", @@ -1263,16 +1483,20 @@ }, { "cell_type": "markdown", - "id": "8e44ec9a", - "metadata": {}, + "id": "e9645ef6", + "metadata": { + "editable": true + }, "source": [ "resulting in" ] }, { "cell_type": "markdown", - "id": "8c4e3a9c", - "metadata": {}, + "id": "37f8d3bd", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial W(\\mathbf{x},s|\\mathbf{x}_0)}{\\partial s}=\n", @@ -1283,8 +1507,10 @@ }, { "cell_type": "markdown", - "id": "2de8b21e", - "metadata": {}, + "id": "04693b2e", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "When $\\tau \\rightarrow 0$ we assume that $\\langle [\\Delta x(\\tau)]^n\\rangle \\rightarrow 0$ more rapidly than $\\tau$ itself if $n > 2$. \n", @@ -1297,8 +1523,10 @@ }, { "cell_type": "markdown", - "id": "06378099", - "metadata": {}, + "id": "97b42418", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial W(\\mathbf{x},s|\\mathbf{x}_0)}{\\partial s}=\n", @@ -1309,8 +1537,10 @@ }, { "cell_type": "markdown", - "id": "17b08fc7", - "metadata": {}, + "id": "5c1afcbd", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "In a more compact form we have" @@ -1318,8 +1548,10 @@ }, { "cell_type": "markdown", - "id": "b6fa0329", - "metadata": {}, + "id": "08f02511", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{\\partial W}{\\partial s}=\n", @@ -1330,8 +1562,10 @@ }, { "cell_type": "markdown", - "id": "19b0d194", - "metadata": {}, + "id": "34529658", + "metadata": { + "editable": true + }, "source": [ "which is the Fokker-Planck equation! It is trivial to replace \n", "position with velocity (momentum)." @@ -1339,8 +1573,10 @@ }, { "cell_type": "markdown", - "id": "1fd9cc94", - "metadata": {}, + "id": "7bc5ffb4", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "**Langevin equation.**\n", @@ -1354,8 +1590,10 @@ }, { "cell_type": "markdown", - "id": "ae5ebbdd", - "metadata": {}, + "id": "860b601e", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "**Langevin equation.**\n", @@ -1365,8 +1603,10 @@ }, { "cell_type": "markdown", - "id": "1fb546bb", - "metadata": {}, + "id": "7c042203", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\xi =6\\pi \\eta a/m\n", @@ -1375,8 +1615,10 @@ }, { "cell_type": "markdown", - "id": "39118f02", - "metadata": {}, + "id": "df6046d4", + "metadata": { + "editable": true + }, "source": [ "where $\\eta$ is the viscosity of the solvent and a is the radius of the particle .\n", "\n", @@ -1385,8 +1627,10 @@ }, { "cell_type": "markdown", - "id": "7e7e0511", - "metadata": {}, + "id": "ec43a7fd", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\mathbf{v}(t)=\\mathbf{v}_{0}e^{-\\xi t}+\\int_{0}^{t}d\\tau e^{-\\xi (t-\\tau )}\\mathbf{F }(\\tau ).\n", @@ -1395,8 +1639,10 @@ }, { "cell_type": "markdown", - "id": "c283a6e0", - "metadata": {}, + "id": "58d4defd", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "**Langevin equation.**\n", @@ -1407,8 +1653,10 @@ }, { "cell_type": "markdown", - "id": "052464c7", - "metadata": {}, + "id": "94c4acaf", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\langle \\mathbf{v}(t)\\cdot \\mathbf{v}(t)\\rangle_{\\mathbf{v}_{0}}=v_{0}^{-\\xi 2t}\n", @@ -1418,8 +1666,10 @@ }, { "cell_type": "markdown", - "id": "2a2a42f9", - "metadata": {}, + "id": "fc71b760", + "metadata": { + "editable": true + }, "source": [ "$$\n", "+\\int_{0}^{t}d\\tau ^{\\prime }\\int_{0}^{t}d\\tau e^{-\\xi (2t-\\tau -\\tau ^{\\prime })}\n", @@ -1429,8 +1679,10 @@ }, { "cell_type": "markdown", - "id": "d0c186bd", - "metadata": {}, + "id": "319f007d", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "**Langevin equation.**\n", @@ -1442,8 +1694,10 @@ }, { "cell_type": "markdown", - "id": "5306ea3b", - "metadata": {}, + "id": "3722d0de", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\langle \\mathbf{F}(t)\\rangle=0,\n", @@ -1452,16 +1706,20 @@ }, { "cell_type": "markdown", - "id": "22b8a942", - "metadata": {}, + "id": "928fa5f6", + "metadata": { + "editable": true + }, "source": [ "and" ] }, { "cell_type": "markdown", - "id": "2432446a", - "metadata": {}, + "id": "9da6e3e2", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\langle \\mathbf{F}(t)\\cdot \\mathbf{F}(t^{\\prime })\\rangle_{\\mathbf{v}_{0}}= C_{\\mathbf{v}_{0}}\\delta (t-t^{\\prime }).\n", @@ -1470,16 +1728,20 @@ }, { "cell_type": "markdown", - "id": "8c0590c9", - "metadata": {}, + "id": "9b286750", + "metadata": { + "editable": true + }, "source": [ "We omit the subscript $\\mathbf{v}_{0}$, when the quantity of interest turns out to be independent of $\\mathbf{v}_{0}$. Using the last three equations we get" ] }, { "cell_type": "markdown", - "id": "4089d80f", - "metadata": {}, + "id": "d746b8e2", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\langle \\mathbf{v}(t)\\cdot \\mathbf{v}(t)\\rangle_{\\mathbf{v}_{0}}=v_{0}^{2}e^{-2\\xi t}+\\frac{C_{\\mathbf{v}_{0}}}{2\\xi }(1-e^{-2\\xi t}).\n", @@ -1488,16 +1750,20 @@ }, { "cell_type": "markdown", - "id": "0ef0c43f", - "metadata": {}, + "id": "97642538", + "metadata": { + "editable": true + }, "source": [ "For large t this should be equal to 3kT/m, from which it follows that" ] }, { "cell_type": "markdown", - "id": "ba185ec7", - "metadata": {}, + "id": "ffa04d3d", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\langle \\mathbf{F}(t)\\cdot \\mathbf{F}(t^{\\prime })\\rangle =6\\frac{kT}{m}\\xi \\delta (t-t^{\\prime }).\n", @@ -1506,16 +1772,20 @@ }, { "cell_type": "markdown", - "id": "b1fcaf35", - "metadata": {}, + "id": "2e6fa2b9", + "metadata": { + "editable": true + }, "source": [ "This result is called the fluctuation-dissipation theorem ." ] }, { "cell_type": "markdown", - "id": "5ef1a930", - "metadata": {}, + "id": "57830d2f", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "**Langevin equation.**\n", @@ -1525,8 +1795,10 @@ }, { "cell_type": "markdown", - "id": "a13a5a62", - "metadata": {}, + "id": "ddf455a3", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\mathbf{v}(t)=\\mathbf{v}_{0}e^{-\\xi t}+\\int_{0}^{t}d\\tau e^{-\\xi (t-\\tau )}\\mathbf{F }(\\tau ),\n", @@ -1535,16 +1807,20 @@ }, { "cell_type": "markdown", - "id": "1f40e236", - "metadata": {}, + "id": "c1279301", + "metadata": { + "editable": true + }, "source": [ "we get" ] }, { "cell_type": "markdown", - "id": "64795362", - "metadata": {}, + "id": "9b02142c", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\mathbf{r}(t)=\\mathbf{r}_{0}+\\mathbf{v}_{0}\\frac{1}{\\xi }(1-e^{-\\xi t})+\n", @@ -1554,16 +1830,20 @@ }, { "cell_type": "markdown", - "id": "d0cfe453", - "metadata": {}, + "id": "1a4afbdd", + "metadata": { + "editable": true + }, "source": [ "from which we calculate the mean square displacement" ] }, { "cell_type": "markdown", - "id": "966e357b", - "metadata": {}, + "id": "cc979cea", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\langle ( \\mathbf{r}(t)-\\mathbf{r}_{0})^{2}\\rangle _{\\mathbf{v}_{0}}=\\frac{v_0^2}{\\xi}(1-e^{-\\xi t})^{2}+\\frac{3kT}{m\\xi ^{2}}(2\\xi t-3+4e^{-\\xi t}-e^{-2\\xi t}).\n", @@ -1572,8 +1852,10 @@ }, { "cell_type": "markdown", - "id": "a15727a3", - "metadata": {}, + "id": "cd36528d", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, Fokker-Planck and Langevin equations\n", "**Langevin equation.**\n", @@ -1583,8 +1865,10 @@ }, { "cell_type": "markdown", - "id": "37b83694", - "metadata": {}, + "id": "ee76fcc2", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\langle (\\mathbf{r}(t)-\\mathbf{r}_{0})^{2}\\rangle =\\frac{6kT}{m\\xi }t\n", @@ -1593,16 +1877,20 @@ }, { "cell_type": "markdown", - "id": "8a19caa6", - "metadata": {}, + "id": "0b8686d1", + "metadata": { + "editable": true + }, "source": [ "from which we get the Einstein relation" ] }, { "cell_type": "markdown", - "id": "991f5999", - "metadata": {}, + "id": "afe59939", + "metadata": { + "editable": true + }, "source": [ "$$\n", "D= \\frac{kT}{m\\xi }\n", @@ -1611,16 +1899,20 @@ }, { "cell_type": "markdown", - "id": "dd908ad8", - "metadata": {}, + "id": "37ff7cc8", + "metadata": { + "editable": true + }, "source": [ "where we have used $\\langle (\\mathbf{r}(t)-\\mathbf{r}_{0})^{2}\\rangle =6Dt$." ] }, { "cell_type": "markdown", - "id": "d0459313", - "metadata": {}, + "id": "60bd1790", + "metadata": { + "editable": true + }, "source": [ "## Importance sampling, programming elements\n", "\n", @@ -1629,8 +1921,10 @@ }, { "cell_type": "markdown", - "id": "48febb03", - "metadata": {}, + "id": "a4c293ef", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\frac{1}{\\Psi_C}\\frac{\\partial \\Psi_C}{\\partial x_k} =\n", @@ -1642,8 +1936,10 @@ }, { "cell_type": "markdown", - "id": "2926c6f1", - "metadata": {}, + "id": "0396e375", + "metadata": { + "editable": true + }, "source": [ "However, \n", "with our written in way which can be reused later as" @@ -1651,8 +1947,10 @@ }, { "cell_type": "markdown", - "id": "90d86bc0", - "metadata": {}, + "id": "1f37ad0a", + "metadata": { + "editable": true + }, "source": [ "$$\n", "\\Psi_C=\\prod_{i< j}g(r_{ij})= \\exp{\\left\\{\\sum_{i