← Back to team overview

yade-users team mailing list archive

Re: [Question #223135]: how mass of clump computed in yade?

 

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

    Status: Open => Answered

Christian Jakob proposed the following answer:
Hi,

This depends on the method you used for creting the clump.

A) If you use clump() or appendClumped() the mass of the clump is simply
sum of masses from clump members [1].

B) If you use replaceByClumps() the mass of clump members is reduced in
case of overlaps [2]. So the mass of the clump should be correct (not
tested yet).

workaround for A): 
- calculate overlaps of your clump members in python
- calculate the corrected volume for each member (using overlaps)
- set O.bodies[clumpId].state.mass = sum_of_your_member_volumes*your_materials_density

[1] https://github.com/yade/trunk/blob/master/core/Clump.cpp#L132
[2] https://github.com/yade/trunk/blob/master/py/wrapper/yadeWrapper.cpp#L345

christian

-- 
You received this question notification because you are a member of
yade-users, which is an answer contact for Yade.