ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/branches/development/src/brains/Snapshot.cpp
(Generate patch)

Comparing trunk/src/brains/Snapshot.cpp (file contents):
Revision 1021 by gezelter, Wed Aug 2 19:40:39 2006 UTC vs.
Revision 1112 by chuckv, Wed Jan 3 20:47:00 2007 UTC

# Line 57 | Line 57 | namespace oopse {
57      hmat_ = m;
58      invHmat_ = hmat_.inverse();
59      
60 +
61      //prepare fortran Hmat
62      RealType fortranHmat[9];
63      RealType fortranInvHmat[9];
# Line 155 | Line 156 | namespace oopse {
156  
157    }
158  
159 +  Vector3d Snapshot::getCOM() {
160 +    if( !hasCOM_ ) {
161 +      sprintf( painCave.errMsg, "COM was requested before COM was computed!\n");
162 +      painCave.severity = OOPSE_ERROR;
163 +      simError();
164 +    }
165 +    return COM_;
166 +  }
167 +  
168 +  Vector3d Snapshot::getCOMvel() {
169 +    if( !hasCOM_ ) {
170 +      sprintf( painCave.errMsg, "COMvel was requested before COM was computed!\n");
171 +      painCave.severity = OOPSE_ERROR;
172 +      simError();
173 +    }
174 +    return COMvel_;
175 +  }
176 +  
177 +  Vector3d Snapshot::getCOMw() {
178 +    if( !hasCOM_ ) {
179 +      sprintf( painCave.errMsg, "COMw was requested before COM was computed!\n");
180 +      painCave.severity = OOPSE_ERROR;
181 +      simError();
182 +    }
183 +    return COMw_;
184 +  }
185 +
186   }
187    

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines