can't get uniform radius distribution

Asked by Jinziyu

my code is
sp.makeCloud(Vector3(0,0,0.02),Vector3(1.5,1.5,0.02),rMean=0.008,rRelFuzz=0.33,num=N_particles)

 but the result is uniform radius distribute in [0.0107511,0.0132688], so rMean is about 0.01200995, not 0.008

Question information

Language:
English Edit question
Status:
Answered
For:
Yade Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Jinziyu (jinziyu) said :
#1
Revision history for this message
Jan Stránský (honzik) said :
#2

Hello,

> my code is

please provide the code as a MWE [1], W = working, complete.
In this case, if you just run the code, you get "NameError: name 'sp' is not defined".
Thanks at least for N_particles value.

In this case it is easy to guess that there should be "sp = yade.pack.SpherePack()" before, but one source of problem could be some improper usage of "sp" before your code. Complete code is always better.

note the warning you get about not all 10000 spheres added.
So probably you get "statistically not sufficient" amount of particles.

If I enlarge your cloud area, I get almost perfect average 0.008:
###
N_particles = 10000
sp = yade.pack.SpherePack()
sp.makeCloud(Vector3(-10,-10,0.02),Vector3(10,10,0.02),rMean=0.008,rRelFuzz=0.33,num=N_particles)
rs = [r for (c,r) in sp]
rAvg = sum(rs)/len(rs)
print(rAvg)
###

Cheers
Jan

[1] https://www.yade-dem.org/wiki/Howtoask

Can you help with this problem?

Provide an answer of your own, or ask Jinziyu for more information if necessary.

To post a message you must log in.