Contact law for a specific interaction

Asked by Adel ALBABA

Hello all,

I am using more than one contact law to handle different types of interactions. Is their a way to know which law is being applied for a specific interaction ? in other words, is their a way in YADE to know which law is being applied by knowing the Ig2 and Ip2 of the interaction ?

Thanks in advance,
Adel

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Adel ALBABA
Solved:
Last query:
Last reply:
Revision history for this message
Chareyre (bruno-chareyre-9) said :
#1

Hello Adel,
> is their a way in YADE to know which law is being applied by knowing the Ig2 and Ip2 of the interaction ?
Yes:
Yade [3]: il=O.engines[2] #the interaction loop in my example case
Yade [4]: il.lawDispatcher.dispFunctor?
...
Docstring:
dispFunctor( (LawDispatcher)arg1, (IGeom)arg2, (IPhys)arg3) -> LawFunctor :
    Return functor that would be dispatched for given argument(s); None
if no dispatch; ambiguous dispatch throws.

#let's see
Yade [5]: il.lawDispatcher.dispFunctor(ScGeom(),FrictPhys())
 -> [5]: <Law2_ScGeom_FrictPhys_CundallStrack instance at 0x33d5a10>

Bruno

Revision history for this message
Adel ALBABA (adel-1) said :
#2

Thanks Bruno, that solved my problem