Skip to Content.
Sympa Menu

cgal-discuss - [cgal-discuss] Inconsistent point/convex hull distance computation values

Subject: CGAL users discussion list

List archive

[cgal-discuss] Inconsistent point/convex hull distance computation values


Chronological Thread 
  • From: SirM2X <>
  • To:
  • Subject: [cgal-discuss] Inconsistent point/convex hull distance computation values
  • Date: Mon, 21 Nov 2016 21:45:17 -0800 (PST)
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=SoftFail ; spf=None
  • Ironport-phdr: 9a23:JccfSRfLyVqqoD5sjXK4pTmAlGMj4u6mDksu8pMizoh2WeGdxc2yZx7h7PlgxGXEQZ/co6odzbGH6Oa6BSdQu97B6ClEK8McEUddyI0/pE8JPo2sMQXDNvnkbig3ToxpdWRO2DWFC3VTA9v0fFbIo3e/vnY4ExT7MhdpdKyuQtaBx/KejL7jvsSLK0UT3GL8MvtOK0C9ogzV88UXmoB/Mb0Zyx3To3IOdf4F63lvIAeongzZvPf4qJtq/CRXpvcg38FFWKT+Oa8/SOoLX3wdL2kp6Ziy5lH4RgyV6y5HCj0b

Given two groups of points A and B, I'd like to compute the distance of all
the points in B to the convex hull of A. I've done this before, and I know
that I can leverage AABB trees for this. I thought I knew everything that
was involved in this computation, but I have a feeling that I don't.
Below is a short code of what I'm trying to do



From what I "thought" I knew, I computed the distance of the query point
with the closest point of the AABB tree using /squared_distance/ function
(stored in /distToPoint/ in the above snippet). But then, I felt the results
were off a bit, so I tried computing the query point's distance to the
closest face. Again I used /squared_distance/ but this time on the face's
plane (basically computing point/plane distance, stored in /distToFace/
above.)

If my understanding was correct, the two values had to be equal, but it
seems that this is not the case and I am super confused as to why :(

Also, I noticed that if I change my kernel from /Simple_cartesian<float>/ to
(say) /Simple_cartesian<double>/, I'd get nan values instead of distances,
and again, I have no idea why this is happening.

Any helps is greatly appreciated :)



--
View this message in context:
http://cgal-discuss.949826.n4.nabble.com/Inconsistent-point-convex-hull-distance-computation-values-tp4662388.html
Sent from the cgal-discuss mailing list archive at Nabble.com.



Archive powered by MHonArc 2.6.18.

Top of Page