Question #703571 on Yade changed:
https://answers.launchpad.net/yade/+question/703571
Jan Stránský proposed the following answer:
> shuzu.append(? ) means I'm not quite sure what to fill in () to add
the particles themselves to the list.
That is why I proposed to "add the particles themselves to the list" in #6.
Instant replay:
###
for b in O.bodies:
...
shuzu.append(b)
###
> Or I add the id of the particle to the list
or, does not really matter.
Body and its ID is unique pair. Having ID you can easily get body itself with
index access on body container: O.bodies[id]
> body.mat = Mat2 in the position of body I need to replace it with,
otherwise an error will be reported in the line body.mat = Mat2, "'int'
object has no attribute 'mat'"
sure, if body is ID (number), body.mat does not make sense
Cheers
Jan
--
You received this question notification because your team yade-users is
an answer contact for Yade.
_______________________________________________
Mailing list: https://launchpad.net/~yade-users
Post to : [email protected]
Unsubscribe : https://launchpad.net/~yade-users
More help : https://help.launchpad.net/ListHelp