yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #10837
[Branch ~yade-pkg/yade/git-trunk] Rev 3959: One more revert in NewtonIntegrator.
------------------------------------------------------------
revno: 3959
committer: Anton Gladky <gladky.anton@xxxxxxxxx>
timestamp: Fri 2014-05-16 14:48:36 +0200
message:
One more revert in NewtonIntegrator.
modified:
pkg/dem/NewtonIntegrator.cpp
--
lp:yade
https://code.launchpad.net/~yade-pkg/yade/git-trunk
Your team Yade developers is subscribed to branch lp:yade.
To unsubscribe from this branch go to https://code.launchpad.net/~yade-pkg/yade/git-trunk/+edit-subscription
=== modified file 'pkg/dem/NewtonIntegrator.cpp'
--- pkg/dem/NewtonIntegrator.cpp 2014-05-16 11:48:12 +0000
+++ pkg/dem/NewtonIntegrator.cpp 2014-05-16 12:48:36 +0000
@@ -146,12 +146,10 @@
// clumps forces
if(b->isClump()) {
b->shape->cast<Clump>().addForceTorqueFromMembers(state,scene,f,m);
- scene->forces.addTorque(id,m);
- scene->forces.addForce(id,f);
#ifdef YADE_OPENMP
- //it is safe here, since only one thread will read/write
- scene->forces.getTorqueUnsynced(id)=m;
- scene->forces.getForceUnsynced(id)=f;
+ //it is safe here, since only one
+ scene->forces.getTorqueUnsynced(id)+=m;
+ scene->forces.getForceUnsynced(id)+=f;
#else
scene->forces.addTorque(id,m);
scene->forces.addForce(id,f);