Comment 6 for bug 1400075

Revision history for this message
Bruno Chareyre (bruno-chareyre) wrote :

It seems to me that:
1/ a robust (velocity-consistent) implementation would need much more than a simple bugfix
2/ assigning velocity is the right way to control motion according to the documentation [1]
Therefore, I would suggest to simply remove addMove from sources.

Do you guys have a realistic example of something that can't be achieved without addMove?
As mentionned in #2, assigning velocity means that the displacement per iteration depends on the timestep but isn't it what we want? I mean, imposing a constant displacement of a body per timestep implies that the velocity of the said body is changing all the time (with a changing dt). A physical quantity depending on a numerical detail is an odd feature.

Further, if someone really wants to addMove() and doesn't care about velocity consictency, it could be simply:
b.state.pos += move #in a pyRunner, typically

[1] https://yade-dem.org/doc/user.html#imposed-velocity

@Janek
>you will see that addMove() isn't used anywhere except for the file ./examples/test/force-move.py

This grep output is typical for such function (supposed to be used through python wrapper mainly), i.e. implementation in the source code + one example script. It doesn't tell really if the function is used or not (by yade users), and if it is used it can still have nasty side effects.

@Vaclav
>I would have to remember hard what was the reason to introduce it

Maybe an intermediate state of the tensile tests, where groups of particles had to be moved as rigid blocks - now done with constant velocity but maybe with constant disp/iter previously?

Bruno