yade-users team mailing list archive
-
yade-users team
-
Mailing list archive
-
Message #14470
Re: [Question #580403]: Displacement Recorder
Question #580403 on Yade changed:
https://answers.launchpad.net/yade/+question/580403
Status: Open => Answered
Jan Stránský proposed the following answer:
Hi Felipe,
you can use PyRunner and plot module:
###########################
def plotAddData():
plot.addData( # [1]
dspl1 = O.bodies[...].state.displ(), # [2]
dspl2 = O.bodies[...].state.displ(),
)
O.engines = [ ...
PyRunner(iterPeriod=..., command="plotAddData()"), # [3]
]
# at the end of simulation (or use another PyRunner to save it periodically)
plot.saveDataTxt(fileName) # [4]
###########################
cheers
Jan
[1] https://yade-dem.org/doc/yade.plot.html#yade.plot.addData
[2] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.State.displ
[3] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.PyRunner
[4] https://yade-dem.org/doc/yade.plot.html#yade.plot.saveDataTxt
--
You received this question notification because your team yade-users is
an answer contact for Yade.