← Back to team overview

yade-users team mailing list archive

[Question #708213]: No. of spheres in a packing


New question #708213 on Yade:

Hello, I m new in yade.  I am trying to fill a box of size 0.1m*0.1m*0.1m with 9500 spheres of mean radius 2 mm and standard deviation of 0.1mm. This condition should be achieved after gravity deposition so that the packing should be stable. I used randomdense packing but it gives approx 16000 spheres. Can anyone help me how to achieve specific no. of spheres in random dense packing.
Below is my script for the same.

#modules import
from yade import pack
#define box of size 0.1*0.1*0.1
O.bodies.append(geom.facetBox((0.05, 0.05, 0.05), (.05, .05, .05), wallMask=31))

#define packing
pred1=pack.inParallelepiped((0,0,0),(0.1,0,0),(0,0.1,0),(0,0,0.12)) #z axis value is increased so that after gravity deposition, final height could be 0.1m
O.bodies.append(pack.randomDensePack(pred1, spheresInCell= 4000, radius=2e-3, rRelFuzz=0.1, seed=1)

#define engines
           PyRunner(command='unbalance()', realPeriod=1, label='force'), 
mass=sum(b.state.mass for b in O.bodies)
vs=mass/density     #fine volume of solids by mass/ density of soil solids

def unbalance():
	print('unbalanced Force', unbalancedForce())
	vol=round(vs/(1-poro),5)                     #finding current volume by porosity formula, n= v-vs/v
	print('volume:', vol)	
	if vol<=0.001:	                        #stop the simulation when final volume of 0.001m3 is reached

Thank you

You received this question notification because your team yade-users is
an answer contact for Yade.