Hbond calculation between two index groups

GROMACS version: 2019.5
GROMACS modification: No

How do I calculate the number of hydrogen bonds between any two index groups? Such as something possible with “distance” command. I could only find an option to supply an index file to the “hbond” command.

Any insights will be highly appreciated. Thanks a lot for reading!

Use

echo x y | gmx hbond -f traj.xtc -s em.tpr -n index.ndx -num Hbond.xvg -g

where x & y are the groups, traj.xtc is your trajectory file, em.tpr is input run file, index.ndx contains the groups, Hbond.xvg is the output file containing the number of hydrogen bonds as a function of time.

more info here

1 Like

This indeed worked, thanks a lot for your assistance.

1 Like