New question #694548 on Yade:
https://answers.launchpad.net/yade/+question/694548

I am using Yade 2020.01a. The MWE below simulates the collision of two PFacets. 
After PFacet 1 (on the left) collides with PFacet 2 (on the right)  unrealistic 
physical behavior is observed. I would expect PFacet 2 to rotate clockwise 
about the y-axis. However, it appears that PFacet 2 has a tendency to rotate 
counter-clockwise about the z-axis with some angular momentum about the y-axis 
(but in the counter-clockwise direction). I have tried smaller and smaller time 
steps, but observe the same behavior.

I am not sure if this is a bug, or if I have a misconception about PFacets. At 
any rate, I would appreciate any time that could be allocated in addressing 
this issue.


MWE: 

import sys
p = os.getcwd() # current working directory
sys.path.append(p)  
from yade import pack, geom, PyRunner, qt
from yade.gridpfacet import *

############################################# engines 
###########################################
O.engines=[

        ForceResetter(),
        InsertionSortCollider(

                [
                Bo1_PFacet_Aabb(),
                Bo1_GridConnection_Aabb()
                ]),

        InteractionLoop(

                [
                Ig2_GridConnection_PFacet_ScGeom(),
                Ig2_Sphere_PFacet_ScGridCoGeom(),
                Ig2_GridNode_GridNode_GridNodeGeom6D(),
                Ig2_Sphere_GridConnection_ScGridCoGeom(),
                Ig2_GridConnection_GridConnection_GridCoGridCoGeom(),
                Ig2_PFacet_PFacet_ScGeom()
                ],


                [
                Ip2_FrictMat_FrictMat_FrictPhys(),
                
Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(setCohesionNow=True,setCohesionOnNewContacts=False),
                ],
                

                [
                Law2_ScGeom_FrictPhys_CundallStrack(),
                Law2_ScGeom6D_CohFrictPhys_CohesionMoment(useIncrementalForm = 
True),
                Law2_ScGridCoGeom_FrictPhys_CundallStrack(), 
                Law2_ScGridCoGeom_CohFrictPhys_CundallStrack(), 
                Law2_GridCoGridCoGeom_FrictPhys_CundallStrack(),
                ]),
                        
                NewtonIntegrator(gravity=(0,0,0), damping=0.0)
                ]

O.dt = 1.0e-9 # times step

############################################# materials 
###########################################
cmatName = 'cmat'
fmatName = 'fmat'

O.materials.append( CohFrictMat( young=1.0e14,poisson=0.3,density=1000.0, 
normalCohesion=1.0e12 ,shearCohesion=1.0e12, fragile = False, 
momentRotationLaw=True, isCohesive = True, etaRoll=1000.0, etaTwist = 1000.0, 
frictionAngle=0.0, alphaKr = 100.0, alphaKtw = 100.0,  label=cmatName ) ) 

O.materials.append( FrictMat( 
young=1.0e14,poisson=0.3,density=1000.0,frictionAngle=0.0,label=fmatName ) )

############################################## pfacets 
#############################################

# pfacet 1 
gnh1_0 = O.bodies.append( gridNode([0.0, 0.0, 0.3],radius = 
0.1,fixed=False,material=cmatName,color=[0, 0, 0]) )
gnh1_2 = O.bodies.append( gridNode([-1.0, 1.0, 0.3],radius = 
0.1,fixed=False,material=cmatName,color=[0, 0, 0]) )
gnh1_3 = O.bodies.append( gridNode([-1.0, -1.0, 0.3],radius = 
0.1,fixed=False,material=cmatName,color=[0, 0, 0]) )

O.bodies.append( gridConnection(gnh1_2,gnh1_3,radius = 0.1,color=[0, 0, 
0],material=fmatName, wire=False) )
O.bodies.append( gridConnection(gnh1_0,gnh1_2,radius = 0.1,color=[0, 0, 
0],material=fmatName, wire=False) )
O.bodies.append( gridConnection(gnh1_0,gnh1_3,radius = 0.1,color=[0, 0, 
0],material=fmatName, wire=False) )

O.bodies.append( pfacet(gnh1_0, gnh1_2, gnh1_3,material=fmatName,color=[1, 0, 
0]) )

# assign initial velocity to pfacet 1
vi = Vector3(10.0, 0.0, 0.0)
for b in O.bodies:
        b.state.vel = vi


# pfacet 2
gnh2_0 = O.bodies.append( gridNode([0.21, 0.0, 0.0],radius = 
0.1,fixed=False,material=cmatName,color=[0, 0, 0]) )
gnh2_1 = O.bodies.append( gridNode([0.21, 1.0, 1.0],radius = 
0.1,fixed=False,material=cmatName,color=[0, 0, 0]) )
gnh2_2 = O.bodies.append( gridNode([0.21, -1.0, 1.0],radius = 
0.1,fixed=False,material=cmatName,color=[0, 0, 0]) )

O.bodies.append( gridConnection(gnh2_0,gnh2_1,radius = 0.1,color=[0, 0, 
0],material=fmatName, wire=False) )
O.bodies.append( gridConnection(gnh2_0,gnh2_2,radius = 0.1,color=[0, 0, 
0],material=fmatName, wire=False) )
O.bodies.append( gridConnection(gnh2_1,gnh2_2,radius = 0.1,color=[0, 0, 
0],material=fmatName, wire=False) )

O.bodies.append( pfacet(gnh2_0, gnh2_1, gnh2_2,material=fmatName,color=[1, 0, 
0]) )


#################################### appearance and view 
##########################################
qtr = qt.Renderer()
qt.Controller()
v = qt.View()

qtr.bgColor = [1,1,1]

-- 
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