erfc (x) = 1 ’ erf (x) = √ (13.180)

π x

we summarize the relevant functions:

β 3 ’(βr)2

w(r) = w(r) = 3/2 e , (13.181)

π

1

•s (r) =

(13.159) erfc (βr), (13.182)

r

1 2 β ’β 2 r2

erfc (βr) + √

f s (r) =

(13.161) e , (13.183)

r2 πr

k2

1

exp ’ 2 .

(13.170) Wk = (13.184)

V 4β

The explicit expressions for the energies and forces are given below. A prime

above a sum means that the self-term i = j for n = 0 and the excluded pairs

(i, j, n) ∈ exclusion list are excluded from the sum.

erfc (βrijn )

11

s

(13.158) UC = qi qj , (13.185)

4πµ0 2 rijn

n

i,j

13.10 Potentials and ¬elds in periodic systems of charges 369

k2

11 1 ik·(r i ’r j )

exp ’ 2

l

(13.160) UC = qi qj e

k2

2µ0 V 2 4β

k=0

i,j

’Uself ’ Uexcl ,

l l

(13.186)

1 2β

√,

l 2

(13.175) Uself = qi (13.187)

4πµ0 π

i

erf (βrijn )

1

l

(13.176) Uexcl = qi qj , (13.188)

4πµ0 rijn

i,j,n∈exclusionlist

qi erfc (βr) 2β

+ √ e’β r ,

22

Fs =

(13.160) qj

i

r2

4πµ0 rπ

n

j

r = rijn = |r i ’ r j ’ Tn|, (13.189)

k2

qi ik

eik·(r i ’r j ) , (13.190)

Fi = ’ exp ’ 2

l

((13.177)

k2

µ0 V 4β

k j

qi qj erf (βr) 2 β ’β 2 r2 r

’√

i,excl = ’F j,excl =

Fl l

(13.178) e ,

r2

4πµ0 πr r

r = r i ’ r j ’ Tn, (i, j, n) ∈ exclusion list. (13.191)

The exclusion forces F li,excl must be subtracted from the long-range force

F l calculated from (13.190). There is no force due the self-energy contained

i

in the long-range energy.

Figure 13.6 shows the Gaussian spread function and the corresponding

short- and long-range potential functions, the latter adding up to the total

potential 1/r.

13.10.4 Cubic spread function

The Gaussian spread function is by no means the only possible choice.14 In

fact, a spread function that leads to forces which go smoothly to zero at a

given cut-o¬ radius rc and stay exactly zero beyond that radius, have the ad-

vantage above Gaussian functions that no cut-o¬ artifacts are introduced in

the integration of the equations of motion. Any charge spread function that

is exactly zero beyond rc will produce a short-range force with zero value

and zero derivative at rc . In addition we require that the Fourier transform

rapidly decays for large k in order to allow e¬cient determination of the

long-range forces; this implies a smooth spread function. A discontinuous

function, and even a discontinuous derivative, will produce wiggles in the

14 Berendsen (1993) lists a number of choices, but does not include the cubic spread function.

370 Electromagnetism

3

2.5 •s(r)

2 r ’1

1.5 r ’1 ’ •s(r)

1

w(r)

0.5

0.5 1 1.5 2 2.5 3

βr

Figure 13.6 Functions for the Ewald sum: w(r) is proportional to the Gaussian

spread function; •s (r) and r’1 ’ •s (r) are the short-range and long-range potential

functions, adding up to the total Coulomb interaction r’1 .

Fourier transform. The following cubic polynomial ful¬lls all requirements;

the force function even has a vanishing second derivative, allowing the use

of higher-order integration algorithms. The functions are all analytical, al-

though tabulation is recommended for e¬cient implementation. Figure 13.7

shows spread and potential functions for the cubic spread function compa-

rable to Fig. 13.6. Figure 13.8 shows the Fourier transform Wk of both the

Gaussian and the cubic spread functions.

The cubic charge spread function is

3r2 2r3

15

(1 ’ 2 + 3 ) for r < rc ,

w(r) = 3

4πrc rc rc

= 0 for r ≥ rc , (13.192)

and its Fourier transform (13.170) is given by