--- trunk/OOPSE/libmdtools/Integrator.hpp 2003/04/07 14:30:36 466 +++ trunk/OOPSE/libmdtools/Integrator.hpp 2003/05/30 19:07:45 540 @@ -6,77 +6,70 @@ #include "AbstractClasses.hpp" #include "SimInfo.hpp" #include "ForceFields.hpp" -#include "ExtendedSystem.hpp" +#include "Thermo.hpp" +#include "ReadWrite.hpp" -class Verlet : public Integrator { +class Integrator : public BaseIntegrator { public: - Verlet( SimInfo &info, ForceFields* the_ff, ExtendedSystem* the_es ); - ~Verlet(); + Symplectic( SimInfo &theInfo, ForceFields* the_ff ); + virtual ~Symplectic(); void integrate( void ); -private: - - void move_a( double dt ); - void move_b( double dt ); - ForceFields* myFF; - ExtendedSystem* myES; +protected: - SimInfo *entry_plug; // all the info we'll ever need - int c_natoms; /* the number of atoms */ - Atom **c_atoms; /* array of atom pointers */ - Molecule* molecules; - int nMols; - - int c_is_constrained; /*boolean to know whether the systems contains - constraints. */ - int c_n_constrained; /*counter for number of constraints */ - int *c_constrained_i; /* the i of a constraint pair */ - int *c_constrained_j; /* the j of a constraint pair */ - double *c_constrained_dsqr; /* the square of the constraint distance */ - double *c_mass; /* the array of masses */ - short is_first; /*boolean for the first time integrate is called */ - double c_box_x; - double c_box_y; - double c_box_z; -}; - -class Symplectic : public Integrator { -public: - Symplectic( SimInfo* the_entry_plug, - ForceFields* the_ff, - ExtendedSystem* the_es); - ~Symplectic(); + virtual void integrateStep( int calcPot, int calcStress ); + virtual void moveA( void ); + virtual void moveB( void ); + virtual void constrainA( void ); + virtual void constrainB( void ); - void integrate( void ); - -private: - + + void checkConstraints( void ); void rotate( int axes1, int axes2, double angle, double j[3], double A[3][3] ); - SimInfo* entry_plug; + ForceFields* myFF; - ExtendedSystem* myES; + SimInfo *info; // all the info we'll ever need + int nAtoms; /* the number of atoms */ + Atom **atoms; /* array of atom pointers */ Molecule* molecules; int nMols; - int is_constrained; /*boolean to know whether the systems contains - constraints. */ - int n_constrained; /*counter for number of constraints */ - int *constrained_i; /* the i of a constraint pair */ - int *constrained_j; /* the j of a constraint pair */ - double *constrained_dsqr; /* the square of the constraint distance */ - double *mass; /* the array of masses */ + int isConstrained; /*boolean to know whether the systems contains + constraints. */ + int nConstrained; /*counter for number of constraints */ + int *constrainedI; /* the i of a constraint pair */ + int *constrainedJ; /* the j of a constraint pair */ + double *constrainedDsqr; /* the square of the constraint distance */ + short isFirst; /*boolean for the first time integrate is called */ + + double dt; - short int isFirst; - SRI **srInteractions; /* array of SRI pointers */ - int nSRI; /* the number of short range interactions */ + Thermo *tStats; + StatWriter* statOut; + DumpWriter* dumpOut; }; + +class NVT : public Integrator{ + + NVT ( void ); + virtual ~NVT(); + +protected: + virtual moveA( void ); + virtual moveB( void ); + +}; + + + + #endif