Johnson's distance subalgorithm
Posted: Mon Jan 09, 2017 2:33 am
I'm following Johnson's distance subalgorithm of GJK collision detection as described in Gino Van Den Bergen's book--
I'm noticing that the "nearest point" routine occasionally (~1 in 20 occurrences) fails to select a sensible position, and so far I have only noticed this when the nearest simplex is a subset of the original. The selected point seems to be much smaller than the real geometric distance (i.e. nearly zero). Selecting the vertexes having del_j^X parameter > 0 seems to give the correct sub-simplex, htough. Re-running the "nearest point" routine on the pruned sub-simplex seems to return the correct answer as well.
It's difficult for me to reason about what might be the problem, as the linear algebra-based formulation is pretty abstract and removed from the geometry. Can anyone offer insight? What should I check?
thanks!
I'm noticing that the "nearest point" routine occasionally (~1 in 20 occurrences) fails to select a sensible position, and so far I have only noticed this when the nearest simplex is a subset of the original. The selected point seems to be much smaller than the real geometric distance (i.e. nearly zero). Selecting the vertexes having del_j^X parameter > 0 seems to give the correct sub-simplex, htough. Re-running the "nearest point" routine on the pruned sub-simplex seems to return the correct answer as well.
It's difficult for me to reason about what might be the problem, as the linear algebra-based formulation is pretty abstract and removed from the geometry. Can anyone offer insight? What should I check?
thanks!