[lammps-users] hybrid/overlay and coulombic energy

Dear lammps users,
I have a question concerning hybrid/overlay command.
The test sample is a 256 SPC/E water molecules in a cubic box. If I define the pair style as follows

pair_style lj/cut/coul/long 20.0
pair_coeff 1 1 0.1552976 3.1655201
pair_coeff 2 2 0.0000000 0.0000000

then the energy computed for the system is

TotEng = 12211.952
KinEng = 685.88439
PotEng = 11526.068
E_vdwl = 387.73259
E_coul = 19168.383
E_long = -8030.0482

and the system evolves normally.
However if I change the previous pair style with

pair_style hybrid/overlay lj/cut 20.0 coul/long 20.0
pair_coeff 1 1 lj/cut 0.1552976 3.1655201
pair_coeff 2 2 lj/cut 0.0000000 0.0000000
pair_coeff * * coul/long

the coulombic energy becomes ten times bigger while the vdw energy is the same

TotEng = 130667.23
KinEng = 685.88439
PotEng = 129981.34
E_vdwl = 387.73259
E_coul = 137623.66
E_long = -8030.0482

I have done this test because I found the same problem in trying to switch from lj/cut/coul/long to a correspondent “lj/smooth/coul/long” style.
Where is my falut?

Thank you in advance.

Davide Vanzo

I don't have this problem with the simple
script and data file attached. The thermo
output is identical in the 2 cases. Are you running
the most current version of LAMMPS?


in.bug (830 Bytes)

data.water (43.4 KB)

Dear Steve,
I checked the version on our clusters (unfortunately I’m not the admin) and I saw that it is the 30Nov10. I compiled the lastest version and everything works fine.