[lammps-users] charmm LJ energy with lammps


I am trying to use lammps to compute LJ energy as per charmm ff.

The system configuration is as follows:
a ring with 6 atoms on the vertices of a regular hexagon. All 6 bonds,
6 angles and 6 dihedrals are defined. Distance between all 1-4 pairs
is the same and all atoms have the same pair coeff.

I was expecting the LJ energy to be 3 x ( lj interaction energy of
single 1-4 pair ) = 3 x -0.5206 = -1.5617
( this is in agreement with another MD package which implements charmm ff )
but E_vdwl from 'thermo' output is off by a factor of 4 ( i.e. E_vdwl
= 12 x -0.5206 )

Any idea on how to fix this discrepancy ?


I am using Jan-09 release of lammps. lj energy of -0.5206 for 1-4 pair
is for conformation in attached data file.

in.charmmLJ (976 Bytes)

data.charmmLJ (1.92 KB)


The reason for the discrepancy is that you have 4 dihedrals defined for each of the three 1-4 pairs. So LAMMPS is computing each 1-4 pair interaction 4 times. One easy way to get agreement is to change your weighting factors from 1.0 to 0.25.


Cool .. scaling epsilon will work for me.
Knowing that the factor comes from the number of dihedral terms makes
it slightly less ad-hoc !