Appendix D
Statistical Errors It is often stated that a computer simulation generates "exact" data for a given model. However, this is true only if w...
Statistical Errors It is often stated that a computer simulation generates "exact" data for a given model. However, this is true only if we can perform an infinitely long simulation. In practice we have neither the budget nor the patience to approximate such a simulation. Therefore, the results of a simulation will always be subjected to statistical errors, which have to be estimated.
D.1
Static Properties: System Size
Let us consider the statistical accuracy of the measurement of a dynamical quantity A in a Molecular Dynamics simulation (the present discussion applies, with minor modifications, to Monte Carlo simulations). During a simulation of total length T, we obtain the following estimate for the equilibrium-average of A: -- "r
dt A(t),
(D.1.1)
where the subscript on A~ refers to averaging over a finite "time" -r. If the ergodic hypothesis is justified then A~ --+ (A/, as -r --, oo, where {A) denotes the ensemble average of A. Let us now estimate the variance in A,, o-2(A): 0"2 ( a )
_-
(a~) -(a~) 1
q:2 0
dtdt'
~
([A(t)- (A)] [A(t')- (A)]).
(D.1.2)
Note that ( [ A ( t ) - ( A ) ] [ A ( t ' ) - (A)]) in equation (D.1.2)is simply the time correlation function of fluctuations in the variable A. Let us denote this correlation function by CA (t -- t'). If the duration of the sampling 9 is much
Appendix D. Statistical Errors
526
larger than the characteristic decay time t~ of CA, then we may rewrite equation (D.1.2) as
]I ~176
~2(a)
-
dt CA (t)
~~ 2 t ~ c a ( o ) . ,-f
(D.1.3)
In the last equation we have used the definition of t~ as half the integral from -oo to oo of the normalized correlation function CA (t)/CA (0). The relative variance in As therefore is given by O'2 (a) -(a> (A>2 ,~ ,,, ( a t e / T ) 2