Re: [Yade-users] [Question #701015]: Pore size
Question #701015 on Yade changed: https://answers.launchpad.net/yade/+question/701015 Status: Answered => Open Mithushan Soundaranathan is still having a problem: Hi Robert, Sorry for asking, how can obtain the pore size using tesselationwrapper. Do I use volume function in the this engine than substract the sphere volume. Than how does I account for overlapping sphere? Could you please point me in the right direction. Best regards, Mithu -- 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 #701028]: Triaxial test cylindrical membrane created away from the pack
Question #701028 on Yade changed: https://answers.launchpad.net/yade/+question/701028 Status: Open => Needs information Jan Stránský requested more information: > I tried scaling the packing, but that doesn't seem to eliminate the issue. if the issue is that the cylinder is not positioned correctly, then the solution is to position it correctly :-) > I've shared the coordinates file in the mail. launchpad questions does not work well with mail.. you can put it here directly, > Here is the code I used to create the sample: what are the stop conditions? what number of iterations to run it? 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 #701015]: Pore size
Question #701015 on Yade changed: https://answers.launchpad.net/yade/+question/701015 Robert Caulk posted a new comment: Ah voilà ;) -- 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 #700761]: about measure seepage discharge in triaxial test
Question #700761 on Yade changed: https://answers.launchpad.net/yade/+question/700761 Status: Open => Answered Robert Caulk proposed the following answer: >>flow.meshUpdateInterval = -1 This means your mesh never updates. If your mesh never updates, then your permeability matrix never updates. Thank you for reading the documentation that we have furnished. cheers, Robert [2]https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.FlowEngine.meshUpdateInterval -- 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 #700761]: about measure seepage discharge in triaxial test
Question #700761 on Yade changed: https://answers.launchpad.net/yade/+question/700761 Ziyu Wang posted a new comment: Sorry..Can anyone provide some ideas.. Thanks a lot! -- 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 #701028]: Triaxial test cylindrical membrane created away from the pack
Question #701028 on Yade changed: https://answers.launchpad.net/yade/+question/701028 Status: Answered => Open Rahul R is still having a problem: Hi Jan, Thank you for your reply. I tried scaling the packing, but that doesn't seem to eliminate the issue. As for the first question, I created the specimen by creating a cylindrical pack and depositing it in a cylindrical facet box of the desired diameter (5 units), and doing compression and extension cycles manually till the desired porosity range and height of the specimen was reached. I've shared the coordinates file in the mail. Here is the code I used to create the sample: from yade import pack #From PSD 1 of PSD curves. Density used is 2530kg/m3 psdSizes,psdCumm=[0.0694, 0.07508, 0.08895, 0.11967, 0.16797, 0.20143, 0.26611, 0.30037, 0.34524, 0.39682, 0.414, 0.44251, 0.46447, 0.49646, 0.52426, 0.60258, 0.70105, 0.73584, 0.80093, 0.89857, 0.99597, 1.23104, 1.64618, 1.99808, 2.57658, 3.44547, 4.69182],[0.00039, 0.01361, 0.02507, 0.04094, 0.08854, 0.12644, 0.20049, 0.23928, 0.29833, 0.38472, 0.41469, 0.45788, 0.49931, 0.55573, 0.59892, 0.69853, 0.77434, 0.80078, 0.83604, 0.87924, 0.90833, 0.94358, 0.96915, 0.98325, 0.99207, 0.99647, 1.] #Create a cylinder pack sp=pack.SpherePack(); sp.makeCloud((25,25,55),(29,29,110),psdSizes=psdSizes,psdCumm=psdCumm,distributeMass=True,num=35000); #This works with f=0.15. cyl=pack.inCylinder((27,27,55),(27,27,110),radius=2) #Creating a predicate to fill the pack. sp1=pack.filterSpherePack(cyl,sp,True) #Create a cylindrical pack using the predicate "cyl" and the psd sizes and %fines provided in "makeCloud". sp1.toSimulation(); #Creating a cylindrical box. O.bodies.append(geom.facetCylinder((27,27,81),radius= 2.5,height= 60,fixed=True)); #Creating and identifying interactions btw particles, walls and facets. O.engines=[ ForceResetter(), InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Facet_Aabb(),Bo1_Wall_Aabb()]), InteractionLoop( [Ig2_Sphere_Sphere_ScGeom(),Ig2_Facet_Sphere_ScGeom(),Ig2_Wall_Sphere_ScGeom()], [Ip2_FrictMat_FrictMat_FrictPhys()], [Law2_ScGeom_FrictPhys_CundallStrack()] ), NewtonIntegrator(gravity=(0,0,-9.81),damping=0.5), #PyRunner(command='compaction()',iterPeriod=50) ] O.dt=.5*PWaveTimeStep() On Tue, 22 Mar 2022 at 16:41, Jan Stránský < question701...@answers.launchpad.net> wrote: > Your question #701028 on Yade changed: > https://answers.launchpad.net/yade/+question/701028 > > Status: Open => Answered > > Jan Stránský proposed the following answer: > Hello, > > > I'm new in Yade. > > welcome :-) > > > I found a code on github ... > > http://bazaar.launchpad.net ... > > we are using GitLab currently as a main repository platform [1] > > > the cylindrical membrane ... is created away from the pack. > > > width = 5, > > height = 9.85 > > ... > > sp= ymport.textExt(...) > > spheres = O.bodies.append(sp) > > How did you create the packing? What is its dimensions and position? > I guess it simply does not fit together with defined cylinder dimensions > and position.. > > Shift and/or resize the packing and/or the cylinder. > > Cheers > Jan > > [1] https://gitlab.com/yade-dev/trunk > > -- > If this answers your question, please go to the following page to let us > know that it is solved: > https://answers.launchpad.net/yade/+question/701028/+confirm?answer_id=0 > > If you still need help, you can reply to this email or go to the > following page to enter your feedback: > https://answers.launchpad.net/yade/+question/701028 > > You received this question notification because you asked the question. > -- 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 #701031]: the way for back-up
Question #701031 on Yade changed: https://answers.launchpad.net/yade/+question/701031 Status: Open => Answered Jan Stránský proposed the following answer: Hello, saving can be done in several ways depending on the definition of "back- up for later use", e.g. O.save [1], export module [2], VTKRecorder [3], ... Cheers Jan [1] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.Omega.save [2] https://yade-dem.org/doc/yade.export.html [3] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.VTKRecorder -- 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 #701030]: Why is my pyrunner command not being called?
Question #701030 on Yade changed: https://answers.launchpad.net/yade/+question/701030 Jan Stránský posted a new comment: > I just fixed the problem. I called the pyrunner command succesfully! For future reference (if somebody goes here looking for solution of the same / similar problem), could you please specify how you fixed the problem? The working code would probably do the job. > We cannot simply add the pyrunner in the O.engines, we have to add the > pyrunner command in this line: > O.engines=O.engines[0:5]+[...]+O.engines[5:7] > > in the middle between O.engines[0:5] and O.engines[5:7], after adding the > pyrunner command, so we can def the command as we want in the following part. Sorry, but this is (or at least should not) be true. You do NOT have to add anything the way O.engines=O.engines[0:5]+[...]+O.engines[5:7] Contrary, I strongly discourage this approach (explained in earlier answers). Moreover, O.engines=O.engines[0:5]+[...]+O.engines[5:7] essentially is equivalent to "simply add the pyrunner in the O.engines". 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 #700953]: Oedometer test based on PSD
Question #700953 on Yade changed: https://answers.launchpad.net/yade/+question/700953 Status: Answered => Solved Soheil Safari confirmed that the question is solved: Thanks Robert Caulk, that solved my question. -- 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 #701031]: the way for back-up
New question #701031 on Yade: https://answers.launchpad.net/yade/+question/701031 is there any way to save a file (e.g.: .yade.bz2) or other back-up for later use if i close the programme by mistake -- 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 #700980]: How to change the strainRate value of TriaxialCompressionEngine during the simulation period?
Question #700980 on Yade changed: https://answers.launchpad.net/yade/+question/700980 Status: Answered => Solved Xifan Li confirmed that the question is solved: https://answers.launchpad.net/yade/+question/701030 I just solved this problem. -- 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 #701030]: Why is my pyrunner command not being called?
Question #701030 on Yade changed: https://answers.launchpad.net/yade/+question/701030 Status: Open => Solved Xifan Li confirmed that the question is solved: Thank you all guys. I just fixed the problem. I called the pyrunner command succesfully! I realize that if we want to use the existing engine (like TriaxStressController, TriaxCompressionEngine) to call the pyrunner command to change the simulation proceed. We cannot simply add the pyrunner in the O.engines, we have to add the pyrunner command in this line: O.engines=O.engines[0:5]+[...]+O.engines[5:7] in the middle between O.engines[0:5] and O.engines[5:7], after adding the pyrunner command, so we can def the command as we want in the following part. Many thanks to Jan who gave me the inspiration and Rober as well and other people who take their time to look at my problem. Cheers -- 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 #700957]: How to simulate the cyclic loading during the biaxial test?
Question #700957 on Yade changed: https://answers.launchpad.net/yade/+question/700957 Status: Answered => Solved Xifan Li confirmed that the question is solved: https://answers.launchpad.net/yade/+question/701030 I just solved this problem. Thank you all guys. -- 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 #701028]: Triaxial test cylindrical membrane created away from the pack
Question #701028 on Yade changed: https://answers.launchpad.net/yade/+question/701028 Status: Open => Answered Jan Stránský proposed the following answer: Hello, > I'm new in Yade. welcome :-) > I found a code on github ... > http://bazaar.launchpad.net ... we are using GitLab currently as a main repository platform [1] > the cylindrical membrane ... is created away from the pack. > width = 5, > height = 9.85 > ... > sp= ymport.textExt(...) > spheres = O.bodies.append(sp) How did you create the packing? What is its dimensions and position? I guess it simply does not fit together with defined cylinder dimensions and position.. Shift and/or resize the packing and/or the cylinder. Cheers Jan [1] https://gitlab.com/yade-dev/trunk -- 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 #701015]: Pore size
Question #701015 on Yade changed: https://answers.launchpad.net/yade/+question/701015 Jan Stránský posted a new comment: @ Robert > I see you are using "o.engines" where you should be using "O.engines" I noticed this, too. In the code, this structure is used: o = Omega() not very "mainstream", but works.. 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 #701030]: Why is my pyrunner command not being called?
Question #701030 on Yade changed: https://answers.launchpad.net/yade/+question/701030 Status: Answered => Open Xifan Li is still having a problem: Thank you Robert, But the point is not the print function, I mean that the above code can run the print() command, but cannot run the triaxload() and triaxunload() command. I add the print() command in order to confirm that my code can run normally, but my main objective is to run the triaxload() & triaxunload() command during the simulation. -- 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 #701030]: Why is my pyrunner command not being called?
Question #701030 on Yade changed: https://answers.launchpad.net/yade/+question/701030 Jan Stránský proposed the following answer: Hello, > but it doesn't work. please be more specific. Is there any error? It has / seems to have no effect? ... ? Also, try to provide a MWE [1]. I.e., if your problem is PyRunner, use just one PyRunner and try to localize the problem. > So I was wondering maybe there's something wrong with the engine code, so I add the "print ('hello')" why did not you put it inside the PyRunner, but to the topmost code? > and it did work. But the pyrunner command still doesn't work. I do not know what is going wrong. put the print inside PyRunner function, together with more valuable info then "hello", (e.g. O.iter etc.) PyRunner is called at the intervals you provide and does what you tell it to do. > triaxload.command=('triaxunload') ('triaxunload') does nothing. Next time the PyRunner calls what you provide, i.e. triaxunload, which is just name of a function. It does not call it. What about triaxload.command='triaxunload()' ? > O.engines=O.engines[0:5]+[...]+O.engines[5:7] this code is very likely to produce errors. E.g. if you add an engine and leave indices 5 and 7, it does completely different thing than you want. It has some use cases, like setting engines, do running, change engines. But since you do this before any running, put the "additional" engines directly to O.engines = [...] code. Cheers Jan [1] https://www.yade-dem.org/wiki/Howtoask -- 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 #700953]: Oedometer test based on PSD
Question #700953 on Yade changed: https://answers.launchpad.net/yade/+question/700953 Status: Open => Answered Robert Caulk proposed the following answer: Hello, >> I am looking for adding something like this but without gravity deposition in the previous code [1]. Ok, so have you tried removing gravity? Cheers, Robert -- 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 #701012]: DFN and Thermal engine
Question #701012 on Yade changed: https://answers.launchpad.net/yade/+question/701012 Status: Needs information => Answered Robert Caulk proposed the following answer: >>Can I find a python script that combines the DFN and the thermal engine ? I do not know of such a script. But as for code it is simply adding the two engines to the engine list. Of course you need to know how to handle DFNFlowEngine and ThermalEngine parameters and geometrical considerations - but it seems you are not using ThermalEngine so that is irrelevant. -- 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 #701015]: Pore size
Question #701015 on Yade changed: https://answers.launchpad.net/yade/+question/701015 Status: Open => Answered Robert Caulk proposed the following answer: Hello, >>can still use it by define dead=1.However, I get an empty vertices dataset. If you want FlowEngine to triangulate your packing, then it should not be dead. If FlowEngine is dead, then it is not doing anything, i.e. not computing a triangulation, hence your empty dataset. If you do not want to compute fluid flow but you still want a triangulation, then you should look into using TesselationWrapper [1]. >>pore size change over time during swelling (radius increase) of the particle. printVertices() is simply giving you the vertices of the triangulation, it is not giving you any pore sizes. You would need to post process the vertices yourself to get the pore sizes. I see you are using "o.engines" where you should be using "O.engines" (and plenty other places where you use o.* instead of O.*). Cheers, Robert [1]https://yade- dem.org/doc/yade.wrapper.html#yade.wrapper.TesselationWrapper -- 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 #701030]: Why is my pyrunner command not being called?
Question #701030 on Yade changed: https://answers.launchpad.net/yade/+question/701030 Status: Open => Answered Robert Caulk proposed the following answer: Hello, Your PyRunner is calling 'triaxunload()'. Your print statement is not inside triaxunload(), thus it will not be called. Cheers, Robert -- 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 #701030]: Why is my pyrunner command not being called?
New question #701030 on Yade: https://answers.launchpad.net/yade/+question/701030 I want to use pyrunner's command to control the loading and unloading process, but it doesn't work. So I was wondering maybe there's something wrong with the engine code, so I add the "print ('hello')", and it did work. But the pyrunner command still doesn't work. I do not know what is going wrong. Here is my code, could you please help me to check about it? Many thanks for your help. ## from yade import pack # The following 5 lines will be used later for batch execution nRead=readParamsFromTable( num_spheres=1000,# number of spheres compFricDegree = 30, # contact friction during the confining phase key='_triax_base_', # put you simulation's name here unknownOk=True ) from yade.params import table num_spheres=table.num_spheres# number of spheres key=table.key targetPorosity = 0.43 #the porosity we want for the packing compFricDegree = table.compFricDegree # initial contact friction during the confining phase (will be decreased during the REFD compaction process) finalFricDegree = 30 # contact friction during the deviatoric loading rate=-0.02 # loading rate (strain rate) damp=0.2 # damping coefficient stabilityThreshold=0.01 # we test unbalancedForce against this value in different loops (see below) young=5e6 # contact stiffness mn,mx=Vector3(0,0,0),Vector3(10,10,.1) # corners of the initial packing ## create materials for spheres and plates O.materials.append(FrictMat(young=young,poisson=0.5,frictionAngle=radians(compFricDegree),density=2600,label='spheres')) O.materials.append(FrictMat(young=young,poisson=0.5,frictionAngle=0,density=0,label='walls')) ## create walls around the packing walls=aabbWalls([mn,mx],thickness=0,material='walls') wallIds=O.bodies.append(walls) ## use a SpherePack object to generate a random loose particles packing sp=pack.SpherePack() sp.makeCloud(minCorner=mn,maxCorner=mx,rRelFuzz=0,num=2000) sp.toSimulation(material='spheres') triax=TriaxialStressController( maxMultiplier=1.+2e4/young, # spheres growing factor (fast growth) finalMaxMultiplier=1.+2e3/young, # spheres growing factor (slow growth) thickness = 0, internalCompaction=False, stressMask = 1, goal1=-2e5, goal2=rate, ) O.engines=[ ForceResetter(), InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Box_Aabb()]), InteractionLoop( [Ig2_Sphere_Sphere_ScGeom(),Ig2_Box_Sphere_ScGeom()], [Ip2_FrictMat_FrictMat_FrictPhys()], [Law2_ScGeom_FrictPhys_CundallStrack()] ), GlobalStiffnessTimeStepper(active=1,timeStepUpdateInterval=100,timestepSafetyCoefficient=0.8), triax, TriaxialStateRecorder(iterPeriod=100, file='WallStresses.txt'), NewtonIntegrator(damping=damp), PyRunner(command='triaxload()',iterPeriod=1, label='triaxload'), ] triax.stressMask = 1 triax.goal1=-2e5 triax.goal2=rate print('hello') def triaxload(): if abs(O.triax.stress(triax.wall_top_id)[1])> 15: triax.stressMask = 1 triax.goal1=-3e5 triax.goal2=rate triaxload.command=('triaxunload') def triaxunload(): if abs(triax.stress(triax.wall_top_id)[1])< 5e4: triax.stressMask = 1 triax.goal1=-1e5 triax.goal2=rate from yade import plot O.engines=O.engines[0:5]+[PyRunner(iterPeriod=20,command='history()',label='recorder')]+O.engines[5:7] def history(): plot.addData(e11=-triax.strain[0], e22=-triax.strain[1], s11=-triax.stress(triax.wall_right_id)[0], s22=-triax.stress(triax.wall_top_id)[1], i=O.iter) plot.plots={'e11': ('s11',),'e22': ('s22',)} O.saveTmp() plot.plot() -- 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 #701028]: Triaxial test cylindrical membrane created away from the pack
New question #701028 on Yade: https://answers.launchpad.net/yade/+question/701028 Hi, I'm new in Yade. I wanted to do a triaxial test on a cylindrical specimen. I found a code on github and modified the code for my specimen (the original code creates a spherical pack and do triaxial test but I created a cylindrical sample of desired porosity and imported the coordinates to this code). I ran the code but the cylindrical membrane that was supposed to be created around the spherical pack is created away from the pack. Can somebody help me? Here is the link to the actual code: http://bazaar.launchpad.net/~yade-pkg/yade/git-trunk/view/head:/examples/concrete/triax.py Here is the code: # -*- encoding=utf-8 -*- from __future__ import print_function # # Triaxial test. Axial strain rate is prescribed and transverse prestress. # Test is possible on prism or cylinder # An independent c++ engine may be created from this script in the future. # from builtins import range from yade import ymport, plot from yade import pack, plot import os # default parameters or from table readParamsFromTable(noTableOk=True, # material parameters young = 10e7, poisson = .3, frictionAngle = 0.15, sigmaT = 1.5e6, # prestress preStress = -3e6, # axial strain rate strainRate = -100, # assamlby parameters rParticle = 0.0005, width = 5, height = 9.85, bcCoeff = 5, # facets division nw = 48, nh = 30, # output specifications fileName = 'test', exportDir = '/tmp', runGnuplot = False, runInGui = True, ) from yade.params.table import * # materials sphereMat = O.materials.append(CohFrictMat(young=young,poisson=poisson,frictionAngle=frictionAngle,alphaKr=0.25,alphaKtw=0,etaRoll=0.005,etaTwist=0,normalCohesion=5e6,shearCohesion=5e6,momentRotationLaw=True,density=2530)) frictMat = O.materials.append(FrictMat( young=young,poisson=poisson,frictionAngle=frictionAngle )) # spheres sp= ymport.textExt('DensepackRD70-80',format='x_y_z_r',shift= Vector3(0,0,0.5*height), scale=1.0, material=sphereMat) spheres = O.bodies.append(sp) #pred = pack.inCylinder((0,0,0),(0,0,height),.5*width) if testType=='cyl' else pack.inAlignedBox((-.5*width,-.5*width,0),(.5*width,.5*width,height)) if testType=='cube' else None #sp=SpherePack() #sp = pack.randomDensePack(pred,spheresInCell=2000,radius=rParticle,memoizeDb='/tmp/triaxTestOnCylinder.sqlite',returnSpherePack=True) #spheres=sp.toSimulation(color=(0,1,1)) # bottom and top of specimen. Will have prescribed velocity bot = [O.bodies[s] for s in spheres if O.bodies[s].state.pos[2]height-rParticle*bcCoeff] vel = strainRate*(height-rParticle*2*bcCoeff) top_limit = 0 top_id = 0 for s in top: if s.state.pos[2]>=top_limit: top_limit = s.state.pos[2] top_id = s.id bot_limit = height bot_id = 0 for s in bot: if s.state.pos[2]<=bot_limit: bot_limit = s.state.pos[2] bot_id = s.id # facets facets = [] rCyl2 = .5*width / cos(pi/float(nw)) for r in range(nw): for h in range(nh): v1 = Vector3( rCyl2*cos(2*pi*(r+0)/float(nw)), rCyl2*sin(2*pi*(r+0)/float(nw)), height*(h+0)/float(nh) ) v2 = Vector3( rCyl2*cos(2*pi*(r+1)/float(nw)), rCyl2*sin(2*pi*(r+1)/float(nw)), height*(h+0)/float(nh) ) v3 = Vector3( rCyl2*cos(2*pi*(r+1)/float(nw)), rCyl2*sin(2*pi*(r+1)/float(nw)), height*(h+1)/float(nh) ) v4 = Vector3( rCyl2*cos(2*pi*(r+0)/float(nw)), rCyl2*sin(2*pi*(r+0)/float(nw)), height*(h+1)/float(nh) ) f1 = facet((v1,v2,v3),color=(0,0,1),material=frictMat) f2 = facet((v1,v3,v4),color=(0,0,1),material=frictMat) facets.extend((f1,f2)) O.bodies.append(facets) mass = O.bodies[0].state.mass for f in facets: f.state.mass = mass f.state.blockedDOFs = 'XYZz' # plots plot.plots = { 'e':('s',), } def plotAddData(): f1 = sum(O.forces.f(b.id)[2] for b in top) f2 = sum(O.forces.f(b.id)[2] for b in bot) f = .5*(f2-f1) s = f/(pi*.25*width*width) e = (top[0].state.displ()[2] - bot[0].state.displ()[2]) / (height-rParticle*2*bcCoeff) plot.addData( i = O.iter, s = s, e = e, ) # apply prestress to facets def addForces(): for f in facets: n = f.shape.normal a = f.shape.area O.forces.addF(f.id,preStress*a*n) # stop condition and exit of the simulation def stopIfDamaged(maxEps=5e-3): extremum = max(abs(s) for s in plot.data['s']) s = abs(plot.data['s'][-1]) e = abs(plot.data['e'][-1]) if
Re: [Yade-users] [Question #700963]: Pore size distribution
Question #700963 on Yade changed: https://answers.launchpad.net/yade/+question/700963 Soheil Safari posted a new comment: Dear Jan; That is great. Thank you very much for your valuable time spent on this useful code. I really appreciate your kind effort in solving my issue. Best regards, Soheil -- 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 #700800]: simulate rectangular lastic
Question #700800 on Yade changed: https://answers.launchpad.net/yade/+question/700800 Status: Needs information => Expired Launchpad Janitor expired the question: This question was expired because it remained in the 'Needs information' state without activity for the last 15 days. -- 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