Ewald summation

From Wikipedia, the free encyclopedia

Ewald summation is a method for computing the interaction energies of periodic systems (e.g. crystals), particularly electrostatic energies. Ewald summation is a special case of the Poisson summation formula, replacing the summation of interaction energies in real space with an equivalent summation in Fourier space. The advantage of this approach is the rapid convergence of the Fourier-space summation compared to its real-space equivalent when the real-space interactions are long-range. Because electrostatic energies consist of both short- and long-range interactions, it is maximally efficient to decompose the interaction potential into a short-range component summed in real space and a long-range component summed in Fourier space.

Contents

[edit] Derivation

Ewald summation rewrites the interaction potential as the sum of two terms

\phi(\mathbf{r}) \ \stackrel{\mathrm{def}}{=}\  \phi_{sr}(\mathbf{r}) + \phi_{lr}(\mathbf{r})

where \phi_{sr}(\mathbf{r}) represents the short-range term that sums quickly in real space and \phi_{lr}(\mathbf{r}) represents the long-range term that sums quickly in Fourier space. The long-ranged part should be finite for all arguments (most notably r = 0) but may have any convenient mathematical form, most typically a Gaussian distribution. The method assumes that the short-range part can be summed easily; hence, the problem becomes the summation of the long-range term. Due to the use of the Fourier sum, the method implicitly assumes that the system under study is infinitely periodic (a sensible assumption for the interiors of crystals). One repeating unit of this hypothetical periodic system is called a unit cell. One such cell is chosen as the "central cell" for reference and the remaining cells are called images.

The long-range interaction energy is the sum of interaction energies between the charges of a central unit cell and all the charges of the lattice. Hence, it can be represented as a double integral over two charge density fields representing the fields of the unit cell and the crystal lattice


E_{lr} = \int\int d\mathbf{r} d\mathbf{r}^{\prime} \rho_{TOT}(\mathbf{r}) \rho_{uc}(\mathbf{r}^{\prime}) \ \phi_{lr}(\mathbf{r} - \mathbf{r}^{\prime})

where the unit-cell charge density field \rho_{uc}(\mathbf{r}) is a sum over the positions \mathbf{r}_{k} of the charges qk in the central unit cell


\rho_{uc}(\mathbf{r}) \ \stackrel{\mathrm{def}}{=}\  \sum_{\mathrm{charges}\ k} q_{k} \delta(\mathbf{r} - \mathbf{r}_{k})

and the total charge density field \rho_{TOT}(\mathbf{r}) is the same sum over the unit-cell charges qk and their periodic images


\rho_{TOT}(\mathbf{r}) \ \stackrel{\mathrm{def}}{=}\  \sum_{n_{1}, n_{2}, n_{3}} \sum_{\mathrm{charges}\ k} 
q_{k} \delta(\mathbf{r} - \mathbf{r}_{k} - n_{1} \mathbf{a}_{1}  - n_{2} \mathbf{a}_{2}  - n_{3} \mathbf{a}_{3})

Here, \delta(\mathbf{x}) is the Dirac delta function, \mathbf{a}_{1}, \mathbf{a}_{2} and \mathbf{a}_{3} are the lattice vectors and n1, n2 and n3 range over all integers. The total field \rho_{TOT}(\mathbf{r}) can be represented as a convolution of \rho_{uc}(\mathbf{r}) with a lattice function L(\mathbf{r})


L(\mathbf{r}) \ \stackrel{\mathrm{def}}{=}\  \sum_{n_{1}, n_{2}, n_{3}}
\delta(\mathbf{r} - n_{1} \mathbf{a}_{1}  - n_{2} \mathbf{a}_{2}  - n_{3} \mathbf{a}_{3})

Since this is a convolution, the Fourier transformation of \rho_{TOT}(\mathbf{r}) is a product


\tilde{\rho}_{TOT}(\mathbf{k}) = \tilde{L}(\mathbf{k}) \tilde{\rho}_{uc}(\mathbf{k})

where the Fourier transform of the lattice function is another sum over delta functions


\tilde{L}(\mathbf{k}) = 
\frac{\left(2\pi \right)^{3}}{\Omega} \sum_{m_{1}, m_{2}, m_{3}}
\delta(\mathbf{k} - m_{1} \mathbf{b}_{1}  - m_{2} \mathbf{b}_{2}  - m_{3} \mathbf{b}_{3})

where the reciprocal space vectors are defined \mathbf{b}_{1} \ \stackrel{\mathrm{def}}{=}\  \mathbf{a}_{2} \times \mathbf{a}_{3} / \Omega (and cyclic permutations) where \Omega \ \stackrel{\mathrm{def}}{=}\  \mathbf{a}_{1} \cdot \left( \mathbf{a}_{2} \times \mathbf{a}_{3} \right) is the volume of the central unit cell (if it is geometrically a parallelepiped, which is often but not necessarily the case). Note that both L(\mathbf{r}) and \tilde{L}(\mathbf{k}) are real, even functions.

For brevity, define an effective single-particle potential


v(\mathbf{r}) \ \stackrel{\mathrm{def}}{=}\  \int d\mathbf{r}^{\prime} \rho_{uc}(\mathbf{r}^{\prime}) \ \phi_{lr}(\mathbf{r} - \mathbf{r}^{\prime})

Since this is also a convolution, the Fourier transformation of the same equation is a product


\tilde{V}(\mathbf{k}) \ \stackrel{\mathrm{def}}{=}\  \tilde{\rho}_{uc}(\mathbf{k}) \tilde{\Phi}(\mathbf{k})

where the Fourier transform is defined


\tilde{V}(\mathbf{k}) = \int d\mathbf{r} \ v(\mathbf{r}) \ e^{-i\mathbf{k} \cdot \mathbf{r}}

The energy can now be written as a single field integral


E_{lr} = \int d\mathbf{r} \ \rho_{TOT}(\mathbf{r}) \ v(\mathbf{r})

Using Parseval's theorem, the energy can also be summed in Fourier space


E_{lr} = 
\int \frac{d\mathbf{k}}{\left(2\pi\right)^{3}} \ \tilde{\rho}_{TOT}^{*}(\mathbf{k}) \tilde{V}(\mathbf{k}) = 
\int \frac{d\mathbf{k}}{\left(2\pi\right)^{3}} \tilde{L}^{*}(\mathbf{k}) \left| \tilde{\rho}_{uc}(\mathbf{k})\right|^{2} \tilde{\Phi}(\mathbf{k}) = 
\frac{1}{\Omega} \sum_{m_{1}, m_{2}, m_{3}}  \left| \tilde{\rho}_{uc}(\mathbf{k})\right|^{2} \tilde{\Phi}(\mathbf{k})

where \mathbf{k} = m_{1} \mathbf{b}_{1} + m_{2} \mathbf{b}_{2} + m_{3} \mathbf{b}_{3} in the final summation.

This is the essential result. Once \tilde{\rho}_{uc}(\mathbf{k}) is calculated, the summation/integration over \mathbf{k} is straightforward and should converge quickly. The most common reason for lack of convergence is a poorly defined unit cell, which must be charge neutral to avoid infinite sums.

[edit] Particle mesh Ewald (PME) method

Ewald summation was developed as a method of theoretical physics, long before the advent of computers. However, the Ewald method has enjoyed widespread use since the 1970's in computer simulations of particle systems, especially those interacting via an inverse square force law such as gravity or electrostatics. Applications include simulations of plasmas, galaxies and molecules.

As in normal Ewald summation, a generic interaction potential is separated into two terms \phi(\mathbf{r}) \ \stackrel{\mathrm{def}}{=}\  \phi_{sr}(\mathbf{r}) + \phi_{lr}(\mathbf{r}) - a short-ranged part \phi_{sr}(\mathbf{r}) that sums quickly in real space and a long-ranged part \phi_{lr}(\mathbf{r}) that sums quickly in Fourier space. The basic idea of particle mesh Ewald summation is to replace the direct summation of interaction energies between point particles


E_{TOT} = \sum_{i,j} \phi(\mathbf{r}_{j} - \mathbf{r}_{i}) = E_{sr} + E_{lr}

with two summations, a direct sum Esr of the short-ranged potential in real space


E_{sr} = \sum_{i,j} \phi_{sr}(\mathbf{r}_{j} - \mathbf{r}_{i})

(that's the particle part of particle mesh Ewald) and a summation in Fourier space of the long-ranged part


E_{lr} = \sum_{\mathbf{k}} \tilde{\Phi}_{lr}(\mathbf{k}) \left| \tilde{\rho}(\mathbf{k}) \right|^{2}

where \tilde{\Phi}_{lr} and \tilde{\rho}(\mathbf{k}) represent the Fourier transforms of the potential and the charge density (that's the Ewald part). Since both summations converge quickly in their respective spaces (real and Fourier), they may be truncated with little loss of accuracy and great improvement in required computational time. To evaluate the Fourier transform \tilde{\rho}(\mathbf{k}) of the charge density field efficiently, one uses the Fast Fourier transform, which requires that the density field be evaluated on a discrete lattice in space (that's the mesh part).

Due to the periodicity assumption implicit in Ewald summation, applications of the PME method to physical systems require the imposition of periodic symmetry. Thus, the method is best suited to systems that can be simulated as infinite in spatial extent. In molecular dynamics simulations this is normally accomplished by deliberately constructing a charge-neutral unit cell that can be infinitely "tiled" to form images; however, to properly account for the effects of this approximation, these images are reincorporated back into the original simulation cell. The overall effect is one of a three-dimensional version of the Asteroids game, in which each dimension "wraps around" on itself. This property of the cell is called a periodic boundary condition. To visualize this most clearly, think of a unit cube; the upper face is effectively in contact with the lower face, the right with the left face, and the front with the back face. As a result the unit cell size must be carefully chosen to be large enough to avoid improper motion correlations between two faces "in contact", but still small enough to be computationally feasible. The definition of the cutoff between short- and long-range interactions can also introduce artifacts.

The restriction of the density field to a mesh makes the PME method more efficient for systems with "smooth" variations in density, or continuous potential functions. Localized systems or those with large fluctuations in density may be treated more efficiently with the fast multipole method of Greengard and Rokhlin.

[edit] Dipole term

The electrostatic energy of a polar crystal (i.e., a crystal with a net dipole \mathbf{p}_{uc} in the unit cell) is conditionally convergent, i.e., depends on the order of the summation. For example, if the dipole-dipole interactions of a central unit cell with unit cells located on an ever-increasing cube, the energy converges to a different value than if the interaction energies had been summed spherically. Roughly speaking, this conditional convergence arises because (1) the number of interacting dipoles on a shell of radius R grows like R2; (2) the strength of a single dipole-dipole interaction falls like \frac{1}{R^{3}}; and (3) the mathematical summation \sum_{n=1}^{\infty} \frac{1}{n} diverges.

This somewhat surprising result can be reconciled with the finite energy of real crystals because such crystals are not infinite, i.e., have a particular boundary. More specifically, the boundary of a polar crystal has an effective surface charge density on its surface \sigma = \mathbf{P} \cdot \mathbf{n} where \mathbf{n} is the surface normal vector and \mathbf{P} represents the net dipole moment per volume. The interaction energy U of the dipole in a central unit cell with that surface charge density can be written


U = \frac{1}{2V_{uc}} \int  
\frac{\left( \mathbf{p}_{uc}\cdot \mathbf{r} \right) 
\left( \mathbf{p}_{uc} \cdot \mathbf{n} \right)dS}{r^{3}}

where \mathbf{p}_{uc} and Vuc are the net dipole moment and volume of the unit cell, dS is an infinitesimal area on the crystal surface and \mathbf{r} is the vector from the central unit cell to the infinitesimal area. This formula results from integrating the energy  dU = -\mathbf{p}_{uc} \cdot \mathbf{dE} where d\mathbf{E} represents the infinitesimal electric field generated by an infinitesimal surface charge dq \ \stackrel{\mathrm{def}}{=}\  \sigma dS (Coulomb's law)


d\mathbf{E} \ \stackrel{\mathrm{def}}{=}\  
\left( \frac{-1}{4\pi\epsilon} \right) \frac{dq \ \mathbf{r}}{r^{3}} = 
\left( \frac{-1}{4\pi\epsilon} \right) 
\frac{\sigma dS \ \mathbf{r} }{r^{3}}

The negative sign derives from the definition of \mathbf{r}, which points towards the charge, not away from it.

[edit] History

The Ewald summation was developed by Paul Peter Ewald in 1921 (see References below) to determine the electrostatic energy (and, hence, the Madelung constant) of ionic crystals.

[edit] Scaling

Generally different Ewald summation methods give different scalings. Direct calculation gives O(N2), where N is the number of atoms in the system. The PME method gives O(N\,\mathrm{log}\,N), where N is the number of atoms in the system.

[edit] See also

[edit] References

  • Ewald P. (1921) "Die Berechnung optischer und elektrostatischer Gitterpotentiale", Ann. Phys. 369, 253-287.
  • Darden T, Perera L, Li L and Pedersen L. (1999) "New tricks for modelers from the crystallography toolkit: the particle mesh Ewald algorithm and its use in nucleic acid simulations", Structure 7, R55-R60.
  • Schlick T. (2002). Molecular Modeling and Simulation: An Interdisciplinary Guide Springer-Verlag Interdisciplinary Applied Mathematics, Mathematical Biology, Vol. 21. New York, NY.