Fast Ewald summation for electrostatic systems with charges and dipoles
Fast Ewald summation for electrostatic systems with charges and dipoles for various types of periodic boundary conditions
Franziska Nestler Chemnitz University of Technology
Faculty of Mathematics
joint work with M. Hofmann, M. Pippig, D. PottsSampTA 2017
Sampling Theory and Applications, 12th International Conference
July 3 – 7, 2017, Tallinn, Estonia
Fast Ewald summation for electrostatic systems with charges and dipoles
1 Introduction: Electrostatic interactions in particle systems
2 Nonequispaced FFT and fast summation
3 P2NFFT for systems with charges and dipoles
4 Numerical results
5 Summary
Introduction: Electrostatic interactions in particle systems
The Coulomb problem
Charged particle system: Let N charges q
j∈Rat positions
xj∈R3be given.
Are interested in the electrostatic potentials (x
ij:=
xi−xj):
φ(j) :=
N
X
i=1 i6=j
q
ikxijk
, j = 1, . . . , N.
→ O(N
2)?
3d-periodic boundary conditions Choose
S:=
Z3,
xj∈[
−L/
2,
L/
2)
3and set
φ(j) :=
Xn∈S N
X
i=1 i6=jifn=0
q
ikxij
+ Ln
k→
crystals, . . .
→conditional convergence for electrical neutral particle systems
Introduction: Electrostatic interactions in particle systems
The Coulomb problem
Charged particle system: Let N charges q
j∈Rat positions
xj∈R3be given.
Are interested in the electrostatic potentials (x
ij:=
xi−xj):
φ(j) :=
N
X
i=1 i6=j
q
ikxijk
, j = 1, . . . , N.
→ O(N
2)?
3d-periodic boundary conditions Choose
S:=
Z3,
xj∈[−L/2,L/2)3and set
φ(j) :=
Xn∈S N
X
i=1 i6=jifn=0
q
ikxij
+ Ln
k→
crystals, . . .
L
→conditional convergence for electrical neutral particle systems
Introduction: Electrostatic interactions in particle systems
The Coulomb problem
Charged particle system: Let N charges q
j∈Rat positions
xj∈R3be given.
Are interested in the electrostatic potentials (x
ij:=
xi−xj):
φ(j) :=
N
X
i=1 i6=j
q
ikxijk
, j = 1, . . . , N.
→ O(N
2)?
3d-periodic boundary conditions Choose
S:=
Z3,
xj∈[
−L/
2,
L/
2)
3and set
φ(j) :=
Xn∈S N
X
i=1 i6=jifn=0
q
ikxij
+ Ln
k→
crystals, . . .
→conditional convergence for electrical neutral particle systems
Introduction: Electrostatic interactions in particle systems
The Coulomb problem
Charged particle system: Let N charges q
j∈Rat positions
xj∈R3be given.
Are interested in the electrostatic potentials (x
ij:=
xi−xj):
φ(j) :=
N
X
i=1 i6=j
q
ikxijk
, j = 1, . . . , N.
→ O(N
2)?
3d-periodic boundary conditions Choose
S:=Z3,
xj∈[
−L/
2,
L/
2)
3and set
φ(j) :=
Xn∈S N
X
i=1 i6=jifn=0
q
ikxij
+
Lnk→
crystals, . . .
→conditional convergence for electrical neutral particle systems
Introduction: Electrostatic interactions in particle systems
Extension to systems with charges and dipoles
Add
dipole particles. Given•
N
ccharges q
j∈Rat positions
xj, j = 1, . . . , N
c,
•
N
ddipoles with
dipole momentsµj∈R3at positions
xj, j = N
c+ 1, . . . , N
c+ N
d. Total number of particles N := N
c+ N
d.
Replace the charges q
jby the operators ξ
j:
q
j7→ξj:=(qj :j∈ {1, . . . , Nc}, µ>j∇xj :j∈ {Nc+ 1, . . . , N}.
Electrostatic potentials:
φ(j) :=
Xn∈S N
X
i=1 i6=jifn=0
ξi
kxij
+ Ln
k, j = 1, . . . , N.
Introduction: Electrostatic interactions in particle systems
Periodic boundary conditions
3d-periodic
S
:=
Z3 →crystals, . . .
L L
L
1
open boundary conditions
S:=
{0
}31
2d-periodic
S
:=
Z2× {0
} →thin liquid films, . . .
L L
1
1d-periodic
S
:=
Z× {0
}2 →nano channels, . . .
L
1
Introduction: Electrostatic interactions in particle systems
Periodic boundary conditions
3d-periodic
S
:=
Z3 →crystals, . . .
L L
L
1
open boundary conditions
S:=
{0
}31
2d-periodic
S
:=
Z2× {0
} →thin liquid films, . . .
L L
1d-periodic
S
:=
Z× {0
}2 →nano channels, . . .
L
Franziska Nestler, TU Chemnitz, Faculty of Mathematics 5/17
Introduction: Electrostatic interactions in particle systems
Ewald splitting
Idea of Ewald summation
[Ewald 1921]:
Ewald splitting
1
r =
erf(αr) r| {z } long ranged, continuous
+
erfc(αr) r| {z } singular in 0, short ranged
0 0.2 0.4 0.6 0.8 1
0 2 4 6 8 10
r
•
erf(x) :=
√2πRx
0
e
−t2dt (error function),
limr→0 erf(αr)
r =√2απ
•
erfc(x) := 1
−erf(x) (complementary error function)
•
α > 0 (scaling parameter)
Introduction: Electrostatic interactions in particle systems
3d-periodic boundary conditions
φ(j) = X
n∈Z3 N
X
i=1 i6=jifn=0
ξierfc(αkxij+Lnk) kxij+Lnk + X
n∈Z3 N
X
i=1
ξierf(αkxij+Lnk)
kxij+Lnk −φself(j)
• short range part:direct evaluation (truncation)
• long range part:
Fourier coefficientsare known analytically.
φself(j) = (2α
√πqj :charges
0 :dipoles
φlong(j) = X
k∈Z3\{0} N
X
i=1
ξie−π2kkk2/(α2L2)
πLkkk2 e2πik>xij/L
→good choice of truncation parameters:O(N3/2)
How to compute the long range part even more efficiently?
→ O(N log N)
•
3d-periodic constraints: FFT for nonequispaced data –
NFFT•
open and mixed periodic b.c.:
NFFT based fast summationIntroduction: Electrostatic interactions in particle systems
3d-periodic boundary conditions
φ(j) = X
n∈Z3 N
X
i=1 i6=jifn=0
ξierfc(αkxij+Lnk) kxij+Lnk + X
n∈Z3 N
X
i=1
ξierf(αkxij+Lnk)
kxij+Lnk −φself(j)
• short range part:direct evaluation (truncation)
• long range part:Fourier coefficientsare known analytically. φself(j) = (2α
√πqj :charges
0 :dipoles
φlong(j) = X
k∈Z3\{0} N
X
i=1
ξie−π2kkk2/(α2L2)
πLkkk2 e2πik>xij/L
→good choice of truncation parameters:O(N3/2)
How to compute the long range part even more efficiently?
→ O(N log N)
•
3d-periodic constraints: FFT for nonequispaced data –
NFFT•
open and mixed periodic b.c.:
NFFT based fast summationIntroduction: Electrostatic interactions in particle systems
3d-periodic boundary conditions
φ(j) = X
n∈Z3 N
X
i=1 i6=jifn=0
ξierfc(αkxij+Lnk) kxij+Lnk + X
n∈Z3 N
X
i=1
ξierf(αkxij+Lnk)
kxij+Lnk −φself(j)
• short range part:direct evaluation (truncation)
• long range part:Fourier coefficientsare known analytically. φself(j) = (2α
√πqj :charges
0 :dipoles
φlong(j) = X
k∈Z3\{0} N
X
i=1
ξie−π2kkk2/(α2L2)
πLkkk2 e2πik>xij/L
→good choice of truncation parameters:O(N3/2)
How to compute the long range part even more efficiently?
→ O(N log N )
•
3d-periodic constraints: FFT for nonequispaced data –
NFFT•
open and mixed periodic b.c.:
NFFT based fast summationNonequispaced FFT and fast summation
FFT for nonequispaced data – NFFT
Notation For M
∈2
Nset
IM:=
{−M/
2, . . . ,
M/
2−1
}d⊂Zd.
Torus
T:=
R/
Z'[
−1/
2,
1/
2)
NFFT:
f(x
j) :=
Xk∈IM
f ˆ
ke
−2πik>xj xj∈Td, j = 1, . . . , N
(inverse) FFT: f(j) :=
Xk∈IM
f ˆ
ke
−2πik>j/M j∈IM, N :=
|IM|= M
dadjoint NFFT:
h(k) :=
N
X
j=1
f
je
2πik>xj k∈ IMComplexity:
O(
|IM|log
|IM|+ N )
[Dutt, Rokhlin 1993] [Beylkin 1995] [Potts, Steidl, Tasche 2001] [Greengard, Lee 2004]
Nonequispaced FFT and fast summation
FFT for nonequispaced data – NFFT
Notation For M
∈2
Nset
IM:=
{−M/
2, . . . ,
M/
2−1
}d⊂Zd. Torus
T:=
R/
Z'[
−1/
2,
1/
2)
NFFT:
f(x
j) :=
Xk∈IM
f ˆ
ke
−2πik>xj xj∈Td, j = 1, . . . , N
(inverse) FFT: f(j) :=
Xk∈IM
f ˆ
ke
−2πik>j/M j∈ IM, N :=
|IM|= M
dadjoint NFFT:
h(k) :=
N
X
j=1
f
je
2πik>xj k∈ IMComplexity:
O(
|IM|log
|IM|+ N )
[Dutt, Rokhlin 1993] [Beylkin 1995]
[Potts, Steidl, Tasche 2001] [Greengard, Lee 2004]
Nonequispaced FFT and fast summation
FFT for nonequispaced data – NFFT
Notation For M
∈2
Nset
IM:=
{−M/
2, . . . ,
M/
2−1
}d⊂Zd. Torus
T:=
R/
Z'[
−1/
2,
1/
2)
NFFT:
f(x
j) :=
Xk∈IM
f ˆ
ke
−2πik>xj xj∈Td, j = 1, . . . , N
(inverse) FFT: f(j) :=
Xk∈IM
f ˆ
ke
−2πik>j/M j∈ IM, N :=
|IM|= M
dadjoint NFFT:
h(k) :=
N
X
j=1
f
je
2πik>xj k∈ IMComplexity:
O(
|IM|log
|IM|+ N )
[Dutt, Rokhlin 1993] [Beylkin 1995]
[Potts, Steidl, Tasche 2001] [Greengard, Lee 2004]
Nonequispaced FFT and fast summation
Further implemented variants (d = 3)
•
Gradient NFFT: Approximate
∇
f(x
j) =
− Xk∈IM
2πik f ˆ
ke
−2πik>xj ∀j = 1, . . . , N.
•
Hessian NFFT: Approximate
Hf(x
j) =
− Xk∈IM
4π
2kk>f ˆ
ke
−2πik>xj ∀j = 1, . . . , N.
•
Adjoint gradient NFFT: For given
fj∈C3approximate
N
X
j=1
f>j∇x
e
2πik>x x=xj
=
N
X
j=1
2πif
>jke
2πik>xj ∀k∈ IM.
Complexity:
O(
|IM|log
|IM|+ N )
X [M. Pippig, PNFFT library, https://github.com/mpip/pfft]Nonequispaced FFT and fast summation
Further implemented variants (d = 3)
•
Gradient NFFT: Approximate
∇
f(x
j) =
− Xk∈IM
2πik f ˆ
ke
−2πik>xj ∀j = 1, . . . , N.
•
Hessian NFFT: Approximate
Hf(x
j) =
− Xk∈IM
4π
2kk>f ˆ
ke
−2πik>xj ∀j = 1, . . . , N.
•
Adjoint gradient NFFT: For given
fj∈C3approximate
N
X
j=1
f>j∇x
e
2πik>x x=xj
=
N
X
j=1
2πif
>jke
2πik>xj ∀k∈ IM.
Complexity:
O(
|IM|log
|IM|+ N )
X [M. Pippig, PNFFT library, https://github.com/mpip/pfft]Nonequispaced FFT and fast summation
NFFT based fast summation in 1d
[Potts, Steidl 2003]Computef(xj) :=
N
X
i=1
ciK(xi−xj) withxj∈[−L/2,L/2] ⇒xi−xj∈[−L, L].
EmbedK(·)into a periodic function:
−L L
K(x)
→Two-point-Taylor interpolation
periodh >2L. . .
KR(x)≈ X
`∈IM
ˆb`e2πi`x/h
Sampleperiodic func.at equispaced nodes. Use the FFT to approximate the FKˆb`.
f(xj)≈
N
X
i=1
ci
X
`∈IM
ˆb`e2πi`(xi−xj)/h= X
`∈IM
ˆb`
N
X
i=1
cie2πi`xi/h
!
| {z }
adj. NFFT
e−2πi`xj/h
| {z }
NFFT
Nonequispaced FFT and fast summation
NFFT based fast summation in 1d
[Potts, Steidl 2003]Computef(xj) :=
N
X
i=1
ciK(xi−xj) withxj∈[−L/2,L/2] ⇒xi−xj∈[−L, L].
EmbedK(·)into a periodic function:
−L L
−h2 h2 h−L K(x)
→Two-point-Taylor interpolation
periodh >2L. . .
KR(x)≈ X
`∈IM
ˆb`e2πi`x/h
Sampleperiodic func.at equispaced nodes. Use the FFT to approximate the FKˆb`.
f(xj)≈
N
X
i=1
ci
X
`∈IM
ˆb`e2πi`(xi−xj)/h= X
`∈IM
ˆb`
N
X
i=1
cie2πi`xi/h
!
| {z }
adj. NFFT
e−2πi`xj/h
| {z }
NFFT
Nonequispaced FFT and fast summation
NFFT based fast summation in 1d
[Potts, Steidl 2003]Computef(xj) :=
N
X
i=1
ciK(xi−xj) withxj∈[−L/2,L/2] ⇒xi−xj∈[−L, L].
EmbedK(·)into a periodic function:
−L L
−h2 h2 h−L K(x) KB(x)
Cp−1
→Two-point-Taylor interpolation
periodh >2L. . .
KR(x)≈ X
`∈IM
ˆb`e2πi`x/h
Sampleperiodic func.at equispaced nodes. Use the FFT to approximate the FKˆb`.
f(xj)≈
N
X
i=1
ci
X
`∈IM
ˆb`e2πi`(xi−xj)/h= X
`∈IM
ˆb`
N
X
i=1
cie2πi`xi/h
!
| {z }
adj. NFFT
e−2πi`xj/h
| {z }
NFFT
Nonequispaced FFT and fast summation
NFFT based fast summation in 1d
[Potts, Steidl 2003]Computef(xj) :=
N
X
i=1
ciK(xi−xj) withxj∈[−L/2,L/2] ⇒xi−xj∈[−L, L].
EmbedK(·)into a periodic function:
−h2 h2
KR(x) Cp−1
→Two-point-Taylor interpolation
periodh >2L. . .
KR(x)≈ X
`∈IM
ˆb`e2πi`x/h
Sampleperiodic func.at equispaced nodes.
Use the FFT to approximate the FKˆb`.
f(xj)≈
N
X
i=1
ci
X
`∈IM
ˆb`e2πi`(xi−xj)/h= X
`∈IM
ˆb`
N
X
i=1
cie2πi`xi/h
!
| {z }
adj. NFFT
e−2πi`xj/h
| {z }
NFFT
Nonequispaced FFT and fast summation
NFFT based fast summation in 1d
[Potts, Steidl 2003]Computef(xj) :=
N
X
i=1
ciK(xi−xj) withxj∈[−L/2,L/2] ⇒xi−xj∈[−L, L].
EmbedK(·)into a periodic function:
−h2 h2
KR(x) Cp−1
→Two-point-Taylor interpolation
periodh >2L. . .
KR(x)≈ X
`∈IM
ˆb`e2πi`x/h
Sampleperiodic func.at equispaced nodes.
Use the FFT to approximate the FKˆb`.
f(xj)≈
N
X
i=1
ci
X
`∈IM
ˆb`e2πi`(xi−xj)/h
= X
`∈IM
ˆb`
N
X
i=1
cie2πi`xi/h
!
| {z }
adj. NFFT
e−2πi`xj/h
| {z }
NFFT
Nonequispaced FFT and fast summation
NFFT based fast summation in 1d
[Potts, Steidl 2003]Computef(xj) :=
N
X
i=1
ciK(xi−xj) withxj∈[−L/2,L/2] ⇒xi−xj∈[−L, L].
EmbedK(·)into a periodic function:
−h2 h2
KR(x) Cp−1
→Two-point-Taylor interpolation
periodh >2L. . .
KR(x)≈ X
`∈IM
ˆb`e2πi`x/h
Sampleperiodic func.at equispaced nodes.
Use the FFT to approximate the FKˆb`.
f(xj)≈
N
X
i=1
ci
X
`∈IM
ˆb`e2πi`(xi−xj)/h= X
`∈IM
ˆb`
N
X
i=1
cie2πi`xi/h
!
| {z }
adj. NFFT
e−2πi`xj/h
| {z }
NFFT
Nonequispaced FFT and fast summation
For d ≥ 2 dimensions, radial kernels
Computef(xj) :=
N
X
i=1
ciK(kxi−xjk), assumekxi−xjk ≤L.
−h2 −L L h
2 h−L 3h
2 Cp−1
K(x)
KB(x)
→regularization in 1d
→two-point-Taylor interpolation
→modification: claim vanishing derivatives inh/2
K(kxk) KB(kxk)
−L L
−h2 h
2 3h
h−L 2
−L L
−h2 h
2 Rotation inRd:
KR(x) :=
K(kxk) :kxk ≤L KB(kxk) :L <kxk ≤h/2
KB(h/2) :else
→h-periodization with respect to all dimensions is a smooth function
→approximateKR(·)by ad-variate trigonometric polynomial (FFT) and proceed analogously to 1d
Nonequispaced FFT and fast summation
For d ≥ 2 dimensions, radial kernels
Computef(xj) :=
N
X
i=1
ciK(kxi−xjk), assumekxi−xjk ≤L.
−h2 −L L h
2 h−L 3h
2 Cp−1
K(x)
KB(x)
→regularization in 1d
→two-point-Taylor interpolation
→modification: claim vanishing derivatives inh/2
K(kxk) KB(kxk)
−L L
−h2 h
2 3h
h−L 2
−L L
−h2 h
2 Rotation inRd:
KR(x) :=
K(kxk) :kxk ≤L KB(kxk) :L <kxk ≤h/2
KB(h/2) :else
→h-periodization with respect to all dimensions is a smooth function
→approximateKR(·)by ad-variate trigonometric polynomial (FFT) and proceed analogously to 1d
P2NFFT for systems with charges and dipoles
3d-periodic boundary conditions
φ(j) =
Xn∈Z3 N
X
i=1 i6=jifn=0
ξierfc(αkxij+Lnk) kxij+Lnk
+
Xn∈Z3 N
X
i=1
ξierf(αkxij+Lnk)
kxij+Lnk −
φ
self(j)
short:direct evaluation (truncation)
long:
Fourier coefficients are known analytically. ˆ b
k:=
e−π2πLkkkk2k/(αk22L2 ),
k6=
0.φ
long(j)
≈ Xk∈IM
ˆ b
k NcX
i=1
q
ie
2πik>xi/L| {z }
adj. NFFT
+
N
X
i=Nc+1
µ>i∇xi
e
2πik>xi/L| {z }
adj. grad. NFFT
!
e
−2πik>xj/L| {z }
NFFT
Computation of the forces:
charges: F(j) =−∇xjφ(j)·qj →gradient NFFT dipoles: F(j) =−∇xj∇>xjφ(j)·µj →Hessian NFFT
[Hofmann, N., Pippig 2016 (preprint)]
P2NFFT for systems with charges and dipoles
3d-periodic boundary conditions
φ(j) =
Xn∈Z3 N
X
i=1 i6=jifn=0
ξierfc(αkxij+Lnk) kxij+Lnk
+
Xn∈Z3 N
X
i=1
ξierf(αkxij+Lnk)
kxij+Lnk −
φ
self(j)
short:direct evaluation (truncation)
long:
Fourier coefficients are known analytically. ˆ b
k:=
e−π2πLkkkk2k/(αk22L2 ),
k6=
0.φ
long(j)
≈ Xk∈IM
ˆ b
k NcX
i=1
q
ie
2πik>xi/L| {z }
adj. NFFT
+
N
X
i=Nc+1
µ>i ∇xi
e
2πik>xi/L| {z }
adj. grad. NFFT
!
e
−2πik>xj/L| {z }
NFFT
Computation of the forces:
charges: F(j) =−∇xjφ(j)·qj →gradient NFFT dipoles: F(j) =−∇xj∇>xjφ(j)·µj →Hessian NFFT
Fast algorithm: particle-particle NFFT,O(NlogN)[Pippig, Potts 2011] [Hofmann, N., Pippig 2016 (preprint)]
P2NFFT for systems with charges and dipoles
3d-periodic boundary conditions
φ(j) =
Xn∈Z3 N
X
i=1 i6=jifn=0
ξierfc(αkxij+Lnk) kxij+Lnk
+
Xn∈Z3 N
X
i=1
ξierf(αkxij+Lnk)
kxij+Lnk −
φ
self(j)
short:direct evaluation (truncation)
long:
Fourier coefficients are known analytically. ˆ b
k:=
e−π2πLkkkk2k/(αk22L2 ),
k6=
0.φ
long(j)
≈ Xk∈IM
ˆ b
k NcX
i=1
q
ie
2πik>xi/L| {z }
adj. NFFT
+
N
X
i=Nc+1
µ>i ∇xi
e
2πik>xi/L| {z }
adj. grad. NFFT
!
e
−2πik>xj/L| {z }
NFFT
Computation of the forces:
charges: F(j) =−∇xjφ(j)·qj →gradient NFFT dipoles: F(j) =−∇xj∇>xjφ(j)·µj →Hessian NFFT
P2NFFT for systems with charges and dipoles
Open and mixed periodic boundary conditions
[N., Pippig, Potts 2015]φlong(j) regularization / fast summation
0dp =
N
X
i=1
ξi
erf(αkxijk) kxijk
erf(αkxijk) kxijk ≈ X
`∈IM
ˆb`e2πi`>xij/h d= 3
1dp
≈ X
k∈IM N
X
i=1
ξie2πikxij,1/LΘp1k,α(kx˜ijk) Θp1k,α(kx˜ijk)≈ X
`∈IM
ˆbk,`e2πi`>x˜ij/h d= 2
2dp
≈ X
k∈IM N
X
i=1
ξie2πik>˜xij/LΘp2k,α(|xij,3|) Θp2k,α(|xij,3|)≈ X
`∈IM
ˆbk,`e2πi`xij,3/h d= 1
→Ewald summation for 1d- and 2d-periodic constraints [M. Porto 2000] [Grzybowski, Gwó´zd´z, Bródka 2000]
φlong(j)≈ X
(∗,∗)∈IM
ˆb(∗,∗) Nc
X
i=1
qie2πi(∗,∗)>x˘i
| {z }
adj. NFFT
+
N
X
i=Nc+1
µ>i∇xie2πi(∗,∗)>x˘i
| {z }
adj. grad. NFFT
!
e−2πi(∗,∗)>x˘j
| {z }
NFFT
→same structure as for 3d-periodic boundary conditions
* periodic dimensions * non periodic dimensions
P2NFFT for systems with charges and dipoles
Open and mixed periodic boundary conditions
[N., Pippig, Potts 2015]φlong(j) regularization / fast summation
0dp =
N
X
i=1
ξi
erf(αkxijk) kxijk
erf(αkxijk) kxijk ≈ X
`∈IM
ˆb`e2πi`>xij/h d= 3
1dp
≈ X
k∈IM N
X
i=1
ξie2πikxij,1/LΘp1k,α(kx˜ijk) Θp1k,α(kx˜ijk)≈ X
`∈IM
ˆbk,`e2πi`>x˜ij/h d= 2
2dp
≈ X
k∈IM N
X
i=1
ξie2πik>˜xij/LΘp2k,α(|xij,3|) Θp2k,α(|xij,3|)≈ X
`∈IM
ˆbk,`e2πi`xij,3/h d= 1
→Ewald summation for 1d- and 2d-periodic constraints [M. Porto 2000] [Grzybowski, Gwó´zd´z, Bródka 2000]
φlong(j)≈ X
(∗,∗)∈IM
ˆb(∗,∗) Nc
X
i=1
qie2πi(∗,∗)>x˘i
| {z }
adj. NFFT
+
N
X
i=Nc+1
µ>i∇xie2πi(∗,∗)>x˘i
| {z }
adj. grad. NFFT
!
e−2πi(∗,∗)>x˘j
| {z }
NFFT
→same structure as for 3d-periodic boundary conditions
* periodic dimensions * non periodic dimensions
P2NFFT for systems with charges and dipoles
Open and mixed periodic boundary conditions
[N., Pippig, Potts 2015]φlong(j) regularization / fast summation
0dp =
N
X
i=1
ξi
erf(αkxijk) kxijk
erf(αkxijk) kxijk ≈ X
`∈IM
ˆb`e2πi`>xij/h d= 3
1dp ≈ X
k∈IM N
X
i=1
ξie2πikxij,1/LΘp1k,α(kx˜ijk)
Θp1k,α(kx˜ijk)≈ X
`∈IM
ˆbk,`e2πi`>x˜ij/h d= 2
2dp ≈ X
k∈IM N
X
i=1
ξie2πik>˜xij/LΘp2k,α(|xij,3|)
Θp2k,α(|xij,3|)≈ X
`∈IM
ˆbk,`e2πi`xij,3/h d= 1
→Ewald summation for 1d- and 2d-periodic constraints [M. Porto 2000] [Grzybowski, Gwó´zd´z, Bródka 2000]
φlong(j)≈ X
(∗,∗)∈IM
ˆb(∗,∗) Nc
X
i=1
qie2πi(∗,∗)>x˘i
| {z }
adj. NFFT
+
N
X
i=Nc+1
µ>i∇xie2πi(∗,∗)>x˘i
| {z }
adj. grad. NFFT
!
e−2πi(∗,∗)>x˘j
| {z }
NFFT
→same structure as for 3d-periodic boundary conditions
* periodic dimensions
* non periodic dimensions
P2NFFT for systems with charges and dipoles
Open and mixed periodic boundary conditions
[N., Pippig, Potts 2015]φlong(j) regularization / fast summation
0dp =
N
X
i=1
ξi
erf(αkxijk) kxijk
erf(αkxijk) kxijk ≈ X
`∈IM
ˆb`e2πi`>xij/h d= 3
1dp ≈ X
k∈IM N
X
i=1
ξie2πikxij,1/LΘp1k,α(kx˜ijk) Θp1k,α(kx˜ijk)≈ X
`∈IM
ˆbk,`e2πi`>x˜ij/h d= 2
2dp ≈ X
k∈IM N
X
i=1
ξie2πik>˜xij/LΘp2k,α(|xij,3|) Θp2k,α(|xij,3|)≈ X
`∈IM
ˆbk,`e2πi`xij,3/h d= 1
→Ewald summation for 1d- and 2d-periodic constraints [M. Porto 2000] [Grzybowski, Gwó´zd´z, Bródka 2000]
φlong(j)≈ X
(∗,∗)∈IM
ˆb(∗,∗) Nc
X
i=1
qie2πi(∗,∗)>x˘i
| {z }
adj. NFFT
+
N
X
i=Nc+1
µ>i∇xie2πi(∗,∗)>x˘i
| {z }
adj. grad. NFFT
!
e−2πi(∗,∗)>x˘j
| {z }
NFFT
→same structure as for 3d-periodic boundary conditions
P2NFFT for systems with charges and dipoles
Open and mixed periodic boundary conditions
[N., Pippig, Potts 2015]φlong(j) regularization / fast summation
0dp =
N
X
i=1
ξi
erf(αkxijk) kxijk
erf(αkxijk) kxijk ≈ X
`∈IM
ˆb`e2πi`>xij/h d= 3
1dp ≈ X
k∈IM N
X
i=1
ξie2πikxij,1/LΘp1k,α(kx˜ijk) Θp1k,α(kx˜ijk)≈ X
`∈IM
ˆbk,`e2πi`>x˜ij/h d= 2
2dp ≈ X
k∈IM N
X
i=1
ξie2πik>˜xij/LΘp2k,α(|xij,3|) Θp2k,α(|xij,3|)≈ X
`∈IM
ˆbk,`e2πi`xij,3/h d= 1
→Ewald summation for 1d- and 2d-periodic constraints [M. Porto 2000] [Grzybowski, Gwó´zd´z, Bródka 2000]
φlong(j)≈ X
(∗,∗)∈IM
ˆb(∗,∗)
Nc
X
i=1
qie2πi(∗,∗)>x˘i
| {z }
adj. NFFT
+
N
X
i=Nc+1
µ>i∇xie2πi(∗,∗)>˘xi
| {z }
adj. grad. NFFT
!
e−2πi(∗,∗)>x˘j
| {z }
NFFT
→same structure as for 3d-periodic boundary conditions
* periodic dimensions * non periodic dimensions
Numerical results
Error estimates for 3d-periodic boundary conditions
Root mean square (rms) errors in the forces
∆F:=
v u u t 1 N
N
X
j=1
kF(j)−F≈(j)k2≈ ?
Two types of errors:
1
Truncation of Ewald sums
Fshort(j)≈Fshorttrunc.(j),Flong(j)≈Flongtrunc.(j)X
charge-charge interactions (3d-p.)
[Kolafa, Perram 1992] Xdipole-dipole interactions (3d-p.)
[Wang, Holm 2001]X
extension to charge-dipole systems (3d-p.)
[Hofmann, N., Pippig 2016 (preprint)]2
NFFT based approximation errors
Flongtrunc.(j)≈FlongNFFT(j)Numerical results
Error estimates for 3d-periodic boundary conditions
Root mean square (rms) errors in the forces
∆F:=
v u u t 1 N
N
X
j=1
kF(j)−F≈(j)k2≈ ?
Two types of errors:
1 Truncation of Ewald sums Fshort(j)≈Fshorttrunc.(j),Flong(j)≈Flongtrunc.(j)
X
charge-charge interactions (3d-p.)
[Kolafa, Perram 1992]X
dipole-dipole interactions (3d-p.)
[Wang, Holm 2001]X
extension to charge-dipole systems (3d-p.)
[Hofmann, N., Pippig 2016 (preprint)]2
NFFT based approximation errors
Flongtrunc.(j)≈FlongNFFT(j)Numerical results
Truncation errors in the Ewald sums (3d-periodic)
Based on existing estimates: Ewald truncation errors are predicted accurately.
charges:
0.5 1 1.5 2
10−14 10−11 10−8 10−5 10−2
rcut
=3.5 rcut
=4.0 rcut
=4.5 rcut
= 5.0 M= 16
M=24 M=32
α
rmsforceerror
dipoles:
0.5 1 1.5 2
10−14 10−11 10−8 10−5 10−2
rcut
=3.5 rcut
=4.0 rcut
=4.5 rcut
= 5.0 M= 16
M=24 M=32
α
rmsforceerror
Figure:
• Solid: Measured rms force errors in a small particle system.Nc=Nd= 50, L= 10.
• Dotted: Predicted rms force errors in the short range part.
• Dasheded: Predicted rms force errors in the Fourier space part.
Numerical results
Approximation errors: P
2NFFT method
• Usage of NFFT algorithms introduces further approximation errors.
• Choose NFFT parameters such that additional errors are sufficiently small.
→Error analysis: Quite well understood for 3d-periodic boundary conditions.
• Use the same parameters for open and mixed periodic boundary conditions.
• Mesh size: apply the same resolution in per. and non per. dimensions→Mper L
=! Mnp h =:β.
0.5 1 1.5 2
10−7 10−6 10−5 10−4 10−3 10−2 10−1 100
rcut= 3 rcut= 4 rcut= 5
β= 2
β= 3
β= 4
α
rmsforceerror
charges
0.5 1 1.5 2
10−7 10−6 10−5 10−4 10−3 10−2 10−1
100 rcut= 3
rcut= 4 rcut= 5
β= 2
β= 3 β= 4
α
dipoles
system:Nc=Nd= 100,L= 10.
3d-periodic
,0d-periodic