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 3473 by chuckv, Fri Nov 14 15:44:34 2008 UTC vs.
Revision 3477 by chuckv, Mon Nov 24 20:25:36 2008 UTC

# Line 341 | Line 341 | namespace oopse {
341        Vector3d facetVel = thisTriangle.getFacetVelocity();
342        RealType hydroLength = thisTriangle.getIncircleRadius()*2.0/3.14;
343  
344 <      RealType f_normal = simParams->getViscosity()*hydroLength*1.439326479e4*OOPSEConstant::energyConvert;
345 <      RealType extPressure = -(targetPressure_ * thisArea);
346 <      RealType randomForce = randNums[thisNumber] * f_normal * OOPSEConstant::kb*simParams->getTargetTemp()/simParams->getDt();
347 <      RealType dragForce = -f_normal * dot(facetVel, unitNormal);      
344 >      RealType f_normal = simParams->getViscosity()*hydroLength*1.439326479e4;
345 >      RealType extPressure = -(targetPressure_ * thisArea)/OOPSEConstant::energyConvert;
346 >      RealType randomForce = randNums[thisNumber++] * sqrt(2.0 * f_normal * OOPSEConstant::kb*targetTemp_/simParams->getDt());
347 >
348 >      RealType dragForce = -f_normal * dot(facetVel, unitNormal);
349 >
350 >
351        Vector3d langevinForce = (extPressure + randomForce + dragForce) * unitNormal;
352        
353        //      Vector3d dragForce = - gamma_t_ * dot(facetVel, unitNormal) * unitNormal / OOPSEConstant::energyConvert;
354        
355 <      //std::cout << "randomForce " << randomForce << " dragForce " << dragForce <<  " hydro  " << hydroLength << std::endl;
355 >      // std::cout << " " << randomForce << " " << f_normal <<   std::endl;
356  
357  
358        for (vertex = vertexSDs.begin(); vertex != vertexSDs.end(); ++vertex){
# Line 547 | Line 550 | namespace oopse {
550      gaussRand.resize(nTriangles);
551      std::fill(gaussRand.begin(), gaussRand.end(), 0.0);
552  
553 +    
554  
555   #ifdef IS_MPI
556      if (worldRank == 0) {

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines