Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

RAPID COMMUNICATIONS

PHYSICAL REVIEW E 87, 030101(R) (2013)


Maintaining the equipartition theorem in small heterogeneous molecular dynamics ensembles
Nima H. Siboni,
1,2,*
Dierk Raabe,
2,
and Fathollah Varnik
2,3,
1
Aachen Institute for Computational Engineering Sciences (AICES), RWTH-Aachen, Germany
2
Max-Planck-Institut f ur Eisenforschung GmbH, D usseldorf, Germany
3
Interdisciplinary Centre for Advanced Materials Simulation (ICAMS), Ruhr-Universit at Bochum, Germany
(Received 14 January 2013; published 7 March 2013)
It has been reported recently that the equipartition theorem is violated in molecular dynamics simulations with
periodic boundary condition [R. B. Shirts et al., J. Chem. Phys. 125, 164102 (2006)]. This effect is associated
with the conservation of the total momentum. Here, we propose a uctuating center of mass molecular dynamics
approach to solve this problem. Using the analogy to a system exchanging momentum with its surroundings, we
work outand validate via simulationsan expression for the rate at which uctuations shall be added to the
system. It is shown that the proposed method maintains equipartition both at equilibrium and beyond equilibrium
in the linear response regime.
DOI: 10.1103/PhysRevE.87.030101 PACS number(s): 05.20.y
I. INTRODUCTION
The equipartition theoremstates that the total kinetic energy
of a classical particle is given by p
2
/(2m) = d k
B
T/2. Here,
p and m are the momentum and mass of the particle. k
B
is the Boltzmann factor, T denotes the temperature, and
d is the spatial dimension. This relation serves to control
the temperature in molecular dynamics (MD) simulations by
adjusting the kinetic energy of the system [1].
It has been shown recently that in canonical ensemble
MD simulations with periodic boundary condition (PBC), this
theorem is violated [2] due to the conservation of the center
of mass (total) momentum, P
cm
. This additional constant of
motion restricts the simulation trajectories to only a subset of
the phase space and thus leads to a difference between the time
and ensemble averages [3,4]. One then nds for a particle of
mass m [5]
E
kin
=
p
2

2m
=
dk
B
T
2
_
1
m
M
total
_
, (1)
where stands for statistical average and M
total
=

N
i=1
m
i
is the total mass of the system (N is the total number
of particles). Equation (1) shows that the violation of the
equipartition theorem can be safely ignored if m M
total
.
Indeed, if all the particles have the same mass, m/M
total
=
1/N, and the effect becomes negligible for many practical
cases. This is also in line with the general observation that
the difference between molecular dynamics ensembles [6] and
thermodynamic ensembles vanishes in the large system limit
(N ) [7].
However, beyond small isoparticle systems, the problem
arises principally also in heteroparticle systems, where for
instance a small number of massive particles are surrounded
by a large number of light particles. This includes explicit
solvent MD simulations of transport properties of colloids and
nanoparticles in the dilute limit and generally all multicompo-
nent mixtures. In these cases, a violation of the equipartition
*
hamidi@mpie.de

d.raabe@mpie.de

Corresponding author: fathollah.varnik@rub.de


theorem may not always be tolerable. For example, let us
consider a system consisting of N
l
light particles of mass
m
0
and N
h
massive particles of mass m
0
. Using Eq. (1),
the average kinetic energy of the heavy particle reads as
E
kin
= [1 /(N
l
+N
h
)]dk
B
T/2. In the limit that the
total mass of the heavy particles is large compared to the
total mass of the light particles ( N
l
/N
h
), this reduces to
E
kin
(1 1/N
h
)dk
B
T/2. Thus, the average kinetic energy
of a single heavy particle approaches zero with increasing
mass.
In this Rapid Communication, we propose a method to
restore the equipartition theorem in MD simulations. First,
we provide evidence from simulations that, as noted in
[2,5], the main cause of the problem is the conservation of the
total momentum. Based on this understanding, we introduce
uctuations of the center of mass momentum (note that, in
equilibrium, P
cm
= P
cm
, since P
cm
= 0). We also give an
expression for the time scale of P
cm
uctuations, Eq. (6), and
test its validity via MD simulations. Finally, we implement
and validate the proposed simulation methodology.
II. VIOLATION OF EQUIPARTITION
FOR A MASSIVE TRACER
As mentioned above, a strong violation of the equipartition
theorem is expected for the case of a massive tracer particle in
a liquid environment. In order to demonstrate this, we perform
MDsimulations of a generic 80:20 binary mixture of Lennard-
Jones particles (types Aand B) [8,9]. Aand Bparticles interact
via U
LJ
(r) = 4

[(d

/r)
12
(d

/r)
6
], with , = A,B,

AB
= 1.5
AA
,
BB
= 0.5
AA
, d
AB
= 0.8d
AA
, d
BB
= 0.88d
AA
,
and m
A
= m
B
. The potential is truncated at twice the minimum
position of the LJ potential, r
c,
= 2.245d

. The parameters

AA
, d
AA
, and m
A
dene the units of energy, length, and mass.
The unit of time is given by
LJ
= d
AA

m
A
/
AA
. The number
density is kept constant at = 1.2 and temperature at T = 1.
The linear dimension and total particle number are in the
range of L [4.7,203] and N [125,10684]. Equations of
motion are integrated using the velocity-Verlet algorithm with
a discrete time step of dt = 0.005.
The results presented here are expected to be general. The
choice of the above model is purely historical. We have been
030101-1 1539-3755/2013/87(3)/030101(4) 2013 American Physical Society
RAPID COMMUNICATIONS
NIMA H. SIBONI, DIERK RAABE, AND FATHOLLAH VARNIK PHYSICAL REVIEW E 87, 030101(R) (2013)
10
(a)
(b)
0
10
1
10
2
10
3
10
4
10
5
particle mass [LJ unit]
0
0.5
1
2
<
E
k
i
n
>

/

(
d
k
B
T
)
k
B
T=1
Theory
Andersen with PBC
N-H with PBC
Andersen with walls
N-H with walls
Andersen with shear
N-H with shear
0 2 4 6 8 10
time [LJ unit]
-20
0
20
40
60
P
c
m

[
L
J

u
n
i
t
]
Andersen with PBC
N-H with PBC
Andersen with walls
N-H with walls
Andersen with shear
N-H with shear
-50 0 50
P
cm
0
0.01
0.02
0.03
0.04
f
(
P
c
m
)
FIG. 1. (Color online) (a) The average kinetic energy of a massive
particle, normalized by dk
B
T/2, versus its mass for two popular
thermostating methods, both in equilibrium and under steady shear
(with uniform shear rate of = 10
3
). The solid line gives the
analytic prediction, Eq. (1). Results for a system containing two
walls are also shown for equilibriumsimulations. While equipartition
is violated in the simulations with PBC, it is well satised in the
simulations with walls. (b) Total momentum versus time for all the
simulations reported in the panel (a). The inset shows the distribution
of P
cm,x
(triangles up), P
cm,y
(triangles down), and P
cm,z
(crosses) for
the case of simulation with walls. The data perfectly obey the expected
Gaussian distribution with zero mean and variance M
total
k
B
T (solid
line).
using it to study a number of problems in the context of
the physics of glasses [1013] and encountered the present
problem as we inserted massive tracer particles to study the
concept of effective temperature [14,15].
With the exception of one, the mass of all particles is
set to unity. One of the particles (of type B) is taken to
be the massive tracer. The mass of this particle is varied
and its kinetic energy is monitored. Simulation results are
averaged over 40 independent runs. All the simulations are
performed both for the Nos e-Hoover (N-H) [16,17] and the
Andersen [18] thermostats. We also extend the present analysis
to a nonequilibrium steady state situation, by imposing a
linear shear ow via the SLLOD algorithm combined with the
Lees-Edwards boundary condition [19]. To avoid ow-induced
bias [20], in this case, only the velocity component along the
vorticity direction is coupled to the thermostat.
As depicted in Fig. 1, independent of the applied thermostat,
the violation of the equipartition theorem occurs in perfect
agreement with the theoretical predictions of Eq. (1).
To show that this behavior is due to the conservation of
the total momentum [2,5], we introduce two walls parallel
to the xy plane. The walls are made of the same particles
as the interior liquid so that liquid-wall interactions induce
uctuations of P
cm
along all spatial directions. Indeed, in
marked contrast to simulations with conserved P
cm
, the
equipartition theorem remains valid in this case (Fig. 1).
III. FLUCTUATING CENTER OF MASS
MOLECULAR DYNAMICS
The above results suggest that a possibility to restore the
equipartition theorem is to introduce walls with roughness on
the particle scale. However, in studies focusing on bulk prop-
erties, walls are undesired since they in general inuence the
system properties unless very large wall-to-wall separations
are used (see, e.g., Refs. [2123], and references therein).
Thus, it is desirable to introduce a method which uses PBC,
while at the same time allowing for uctuations of the total
momentum. Such a method is proposed here. Our approach is
motivated by the fact that in a system exchanging momentum
with its environment, the center of mass momentum is a
uctuating quantity.
We thus propose the following scheme: (i) Draw a value
for P
cm
and (ii) distribute it among particles. These steps are
carried over, repeatedly, during the simulation. In order to have
the canonical sampling of the phase space, the total momentum
assigned in step (i) should assume a distribution probability
coinciding with the canonical distribution function for P
cm
:
f( P
cm
) =
_
f ()
_
N

i=1
p
i
P
cm
_
d
=
_
1
2k
B
T M
total
exp
_

P
2
cm
2k
B
T M
total
_
, (2)
where f () is the probability of the microstate , and is the
Dirac delta function. Similar to the discussion in Ref. [1] for
choosing kinetic energy from the canonical distribution, one
has a certain exibility in choosing the sampling rate.
We provide a physical criterion to estimate the time scale of
the P
cm
uctuations. For a nonisolated system with P
cm
(t =
0) = 0, the total momentum will increase with time due to
interactions with the surrounding medium. On the other hand,
too large a value of P
cm
will decay due to the same interactions.
Collisions with the surrounding medium thus provide a source
of stochastic noise and, at the same time, give rise to viscous
friction. This is very similar to velocity uctuations of a
Brownian particle caused by collisions with the particles of
the surrounding uid. The probability distribution of these
uctuations is obtained as the solution of a Fokker-Planck
equation subjected to the potential [24],
f( P
cm
,t )
t
=

P
cm

_
f

P
cm

_
+D
_

P
cm
_
2
f, (3)
where ( P
cm
) = P
2
cm
/(2M
total
) and |
P
cm
= (/P
cm,x
,
/P
cm,y
,/P
cm,z
). The mobility and diffusion constant
D obey the Einstein relation = D/(k
B
T ). Given P

cm
at
time t

, the conditional probability distribution at a time t > t

030101-2
RAPID COMMUNICATIONS
MAINTAINING THE EQUIPARTITION THEOREM IN SMALL . . . PHYSICAL REVIEW E 87, 030101(R) (2013)
is [24]
f( P
cm
,t | P

cm
,t

) =
_
1
2
2
(t,t

)
exp
_
{ P
cm
P

cm
exp[ (t t

)]}
2
2
2
(t,t

)
_
,
(4)
where = /M
total
and
2
(t,t

) = dk
B
T M
total
{1
exp[2 (t t

)]}. It is seen from Eq. (4) that f reaches


the expected Maxwell distribution, Eq. (2), in the limit of long
times, t t

1/ . The characteristic time for reaching the


equilibrium distribution of center of mass uctuations is thus
obtained from = 1/ ,
=
M
total
k
B
T
D
. (5)
This expression is not fully satisfactory as it contains an
important unknown parameter, D. We therefore attempt at an
estimate of from a microscopic consideration. Starting with
P
cm
(t = 0) = 0, collisions with the surrounding medium will
lead to P
2
cm
= dM
total
k
B
T within a time of the order of .
For simplicity, we assume here that P
cm
is the sum of N
s
statistically independent elementary momentum uctuations,
p
i
, resulting from the collisions between uid particles
with the systems boundary, P
cm
=

N
s
i
p
i
. This yields
P
2
cm
= N
s
p
2
and thus N
s
p
2
= dM
total
k
B
T . The time
scale is encoded in the number of elementary collisions N
s
.
To see this, we rst note that momentum exchange occurs
within a skinparallel to the boundaryof thickness equal
to mean free path, l
free
. On average,
1
6
of these particles in the
skin layer move along the perpendicular direction toward the
boundary and will undergo a collision within a time of t
l
free
/v = l
free
/

3k
B
T/m where v is the average thermal
velocity. The total number of collisions within a time of is
thus obtained as N
s
l
free
A/6 /t A

k
B
T/(12m).
To arrive at a closed expression for , the magnitude of the
typical momentum exchange per collision is estimated: p
2mv =

12mk
B
T . Combining the above two expressions
for N
s
and using this last relation for p, one nally nds
=
C
(mk
B
T )
1/2
M
total
A
, (6)
where C is a constant prefactor. Equation (6) gives an estimate
for the characteristic time of the P
cm
uctuations in a system
exchanging momentum with a boundary of area A.
To test Eq. (6), we have performed MD simulations of
the binary LJ model between two parallel walls for different
system sizes. is obtained from the decay of the P
cm
autocorrelation function. We identify the parameter A in
Eq. (6) as the surface of the walls (note the PBC along the x
and y directions). Two different geometries are studied leading
to qualitatively different results for in terms of the total
mass: (I) a cube with variable length L so that M
total
= L
3
and A = L
2
= (M
total
/)
2/3
and thus M
1/3
total
; (II) constant
wall area A but variable wall-to-wall separation. This gives
M
total
. These two sets of simulations clearly conrm the
validity of Eq. (6) (Fig. 2).
10
2
10
3
10
4
M
total
10
0
10
1
t
i
m
e

s
c
a
l
e
,

MD (case I)
MD (case II)
~M
1/3
total
~M
total
FIG. 2. (Color online) The time scale for P
cm
uctuations
versus total mass in a system conned by two planar walls.
is determined from the decay of the autocorrelation function,
P
cm
(t ) P
cm
(0). Results are shown for two different geometries. In
case I, the simulation box is a cube and the variation of M
total
is
accompanied by a corresponding change of the surface area of the
walls. In case II, the surface area of the walls is kept constant but only
the distance of the walls is varied. Using Eq. (6), one thus expects
M
1/3
total
in case I but M
total
in case II (solid lines).
Therefore, in the proposed uctuating center of mass
molecular dynamics (FCMMD) scheme, P
cm
is updated with
a time step of the order of , Eq. (6). The question arises
now as to how to distribute a given P
cm
among particles. In
the canonical ensemble, if the total momentum of the system
is P
cm
, the conditional average for the particle velocity is
equal to v|
P
cm
= V
cm
(V
cm
=center of mass velocity). This
means that the velocity of all particles shall be incremented
by the uctuating center of mass velocity. We increment, in
successive time steps of t = /N, the velocity of a single,
randomly selected particle by V
cm
. This is motivated by the
fact that in a real system, collisions between the uid particles
and the boundary occur successively in time. One should note
that in contrast to our implementation, simultaneous increment
of all velocities will have no effect on the dynamics of the
10
0
10
1
10
2
10
3
10
4
10
5
10
6
particle mass
0
0.2
0.4
0.6
0.8
1
<
E
k
i
n
>
/
(
d
m
k
B
T
)
k
B
T=1
Theory (no P
cm
-fluct.)
MD (no P
cm
-fluct.)
FCMMD (equilibrium)
FCMMD (steady shear)
FIG. 3. (Color online) Restoring the equipartition theoremvia the
proposed uctuating center of mass molecular dynamics (FCMMD)
method. The average kinetic energy of a massive particle, normalized
by d k
B
T/2, is shown versus its mass both for equilibriumsimulations
as well as under steady shear in the linear response regime (uniform
shear rate of = 10
3
). For comparison, we also plot results of
MD simulations without P
cm
uctuations and the corresponding
theoretical curve, Eq. (1).
030101-3
RAPID COMMUNICATIONS
NIMA H. SIBONI, DIERK RAABE, AND FATHOLLAH VARNIK PHYSICAL REVIEW E 87, 030101(R) (2013)
system (Galilean invariance). After adding momentum to each
particle, relative velocities of all particles with respect to the
center of mass are rescaled. This last operation does not modify
the center of mass momentum but allows restoration of the
kinetic energy exactly to the value before updating P
cm
.
As shown in Fig. 3, our simulations conrm that the
proposed approach allows us to maintain the equipartition
theorem both in equilibrium simulations as well as in a system
beyond equilibrium in the linear response regime.
IV. CONCLUSION
In this work, we propose a modication of the molecular
dynamics method with periodic boundary condition to restore
the equipartition theorem. The method is based on introducing
uctuations of the center of mass momentum. The issue of
a proper rate at which P
cm
uctuations are added to the
system is also addressed and validated against simulations.
It is shown that the method restores equipartition both at
equilibrium and under steady shear in the linear response
regime. This latter nding is of crucial importance for studies
which focus on a violation of the equipartition due to nonlinear
off-equilibrium effects [14,15]. It is noteworthy that the
violation of equipartition does not exclusively occur in MD
simulations. As an example, it has also been observed in the
uctuating lattice Boltzmann method where equipartitioning is
important at all length scales [25]. The relevance of the present
work is thus not restricted to molecular dynamics simulations
but also extends to uctuating mesoscale methods [26,27].
ACKNOWLEDGMENTS
N.H.S. gratefully acknowledges the nancial support from
the Deutsche Forschungsgemeinschaft (Grant No. GSC 111).
ICAMS gratefully acknowledges funding from its industrial
sponsors, the state of North RhineWestphalia and the Euro-
pean Commission in the framework of the European Regional
Development Fund (ERDF).
[1] G. Bussi, D. Donadio, and M. Parrinello, J. Chem. Phys. 126,
014101 (2007).
[2] R. B. Shirts, S. R. Burt, and A. M. Johnson, J. Chem. Phys. 125,
164102 (2006).
[3] J. R. Ray and H. Zhang, Phys. Rev. E 59, 4781 (1999).
[4] M. E. Tuckerman, Y. Liu, G. Ciccotti, and G. J. Martyna,
J. Chem. Phys. 115, 1678 (2001).
[5] M. J. Uline, D. W. Siderius, and D. S. Corti, J. Chem. Phys. 128,
124301 (2008).
[6] J. J. Erpenbeck and W. W. Wood, in Statistical Mechanics Part B:
Time-Dependent Processes, edited by B. Berne (Plenum Press,
New York, 1977).
[7] J. L. Lebowitz, J. K. Percus, and L. Verlet, Phys. Rev. 153, 250
(1967).
[8] W. Kob and H. C. Andersen, Phys. Rev. Lett. 73, 1376 (1994).
[9] W. Kob and H. C. Andersen, Phys. Rev. E 51, 4626 (1995).
[10] F. Varnik, L. Bocquet, and J.-L. Barrat, J. Chem. Phys. 120, 2788
(2004).
[11] F. Varnik, J. Chem. Phys. 125, 164514 (2006).
[12] F. Varnik and O. Henrich, Phys. Rev. B 73, 174209 (2006).
[13] F. Varnik and D. Raabe, Phys. Rev. E 77, 011504 (2008).
[14] P. Sollich, Phys. Rev. E 58, 738 (1998).
[15] L. Berthier and J.-L. Barrat, J. Chem. Phys. 116, 6228 (2002).
[16] S. Nos e, J. Chem. Phys. 81, 511 (1984).
[17] W. G. Hoover, Phys. Rev. A 31, 1695 (1985).
[18] H. C. Andersen, J. Chem. Phys. 72, 2384 (1980).
[19] D. J. Evans and G. P. Morriss, Statistical Mechanics of
Nonequilibrium Liquids (Academic Press, London, 1990).
[20] D. J. Evans and G. P. Morriss, Phys. Rev. Lett. 56, 2172
(1986).
[21] F. Varnik, J. Baschnagel, and K. Binder, Phys. Rev. E65, 021507
(2002).
[22] F. Varnik, J. Baschnagel, and K. Binder, Eur. Phys. J. E 8, 175
(2002).
[23] J. Baschnagel and F. Varnik, J. Phys.: Condens. Matter 17, R851
(2005).
[24] H. Risken, The Fokker-Planck Equation, 2nd ed. (Springer,
Berlin, 1989).
[25] S. T. T. Ollila, C. Denniston, M. Karttunen, and T. Ala-Nissila,
J. Chem. Phys. 134, 064902 (2011).
[26] M. Gross, R. Adhikari, M. E. Cates, and F. Varnik, Phys. Rev. E
82, 056714 (2010).
[27] M. Gross, M. Cates, F. Varnik, and R. Adhikari, J. Stat. Mech.
(2011) P03030.
030101-4

You might also like