How can I calculate the total density over specified index groups? (gmx energy)

GROMACS version: 2016.4

Hi all,

I have a polymer/surface system and I’d like to calculate the total density for the polymer part only. I’ve been trying to use gmx energy but my .edr file is for the whole system. I’ve heard to use -rerun but I’m struggling to understand how this works. Could anyone point me in the right direction?

Thanks in advance!

Hi,

have you tried gmx densmap or gmx density?

If gmx energy cannot output energies for each group separately that is most probably because you specified System instead of all groups separately in your .mdp file (at leat this is what usually occurs to me); nevertheless, I recall that gmx traj could help, too.