Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
computational_physics
lectures
Commits
8905c059
Commit
8905c059
authored
Mar 26, 2020
by
Boris Varbanov
Committed by
Michael Wimmer
Mar 26, 2020
Browse files
Corr description
parent
a6cc9e55
Changes
2
Hide whitespace changes
Inline
Sidebyside
README.md
View file @
8905c059
...
...
@@ 47,7 +47,7 @@ from a separate `.py`file, put that file into `code`. It will then be visible d
Changes you make to the documentation are directly deployed to the webserver after pushing.
If you work in a separate branch called
`branch_name`
, the changes are deployed to
`https://comp
phy
s.quantumtinkerer.tudelft.nl/test_builds/branch_name`
. In this way you can
`https://comp
utationalphysic
s.quantumtinkerer.tudelft.nl/test_builds/branch_name`
. In this way you can
check intermediate stages without exposing this to the students directly.
## Testing the build locally
...
...
src/proj1moldynweek5.md
View file @
8905c059
...
...
@@ 7,7 +7,7 @@ observable $A$ as
$$
\l
angle A
\r
angle =
\f
rac{1}{N}
\s
um_{n>0}^{N}{A_n}$$
where $N$ the total simulation time (we only consider the data
*after*
where $N$
is
the total simulation time (we only consider the data
*after*
the equilibration phase). This average would converge to the actual
thermodynamic average if we could go to $N=
\i
nfty$. Since in our
simulation $N$ is always finite, the time average is only an
*estimate*
of the
...
...
@@ 19,7 +19,7 @@ If we had statistically independent random data for an physical
observable $A$, we could compute the standard deviation of an average
$
\l
angle A
\r
angle$ with the wellknown formula
$$
\s
igma_A =
\s
qrt{
\f
rac{1}{N1}
\l
eft(
\l
angle A^2
\r
angle

\l
angle A
\r
angle
^2
\r
ight)}$$.
$$
\s
igma_A =
\s
qrt{
\f
rac{1}{N1}
\s
um_n
\l
eft(A_n

\l
angle A
\r
angle
\r
ight)
^2
}$$.
However, this does
**not**
work with molecular dynamics, as we do
**not**
have statistically
independent random data. We are doing a timeevolution, meaning that every new
...
...
@@ 29,14 +29,14 @@ configuration is a small variation of the previous configuration  the data thus
### The autocorrelation function
Correlated data means that the data sequence has a memory of the
previous configurations.
Let's now assume that we have a sequence of
correlated data $A_n$.
We can quantify the amount of correlation can
by the autocorrelation function:
previous configurations. Let's now assume that we have a sequence of
correlated data $A_n$. We can quantify the amount of correlation can
by the
normalized
autocorrelation function
(also seen as Pearson correlation coefficient in the literature)
:
$$
\c
hi_A(t) =
\s
um_n
\l
eft(A_n 
\l
angle A
\r
angle
\r
ight)
$$
\c
hi_A(t) =
\f
rac{1}{
\s
igma_A^2}
\s
um_n
\l
eft(A_n 
\l
angle A
\r
angle
\r
ight)
\l
eft(A_{n + t} 
\l
angle A
\r
angle
\r
ight) $$
that compares the fluctuations at a certain time distance. Typically
that compares the fluctuations at a certain time distance
, assuming a stationary process
. Typically
the autocorrelation function has an exponential decay $e^{t/
\t
au}$,
where $
\t
au$ is the correlation time of the simulation (Note that in
my definition here the correlation "time" refers to the index $n$ and
...
...
@@ 52,12 +52,10 @@ $$
The formula above is valid for computing the autocorrelation function for an infinitely
long timeseries. To compute it from your finite length simulation data, you
can use the formula
$$
\c
hi_A(t) =
\f
rac{1}{N  t}
\s
um_{n=1}^{Nt} A_n A_{n+t} 
\f
rac{1}{Nt}
\s
um_{n=1}^{Nt} A_n
\t
imes
\f
rac{1}{Nt}
\s
um_{n=1}^{Nt} A_{n+t}
\,
.
$$
To get $
\t
au$ you would then have to fit $
\c
hi_A(t)$ to $e^{t/
\t
au}$.
\c
hi_A(t) =
\f
rac{
\l
eft(Nt
\r
ight)
\s
um_{n} A_n A_{n+t} 
\s
um_{n} A_n
\t
imes
\s
um_{n} A_{n+t}}{
\s
qrt{
\l
eft(Nt
\r
ight)
\s
um_{n} A_n^2 
\l
eft(
\s
um_{n} A_n
\r
ight)^2}
\s
qrt{
\l
eft(Nt
\r
ight)
\s
um_{n} A_{n+t}^2 
\l
eft(
\s
um_{n} A_{n+t}
\r
ight)^2}}
$$
for $1
\l
eq n
\l
eq Nt$. To get $
\t
au$ you would then have to fit $
\c
hi_A(t)$ to $e^{t/
\t
au}$.
#### Example
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment