← Back to team overview

yade-dev team mailing list archive

[Branch ~yade-dev/yade/trunk] Rev 2104: And more fixing damping shear direction

 

------------------------------------------------------------
revno: 2104
committer: Sergei D <sega@sega>
branch nick: trunk
timestamp: Thu 2010-03-25 17:55:30 +0300
message:
  And more fixing damping shear direction
modified:
  pkg/dem/meta/ViscoelasticPM.cpp


--
lp:yade
https://code.launchpad.net/~yade-dev/yade/trunk

Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-dev/yade/trunk/+edit-subscription.
=== modified file 'pkg/dem/meta/ViscoelasticPM.cpp'
--- pkg/dem/meta/ViscoelasticPM.cpp	2010-03-25 14:39:31 +0000
+++ pkg/dem/meta/ViscoelasticPM.cpp	2010-03-25 14:55:30 +0000
@@ -78,7 +78,7 @@
 	// and then add the viscous part if we pass the Mohr-Coulomb criterion.
 	// See http://www.mail-archive.com/yade-users@xxxxxxxxxxxxxxxxxxx/msg01391.html
 	shearForce += phys.ks*dt*shearVelocity;
-	const Vector3r shearForceVisc = phys.cs*shearVelocity;
+	Vector3r shearForceVisc = Vector3r::ZERO;
 
 	phys.normalForce = ( phys.kn * geom.penetrationDepth + phys.cn * normalVelocity ) * geom.normal;
 	phys.prevNormal = geom.normal;
@@ -88,6 +88,7 @@
 	{
 		maxFs = Mathr::Sqrt(maxFs) / shearForce.Length();
 		shearForce *= maxFs;
+		shearForceVisc =  phys.cs*shearVelocity;
 	}
 
 	Vector3r f = phys.normalForce + shearForce + shearForceVisc;


Follow ups