ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE/libmdtools/SimInfo.hpp
(Generate patch)

Comparing:
branches/mmeineke/OOPSE/libmdtools/SimInfo.hpp (file contents), Revision 377 by mmeineke, Fri Mar 21 17:42:12 2003 UTC vs.
trunk/OOPSE/libmdtools/SimInfo.hpp (file contents), Revision 746 by mmeineke, Thu Sep 4 21:48:35 2003 UTC

# Line 1 | Line 1
1   #ifndef __SIMINFO_H__
2   #define __SIMINFO_H__
3  
4 + #include <map>
5 + #include <string>
6 + #include <vector>
7  
5
8   #include "Atom.hpp"
9   #include "Molecule.hpp"
10   #include "AbstractClasses.hpp"
11   #include "MakeStamps.hpp"
12 + #include "SimState.hpp"
13  
14   #define __C
15   #include "fSimulation.h"
16   #include "fortranWrapDefines.hpp"
17 + #include "GenericData.hpp"
18  
19  
20  
# Line 19 | Line 23 | class SimInfo{ (public)
23   public:
24  
25    SimInfo();
26 <  ~SimInfo(){}
26 >  ~SimInfo();
27  
28    int n_atoms; // the number of atoms
29    Atom **atoms; // the array of atom objects
# Line 30 | Line 34 | class SimInfo{ (public)
34    unsigned int n_bends;    // number of bends
35    unsigned int n_torsions; // number of torsions
36    unsigned int n_oriented; // number of of atoms with orientation
37 +  unsigned int ndf;        // number of actual degrees of freedom
38 +  unsigned int ndfRaw;     // number of settable degrees of freedom
39 +  unsigned int nZconstraints; // the number of zConstraints
40  
41    unsigned int setTemp;   // boolean to set the temperature at each sampleTime
42 +  unsigned int resetIntegrator; // boolean to reset the integrator
43  
44    unsigned int n_dipoles; // number of dipoles
37  double rRF;             // the reaction field cut off radius
38  double dielectric;      // the dielectric of the medium for reaction field
45  
46 +
47    int n_exclude;  // the # of pairs excluded from long range forces
48 <  int *excludes;       // the pairs themselves
48 >  Exclude** excludes;       // the pairs themselves
49  
50    int nGlobalExcludes;
51    int* globalExcludes; // same as above, but these guys participate in
52                         // no long range forces.
53  
54    int* identArray;     // array of unique identifiers for the atoms
55 +  int* molMembershipArray;  // map of atom numbers onto molecule numbers
56  
57    int n_constraints; // the number of constraints on the system
58  
59    unsigned int n_SRI;   // the number of short range interactions
52  SRI **sr_interactions;// the array of short range force objects
60  
61    double lrPot; // the potential energy from the long range calculations.
62  
63 <  double box_x, box_y, box_z; // the periodic boundry conditions
64 <  double rList, rCut; // variables for the neighborlist
63 >  double Hmat[3][3];  // the periodic boundry conditions. The Hmat is the
64 >                      // column vectors of the x, y, and z box vectors.
65 >                      //   h1  h2  h3
66 >                      // [ Xx  Yx  Zx ]
67 >                      // [ Xy  Yy  Zy ]
68 >                      // [ Xz  Yz  Zz ]
69 >                      //  
70 >  double HmatInv[3][3];
71 >
72 >  double boxL[3]; // The Lengths of the 3 column vectors of Hmat
73 >  double boxVol;
74 >  int orthoRhombic;
75    
76 +
77 +  double dielectric;      // the dielectric of the medium for reaction field
78 +
79 +  
80    int usePBC; // whether we use periodic boundry conditions.
81    int useLJ;
82    int useSticky;
# Line 69 | Line 90 | class SimInfo{ (public)
90    double sampleTime, statusTime; // the position and energy dump frequencies
91    double target_temp;            // the target temperature of the system
92    double thermalTime;            // the temp kick interval
93 +  double currentTime;            // Used primarily for correlation Functions
94 +  double resetTime;              // Use to reset the integrator periodically
95  
96    int n_mol;           // n_molecules;
97    Molecule* molecules; // the array of molecules
# Line 81 | Line 104 | class SimInfo{ (public)
104    
105    char ensemble[100]; // the enesemble of the simulation (NVT, NVE, etc. )
106    char mixingRule[100]; // the mixing rules for Lennard jones/van der walls
107 <  Integrator *the_integrator; // the integrator of the simulation
107 >  BaseIntegrator *the_integrator; // the integrator of the simulation
108  
109    char finalName[300];  // the name of the eor file to be written
110    char sampleName[300]; // the name of the dump file to be written
111    char statusName[300]; // the name of the stat file to be written
112  
113 <
113 >  int seed;                    //seed for random number generator
114    // refreshes the sim if things get changed (load balanceing, volume
115    // adjustment, etc.)
116  
# Line 97 | Line 120 | class SimInfo{ (public)
120    // sets the internal function pointer to fortran.
121  
122    void setInternal( void (*fSetup) setFortranSimList,
123 <                    void (*fBox) setFortranBoxList ){
123 >                    void (*fBox) setFortranBoxList,
124 >                    void (*fCut) notifyFortranCutOffList ){
125      setFsimulation = fSetup;
126      setFortranBoxSize = fBox;
127 +    notifyFortranCutOffs = fCut;
128    }
129  
130 +  int getNDF();
131 +  int getNDFraw();
132 +
133 +  void setBox( double newBox[3] );
134 +  void setBoxM( double newBox[3][3] );
135 +  void getBoxM( double theBox[3][3] );
136 +  void scaleBox( double scale );
137 +  
138 +  void setRcut( double theRcut );
139 +  void setEcr( double theEcr );
140 +  void setEcr( double theEcr, double theEst );
141 +
142 +  double getRcut( void )  { return rCut; }
143 +  double getRlist( void ) { return rList; }
144 +  double getEcr( void )   { return ecr; }
145 +  double getEst( void )   { return est; }
146 +
147 +  void setTime( double theTime ) { currentTime = theTime; }
148 +  void incrTime( double dt ) { currentTime += dt; }
149 +  void decrTime( double dt ) { currentTime -= dt; }
150 +  double getTime( void ) { return currentTime; }
151 +
152 +  void wrapVector( double thePos[3] );
153 +
154 +  void matMul3(double a[3][3], double b[3][3], double out[3][3]);
155 +  void matVecMul3(double m[3][3], double inVec[3], double outVec[3]);
156 +  void invertMat3(double in[3][3], double out[3][3]);
157 +  void transposeMat3(double in[3][3], double out[3][3]);
158 +  void printMat3(double A[3][3]);
159 +  void printMat9(double A[9]);
160 +  double matDet3(double m[3][3]);
161 +
162 +  SimState* getConfiguration( void ) { return myConfiguration; }
163 +  
164 +  void addProperty(GenericData* prop);
165 +  GenericData* getProperty(const string& propName);
166 +  vector<GenericData*> getProperties();      
167 +
168 +  int getSeed(void) {  return seed; }
169 +  void setSeed(int theSeed) {  seed = theSeed;}
170 +
171   private:
172 +
173 +  SimState* myConfiguration;
174 +
175 +  double origRcut, origEcr;
176 +  int boxIsInit, haveOrigRcut, haveOrigEcr;
177 +
178 +  double oldEcr;
179 +  double oldRcut;
180 +
181 +  double rList, rCut; // variables for the neighborlist
182 +  double ecr;             // the electrostatic cutoff radius
183 +  double est;             // the electrostatic skin thickness
184 +  double maxCutoff;
185    
186 +  void calcHmatInv( void );
187 +  void calcBoxL();
188 +  void checkCutOffs( void );
189 +
190    // private function to initialize the fortran side of the simulation
191    void (*setFsimulation) setFortranSimList;
192  
193    void (*setFortranBoxSize) setFortranBoxList;
194 +  
195 +  void (*notifyFortranCutOffs) notifyFortranCutOffList;
196 +  
197 +  //Addtional Properties of SimInfo
198 +  map<string, GenericData*> properties;
199 +
200   };
201  
202  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines