← Back to team overview

yade-dev team mailing list archive

[Bug 813925] Re: InteractionContainer::erase: attempt to delete non-existent interaction

 

Interesting Bruno's opinion.
Needs to be checked.

http://www.mail-archive.com/yade-dev@xxxxxxxxxxxxxxxxxxx/msg07298.html

===================================================

Re: [Yade-dev] [Bug 813925] Re: InteractionContainer::erase:	attempt to delete	non-existent interaction
Bruno Chareyre
Fri, 14 Oct 2011 14:24:37 -0700

Anton,

I maybe understood the problem.
If we have, let's say, interaction (b1,b2). Then you delete both b1,b2
and create new bodies in the same iteration.
The new bodies will take ids left by b1 and b2, hence we have new bodies
with the same id as old bodies, and of course they don't contain the
interactions that were in b1/b2.
When traversing linIntrs, the old interactions are found, but they are
no longer contained in the new bodies. It triggers the "attempt to
delete    non-existent interaction". The fix is really simple: remove
the interaction from linIntrs even if they are not found in b1.
Currently we skip them and print warning. This is not good since they
will sit in memory forever.

After fixing this, we can revert the change in "if((!b1) or (!b2))
return false;" 

I can't try that now unfortunately. Will do ASAP, if I have a decent PC
and you send a script.

Also, I realized that bodies removal/addition breaks the "old" collider
stride mechanism, because bodies can be moving around (deleted at
position P1, added at position P2) with null velocity. Since the
collider is tracking velocities, it will not detect the movement. The
new collider should be ok, since it compares initial (stored in bbox)
and current position.

Bruno
===================================================

-- 
You received this bug notification because you are a member of Yade
developers, which is the registrant for Yade.
https://bugs.launchpad.net/bugs/813925

Title:
  InteractionContainer::erase: attempt to delete non-existent
  interaction

Status in Yet Another Dynamic Engine:
  New

Bug description:
  The problem occurs on simulations with intensive adding/deleting particles and large number of interactions.
  r2893 [1] did not solve the problem. The LOG_ERROR is still appears.

  [1] http://bazaar.launchpad.net/~yade-dev/yade/trunk/revision/2893

To manage notifications about this bug go to:
https://bugs.launchpad.net/yade/+bug/813925/+subscriptions


Follow ups

References