Molecular Simulation/Periodic Boundary Conditions



Macroscopic systems are extremely large and are, therefore, expensive to compute by molecular simulations. For instance, one gram of water has about 3 x 1022 molecules, a number too large to be calculated, even on computers. Fortunately, periodic boundary conditions enable us to mimic an infinite system by treating a relatively small part of a system to achieve a reasonable representation of the infinite system. The particles of this small subsystem are controlled by a set of boundary conditions called a unit cell (e.g., a three-dimensional box). During the simulation, particles are free to move in the central (original) cell; therefore, their periodic images of the adjacent cells move in an identical way. This means any particle that crosses one boundary of the cell, will reappear on the opposite side.

Non-Bonded Interactions Under Periodic Boundary Conditions
A particle in a periodic cell has non-bonded interactions with the other particles both in the original cell, and also in the surrounding cells (the periodic images of the original cell). The non-bonded potential energy ($$\mathcal{V}^{NB}$$) can be written as:

$$\mathcal{V}^{NB} = \sum\limits_s^{} {\sum\limits_{i > j}^{} {v_{ij}^{NB}({r_{ij,s}})} }$$

$$v_{ij}^{NB}({r_{ij,s}}) = 4{\varepsilon _{ij}}\left[ {{{\left( {\frac{{{\sigma _{ij}}}}} \right)}^{12}} - {{\left( {\frac{{{\sigma _{ij}}}}} \right)}^6}} \right] + \frac{{{r_{ij,s}}}}$$

where $${r_{ij,s}} = \left| {{{\rm{r}}_i} - {{\rm{r}}_j} + s} \right|$$, and $${s}$$ is a translational vector to different cell images. For a periodic cubic cell of length $${L}$$, $$\mathcal{s}$$ becomes $$s = \left[ \begin{array}{l} {n_x}L\\ {n_y}L\\ {n_z}L \end{array} \right]$$

where $${n_x}$$, $${n_y}$$, and $${n_z}$$ are vectors of integers. The number of possible translational vectors, $${s}$$, are infinite. This will lead us to an infinite number of non-bonded interactions. Thus, we need to perform some approximations to deal with this problem.

The first term of the $$v_{ij}^{NB}({r_{ij,s}})$$ is the Lennard-Jones potential. This potential has an attractive component ($${C_6}{r^{ - 6}}$$) for London dispersion, which is a short range interaction. Accordingly, if the distance between interacting particles increases (i.e., r > 10 Å), the interaction becomes very weak. Thus, the interactions can be truncated for distances greater than 10 A. However, the potential will lose its continuity because of the unexpected truncation. This problem can be fixed by employing a switching function, which will smoothly scale down van der Waals interactions to zero at the cutoff distance. For faster computation, pair lists are designed to search for particles that could be inside the cutoff area within a specified range ($$r_{pairlistdist}$$ is ~2 Å larger than $$r_{cutoff}$$), and, during the simulation, lists are updated.

The second term of the $$v_{ij}^{NB}({r_{ij,s}})$$ represents the long rang ($${r^{ - 1}}$$) electrostatic potential, which cannot be truncated the same way as the Lennard-Jones potential. However, the particle mesh Ewald method could be used for treating the long range interaction part.

Minimum Image Convention
The periodic boundary conditions use the minimum image convention to calculate distances between particles in the system. Let us consider that we have four particles ($$i$$, $$j$$, $$k$$, and $$l$$) in a cubic box of length $$L$$. Then, the potential interactions will be calculated between the particle ($$i$$) and the nearest periodic images of the other particles ($$j$$, $$k$$, and $$l$$). The minimum image convention was first used by Metropolis and coworkers.

Periodic Boundary Conditions with NAMD
NAMD software requires three cell basis vectors to provide the periodic cell its size and shape: cellBasisVector1, cellBasisVector2, and cellBasisVector3. Each vector is perpendicular to the other two. The coordinates of the center of the periodic cell can be specified by the “cellOrigin” command. In addition, the “wrapAll on” command is usually used to ensure that any particle that crosses the boundary of the original cell will be imaged back into the cell.