Skip to content

GeogramPlus

Bruno edited this page Jun 15, 2024 · 1 revision

The optional geogramplus expansion package

Intersection points are represented using exact arithmetics, either with expansion_nt (Shewchuk's arithmetic expansions), or with the optional faster exact_nt number types implemented in the geogramplus expansion package (marketed by the Tessael company).

The geogramplus expansion package provides the exact_nt number type (arbitratry-precision floating point numbers), as well as geometric predicates based on it. It is both much faster (10x to 20x) and supports a much larger range of numbers (expansion_nt may underflow or overflow when multiplying very small or very large numbers, which may happen when computing surface intersections with very degenerate configurations). Geogramplus/exact_nt offers stronger guarantees, with a much wider exponent range:

number type speed exponent range
geogram expansion_nt 1x [-1022,1023]
geogram+ exact_nt 10x-20x [-2M, 2M]

Geogramplus provides:

  • exact_nt: exact floating point number type based on GMP. Supports +,-,*,sign, conversion from double, conversion to interval_nt.
  • vector types based on exact_nt: vec2Ex (2d), vec2Ex (3d), vec2HEx (2d homogeneous), vec3HEx (3d homogeneous) (through instanciations of vec2g<>, vec3g<>, vec2Hg<>, vec3Hg<>)
  • predicates: orient_2d, orient_3d, orient_2d_projected, incircle_2d_SOS with airthmetic filters
Clone this wiki locally