// Copyright 2005-2007 Nanorex, Inc. See LICENSE file for details. #ifndef NEWTABLES_H_INCLUDED #define NEWTABLES_H_INCLUDED #define RCSID_NEWTABLES_H "$Id$" /** table length for bond stretch/bending functions */ #define TABLEN 150 #define QUALITY_INTERPOLATED 4 #define QUALITY_GUESSED 3 #define QUALITY_INACCURATE 0 struct interpolationTable { double start; double scale; // y = ax^3 + bx^2 + cx + d or... // y = ((ax + b)x + c)x + d // y' = 3ax^2 + 2bx + c or... // y' = (3ax + 2b)x + c double a[TABLEN]; double b[TABLEN]; double c[TABLEN]; double d[TABLEN]; }; struct bondStretch { char *bondName; /** bond type, atom types & order */ //int typ, ord, a1, a2; double ks; // stiffness in N/m double r0; // base radius in pm, or 1e-12 m double de; // aJ, or 1e-18 J double beta; // sqrt(ks/2 de), 1e12 m^-1, for Morse double inflectionR; // r value in pm where d^2(Lippincott(r)) / dr^2 == 0 // These are the indices into the interpolation tables where the // potential exceeds ExcessiveEnergyLevel. If a dynamics run // references table entries outside these bounds, a warning will be // emitted. int maxPhysicalTableIndex; int minPhysicalTableIndex; // For minimize, the potential function extends as a cubic // polynomial beyond the end of the interpolation table: // potential = potentialExtensionA // + potentialExtensionB * r // + potentialExtensionC * r^2 // + potentialExtensionD * r^3 double potentialExtensionA; double potentialExtensionB; double potentialExtensionC; double potentialExtensionD; int parameterQuality; // how sure are we of these parameters // Non-zero if this stretch should be pure quadratic, instead of // Lippincott-Morse. Set to 1 if GROMACS should consider this // stretch to be a chemical bond (for purposes of excluding // non-bonded interactions), or 6 for a quadratic potential without // the bond. int quadratic; int warned; // set to non-zero if a warning about using this entry has been printed struct interpolationTable LippincottMorse; }; struct vanDerWaalsParameters { char *vdwName; double rvdW; // in pm (1e-12 m) double evdW; // in zJ (1e-21 J) // Transition interval for smooth cutoff. Normal function is used // for 0