[gmx-developers] Adding new parameter to output file

Pim Schravendijk schraven at mpip-mainz.mpg.de
Tue Aug 17 23:52:06 CEST 2004

Hello all,

In the force() function in force.c I am calling a function that calculates
forces/energies and I would like to print these to one of the gromacs 
output files. 

Easiest thing to do was:

#include "main.h"


fprintf(stdlog,"my text %f", parameter); 

and that actually works (yay!)

But I have some additional (beginner) questions:

In e.g. force(), the FILE *fp parameter is declared in the function call, 
can I do something with that? I also see FILE *log around, what is this 
all referring to?

It would be even nicer to put it into the ener.edr output although this
seems not very straightforward to me, I can't really find a struct
containg all the values that are written down to the ener file. This
question resembles
http://www.gromacs.org/pipermail/gmx-developers/2004-March/000823.html But
I couldn't find an answer on that one.

Greetings, Pim

Pim Schravendijk - PhD Student
Max Planck Institute for Polymer Research

More information about the gromacs.org_gmx-developers mailing list