# [gmx-users] problem with g_energy tool

Veera Krasnenko veera.krasnenko at ut.ee
Tue Jan 2 23:46:22 CET 2007

```Tere hommikust, Koit Harrievich!

Sain Gromacs-st vastust (allpool). Kuna, minu arust, meil on suured
fluktuatsioonid (ja need oli ka toodud kirjas), siis ma ei saa aru, mis
pärast siin pakutakse niisugune variant.
Aga proovisin teha, nagu siin pakutakse. Küsimus oli ainult Ezero
valimisest. Selleks võtsin keskmine 200 viimasest ps.
Ezero - kT ln <e^((E-Ezero)/kT) >,
tulemused ei pea erinema sellega:
- kT ln <e^(E/kT)>,
Kas jälle mingit ebatäpsus programmis või...
Äkki Teil on mingit seletus?

Lugupidamisega,

Veera Krasnenko

> Veera Krasnenko wrote:
>> Dear All,
>>
>> Could you help me to identify what is going wrong in our calculations
>> We run g_energy tool with results produced by mdrun (GROMACS).
>> And we got the follow output:
>> "...
>> Statistics over 1500001 steps [ 0.0000 thru 3000.0002 ps ], 5 data sets
>>
>> Energy                      Average       RMSD     Fluct.      Drift
>> Tot-Drift  -kT ln<e^(E/kT)>
>> -------------------------------------------------------------------------------
>> Potential                   -586133    1715.72    969.946   -1.63418
>> -4902.54         inf
>> Kinetic-En.                 46711.9    167.786    167.784 0.000920543
>> 2.76163     47433.7
>> Total-Energy                -539421    1708.57    958.414   -1.63326
>> -4899.78         inf
>> Volume                      359.509    1.36219   0.682818 0.00136104
>> 4.08312     359.985
>> pV                          23.1223     1475.3     1475.3 0.00232535
>> 6.97605         inf
>> ..."
>> As you can see many values are calculated as 'infinite'. This
>> happens because energies produced in previous calculation are about 10^5
>> kJ. So even e^1000 is pretty big - almost infinite. We tried to
>> solve this by modifying equation in sources like this:
>>
>> Before: -kT ln<e^(E/kT)>
>> After: 1000 * [-kT ln <e^(E/(kT*1000))>]
>>
>> Now there is no more 'infinities', but we still have doubts
>> - Is it known problem or this is our problems in calculations on
>> previous
>> steps or in build ?
>>
>>
>> Vera
>
> What you could try is to subtract the average with the -zero flag. This
> will only work if your fluctuations are small however. In addition you
> should carefully evaluate what the numbers mean. g_energy -h gives you a
> short introduction.
>
> Your result including zero would be:
>
> Ezero - kT ln <e^((E-Ezero)/kT) >
>
> --
> David.
> ________________________________________________________________________
> David van der Spoel, PhD, Assoc. Prof., Molecular Biophysics group,
> Dept. of Cell and Molecular Biology, Uppsala University.
> Husargatan 3, Box 596,  	75124 Uppsala, Sweden
> phone:	46 18 471 4205		fax: 46 18 511 755
> spoel at xray.bmc.uu.se	spoel at gromacs.org   http://folding.bmc.uu.se
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
> _______________________________________________
> gmx-users mailing list    gmx-users at gromacs.org
> http://www.gromacs.org/mailman/listinfo/gmx-users
> Please don't post (un)subscribe requests to the list. Use the
> www interface or send it to gmx-users-request at gromacs.org.