← Back to team overview

yade-users team mailing list archive

[Question #681356]: How to get the informations of interaction between polyhedras?

 

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

Hi,
During the simulation of the interactions between two polyhedrons or one polyhedron and wall, I want to detect the equivalent CrossSection, penetration Volume and depth, contact point between them. I tried wrapper of PolyhedraGeom() such as contactPoint, equivalentCrossSection, penetrationVolume and something else, but it returned nothing for that.  Please tell me how to get these informations during the simulation. 

Following are the simple example   for two polyhedrons contact:
####################################
from yade import pack,export
from yade import polyhedra_utils
from yade import geom,utils,ymport
from yade import qt
from yade import *

matP = PolyhedraMat()
matP.density = 2500 #kg/m^3 
matP.young = 3e8
matP.poisson = 0.21 # real 0.21
matP.frictionAngle = 0.65

O.materials.append(matP)

matW = PolyhedraMat()
matW.density = 1950 #kg/m^3 
matW.young = 6e7
matW.poisson = 0.33 # real 0.21
matW.frictionAngle = 0.23

O.materials.append(matW)

b1 = polyhedra_utils.polyhedra(matP,size=(0.046,0.046,0.046),seed=4)
b1.state.pos=(0.2,0.2,0.46)
O.bodies.append(b1)

b2=polyhedra_utils.polyhedra(matW,v=((0,0,0.35),(0.4,0,0.35),(0.4,0.4,0.35),(0,0.4,0.35),(0,0,0.4),(0.4,0,0.4),(0.4,0.4,0.4),(0,0.4,0.4)),fixed=True, color=(0.75,0.65,0.65))
O.bodies.append(b2)
O.bodies[1].state.blockedDOFs='xyzXYZ'

O.forces.setPermF(O.bodies[0].id,(0,0,-100))

O.engines =[
	ForceResetter(),
	InsertionSortCollider([Bo1_Polyhedra_Aabb(),Bo1_Wall_Aabb(),Bo1_Facet_Aabb()]),
	InteractionLoop(
		[Ig2_Wall_Polyhedra_PolyhedraGeom(),Ig2_Polyhedra_Polyhedra_PolyhedraGeom(),Ig2_Facet_Polyhedra_PolyhedraGeom(),Ig2_Sphere_Sphere_ScGeom()],
		[Ip2_PolyhedraMat_PolyhedraMat_PolyhedraPhys(),Ip2_FrictMat_PolyhedraMat_FrictPhys(),Ip2_FrictMat_FrictMat_FrictPhys()],
		[Law2_PolyhedraGeom_PolyhedraPhys_Volumetric()],
	),
	NewtonIntegrator(damping=0.7,gravity=(0,0,-9.81),label='newton'),
	#PyRunner(command='IniBalance()',iterPeriod=1,label='step')
]

O.dt = 0.000001

O.pause()

qt.Controller()
V = qt.View()
V.screenSize = (550,450)
V.sceneRadius = 1
V.eyePosition = (0.7,0.5,0.1)
V.upVector = (0,0,1)
V.lookAt = (0.15,0.15,0.1)

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

Thanks a lot
best regard!
Dez


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