Home › Forum › SOFA › Using SOFA › Best way to detect and quantify interpenetration
Tagged: 64_bits, collision, Linux_ubuntu, SOFA_other
- This topic has 2 replies, 2 voices, and was last updated 4 years ago by Scheikl.
-
AuthorPosts
-
19 December 2020 at 23:34 #18072ScheiklBlocked
Dear SOFA Community,
assume we have to collision models (model 1 and model 2) consisting of triangles (model 1) and points (model2).From observation, I assume that if the force between two colliding objects exceeds a certain value (depending on
contactStiffness
in the collision models) the particular collision gets “ignored” resulting in interpenetration of the two surfaces.There are often still some valid collision contacts between model 1 and model 2, but some of the points of model 2 are “behind” the surface of model 2.
The distance
value
ofsofa::core::collision::DetectionOutput
stored insofa::core::collision::ContactListener
yields some negative values up to the point where the collisions are properly “ignored”.What would be the best way to detect and quantify the amount of interpenetration of two collision models, after they no longer registered in
ContactListener
?Cheers,
PaulSOFA version: v20.12_beta
11 January 2021 at 14:05 #18176HugoKeymasterHey @scheikl
As we discussed during our training session, the collision response proposes mainly two approaches:
– the penalty (or penality) approach
– the full constraint resolution using Lagrange multipliersThe contactStiffness defined in any CollisionModel will be used in case of penalty. This stiffness will corresponds to the stiffness of springs, dynamically added during the simulation when a collision occurs.
The ProximityIntersection will use the contact information (collision models, contact alarm and contact distance) to compute the DetectionOutput and this “value” corresponding to the interpenetration.
If I understand correctly you would like to keep the contact info even once the contact is solved ? correct ?
Best
Hugo
11 January 2021 at 14:33 #18177ScheiklBlockedHi @hugo ,
thanks for the follow-up! 🙂Yes and no.
I would like tho get a measure of how much overlap is between two volumetric meshes.
I guess that should happen outside of the collision pipeline.
For example a small ball inside (at the center) of a large ball would not stand in collision with the larger ball.
So I am looking for something like>>> std::cout << getOverlap(collisionModelSmallBall, collisionModelLargeBall) << "\n"; 1.0
Cheers,
Paul -
AuthorPosts
- You must be logged in to reply to this topic.