Determining breaked interactions in JCFpm

Asked by mohsen

In the name of God

Hi every body

When using Law2_ScGeom_JCFpmPhys_JointedCohesiveFrictionalPM(), i wonder how to determine breaked interactions? I know the 'recordCracks' method, but i need a technique to specify the interaction itself that is an instance of O.interactions.
It might be said that after breakage there is no interaction hence how could one distinguish suspicious interactions just before breakage?

Also please help me to use 'nbTensCracks', a method of Law2_ScGeom_JCFpmPhys_JointedCohesiveFrictionalPM,? how to recall it to know the total number of tensile microcracks?

Regards.

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Jérôme Duriez
Solved:
Last query:
Last reply:
Revision history for this message
Best Jérôme Duriez (jduriez) said :
#1

Hi,

Looking at interactions "i", you may (equivalently) look at i.phys.breakOccurred, or i.phys.isBroken, see JCFpmPhys doc [1]

However, as you understood, interactions broken in tension will most probably disappear right after breakage (though one way to avoid this behavior is to define neverErase=True in Law2_ScGeom_JCFpmPhys_JointedCohesiveFrictionalPM), and it will be impossible to access them (they're gone..)

Depending what you want determine about broken interactions (their locations ? their number ? ..), you may also look at the bodies-related variables JCFpmState.damageIndex, nbBrokenBonds...: b.state.damageIndex where b is a body.

As for the Law2 variable nbShearCracks, nbTensCracks, you classically just have to access the Law2 Python object (let say it's named "object"), and ask for "object.nbTensCracks".

A convenient way of accessing this Law2 Python object is to use labels: see https://yade-dem.org/doc/user.html#labeling-things

E.g. having in your InteractionLoop definition (in O.engines) :

Law2_ScGeom_JCFpmPhys_JointedCohesiveFrictionalPM(..., label='object')

Then object.nbTensCracks

[1] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.JCFpmPhys

Revision history for this message
mohsen (agha-mohsena) said :
#2

Thanks Jérôme Duriez, that solved my question.