New question #681410 on Yade: https://answers.launchpad.net/yade/+question/681410
Hi all, I'm newbie to yade and try to model cylindrical membrane using Pfacet elements for triaxial test. I have used two for loops to create membrane mesh and I can not see the fully developed membrane in 3D view in Yadedaily. Instead I can only see a strip along height of the cylinder(revolving is not happened). A minimum working exmaple is attached below. Could you please help me on this? # encoding: utf-8 from yade import qt from yade.gridpfacet import * ########################### ##### ENGINES ##### ########################### O.engines=[ ForceResetter(), InsertionSortCollider([ Bo1_Sphere_Aabb(), Bo1_Wall_Aabb(), Bo1_PFacet_Aabb(), ],sortThenCollide=True), InteractionLoop( [ Ig2_GridNode_GridNode_GridNodeGeom6D(), Ig2_GridConnection_GridConnection_GridCoGridCoGeom(), Ig2_Sphere_Sphere_ScGeom6D(), Ig2_Sphere_PFacet_ScGridCoGeom(), ], [ Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(setCohesionNow=True,setCohesionOnNewContacts=True), Ip2_FrictMat_FrictMat_FrictPhys()], [ Law2_ScGeom6D_CohFrictPhys_CohesionMoment(), Law2_ScGeom_FrictPhys_CundallStrack(), Law2_ScGridCoGeom_FrictPhys_CundallStrack(), Law2_GridCoGridCoGeom_FrictPhys_CundallStrack() ]), GlobalStiffnessTimeStepper(timestepSafetyCoefficient=0.8,label='ts'), NewtonIntegrator(gravity=(0,-9.81,0),damping=0.1,label='newton') ] #materials O.materials.append(CohFrictMat(young=1e7,poisson=1,density=2650,frictionAngle=radians(30),normalCohesion=3e7,shearCohesion=3e7,momentRotationLaw=True,label='gridNodeMat')) O.materials.append( FrictMat( young=1e7,poisson=0.1,density=2650,frictionAngle=radians(30),label='pFacetMat' ) ) ################################### ##### PFacet creators ##### ################################### nodesIds=[] cylIds=[] P_facets=[] c=0 width=0.1 #diameter of cylinder height=0.2 #height of cylinder nw = 40 # no of nodes along perimeter nh = 12 # no of nodes along height r=width/100 #radius of grid node color1=[255./255.,102./255.,0./255.] color2=[0,0,0] color3=[0.5,0.5,0.5] rCyl2 = .5*width / cos(pi/float(nw)) for r in xrange(nw): for h in xrange(nh): c=c+1 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) ) V1=(O.bodies.append(gridNode([rCyl2*cos(2*pi*(r+0)/float(nw)),rCyl2*sin(2*pi*(r+0)/float(nw)), height*(h+0)/float(nh)],r,wire=True,fixed=False, material='gridNodeMat',color=color1)) ) V2=(O.bodies.append(gridNode([rCyl2*cos(2*pi*(r+1)/float(nw)),rCyl2*sin(2*pi*(r+1)/float(nw)), height*(h+0)/float(nh)],r,wire=True,fixed=False, material='gridNodeMat',color=color2)) ) V3=(O.bodies.append(gridNode([rCyl2*cos(2*pi*(r+1)/float(nw)),rCyl2*sin(2*pi*(r+1)/float(nw)), height*(h+1)/float(nh)],r,wire=True,fixed=False, material='gridNodeMat',color=color1)) ) V4=(O.bodies.append(gridNode([rCyl2*cos(2*pi*(r+0)/float(nw)),rCyl2*sin(2*pi*(r+0)/float(nw)), height*(h+1)/float(nh)],r,wire=True,fixed=False, material='gridNodeMat',color=color2)) ) # append node ids to seperate matrix for later use nodesIds.append(V1) nodesIds.append(V2) nodesIds.append(V3) nodesIds.append(V4) #create grid connection cylIds.append(O.bodies.append(gridConnection(V1,V2,r,material='gridNodeMat',color=color3))) cylIds.append(O.bodies.append(gridConnection(V2,V3,r,material='gridNodeMat',color=color3))) cylIds.append(O.bodies.append(gridConnection(V1,V3,r,material='gridNodeMat',color=color3))) cylIds.append(O.bodies.append(gridConnection(V3,V4,r,material='gridNodeMat',color=color3))) cylIds.append(O.bodies.append(gridConnection(V4,V1,r,material='gridNodeMat',color=color3))) #create Pfacets O.bodies.append(pfacet(V1,V2,V3,wire=True,material='pFacetMat',color=color3)) O.bodies.append(pfacet(V1,V3,V4,wire=True,material='pFacetMat',color=color3)) if c%50==0: print c qt.View() 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