← Back to team overview

yade-users team mailing list archive

Re: ball mill

 

        'def myAddPlotData():
        plot.addData(Torque=O.forces.t(millIds)[1],
        
        time=O.time)' but it has similar errors.
        
        I don't know why it has such errors.
        
        
I assume you did read documentation at https://www.yade-dem.org/sphinx,
right?

O.forces.t only wants one id (not list of many ids)
https://yade-dem.org/sphinx/yade.wrapper.html#yade.wrapper.ForceContainer.t Besides, torque on the body is relative to its centroid, which is not what you want.

You are looking for
https://yade-dem.org/sphinx/yade.utils.html#yade.utils.sumTorques which
computes torque with respect to given axis (from both forces and torques
on particles); so assuming e.g. your mill has rotation axis passing
through (0,0,1) and is oriented (1,0,0), you the the torque value from

 utils.sumTorques(millIds,(1,0,0),(0,0,1))

Then you will have

 plot.addData(torque=utils.sumTorques(...)[1],time=O.time)

HTH, Vaclav





References