[gmx-users] How to add another electrostatic summation method in Gromacs
Mark.Abraham at anu.edu.au
Thu Mar 26 23:56:02 CET 2009
Shuangxing Dai wrote:
> Thank you for your help. I attached the page of the form of potential.
> The equation (5.13) gives all the potential energy of neighbours of one
> ion in a truncation sphere. Rc is cut-off. Since this potential depends
> on all the neighbours in a cut-off distance, I cannot give the pair
> interaction because in this method, only the total potential energy of
> one ion maks sense. In Ewald summation, both the real space and
> reciprocal space summation can be written as the summation of pair
> potential. But in wolf, I cannot do that.
It looks separable into a double sum over atom pairs from within a
cutoff, since the value of that limit is constant.
> Since I cannot use Ewald without peoriodical boundary conditions while
> this Wolf method can, so I cannot simply use Gromacs to do my
> simulation. The question is which files needed to be modified if I want
> to add a new one? Is there any direct way? Or I should read all the
> whole code?
You can start by reading the kernel code generated by mknb during the
make process and found in src/gmxlib/nonbonded/nb_kernel. If you play
with the flags to mknb you can get comments embedded in the C files.
Find the one that does Ewald without table lookups and consider how
you'd need to change it to suit your needs.
More information about the gromacs.org_gmx-users