← Back to team overview

yade-users team mailing list archive

Re: [Question #257929]: Different instances of same interaction (interaction properties)

 

Question #257929 on Yade changed:
https://answers.launchpad.net/yade/+question/257929

    Status: Open => Answered

Jérôme Duriez proposed the following answer:
Then using the classical Ip functors, it is not possible. Because with
normal yade use, what you assign is normalCohesion and not
normalAdhesion.

I think the only way would be to use python loops.
for i in O.interactions:
 if isinstance(i.id1.shape,Sphere) and isinstance(i.id2.shape,Sphere) 
     i.phys.normalAdhesion = 1e3
  else if
.... (this code will not work as it is, but I hope you get the idea)

So that these python operations override what Ip2 did. The good thing is
that Ip2 does its job only once : at interaction creation. You will
surely have to think when and how often you have to do these operations.

-- 
You received this question notification because you are a member of
yade-users, which is an answer contact for Yade.