Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Which of the following are predicates?

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Which of the following are predicates?


Chronological Thread 
  • From: Marc Glisse <>
  • To:
  • Subject: Re: [cgal-discuss] Which of the following are predicates?
  • Date: Thu, 26 Sep 2013 03:37:52 +0200 (CEST)

On Thu, 26 Sep 2013, ax487 wrote:

I am currently working with the
Exact_predicates_inexact_constructions_kernel provided by CGAL 4.2. I am
however unsure which of the following functions are actually geometric
predicates and therefore evaluated exactly:

Any kernel functor with a discrete return type (like an enum) should be a predicate, that includes all those you are listing.

- The output of the do_intersect function for a pair of objects each of
which may be either a Ray_2, a Segment_2 or a Line_2.
- The output of the orientation function: I would imagine that I can
rely upon LEFT_TURN/RIGHT_TURN, but I believe that verifying whether
three points are collinear is unlikely to ever work correctly using
anything other than rational arithmetic.
- The output of the bounded_side_2 for convex/simple/not simple
polygons, specifically in the case of the result being ON_BOUNDARY

CGAL does use exact arithmetic (like rationals) if needed to evaluate predicates, and particularly for the ON_BOUNDARY case. It first tries faster methods, but if it can't prove the correct answer using those, it falls back to exact.

--
Marc Glisse



Archive powered by MHonArc 2.6.18.

Top of Page