yade-users team mailing list archive
-
yade-users team
-
Mailing list archive
-
Message #01037
Re: How to reset a body's velocity?
>> I don't really understand the problem. Can't you just set p->velocity =
>> 0 somwhere in the code
>>
>
> No, because a integrator will set back the old value.
> Currently, the veloctiy can not be changed outside integrator.
>
You could make the vector<Vector3r>
LeapFrogPositionIntegrator::prevVelocities public, then you could change
it from anywhere: reset prevVelocities for particles in question and set
velocity of the particle itself to zero as well.
How and where do you load these particles? If you load/save simulation,
prevVelocities will be empty and the problem doesn't arise.
Vaclav
_______________________________________________
Yade-users mailing list
Yade-users@xxxxxxxxxxxxxxxx
https://lists.berlios.de/mailman/listinfo/yade-users
Follow ups
References