← Back to team overview

yade-users team mailing list archive

Re: [Question #687386]: "Law2_ScGeom_MindlinPhys_Mindlin ()" engine problem

 

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

    Status: Answered => Open

Pengfei Tan is still having a problem:
Thank you for your patient reply, Jan.


>Please update the script to be MWE also w.r.t time (making the problematic interaction in the first or a few time steps).

 Sorry for not providing a suitable code in which the error can occur
fast.

Please try the following code:

############################################################

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

radius=4e-2
l=10
th=5e-2
rad=30e-2

#### Material properties ####
###cylinders###
Df=2590 #Density
Vf=0.21 #Poisson ratio
Ef=1e8 #Young's modulus

###powders###
Dp=1020 
Vp=0.393 
Ep=1e8 

###walls###
Dw=8030 
Vw=0.265 
Ew=1e8

O.engines=[
 ForceResetter(),
 InsertionSortCollider([
  Bo1_GridConnection_Aabb(),
  Bo1_PFacet_Aabb(),
  Bo1_Sphere_Aabb(),
 ]),
 InteractionLoop([
  Ig2_GridNode_GridNode_GridNodeGeom6D(),
  Ig2_Sphere_Sphere_ScGeom(),
  #Ig2_Sphere_Sphere_ScGeom6D(),
  Ig2_Sphere_GridConnection_ScGridCoGeom(),
  Ig2_GridConnection_GridConnection_GridCoGridCoGeom(),
  Ig2_Sphere_PFacet_ScGridCoGeom(),
  Ig2_GridConnection_PFacet_ScGeom(), 
 ],
 [
  Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(setCohesionNow=True,setCohesionOnNewContacts=True),
  Ip2_FrictMat_FrictMat_MindlinPhys(gamma=40e-3),
  #Ip2_FrictMat_FrictMat_FrictPhys(),
 ],
 [
  #Law2_ScGeom_FrictPhys_CundallStrack(),
  Law2_ScGeom_MindlinPhys_Mindlin(includeAdhesion=True),
  Law2_ScGeom6D_CohFrictPhys_CohesionMoment(),
  Law2_ScGridCoGeom_FrictPhys_CundallStrack(), 
  Law2_GridCoGridCoGeom_FrictPhys_CundallStrack(),
 ]
 ),
 GlobalStiffnessTimeStepper(timestepSafetyCoefficient=0.01,label='ts'),
 NewtonIntegrator(gravity=(0.,0,-9.8),damping=0.5,label='newton'),
]
O.dt=0.1*PWaveTimeStep()

O.materials.append( CohFrictMat( young=Ef,poisson=Vf,density=Df,frictionAngle=radians(18),normalCohesion=1e20,shearCohesion=1e20,momentRotationLaw=True,label='cMat' ) )
O.materials.append( FrictMat( young=Ef,poisson=Vf,density=Df,frictionAngle=radians(18),label='fMat' ) ) 

O.materials.append( FrictMat(
young=Ep,poisson=Vp,density=Dp,frictionAngle=radians(18),label='sphereMat'
) )

O.materials.append( CohFrictMat( young=Ew,poisson=Vw,density=Dw,frictionAngle=radians(30),normalCohesion=1e20,shearCohesion=1e20,momentRotationLaw=True,label='cMatw' ) )
O.materials.append( FrictMat( young=Ew,poisson=Vw,density=Dw,frictionAngle=radians(30),label='fMatw' ) ) 

nodesIds=[]
cylIds=[]
cylinder((-l/2,0,1*l),(l/2,0,1*l),radius=radius,nodesIds=nodesIds,cylIds=cylIds,color=[1,0,0],fixed=False,intMaterial='cMat',extMaterial='fMat')

s1=O.bodies.append(sphere([0,0,2*rad],radius=rad,fixed=True,material='sphereMat'))
s2=O.bodies.append(sphere([0,0,0.5*l],radius=rad,fixed=False,material='sphereMat'))

#Bottom surface
color=[255./255.,102./255.,0./255.]
n0=O.bodies.append( gridNode([-l,-l,0],th,wire=False,fixed=True,material='cMatw',color=color) )
n1=O.bodies.append( gridNode([l,-l,0],th,wire=False,fixed=True,material='cMatw',color=color) )
n2=O.bodies.append( gridNode([l,l,0],th,wire=False,fixed=True,material='cMatw',color=color) )
n3=O.bodies.append( gridNode([-l,l,0],th,wire=False,fixed=True,material='cMatw',color=color) )
O.bodies.append( gridConnection(n0,n1,th,color=color,material='fMatw') )
O.bodies.append( gridConnection(n1,n2,th,color=color,material='fMatw') )
O.bodies.append( gridConnection(n2,n0,th,color=color,material='fMatw') )
O.bodies.append( gridConnection(n2,n3,th,color=color,material='fMatw') )
O.bodies.append( gridConnection(n3,n0,th,color=color,material='fMatw') )
O.bodies.append( pfacet(n0,n1,n2,wire=False,material='fMatw',color=color) )
O.bodies.append( pfacet(n0,n2,n3,wire=False,material='fMatw',color=color) )

#### For viewing ####
qt.View()
Gl1_Sphere.stripes=True

#### Allows to reload the simulation ####
O.saveTmp()

############################################################

Ps: In the new code, I just reduce Young's modulus and increase
geometrical dimensions so that the time step can be increased.


>A solution is to add another Law2, exactly matching GridCoGridCoGeom and MindlinPhys.

In my case, there are PFacet, cylindrical and spherical particles.
Actually, I only want to use the MindlinPhys (which includes the
adhesion force) for the contact between spherical particles, which is
realized by "Law2_ScGeom_MindlinPhys_Mindlin".

Would it be possible to modify the source code to let Yade choose the
"Law2_ScGeom_MindlinPhys_Mindlin" for the contact between spherical
particles and other Law2s (such as
"Law2_ScGridCoGeom_FrictPhys_CundallStrack" and
"Law2_GridCoGridCoGeom_FrictPhys_CundallStrack" ) for the contact
associated with PFacet and cylindrical particles?

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.