[gmx-users] Re: Computing prot pot ener in the gmx code

pascal.baillod at epfl.ch pascal.baillod at epfl.ch
Mon Jan 9 14:51:25 CET 2006

Thank you very much, David!

Thanks for your indications concerning the summing of potential energy terms in
gromacs. (For reminder, I am trying to get them in order to carry out REMD
simulations in function of the potential energy of a solute and not of the
entire system.)

If I understood you well, I could, in the file tgroup.c, create a new routine
sum_epotPROT, that would be exactly like the routine sum_epot of the same file,
safe for the indexes of grps->estat.ee[i]. The new routine would look like:

void sum_epotPROT(t_grpopts *opts,t_groups *grps,real epot[])
  int i;

  /* Accumulate energies */
  epot[F_COUL_SR]  = sum_v(grps->estat.nn,grps->estat.ee[0]);
  epot[F_LJ]       = sum_v(grps->estat.nn,grps->estat.ee[1]);
  epot[F_LJ14]     = sum_v(grps->estat.nn,grps->estat.ee[2]);
/* lattice part of LR doesnt belong to any group
 * and has been added earlier
  epot[F_BHAM]     = sum_v(grps->estat.nn,grps->estat.ee[egBHAMSR]);
  epot[F_BHAM_LR]  = sum_v(grps->estat.nn,grps->estat.ee[egBHAMLR]);

  epot[F_EPOT] = 0;
  for(i=0; (i<F_EPOT); i++)
    if (i != F_DISRESVIOL && i != F_ORIRESDEV && i != F_DIHRESVIOL)
      epot[F_EPOT] += epot[i];

The prot-solvent terms are not quite clear to me. You say index i stands for
i=1: Prot-solvent
i=2: Solvent-protein

What exactly is the difference between these 2? Would you scale it down in order
not to have it twice with:

epot[F_LJ]       = sum_v(grps->estat.nn,grps->estat.ee[1]*0.5);
epot[F_LJ14]     = sum_v(grps->estat.nn,grps->estat.ee[2]*0.5);

..in the new routine sum_epotPROT?

Thank you very much for your help!

ps. I'll post further email on this issue on the developers mailing list.


Pascal Baillod (PhD student) 
Swiss Federal Institute of Technology EPFL	        Tel: +41-(0)21-693-0322
Institute of Chemical Sciences and Engineering ,	Fax: +41-(0)21-693-0320
Laboratory of Computational Chemistry and Biochemistry	pascal.baillod at epfl.ch
Room BCH 4121, Avenue Forel,	                        http://lcbcpc21.epfl.ch
CH-1015 Lausanne	

More information about the gromacs.org_gmx-users mailing list