Error in Coulomb cutoffs of hybrid pair sub-styles

Hi,

I’m trying to model a system with multiple pair styles - it requires table potentials, Morse interactions, LJ and Coulomb interactions. My main command for setting these pair styles is :

pair_style hybrid/overlay lj/cut/coul/cut 3.5 lj/charmm/coul/long 8 12 morse 2.366 table linear 1000

I’m using pppm kspace style, and my table files have 20.01 as the outer cutoff. The error that I get is:

ERROR: Coulomb cutoffs of pair hybrid sub-styles do not match (…/pair_hybrid.cpp:935)

How do I fix this error? I’m using the 17 Aug 2017 version of LAMMPS.

PS - I tried setting the Coulomb cutoffs to be the same in the command above, but I still get the same error. I tried looking up other posts such as this and this, but I’m not able to fix my error.

This is a very old version of LAMMPS, and an unusual combination of sub-styles. Your best bet is to tabulate everything and proceed from there.

1 Like

I agree with @srtee that such an overly complex hybrid potential command line is highly suspicious and very likely to describe a bogus model.

Three things stand out that make very little sense.

  • hybrid/overlay: which of the pair styles to you want to add to another? none of them look like likely candidates for that
  • coul/cut and coul/long with kspace: this is guaranteed to give bogus results, since kspace will always cover all charges and coul/cut is not compatible with that and this is what causes the error. the cutoff data for coul/cut is a 2d array covering all pairs of atom types while coul/long only allows a single global value, so those two cutoff definitions will never match even if you use the same cutoff values
  • extremely short cutoff for lj/cut/coul/cut: this is going to introduce massive jumps in the potential energy and forces when atoms cross the cutoff distance and that in turn will lead to unphysical anomalies in the density inside and outside the cutoff.

In short, even if you manage to bypass the check that throws the current error, it is not likely that this model is going to produce physically meaningful results.

Hi,

Thank you for the replies. This is part of a method I’m trying to develop which uses reactive MD (bond making and breaking is allowed). The parameters that I’m using are derived from quantum chemical calculations carried out separately so I’m trying to make them work with the corresponding styles required.

In keeping with the comments (thanks for those!) I changed it to the following :

pair_style      hybrid/overlay lj/charmm/coul/long 8 12 morse 2.366 table linear 2000

However, I keep getting the same error :

ERROR: Coulomb cutoffs of pair hybrid sub-styles do not match (../pair_hybrid.cpp:935)

However, the following command works well (for a similar system), with results that make sense :

pair_style      hybrid/overlay lj/charmm/coul/long 8 12 morse 2.366

Could you suggest a way to include the tabulated potentials without any error? Without resorting to tabulating everything? I would like to keep the LJ/Coulomb terms, along with the Morse interactions and tabulated interactions. I’ve removed coul/cut and removed the short cutoff for coul/cut as suggested.

Thank you!