Hello,
I am analyzing MD simulations correctly ended of proteins in water. My goal is to have different snapshots as pdb files containing the protein and all water molecules within 1 Angstrom.
I have created a ndx file using the command line:
gmx select -f md_0_1.trr -s md_0_1.tpr -select “group “Protein” or resname SOL and same residue as within 1 of group “Protein”” -on output.ndx
The file is correct, for each shapshot (82, in this case) I have atom indexes of proteins and closest water molecules. I attach a picture of output.ndx, where atoms 1-212 are protein atoms, whereas other indexes are water atoms.
However, if I use this ndx file as input for trjconv, Gromacs asks me which one of the 82 selection I want to use.
gmx trjconv -f md_0_1_noPBC.xtc -s md_0_1.tpr -o prot.pdb -sep -split 10000 -n output.ndx
For example, if I choose 0, Gromacs will save pdb files with the index atom selection at t0. I want to use; if I choose 81, Gromacs will save pdb files with the index atom selection at t81. This is wrong because closest water molecules are different during the simulation. I was expecting that Gromacs would automatically have used selection 0 for prot0.pdb, … selection 81 for prot81.pdb and so on.
Is there a way to combine selection at t0 with shapshot 0, selection at t1 with snapshot 1…?
Thank you all in advance,
Cesare
GROMACS version: 2021
GROMACS modification: No