Issue using hybrid/overlay for soft, lj/cut, and bpm/spring


I am running LAMMPS from Oct 29 2020.

I am wondering if there are restrictions using the hybrid/overlay. I try to use the following (bolded), but ended up getting an error:

ERROR: Illegal pair_style command (src/pair_soft.cpp:150)
Last command: pair_style hybrid/overlay soft 1.12246 bpm/spring lj/cut 1.12246

I am able to get some hybrid/overlays to work (ie zero and lj/cut), but I’m wondering why this one isn’t working. I’ve tried the two-way combos as well (soft + bpm/spring, lj/cut + bpm/spring, lj/cut + soft), and these also fail (if I include the “cutoff distance” for bpm/spring also, that fails). How can I make this work?

You must update your LAMMPS version.
This has multiple benefits:

  • quite a few bugs have been fixed
  • there are better error diagnostics
  • it contains the BPM package

You are obviously looking at the documentation for a more recent version of LAMMPS than what you are using. But that is a mistake since new packages get added and the syntax of commands sometimes changes.

Makes sense - I updated and it resolved that issue. Thanks!