New question #708516 on Yade: https://answers.launchpad.net/yade/+question/708516
I want to load two different files one is of sphere packing and second one is geogrid. Then i again want to load same sphere packing so that my system would be - packing then geogrid then packing. Then i want to deposit them under gravity. My problem is only the latest one uploads rest do not. How to make it up? Here is my script- from yade import pack,geom,qt from yade.gridpfacet import * from yade import utils from pylab import * from pprint import pprint from yade import plot from builtins import range from yade import export #Load packing from previous script O.load('packing.yade') sp = SpherePack() sp.fromSimulation() sp = pack.SpherePack([(b.state.pos,b.shape.radius) for b in O.bodies if isinstance (b.shape, Sphere)]) print (len(O.bodies)) #load grid grid.yade O.load('grid.yade') #again load packing O.load('packing.yade') E=5e6 Poisson=0.3 Density=2650 v=0.05 rm=0.0019 O.engines=[ ForceResetter(), InsertionSortCollider([Bo1_Sphere_Aabb(), Bo1_GridConnection_Aabb()]), InteractionLoop([ Ig2_Sphere_Sphere_ScGeom(), Ig2_Sphere_GridConnection_ScGridCoGeom(), Ig2_GridNode_GridNode_GridNodeGeom6D(), Ig2_GridConnection_GridConnection_GridCoGridCoGeom(), ], [ Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(setCohesionNow=True,setCohesionOnNewContacts=False), Ip2_FrictMat_FrictMat_FrictPhys() ], [ Law2_ScGeom6D_CohFrictPhys_CohesionMoment(), Law2_ScGeom_FrictPhys_CundallStrack(), Law2_ScGridCoGeom_FrictPhys_CundallStrack(), Law2_GridCoGridCoGeom_FrictPhys_CundallStrack(), ] ), GlobalStiffnessTimeStepper(timestepSafetyCoefficient=0.5,label='ts'), NewtonIntegrator(gravity=(0,0,-9.81),damping=.8,label='newton'), PyRunner(command='checkUnbalanced()', realPeriod=1, label='checker'), ] O.materials.append( CohFrictMat( young=5e6,poisson=.3,density=2650,frictionAngle=0,normalCohesion=3e100,shearCohesion=3e100,momentRotationLaw=True,label='cohfrictMat' ) ) O.materials.append( FrictMat( young=E,poisson=Poisson,density=Density, frictionAngle=radians(20),label='frictMat' ) ) #Box O.bodies.append(geom.facetBox((0.05, 0.05, 0.05), (.05, .05, .05), wallMask=31, material='frictMat')) def checkUnbalanced(): print('unbalanced force:', unbalancedForce(), 'porosity', utils.porosity()) if unbalancedForce() > 0.05: return O.pause() qt.Controller() qtv = qt.View() qtr = qt.Renderer() qtr.bgColor=[1,1,1] Gl1_Sphere.stripes=0 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