ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE-4/src/integrators/SMIPDForceManager.cpp
(Generate patch)

Comparing trunk/OOPSE-4/src/integrators/SMIPDForceManager.cpp (file contents):
Revision 3464 by chuckv, Mon Oct 20 19:36:32 2008 UTC vs.
Revision 3465 by chuckv, Tue Oct 21 16:44:00 2008 UTC

# Line 301 | Line 301 | namespace oopse {
301       int nSurfaceSDs = surfaceMesh_->getNs();
302  
303      
304 <    std::vector<Triangle*> sMesh = surfaceMesh_->getMesh();
304 >    std::vector<Triangle> sMesh = surfaceMesh_->getMesh();
305      int nTriangles = sMesh.size();
306  
307  
# Line 319 | Line 319 | namespace oopse {
319      /* Loop over the mesh faces and apply random force to each of the faces*/
320      
321      
322 <    std::vector<Triangle*>::iterator face;
322 >    std::vector<Triangle>::iterator face;
323      std::vector<StuntDouble*>::iterator vertex;
324      int thisNumber = 0;
325      for (face = sMesh.begin(); face != sMesh.end(); ++face){
326      
327 <      Triangle* thisTriangle = *face;
328 <      std::vector<StuntDouble*> vertexSDs = thisTriangle->getVertices();
327 >      Triangle thisTriangle = *face;
328 >      std::vector<StuntDouble*> vertexSDs = thisTriangle.getVertices();
329        
330        /* Get Random Force */
331 <      Vector3d unitNormal = thisTriangle->getNormal();
331 >      Vector3d unitNormal = thisTriangle.getNormal();
332        unitNormal.normalize();
333        Vector3d randomForce = -randNums[thisNumber] * unitNormal;
334 <      Vector3d centroid = thisTriangle->getCentroid();
334 >      Vector3d centroid = thisTriangle.getCentroid();
335  
336 <      Vector3d langevinForce = randomForce - gamma_t_*thisTriangle->getFacetVelocity();
336 >      Vector3d langevinForce = randomForce - gamma_t_*thisTriangle.getFacetVelocity();
337        
338        for (vertex = vertexSDs.begin(); vertex != vertexSDs.end(); ++vertex){
339          if ((*vertex) != NULL){

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines