SWM4-NDP water model with TGNVT thermostat. Possible in LAMMPS?

I am doing a simulation of an ionic liquid in presence of water, for which I use SWM4-NDP model.

Very simply put, I am using Cl&Pol force field and temperature grouped barostat proposed by Son et al (2019), TGNPT. The moment I introduce water, the simulation crashes saying “Bond atoms X Y missing…” referring to the bond between O and M (particular of SWM4-NDP model).

Is it possible in LAMMPS to use TGNPT with water like Son et al. do (but in OpenMM)? If so, what kind of treatment do i have to apply for the water?

I have tried to explain the problem in simple terms, but I can get into detail if needed. I could not upload any input file as I am new user.

Thanks in advance,
Mikel

Please check out this example input from the LAMMPS source code distribution: examples/PACKAGES/drude/swm4-ndp

I have gone through the examples in the drude folder and taken the input files from there to avoid issues with it, but here I will post just a schematic summary for the sake of brevity.

Using the examples/PACKAGES/drude/swm4-ndp as starting point:
1- Use fix rigid/npt/small for all molecule types. It works fine, but all molecule types are treated as rigid bodies and I would only like to apply this to water type molecules.
This leads me to the next point.

2- Using these two fixes applying to different groups: ERROR: Must not have multiple fixes change box parameter x.

3- I use only fix npt, but with SHAKE I make C-H bonds and water rigid (one bond: O-H, one angle: H-O-H). ERROR: Bond atoms Ow M missing on proc 0 at step 1. This bond is well defined on the data.lmp file, it has a very small lenght, 0.24 A, and a constant of 500, and is not included on SHAKE.

4.1- TGNPT to the whole system. Error: Bond atoms Ow M missing on proc 0 at step 1. The error is repeated so there must be an issue with swm4-ndp. In the examples there is one single method of making water rigid, with fix rigid/nph/small. Using SHAKE algorithm to make it rigid leads me to errors so that is the key question, how to make water rigid.

I have tried to explain it clearly, to get more into details I would upload some input files if necessary

This is easily avoided. You must not run multiple instances of NPT fixes. “There can be only one…”. This means, only one of your time integration fixes can control the box size based on the (global!!) pressure, the others must not change the volume and thus should be either NVT or NVE style fixes.