E_coul inconsistency

The value of E_long (edit: E_coul) changes after a run 0 has been used. It is a small variation, but is consistent and only happens once. Consider the following sequence of commands:

run 10 
run 0  # Same value of the last step.
run 0  # Here it changes!
run 0  # From now on, it stays constant.
run 0 
run 0 

This issue happens consistently across versions from 2019 to 22 Mar 2022. I am attaching a simple example to demonstrate this behaviour:

grep "   10 " tip3p_aa_02.log
   Step         TotEng         E_vdwl         E_coul         E_long         KinEng         PotEng          Temp 
        10  -7931.6387      2139.1969      39177.767     -51061.339      1812.7368     -9744.3755      304.21993    
        10  -7931.6387      2139.1969      39177.767     -51061.339      1812.7368     -9744.3755      304.21993    
        10  -7931.5945      2139.1969      39177.811     -51061.339      1812.7368     -9744.3313      304.21993    
        10  -7931.5945      2139.1969      39177.811     -51061.339      1812.7368     -9744.3313      304.21993    
        10  -7931.5945      2139.1969      39177.811     -51061.339      1812.7368     -9744.3313      304.21993    
        10  -7931.5945      2139.1969      39177.811     -51061.339      1812.7368     -9744.3313      304.21993

tip3p_box.data.gz (59.7 KB)
tip3p_aa_02.in (970 Bytes)

a) E_long remains consistent, E_coul changes
b) this is a side effect of using fix shake. during the setup phase of a run it uses some position estimator to reconstruct old positions that are required for doing the mid-step updates. that is not set up for being initialized multiple times for the same step. if you change your “run 0” commands to “run 0 pre no” the values will be consistent.

My bad, of course.

Cool, I learned something. Thanks for sharing :slight_smile:

You should study the implications of using “pre no” from the documentation of the “run” command. Sometimes it is helpful, sometimes it will cause problems. For this kind of use case, you probably also want to use “post no” to skip printing data that is usually only of interest after a longer run.

1 Like