Clump mass issue with replaceByClumps()

Asked by behzad

Hi there,

It still have an issue with clump mass calculation with replaceByClumps().

id_Mat=O.materials.append(FrictMat(young=1e7,poisson=0.3,density=1000,frictionAngle=1))
Mat=O.materials[id_Mat]

sp=pack.SpherePack()
sp.makeCloud(minCorner=(-1.5,-1.5,.1),maxCorner=(1.5,1.5,2),rMean=.2,rRelFuzz=0.0,num=1,periodic=False)
O.bodies.append([sphere(c,r,material=Mat) for c,r in sp])

#Coke:
relRadList4=[0.000471583e3,0.00060213e3,0.000631454e3,0.000493144e3,0.000695336e3,0.000395284e3,0.000550567e3,0.00037674e3,0.000656561e3,
0.000218143e3,0.000223094e3,0.000484354e3,0.00036813e3,0.000514327e3,0.000395357e3,0.000377391e3,0.000454081e3,0.000355504e3,
0.00061375e3,0.00068747e3,0.000508243e3,0.000447592e3,0.000549008e3,0.000486356e3,0.000664425e3,0.000587608e3,0.00015184e3,
0.000695789e3,0.000484995e3,0.000443755e3]
relPosList4=[[0.000213504e3,0.000920219e3,5.17294e-002],[0.000181129e3,-0.000693148e3,-0.000301356e3],[0.000191565e3,0.000550929e3,0.000472726e3],[-6.9806e-002,0.000814473e3,0.000504795e3],[-0.00016687e3,-4.19741e-002,0.000273102e3],[-0.000632058e3,-0.000285906e3,0.000255655e3],[8.5103e-002,-2.87712e-003,0.000608655e3],[-0.000369852e3,6.12296e-003,-0.00056701e3],[7.38905e-002,0.000497426e3,2.97204e-002],[0.000135818e3,0.000562643e3,-0.000842692e3],[0.000748387e3,0.00077499e3,0.000784656e3],[7.88683e-002,0.000626452e3,-0.00032004e3],[0.000526651e3,-0.000553811e3,0.000109479e3],[0.000136113e3,0.000176874e3,-0.000254769e3],[-0.000209755e3,-0.000765094e3,-0.000832511e3],[-0.000945048e3,-0.00034182e3,-0.000150738e3],[0.000425963e3,-0.000381421e3,-0.000472185e3],[0.000544025e3,0.000492145e3,0.000918189e3],[-0.000262527e3,0.000319288e3,0.000244014e3],[-0.0002573e3,-0.000432994e3,-0.000293022e3],[0.000500309e3,-0.000741747e3,-0.000145635e3],[0.000354013e3,4.94286e-002,0.000772469e3],[7.29082e-002,-0.000364611e3,-0.000799481e3],[0.00015904e3,0.000954791e3,0.00058286e3],[0.000106567e3,-0.000252692e3,2.9281e-002],[-0.000616653e3,-0.000235914e3,-0.000163413e3],[-0.00114642e3,8.90673e-002,-0.000146111e3],[-0.000361004e3,-0.000311422e3,-0.000152367e3],[-0.000655366e3,-2.8257e-002,-0.000169021e3],[-0.000501808e3,-6.06848e-002,-0.000385601e3]]

templates= []
templates.append(utils.clumpTemplate(relRadii=relRadList4,relPositions=relPosList4))
O.bodies.replaceByClumps(templates,[1.0])

As it's written in the manual, the volume of the clump must be the same as the ball which is replaced by the clump.

The initial ball here has the radius of 0.2 which gives the volume of 0.0335. The material has the density of 1000, so mass of the ball is 33.5.

However, mass of the clump is 99.808

O.bodies[32].state.mass
 -> [14]: 99.80883330235272

How this is calculated? and why 99.80? Why it's not 33.5? Can we control it?
and I didn't find any clue about adaptClumpMasses().

Thanks

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
behzad
Solved:
Last query:
Last reply:
Revision history for this message
Christian Jakob (jakob-ifgt) said :
#1

Hi,

For inertia/mass/volume calculation, use

O.bodies.replaceByClumps(templates,[1.0], discretization=5)

where discretization is explained here:

https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.BodyContainer.clump

So for more accurate inertia/mass/volume calculation increase discretization. But however increasing it will lead to higher initialization time for clumps. Fortunately it is parallelized, so you can use -j option to reduce calc. time on creation of clumps ;)

Please give us the results for mass for discretization=5, 10 and 15. Thanks.

Regards,

Christian

Revision history for this message
behzad (behzad-majidi) said :
#2

Hi Christian,

Thanks for the answer.

Yes, I see. Even with discretization=1, the mass is very close to expected value. So, the default value is 0.

I've got mass of the clump for different values of discretization. Mass of the initial ball is 33.5103.

discretization mass of the clump

0 99.8088
1 33.8583
2 33.5651
3 33.5274
4 33.5174
5 33.5245
6 33.5106
7 33.5099
10 33.5101
15 33.5089

By the way, what updateClumpProperties() does? It's used to change the mass or inertia properties? In a normal simulation, we don't need to update these properties, right?

Revision history for this message
Christian Jakob (jakob-ifgt) said :
#3

Hi,

Thank you for your feedback on yade's clump logic. Your results look good even for a low discretization (in your case 6) ...

updateClumpProperties() can be used when the mass/volume/inertia of a clump was changed manually by the user (and it should be updated to the "real" value afterwards). I think you do not need it atm. But of course you can check this function ...

Cheers,

Christian

Revision history for this message
behzad (behzad-majidi) said :
#4

Thanks!