Change number type for reference implementation of geometric predicates and constructions

Issue #766 new
Benjamin Dam Kehlet created an issue

The reference implementation current uses the CGAL::Epeck::FT as number type. This requires linking with GMP and MPFR and makes it cumbersome to enable the reference implementation. CGAL's own implementation of arbritrary precision rationals suffers from overflow (the exponential is represented as a double), but boost::multiprecision should be possible to plugin.

Official response

  • Anders Logg (Chalmers)

    Reminder regarding the CGAL reference implementation to others not involved in the multimesh development: The multimesh branch on bitbucket/logg/dolfin introduces a CGAL reference implementation using exact arithmetic. This allows a user (or developer) to run all low-level geometric predicates using both the DOLFIN implementation (using inexact arithmetic) and CGAL (using exact arithmetic). An error is issued when the predicates do not agree. This makes it possible to run complex test cases and have all minor discrepancies reported. This does not reintroduce a CGAL dependency but allows developers to build DOLFIN with the special flag DOLFIN_ENABLE_CGAL_EXACT_ARITHMETIC against a header-only CGAL include directory.

Comments (4)

  1. Anders Logg (Chalmers)

    Reminder regarding the CGAL reference implementation to others not involved in the multimesh development: The multimesh branch on bitbucket/logg/dolfin introduces a CGAL reference implementation using exact arithmetic. This allows a user (or developer) to run all low-level geometric predicates using both the DOLFIN implementation (using inexact arithmetic) and CGAL (using exact arithmetic). An error is issued when the predicates do not agree. This makes it possible to run complex test cases and have all minor discrepancies reported. This does not reintroduce a CGAL dependency but allows developers to build DOLFIN with the special flag DOLFIN_ENABLE_CGAL_EXACT_ARITHMETIC against a header-only CGAL include directory.

  2. Log in to comment