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

Comparing trunk/OOPSE/libmdtools/Molecule.hpp (file contents):
Revision 490 by gezelter, Fri Apr 11 15:16:59 2003 UTC vs.
Revision 1104 by gezelter, Tue Apr 13 16:26:03 2004 UTC

# Line 4 | Line 4
4   #include "Atom.hpp"
5   #include "SRI.hpp"
6   #include "MoleculeStamp.hpp"
7 < #include "Exclude.hpp"
7 > #include "RigidBody.hpp"
8  
9   typedef struct{
10    
# Line 13 | Line 13 | typedef struct{
13    int nBonds;    // ... .. ..  . .bonds .. .. . . . .
14    int nBends;    // . . . . .. . .bends . . . . .. .
15    int nTorsions; // .. . . .. . . torsions . . .. . .
16 +  int nRigidBodies; // .. .. .. . rigid bodies ... ..
17    int nOriented; // .. . . . .. . oriented atoms . . .
17  int nExcludes; // . . .. . . . .exclude pairs.. . . .
18  
19    Atom** myAtoms;      // the array of atoms
20  Exclude** myExcludes;// the array of Excluded pairs
20    Bond** myBonds;      // arrays of all the short range interactions
21    Bend** myBends;
22    Torsion** myTorsions;
23 <
24 <
23 >  vector<RigidBody*>   myRigidBodies;
24 >  vector<StuntDouble*> myIntegrableObjects;
25   } molInit;
26  
27   class Molecule{
# Line 40 | Line 39 | class Molecule{ (public)
39    int getMyIndex( void ) { return myIndex; }
40    int getGlobalIndex( void ) { return globalIndex; }
41  
42 <  int getNAtoms   ( void ) {return nAtoms;}
43 <  int getNBonds   ( void ) {return nBonds;}
44 <  int getNBends   ( void ) {return nBends;}
45 <  int getNTorsions( void ) {return nTorsions;}
46 <  int getNOriented( void ) {return nOriented;}
47 <  int getNExcludes( void ) {return nExcludes;}
48 <  int getNMembers ( void ) {return nMembers;}
49 <  int getStampID  ( void ) {return stampID;}
42 >  int getNAtoms   ( void )    {return nAtoms;}
43 >  int getNBonds   ( void )    {return nBonds;}
44 >  int getNBends   ( void )    {return nBends;}
45 >  int getNTorsions( void )    {return nTorsions;}
46 >  int getNRigidBodies( void ) {return myRigidBodies.size();}
47 >  int getNOriented( void )    {return nOriented;}
48 >  int getNMembers ( void )    {return nMembers;}
49 >  int getStampID  ( void )    {return stampID;}
50  
51 <  Atom**     getMyAtoms   ( void ) {return myAtoms;}
52 <  Bond**     getMyBonds   ( void ) {return myBonds;}
53 <  Bend**     getMyBends   ( void ) {return myBends;}
54 <  Torsion**  getMyTorsions( void ) {return myTorsions;}
55 <  Exclude**  getMyExcludes( void ) {return myExcludes;}
51 >  Atom**      getMyAtoms   ( void )    {return myAtoms;}
52 >  Bond**      getMyBonds   ( void )    {return myBonds;}
53 >  Bend**      getMyBends   ( void )    {return myBends;}
54 >  Torsion**   getMyTorsions( void )    {return myTorsions;}
55 >  vector<RigidBody*> getMyRigidBodies( void ) {return myRigidBodies;}
56    
57 <  void setStampID( int info ) {stampID = info;}
59 <  
57 >  void setStampID( int info ) {stampID = info;}
58  
61
62
59    void calcForces( void );
60 +  void atoms2rigidBodies( void );
61    double getPotential( void );
62    
63    void printMe( void );
# Line 68 | Line 65 | class Molecule{ (public)
65    void getCOM( double COM[3] );
66    void moveCOM( double delta[3] );
67    double getCOMvel( double COMvel[3] );
68 +  
69 +  double getTotalMass();
70  
71   private:
72  
# Line 76 | Line 75 | class Molecule{ (public)
75    int nBonds;    // ... .. ..  . .bonds .. .. . . . .
76    int nBends;    // . . . . .. . .bends . . . . .. .
77    int nTorsions; // .. . . .. . . torsions . . .. . .
78 +  int nRigidBodies; // .. . . .. .rigid bodies . . .. . .
79    int nOriented; // .. . . . .. . oriented atoms . . .
80    int nMembers;  // .. . . . . . .atoms (legacy code) . . .
81  int nExcludes; // . . . . .. .. excludes .. . .
81  
82    int myIndex; // mostly just for debug (and for making pressure calcs work)
83    int globalIndex;
# Line 87 | Line 86 | class Molecule{ (public)
86    Bond** myBonds;     // arrays of all the short range interactions
87    Bend** myBends;
88    Torsion** myTorsions;
89 <  Exclude** myExcludes; // array of the excluded pairs of long range forces
90 <  
89 >  vector<RigidBody*>   myRigidBodies;
90 >  vector<StuntDouble*> myIntegrableObjects;
91 >
92   };
93  
94   #endif

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines