← Back to team overview

yade-users team mailing list archive

Re: [Question #691285]: Extract Normals and Shears/tangentials forces on a ballMill

 

Question #691285 on Yade changed:
https://answers.launchpad.net/yade/+question/691285

Jan Stránský requested more information:
Hello,

please provide a complete MWE [1]. There might be maaany reasons, it
seems to be necessary to be able to try the code to solve the problem.

>
PyRunner(command='exportForces()',iterPeriod=int(math.ceil(tRec/O.dt))),

just use iterPeriod=1 if you want the export each iteration (which I
understood so far).

> The normalForce file appear in the folder of simulation, but the value of fn extracted at any time step is always 0.
> i don't know if there's a command missing in the code, that would activate the force?

there is no special command (if your simulation works).
But is you do not export each iteration, it is possible that the force just is zero..

> def exportForces():
> fn = 0 # initialization of the normal force
> ...
>      fn = fn + i.phys.normalForce

this should be error, fn=0 is int and you cannot add i.phys.normalForce (Vector3) to it.
And as it is given here is syntax error..

waiting for MWE :-)
cheers
Jan

[1] https://www.yade-dem.org/wiki/Howtoask

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.