* To help us fund GROMACS development, we humbly ask that you cite
* the research papers on the package. Check out http://www.gromacs.org.
*/
-#ifdef HAVE_CONFIG_H
-#include <config.h>
-#endif
+#include "gmxpre.h"
+
+#include <assert.h>
+#include <stdlib.h>
#include "gromacs/commandline/pargs.h"
-#include "typedefs.h"
-#include "gromacs/utility/smalloc.h"
-#include "vec.h"
#include "gromacs/fileio/tpxio.h"
#include "gromacs/fileio/trxio.h"
-#include "xvgr.h"
-#include "rmpbc.h"
-#include "pbc.h"
-#include "physics.h"
-#include "index.h"
+#include "gromacs/fileio/xvgr.h"
+#include "gromacs/gmxana/gmx_ana.h"
+#include "gromacs/legacyheaders/macros.h"
+#include "gromacs/legacyheaders/typedefs.h"
+#include "gromacs/math/units.h"
+#include "gromacs/math/vec.h"
+#include "gromacs/pbcutil/pbc.h"
+#include "gromacs/pbcutil/rmpbc.h"
#include "gromacs/statistics/statistics.h"
-#include "gmx_ana.h"
-#include "macros.h"
-
-#include "gromacs/legacyheaders/gmx_fatal.h"
+#include "gromacs/topology/index.h"
+#include "gromacs/utility/fatalerror.h"
+#include "gromacs/utility/smalloc.h"
#define SQR(x) (pow(x, 2.0))
#define EPSI0 (EPSILON0*E_CHARGE*E_CHARGE*AVOGADRO/(KILO*NANO)) /* EPSILON0 in SI units */
xshfr[i] = 0.0;
}
}
-
+ assert(time != NULL);
if (nfr == 0)
- if (bACF)
+ if (bACF && (ii < nvfr))
{
fprintf(stderr, "Integral and integrated fit to the current acf yields at t=%f:\n", time[vfr[ii]]);
fprintf(stderr, "sigma=%8.3f (pure integral: %.3f)\n", sgk-malt*pow(time[vfr[ii]], sigma), sgk);
}
else
{
- fprintf(stderr, "Too less points for a fit.\n");
+ fprintf(stderr, "Too few points for a fit.\n");
}
{ efTPS, NULL, NULL, ffREAD }, /* this is for the topology */
{ efNDX, NULL, NULL, ffOPTRD },
{ efTRX, "-f", NULL, ffREAD }, /* and this for the trajectory */
- { efXVG, "-o", "current.xvg", ffWRITE },
- { efXVG, "-caf", "caf.xvg", ffOPTWR },
- { efXVG, "-dsp", "dsp.xvg", ffWRITE },
- { efXVG, "-md", "md.xvg", ffWRITE },
- { efXVG, "-mj", "mj.xvg", ffWRITE},
- { efXVG, "-mc", "mc.xvg", ffOPTWR }
+ { efXVG, "-o", "current", ffWRITE },
+ { efXVG, "-caf", "caf", ffOPTWR },
+ { efXVG, "-dsp", "dsp", ffWRITE },
+ { efXVG, "-md", "md", ffWRITE },
+ { efXVG, "-mj", "mj", ffWRITE },
+ { efXVG, "-mc", "mc", ffOPTWR }
};
#define NFILE asize(fnm)