yade-users team mailing list archive
-
yade-users team
-
Mailing list archive
-
Message #28452
[Question #703469]: Segmentation fault while VTKrecorder used
New question #703469 on Yade:
https://answers.launchpad.net/yade/+question/703469
Hi!
When I am starting the script with yade -12 ... and I am using the VTKrecorder I always get the Segmentation fault and I dont know why. Also I need to run it on multiple threads because with it the simulation is much faster.
Here is the code:
from yade import pack, plot, qt,ymport
idSteel=O.materials.append(FrictMat(density=7850, young=210e6,poisson=0.2,frictionAngle=0.52,label="steel"))
idGrain = O.materials.append(FrictMat(density=1180, young=80e6,poisson=0.31,frictionAngle=0.1375,label="grain"))
csiga = O.bodies.append(ymport.stl("csiga.stl",color=(239,65,45), material=idSteel, wire = False, fixed=True,scale=0.001))
csigahaz = O.bodies.append(ymport.stl("haz_delta6_m08.stl",color=(239,174,45), material=idSteel, wire = True, fixed=True,scale=0.001))
sugar = 0.0029
a_tav = 0.0031
b_tav = 0.0027
felho = pack.SpherePack()
szemcse = pack.SpherePack([((0.0062,0,0),sugar),((a_tav,b_tav/2,0),sugar),((a_tav,-b_tav/2,0),sugar),((0,b_tav/2,0),sugar),((0,-b_tav/2,0),sugar)])
felho.makeClumpCloud((-0.08,0.15,-0.5),(0.08,0.20,-0.25), [szemcse])
felho.toSimulation(material = idGrain)
#engine
O.engines = [
ForceResetter(),
InsertionSortCollider([Bo1_Sphere_Aabb(), Bo1_Facet_Aabb()]),
InteractionLoop(
# handle sphere+sphere and facet+sphere collisions
[Ig2_Sphere_Sphere_ScGeom(), Ig2_Facet_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom_FrictPhys_CundallStrack()]
),
NewtonIntegrator(gravity=(0, -9.81, 0), damping = 0.4, dampGravity=False,label='newton'),
RotationEngine(ids=csiga, rotateAroundZero = True,zeroPoint=(0,0,0), rotationAxis = [0,0,1], angularVelocity = 0, dead=True),
DomainLimiter(dead = False, hi=(0.1,0.3,0.5), lo = (-0.1,-0.2,-0.5), mask = 1, iterPeriod=100),
PyRunner(iterPeriod=20000,command='addBodies()',nDo=7,label='addb'),
VTKRecorder(fileName='n240_d6_m08', recorders=['all'], iterPeriod=1000),
]
O.dt = 0.6 * PWaveTimeStep()
def checkUnbalanced():
if O.iter > 10000:
if unbalancedForce() < 0.05:
O.pause()
def csigRot():
if O.engines[4].dead == True:
O.engines[4].dead = False
O.engines[4].angularVelocity = 24.0855
def addBodies():
felho = pack.SpherePack()
szemcse = pack.SpherePack([((0.0062,0,0),sugar),((a_tav,b_tav/2,0),sugar),((a_tav,-b_tav/2,0),sugar),((0,b_tav/2,0),sugar),((0,-b_tav/2,0),sugar)])
felho.makeClumpCloud((-0.08,0.15,-0.5),(0.08,0.2,-0.25), [szemcse])
felho.toSimulation(material = idGrain)
O.dt = 0.6 * PWaveTimeStep()
print(O.dt)
O.saveTmp()
--
You received this question notification because your team yade-users is
an answer contact for Yade.