Add extraction code to a case

Asked by Daniel Enrique Morales Molina

Hi all,
I wrote a code (inside the study case) to extract spheres from an arrangement without cohesion (facets opens and close , and bodies.erase... I could paste the code here if it's necessary) ,

Without cohesion, I use the followings engines:
[Ig2_Sphere_Sphere_L3Geom (), Ig2_Facet_Sphere_Dem3DofGeom ()]
[Ip2_FrictMat_FrictMat_FrictPhys ()]
[Law2_Dem3DofGeom_FrictPhys_CundallStrack (), Law2_L3Geom_FrictPhys_ElPerfPl (nobreak = False)]
)

  The code works fine, but when I add cohesive material (O.materials.append(CohFrictMat(young=30e6,poisson=0.2,density=3648,frictionAngle=0,normalCohesion=3e5,shearCohesion=60e6))),

 I use the engines:

[Ig2_Sphere_Sphere_ScGeom6D(),Ig2_Facet_Sphere_Dem3DofGeom()],[Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(setCohesionNow=True),Ip2_FrictMat_FrictMat_FrictPhys()],
[Law2_ScGeom6D_CohFrictPhys_CohesionMoment(),Law2_Dem3DofGeom_FrictPhys_CundallStrack()]
),

the code for saying: Segmentation fault ("Fallo de segmentación") .

1) How could I get a more especific error?
2) Maybe I'm not using the right engines (I'm using the same engines that I use to obtain an spheres arrangement with cohesion inside of a box.. that works fine)

Thanks!

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Anton Gladky
Solved:
Last query:
Last reply:
Revision history for this message
Best Anton Gladky (gladky-anton) said :
#1

Hi,

> 1) How could I get a more especific error?

you should start the same script in debug-mode, for that you need:
a) recompile yade with debug=True
b) or, if you use packaged version, install yade-dbg

then you start the same script:
yade --debug scriptname.py

After that you will get a bunch of information, which helps to
localize the problem

> 2) Maybe I'm not using the right engines (I'm using the same engines that I use to obtain an spheres arrangement with cohesion inside of a box.. that works fine)
It is better to show the whole script.

Anton

Revision history for this message
Bruno Chareyre (bruno-chareyre) said :
#2

Sorry but it is not very clear what you are trying to do (debugging aside,
Anton replied on that point).
Quick remarks: Dem3DofGeom have known bugs, I recommend ScGeom instead
Quick question: what is the "study case"?

Bruno

Revision history for this message
Daniel Enrique Morales Molina (dmorales-ing-uchile) said :
#3

Hi all, and thanks for your answers,
I did what Anton said (debug=True), and I found the problem. It was because I've defined the material (CohFrictMat) before the construction of the facets, so the CohFrictMat was applied to the facets.
Now, every time that a facet appear , It appear with a the dafault material (material=utils.defaultMaterial()), and the engines can handle that.

I will do what Bruno said (change Dem3DofGeom to ScGeom).
The "study case" it's the case that I'm trying to model (block caving method), It's the python code, and the extraction code It's just a class inside.

Again, thanks all for your answers!

Revision history for this message
Daniel Enrique Morales Molina (dmorales-ing-uchile) said :
#4

Thanks Anton Gladky, that solved my question.