Question #689446 on Yade changed:
https://answers.launchpad.net/yade/+question/689446

Description changed to:
Dear all,

I would like to simulate the spreading process of spherical powders by a
roller under the periodic boundary condition. The roller is represented
by a cylindrical particle. Since the radius of the cylindrical roller is
larger than a half of the periodic size. The simulation always
encountered the error "Segmentation fault (core dumped)". Please give
some suggestions about how to add this large cylinder into the periodic
cell.

Sincerely appreciate your help.

Best regards,
Pengfei


Please see script as follows:

######################################################################
from yade.gridpfacet import *
from yade import pack, plot,qt,export

#Size of periodic cell
Ls=50.
Ws=8.
Hs=20.

rc=10.  #Radius of cylindrical roller

#### Periodic boundary conditions ###
O.periodic = True
O.cell.setBox(Ls,Ws,Hs)

#### Engines ####
O.engines=[
        ForceResetter(),
        InsertionSortCollider([
                Bo1_GridConnection_Aabb(),
                Bo1_Box_Aabb(),
                Bo1_Sphere_Aabb(),
        ],allowBiggerThanPeriod = True),
        InteractionLoop([
                Ig2_GridNode_GridNode_GridNodeGeom6D(),
                Ig2_Sphere_Sphere_ScGeom(),
                Ig2_Box_Sphere_ScGeom(),
                Ig2_Sphere_GridConnection_ScGridCoGeom(),
                Ig2_GridConnection_GridConnection_GridCoGridCoGeom(),

        ],
        [
                
Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(setCohesionNow=True,setCohesionOnNewContacts=False),
                Ip2_FrictMat_FrictMat_FrictPhys()
        ],
        [
                Law2_ScGeom_FrictPhys_CundallStrack(),         
                Law2_ScGeom6D_CohFrictPhys_CohesionMoment(),    
                Law2_ScGridCoGeom_FrictPhys_CundallStrack(),    
                Law2_GridCoGridCoGeom_FrictPhys_CundallStrack()
        ]
        ),
        GlobalStiffnessTimeStepper(timestepSafetyCoefficient=0.1,label='ts'), 
        NewtonIntegrator(gravity=(0.,0,-10),damping=0.5,label='newton'),
        PyRunner(command='addMovement()',iterPeriod=1),

]
O.dt=0.1*PWaveTimeStep()

#### Create materials ####
O.materials.append( CohFrictMat( 
young=1e9,poisson=0.3,density=1000,frictionAngle=radians(30.),normalCohesion=1e500,shearCohesion=1e500,momentRotationLaw=True,label='cMat'
 ) )
O.materials.append( FrictMat( 
young=1e9,poisson=0.3,density=1000,frictionAngle=radians(30.),label='fMat' ) )
O.materials.append(FrictMat(young=1e9,poisson=0.3,frictionAngle=radians(30.),density=1600,label='spheremat'))

### Cylindrical roller ###
#cylinder((12.,0.,rc+1.5),(12.,Ws,rc+1.5),radius=rc,nodesIds=nodesIds,cylIds=cylIds,color=[1,0,0],fixed=False,intMaterial='cMat',extMaterial='fMat')
nodesIds=[]
cylIds=[]
cylinderConnection([[12.,0,rc+1.5],[12.,0.33*Ws,rc+1.5],[12.,0.33*2*Ws,rc+1.5],[12.,Ws,rc+1.5]],radius=rc,fixed
 = 
True,nodesIds=nodesIds,cylIds=cylIds,color=[1,0,0],intMaterial='cMat',extMaterial='fMat')
O.engines=O.engines+[ 
TranslationEngine(translationAxis=[1,0,0],ids=nodesIds+cylIds,label="transEngine")+RotationEngine(rotationAxis=(0,1,0),ids=nodesIds+cylIds,label="rotEngine")
 ]

### Box as substrate ###
O.bodies.append(box(center= (0,0,0.2),extents=(60.,60.,0),fixed=True,color = 
(128.,128.,128.),wire = False,material = 'fMat'))

#### Spheres ####
sp=pack.SpherePack()
Ns=sp.makeCloud(Vector3(25.,0.,1.),Vector3(30.,Ws,6.),0.3,0.2,50,False,0.8)
sphereID=sp.toSimulation(material='spheremat')

def addMovement():
        transEngine.velocity=1.
        rotEngine.angularVelocity=-1./5.

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

Reply via email to