Re: [Yade-users] [Question #293179]: 'Name error' while calling function
Question #293179 on Yade changed: https://answers.launchpad.net/yade/+question/293179 subha posted a new comment: Thanks Klaus, For some reason, option#1 resulted in a segmentation fault (core dumped) however option#2 worked but obviously at the expense of increased simulation time as you previously indicated. SM -- 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 #293179]: 'Name error' while calling function
Question #293179 on Yade changed: https://answers.launchpad.net/yade/+question/293179 Klaus Thoeni posted a new comment: add #10: you have two options: 1. execute the line plot.saveDataTxt('file2.txt.bz2') in the terminal after you have finished the simulation 2. put the line back where you had it at the beginning, it was only a suggestion to move it outside the PyRunner for better performance K -- 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 #293179]: 'Name error' while calling function
Question #293179 on Yade changed: https://answers.launchpad.net/yade/+question/293179 subha posted a new comment: Hi Jerome, Thanks for your comment. How do I define the scope of a function local or global in the script? Thanks, SM -- 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 #293179]: 'Name error' while calling function
Question #293179 on Yade changed: https://answers.launchpad.net/yade/+question/293179 subha posted a new comment: Hi Klaus, I noticed that if O.run(N,False) is used, the script does not write the data in the text file, but saves the images. SM -- 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 #293345]: capillary files
Question #293345 on Yade changed: https://answers.launchpad.net/yade/+question/293345 Status: Open => Answered Jérôme Duriez proposed the following answer: Hello, "r" stands for the radii ratio (greater radius divided by smaller radius) between two capillary bonded spheres. The very first lines of each file include - the r value - the number Nd of dimensionless interparticle distances in this file - a number Nuc of dimensionless capillary pressure values Then, you have Nuc lines describing Nuc capillary bridge configurations in terms of 6 columns with : - the dimensionless distance value (constant along these Nuc lines) - a dimensionless capillary pressure value - a dimensionless liquid volume volume - a dimensionless force value - a filling angle on the smallest particle (in degrees) - a filling angle on the biggest particle (in degrees) (This scheme repeats Nd times) If you're interested in these files, I'd recommend you give a look to https://bugs.launchpad.net/yade/+bug/1440887, and especially #4 that gives a MATLAB file to plot the capillary files data. -- 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
[Yade-users] [Question #293345]: capillary files
New question #293345 on Yade: https://answers.launchpad.net/yade/+question/293345 Hello all, I have a quick question regarding the capillary files. There are ten files named like M(r=numbers). What does r stand for? Also, in the file, can someone please tell me what each column of data stands for? Thank you. Sincerely, Seungcheol -- 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 #293342]: Problem with simulation
Question #293342 on Yade changed: https://answers.launchpad.net/yade/+question/293342 Status: Open => Answered Jérôme Duriez proposed the following answer: Hi, According to the name of Ig2_Sphere_ChainedCylinder_CylScGeom6D(), the interaction between Sphere and chainedCylinder has a "geom" of CylScGeom6D type Thus, you need to include in your simulations a "Law2" that can handle such interactions, wich is not the case here (none of your Law2 functors include CylScGeom6D in its name). I'd advice you to give a close look to https://yade- dem.org/doc/user.html#functors-choice, instead of using brute force and stuffing as many functors as possible (without the right one, by lack of luck) into your simulation ;-) ;-) PS: the title of your question is not so original -- 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
[Yade-users] [Question #293342]: Problem with simulation
New question #293342 on Yade: https://answers.launchpad.net/yade/+question/293342 Hello friends, I created the simulation below and I had a problem. My objective is to make the cylinder collide with spheres. But, I can't do this. When I run the simulation the cylinder goes inside the spheres. I ask if someone could help in this problem. import sys from yade import ymport, utils , plot import math Material microproperties -> SHALE! intR=1.22955 DENS=2659.6453 YOUNG=40e9 FRICT=25 ALPHA=0.25 TENS=10e5 COH=10e6 aRes=1e-3 damp=0.2 jointFRICT=25 jointDIL=15 material definition def sphereMat(): return JCFpmMat(type=1,density=DENS,young=YOUNG,poisson = ALPHA,frictionAngle=radians(FRICT), tensileStrength=TENS,cohesion=COH,jointNormalStiffness=YOUNG/10.,jointShearStiffness=0.2*YOUNG/10., jointTensileStrength=0.,jointCohesion=0.,jointFrictionAngle=radians(jointFRICT),jointDilationAngle=radians(jointDIL)) O.engines=[ ForceResetter(), InsertionSortCollider([ Bo1_ChainedCylinder_Aabb(), Bo1_Sphere_Aabb() ]), InteractionLoop( # Geomeetric interactions [Ig2_ChainedCylinder_ChainedCylinder_ScGeom6D(), Ig2_Sphere_ChainedCylinder_CylScGeom6D(), Ig2_Sphere_Sphere_ScGeom6D(), Ig2_Sphere_Sphere_L3Geom(),Ig2_Facet_Sphere_L3Geom() ], [Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(setCohesionNow=True,setCohesionOnNewContacts=True), Ip2_FrictMat_FrictMat_FrictPhys() ], [Law2_ScGeom6D_CohFrictPhys_CohesionMoment(label='law'), Law2_ScGeom_FrictPhys_CundallStrack(), Law2_L3Geom_FrictPhys_ElPerfPl(), ] ), ## Motion equation NewtonIntegrator(damping=0.4,gravity=[0,0,0]), PyRunner(command='main()',iterPeriod=10) ] O.dt=1e-7 # create a cylinder cil = chainedCylinder(begin=Vector3(0.3,0.4,2.02), end=Vector3(0.3,0.6,2.02),radius=0.025,color=Vector3(0.6,0.5,0.5)) # read a sphere's package PACKING = '10K_P1' O.bodies.append(ymport.text(PACKING+'.spheres',scale=1.,shift=Vector3(0,0,0),material=sphereMat)) yade.qt.View(); def main(): global Fn,Ft O.bodies[0].dynamic=False O.bodies[0].state.vel[2]=-500.0 -- 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 #293216]: Creating Ellipse or Ellipsoid
Question #293216 on Yade changed: https://answers.launchpad.net/yade/+question/293216 Jan Stránský proposed the following answer: Hi Mohsen, if you have different question than the original problem, please open a new question. your 2) comes from 1). I always use randomDensePack with spheresInCell parameter, usually with value between 300 and 2000. Then your example (memoizeDb, too) works OK. cheers Jan 2016-05-05 9:17 GMT+02:00 mohsen: > Question #293216 on Yade changed: > https://answers.launchpad.net/yade/+question/293216 > > mohsen posted a new comment: > Hi Felipe and Jan > Jan i also have some trouble with making a predicate! > generally when i using randomDensePack, i encounter some errors or > warnings that i can not understand their meanings! > Jan can you help us about "memoizeDb"? I think some errors is because of > this. > > in the following is my simple code and warnings: > > ### > ## construct the predicate first > pred=pack.inCylinder(centerBottom=(0,0,-.1),centerTop=(0,0,.1),radius=.05) > ## alternatively: pack.inHyperboloid((0,0,-.1),(0,0,.1),.05,.03) > > ## pack the predicate with spheres (will be explained later) > spheres=pack.randomDensePack(pred,radius=8.5e-3) > > ## add spheres to simulation > O.bodies.append(spheres) > > > Warnings: > WARN > /build/yadedaily-1.20.0-126-e3271e8~trusty/pkg/dem/SpherePack.cpp:104 > makeCloud: porosity must be >0, changing it for you. It will be ineffective > if rMean>0. > /usr/lib/x86_64-linux-gnu/yadedaily/py/yade/pack.py:296: FutureWarning: > The default behavior will change; specify returnSpherePack=True for the new > behavior, and False to get rid of this warning (your code will break in the > future, however). The returned SpherePack object can be added to the > simulation using SpherePack.toSimulation() > warnings.warn('The default behavior will change; specify > returnSpherePack=True for the new behavior, and False to get rid of this > warning (your code will break in the future, however). The returned > SpherePack object can be added to the simulation using > SpherePack.toSimulation()',category=FutureWarning) > /usr/lib/x86_64-linux-gnu/yadedaily/py/yade/pack.py:301: UserWarning: > Packing's dimension > (Vector3(0.09220547603362886,0.09204759935856582,0.1700020579236124)) > doesn't fully contain dimension of the predicate (Vector3(0.1,0.1,0.2)). > if dimP[0]>dimS[0] or dimP[1]>dimS[1] or dimP[2]>dimS[2]: > warnings.warn("Packing's dimension (%s) doesn't fully contain dimension of > the predicate (%s)."%(dimS,dimP)) > > > > 2- another problem is that the spheres in generated pack have overlap!! > How can we avoid this? ( I know that the over lap is removed if we give a > number to spheresInCell, i.e activating periodic condition. but is there > any other way to have a aperiodic scene without overlap) > Is there another method to construct a cylinder filled with spheres with > no initial overlap? > > -- > 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 > -- 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 #291202]: Clumping - angl of repose
Question #291202 on Yade changed: https://answers.launchpad.net/yade/+question/291202 Status: Answered => Open Seti is still having a problem: Yes, I have even tried O.dt=.1*utils.PWaveTimeStep() , no different ! -- 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 #291202]: Clumping - angl of repose
Question #291202 on Yade changed: https://answers.launchpad.net/yade/+question/291202 Seti gave more information on the question: Yes, I have even tried O.dt=.1*utils.PWaveTimeStep() , no difference! -- 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 #291202]: Clumping - angl of repose
Question #291202 on Yade changed: https://answers.launchpad.net/yade/+question/291202 Status: Open => Answered Jérôme Duriez proposed the following answer: Have you tried to play with (decrease) the timestep ? Excessively high timesteps are a classical reason for "explosion" -- 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 #291202]: Clumping - angl of repose
Question #291202 on Yade changed: https://answers.launchpad.net/yade/+question/291202 Seti gave more information on the question: I think this explosion is depended on percentage of clumping . I mean by increasing the ratio of clumping the sample explode sooner. I am not sure what is the conflict. Does anybody experience in this regard. Thanks Seti -- 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 #291202]: Clumping - angl of repose
Question #291202 on Yade changed: https://answers.launchpad.net/yade/+question/291202 Status: Answered => Open Seti is still having a problem: Hi Kalus, Thanks for your response . I have tried to use mackeCloud , easily as per below, However I have the same problem. Would you please? from yade import pack,utils, qt, plot #create material soil1 = CohFrictMat(young=30e9,poisson=0.3,frictionAngle=radians(30),density=2600.0,normalCohesion=1e6, shearCohesion=80e6,label='soil') #color=(1,0,0) red color O.materials.append(soil1) O.bodies.append(utils.wall(0,axis=1,sense=1)) O.materials.append(CohFrictMat(young=30e9,poisson=0.3, frictionAngle = radians(30) , label='wallmat')) wallmat = O.materials[-1] sp=SpherePack() sp.makeCloud((0,0,0),(14.5,14.5,14.5),rMean=0.5,rRelFuzz=0.0) #sp.makeCloud((0,0,0),(14.5,14.5,14.5),rMean=0.2,rRelFuzz=0.0,False,0.95,[0.2,0.3,0.4,0.5,0.6,0.7,0.8],[0.14,0.28,0.34,0.50,0.65,0.85,1.00]) #spheres.toSimulation() sp.toSimulation() #O.bodies.append(spheres) -- 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 #292846]: Particle packing - How to avoid overlap
Question #292846 on Yade changed: https://answers.launchpad.net/yade/+question/292846 Status: Open => Answered Jan Stránský proposed the following answer: Hi Varun, yes, you are right. The s[1]-particle_radius in old and s[1] in new version should do the same. cheers Jan 2016-05-04 23:07 GMT+02:00 VG: > Question #292846 on Yade changed: > https://answers.launchpad.net/yade/+question/292846 > > VG posted a new comment: > Also, I got the latest update of yadedaily which has the change you > mentioned above. The point you mentioned above: > > "in pack.inSphere, it was a real bug. Of course, you can play with settings > like using s[1] or s[1]-particle_radius, but this is different point." > > With the new version of yadedaily, it generates the exact same number of > particles in an aggregate, as generated when I used > "s[1]-particle_radius" instead of "s[1]" with the previous version of > yadedaily. > > In my opinion, your fix in the code and the use of > "s[1]-particle_radius" while generating randomDensepack are doing the > exact same things. > > > For example, in the above script, using a sample_diameter of 2e-4 and > particle diameter of 1e-5, results in 3732 particles within an agglomerate > results in a packing ratio of 0.466, whereas the previous version lead to > 4372 particles and a packing ratio of 0.55. > > -- > 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 > -- 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 #293247]: Physic interaction betweem particles and polyhedra
Question #293247 on Yade changed: https://answers.launchpad.net/yade/+question/293247 Jérôme Duriez proposed the following answer: Yes, this is what I meant (in case your non-spherical bodies are all of the same type, either Facet or Box, you may remove either Bo1_Box_Aabb() ; Ig2_Box_Sphere_ScGeom() or Bo1_Facet_Aabb() ; Ig2_Facet_Sphere_ScGeom()) This being said, I realize my lengthy answer may not be directly related to your initial problem, I am sorry... I now understand you have different material parameters (these en,es) for different bodies. Usually, YADE handles this at the bodies "material" properties level [1]. For instance, simulations with "FrictPhys" handle like a charm different friction angles for sphere-sphere and sphere-box interactions. We just put different values for the frictionAngle attribute of the sphere or box bodies' Material [2], and one unique Ip2 (Ip2_FrictMat_FrictMat_FrictPhys) does the job giving different local friction angles for sphere-sphere and sphere-box interactions. Here, the design of Ip2_FrictMat_FrictMat_MindlinPhys is flawed in my point of view (I'm not used to MindlinPhys, though) if these en,es,krot are material parameters that can be different among bodies. Because including these parameters in Ip2_FrictMat_FrictMat_MindlinPhys prevents playing with different parameters the same way as frictionAngle within FrictPhys (hence your problem).. I see two possible solutions to your problem, both involving modifying the source code - either modifying the source code of Ip2_FrictMat_FrictMat_MindlinPhys to detect the shape of interacting bodies and assign distinct en,es in accordance. From my point of view, this would not conform the classical YADE design I exposed in #6, I agree thus with Jan it would be "hacky" - removing these en,es from Ip2_FrictMat_FrictMat_MindlinPhys to insert them in a (new ?) material class. Which would make more sense, from my point of view. Further discussion would require other people more used to MindlinPhys than me. Hope it still helps [1] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.Body.material [2] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.FrictMat.frictionAngle -- 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 #293247]: Physic interaction betweem particles and polyhedra
Question #293247 on Yade changed: https://answers.launchpad.net/yade/+question/293247 Jonathan Pergoli posted a new comment: Hi Jérome, you mean this: O.engines=[ ForceResetter(), InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Facet_Aabb(),Bo1_Box_Aabb()]), InteractionLoop( [Ig2_Sphere_Sphere_ScGeom(),Ig2_Facet_Sphere_ScGeom(),Ig2_Box_Sphere_ScGeom()], [Ip2_FrictMat_FrictMat_MindlinPhys(en=.55,es=.55,krot=3)], [Law2_ScGeom_MindlinPhys_Mindlin(includeMoment=True)] ), NewtonIntegrator(gravity=(0,0,-2.5e-4),damping=.2) ] ? -- 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 #293216]: Creating Ellipse or Ellipsoid
Question #293216 on Yade changed: https://answers.launchpad.net/yade/+question/293216 mohsen posted a new comment: Hi Felipe and Jan Jan i also have some trouble with making a predicate! generally when i using randomDensePack, i encounter some errors or warnings that i can not understand their meanings! Jan can you help us about "memoizeDb"? I think some errors is because of this. in the following is my simple code and warnings: ### ## construct the predicate first pred=pack.inCylinder(centerBottom=(0,0,-.1),centerTop=(0,0,.1),radius=.05) ## alternatively: pack.inHyperboloid((0,0,-.1),(0,0,.1),.05,.03) ## pack the predicate with spheres (will be explained later) spheres=pack.randomDensePack(pred,radius=8.5e-3) ## add spheres to simulation O.bodies.append(spheres) Warnings: WARN /build/yadedaily-1.20.0-126-e3271e8~trusty/pkg/dem/SpherePack.cpp:104 makeCloud: porosity must be >0, changing it for you. It will be ineffective if rMean>0. /usr/lib/x86_64-linux-gnu/yadedaily/py/yade/pack.py:296: FutureWarning: The default behavior will change; specify returnSpherePack=True for the new behavior, and False to get rid of this warning (your code will break in the future, however). The returned SpherePack object can be added to the simulation using SpherePack.toSimulation() warnings.warn('The default behavior will change; specify returnSpherePack=True for the new behavior, and False to get rid of this warning (your code will break in the future, however). The returned SpherePack object can be added to the simulation using SpherePack.toSimulation()',category=FutureWarning) /usr/lib/x86_64-linux-gnu/yadedaily/py/yade/pack.py:301: UserWarning: Packing's dimension (Vector3(0.09220547603362886,0.09204759935856582,0.1700020579236124)) doesn't fully contain dimension of the predicate (Vector3(0.1,0.1,0.2)). if dimP[0]>dimS[0] or dimP[1]>dimS[1] or dimP[2]>dimS[2]: warnings.warn("Packing's dimension (%s) doesn't fully contain dimension of the predicate (%s)."%(dimS,dimP)) 2- another problem is that the spheres in generated pack have overlap!! How can we avoid this? ( I know that the over lap is removed if we give a number to spheresInCell, i.e activating periodic condition. but is there any other way to have a aperiodic scene without overlap) Is there another method to construct a cylinder filled with spheres with no initial overlap? -- 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