[DFTB-Plus-User] question on Ewald summation in coulomb.F90

Wei Lai wei.weilai at gmail.com
Fri Dec 21 04:29:31 CET 2018


Dear DFTB+ users and developers,

I have a question regarding the calculation of Ewald energy in coulomb.F90
(18.2 version).  I only have very limited knowledge of Fortran and Ewald
summation but wonder if someone could clarify a question of a factor 2 for
the reciprocal energy, self energy, and background charge energy.

For the reciprocal energy, line 1416 reads:
    recSum = 2.0_dp * recSum * 4.0_dp * pi / vol
The factor of "4.0_dp * pi / vol" should be "2.0_dp * pi / vol"?

For the self energy, line 1379 reads:
      ewald = ewald - 2.0_dp * alpha / sqrt(pi)
The factor of "2.0_dp * alpha / sqrt(pi)" should be "alpha / sqrt(pi)"?

For the background charge energy, line 1377 reads:
        & - pi / (vol*alpha**2)
while it should be "pi / (2*vol*alpha**2)?

I understand this factor of 2 might be intentional and just for
intermediate steps but it doesn't seem be taken care of for the final Ewald
energy.  I think I am perhaps missing something obvious.

Thanks, Wei
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.zfn.uni-bremen.de/pipermail/dftb-plus-user/attachments/20181220/b51ae33a/attachment.html>


More information about the DFTB-Plus-User mailing list