Gmx grompp is broken and distorting my input PDB?

GROMACS version: 2024.3-conda_forge
GROMACS modification: No

I am trying to simulate a system with two proteins and a ligand. The input processed structure + box is solvated properly and without any issues that I’ve noticed.

I am attempting to now add ions to my system via the following:

gmx grompp -f ions.mdp -c input_solv.pdb -p topol.top -o ions.tpr -maxwarn 1000

Unfortunately, this command absolutely wrecks my PDB file by not only distorting atom serial numbers, chain ID, but by also modifying the coordinates of the input proteins.

I could not fit my structures in this post so for convenience I have uploaded input_processed.pdb (structure prior to all gromacs steps) and ions.pdb (the structure after running the above command) here: https://file.io/COeYgD0s0r0w

Atom serial numbers and chain IDs are not preserved in GROMACS and they are not meant to be.

I can’t access your input files. gmx grompp doesn’t write any coordinates and won’t affect your input PDB, so the problem must be elsewhere. You say that you get an ions.pdb file after running gmx grompp, which sounds strange. Are you also running gmx mdrun? Regarding the coordinates, it almost certainly has to do with the periodic box of the system. I assume that the coordinates may change already after solvating the system, right? That is, even before gmx grompp. If you want to compare with the original coordinates, you can superimpose/fit the proteins, of the different files, on top of each other, possibly after other PBC treatments, such as making molecules whole again etc.

Hi Magnus,

Thank you very much for your response. I ran another command to extract coordinates for ions.pdb using the outputs from the prior command.

I also figured out the issue. The atomtypes needed to be extracted from the itp file before inclusion and the atom serial numbers in the ligand overlapped with some of the protein atoms. I can definitely confirm that the combination of these issue did in fact cause gromacs to try and “merge” the files into a distorted mess of molecules.

I am very grateful to the open source. I would however be more grateful if they added some better error parsing or ideally a better way to provide topologies and more complex systems.