Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-19 Thread Jan Stránský
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Status: Open => Answered

Jan Stránský proposed the following answer:
> NameError: name 'boxVolume' is not defined

it was meant to be already pre-computed value, like
boxVolume = width * depth * height

> And please help me with medium packing of spheres.

read this thread, help has already been given several times:
"Choose dense packaging first and go from there."
"One solution is e.g. to use randomDensePack with larger particles then desired 
and than make the particles smaller to desired size."
"probably you will have to develop your own approach"

> Following is the script for dense packing. I modify the gravity deposition 
> tutorial. Suggest me the corrections if i am going wrong.
> PROBLEM STATEMENT- Find packing fraction of dense packing of spheres which 
> deposits under gravity in a rectangular box.

It depends on the specific problem definitions.
It can be perfectly OK, or it can be pretty wrong, really depending on the 
definitions.
Like, should the initial packing be already dense? or it should be loose 
packing and made dense by the gravity deposition (more natural case IMO)?
Should it be one particle size, or rather various particle sizes?
... ?

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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-19 Thread Amrisha Khandelwal
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Amrisha Khandelwal posted a new comment:
Thank you Jan for #5..
I run this command. I am getting following error:

NameError Traceback (most recent call last)
/usr/bin/yade in 
> 1 packingFraction = getSpheresVolume() / boxVolume()

NameError: name 'boxVolume' is not defined

-- 
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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-19 Thread Amrisha Khandelwal
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Status: Needs information => Open

Amrisha Khandelwal gave more information on the question:
Thank you for your response Jan and Bernard..
Following is the script for dense packing. I modify the gravity deposition 
tutorial. Suggest me the corrections if i am going wrong. 
PROBLEM STATEMENT- Find packing fraction of dense packing of spheres which 
deposits under gravity in a rectangular box. 

And please help me with medium packing of spheres.

from yade import pack

# create rectangular box from facets
O.bodies.append(geom.facetBox((.5, .5, .5), (.5, .5, .5), wallMask=31))
if 0:
# create empty sphere packing
# sphere packing is not equivalent to particles in simulation, it contains only 
the pure geometry
  sp = pack.SpherePack()
# generate randomly spheres with uniform radius distribution
  sp.makeCloud((0, 0, 0), (1, 1, 1), rMean=.05, rRelFuzz=.5, periodic=True)
# add the sphere pack to the simulation
  sp.toSimulation()
else:
# add dense packing
  O.bodies.append(pack.regularHexa(pack.inAlignedBox((0,0,0), (1,1,1)), 
radius=.05, gap=0))
O.engines = [
ForceResetter(),
InsertionSortCollider([Bo1_Sphere_Aabb(), Bo1_Facet_Aabb()]),
InteractionLoop(
# handle sphere+sphere and facet+sphere collisions
[Ig2_Sphere_Sphere_ScGeom(), Ig2_Facet_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom_FrictPhys_CundallStrack()]
),
NewtonIntegrator(gravity=(0, 0, -9.81), damping=0.4),
# call the checkUnbalanced function (defined below) every 2 seconds
PyRunner(command='checkUnbalanced()', realPeriod=2)
]
O.dt = .5 * PWaveTimeStep()
O.trackEnergy = True

def checkUnbalanced():
if unbalancedForce() < .05:
O.pause()
O.saveTmp()

-- 
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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-19 Thread Jan Stránský
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Jan Stránský posted a new comment:
> packingFraction = sum(4/3.*pi*pow(b.shape.radius,3) for b in O.bodies)
/ boxVolume

with credit to Vasileios' answer at [3], it can be simplified to
packingFraction = getSpheresVolume() / boxVolume
using getSpheresVolume [4] (I did not know about the function).

Cheers
Jan

[3] https://answers.launchpad.net/yade/+question/704153
[4] https://yade-dem.org/doc/yade.utils.html#yade._utils.getSpheresVolume

-- 
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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-14 Thread Bernard Stafford
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Bernard Stafford posted a new comment:
Choose dense packaging first and go from there.

-- 
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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-13 Thread Jan Stránský
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Status: Open => Needs information

Jan Stránský requested more information:
Hello,

thanks for adding more information, but still it is too ambiguous.
As I said, there are many approaches [2] with various requirements (on 
boundary, spatial distribution, size distribution, ...).

Please be more specific, clear and also please answer all the questions from my 
previous information request (and of course from this one).
Otherwise we can give just as general answers.

Also please read [1] and provide a MWE [1] for your loose and dense
packing.

> Can anyone help me for finding solution to simulate medium packing of
spheres?

How do you define "medium"?

What is "packing"?
- uniform size? particle size distribution?
- regular? random?

> help me ... to simulate medium packing
> My problem is to simulate loose, medium and dense packing of spheres

What does "to simulate" mean? Just to create? Or some actual simulation,
like compaction?

> finding its packing fraction and porosity.

packingFraction = sum(4/3.*pi*pow(b.shape.radius,3) for b in O.bodies) /
boxVolume

> Loose ... packing, I made

how?

> Which parameters need to be changed for solving it?

I doubt there is a parameter for such thing..
The packing creation is either loose (to spent as little time as possible) or 
dense (to make it as dense as possible).
For in-between case, probably you will have to develop your own approach (one 
"blind" option I gave in answer #1, randomDensePack and then reducing size of 
particles)

Cheers
Jan

[1] https://www.yade-dem.org/wiki/Howtoask
[2] https://yade-dem.org/doc/user.html#sphere-packings

-- 
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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-12 Thread Amrisha Khandelwal
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Status: Needs information => Open

Amrisha Khandelwal gave more information on the question:
Thank you Jan for suggesting your solution.. I made changes in
question.. Please check again and help.

Thank you
Amrisha

-- 
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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-12 Thread Amrisha Khandelwal
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Description changed to:
I am new to yade. Can anyone help me for finding solution to simulate medium 
packing of spheres?
My problem is to simulate loose, medium and dense packing of spheres in a box 
and finding its packing fraction and porosity.
Loose and dense packing, I made but i stuck in medium density. 
Dense packing, I made with randomDensePack function. 
Which parameters need to be changed for solving it?

-- 
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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #704099]: Packing of Medium Density

2022-12-12 Thread Jan Stránský
Question #704099 on Yade changed:
https://answers.launchpad.net/yade/+question/704099

Status: Open => Needs information

Jan Stránský requested more information:
Hello,

> I am new to yade.

welcome :-)

Can anyone help me ...

please be more specific and define more precisely:
- packing:
- spheres? clumps? polyhedrons? ... ?
- sizes? uniform size? particle size distribution? ... ?
- regular? random?
- periodic or not? within what shape? ... ?
- ...
- medium density, medium packing:
- medium of what? between pure makeCloud and randomDensePack?
- more rigorous definition and requirements:
- E.g. only packing density, or also some spatial distribution 
requirements, ...

There are maaany options and the proper answer depends on what you
actually want.

One solution is e.g. to use randomDensePack with larger particles then
desired and than make the particles smaller to desired size.

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 : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp