GROMACS version: 2023.4
GROMACS modification: Yes/No
Here post your question
Hello everyone!
I want to apply position restraints on water molecules that are 0.55nm away from my protein.
Forcefield I’m using: charmm36-jul2022.ff
I’ve extracted just the protein and these water molecules into a separate .gro file. I generated an index file with group “restrain_water_ow” that contains indices of only the oxygen atoms of the water molecules, through which i generated an .itp file using the command:
gmx genrestr -f prot_0.55water.gro -n posres_index.ndx -o posres_water.itp -fc 1000 1000 1000
One thing to note is that, i’ve been using the same topology file as i’ve gotten post npt equilibration (npt.gro was the file from which prot_0.55water.gro was extracted). I just changed the no. of water molecules once i extracted prot_0.55water.gro
In this topol.top, after generated of the itp file, i included:
#ifdef POSRES_WATER
#include "posres_water.itp"
#endif
And in the mdp file i made sure to define = -DPOSRES_WATER
But it did not seem to work, I figured I’d rather include this in the tip3p.itp file since that was the water model that was used and included in the water topology.
This did not seem to work as well, I kept getting errors like index out of bounds- i thought it was because i was only including the oxygens and not the hydrogens and tried this as well, i was still getting the same error.
I changed the format of the .itp to:
[ POSRES_WATER ]
; atom type g r k
3318 2 1 2 1000
The error i’m encountering now is as follows:
WARNING 3911 [file posres_water.itp, line 3915]:
Too few parameters on line (source file
…/gromacs-2023.4/src/gromacs/gmxpreprocess/toppush.cpp,
line 1428)
multiple warnings for each line in the itp file.
What does this error signify? is it just an indentation error? Or are there not enough parameters?
I’m fairly new to gromacs, I apologize if the information i’ve provided is haphazard. Any help that would point me the right direction will be appreciated.
Thank you
Aarya