Aleph-w 7.10.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
robust_predicates_example.cc File Reference

Demonstrates robust geometry predicates using exact arithmetic. More...

#include <iostream>
#include <cassert>
#include <geom_algorithms.H>
#include <point.H>
Include dependency graph for robust_predicates_example.cc:

Go to the source code of this file.

Functions

static void print_banner (const char *title)
 
static const char * orientation_str (Orientation o)
 
static const char * in_circle_str (InCircleResult r)
 
void scenario_orientation ()
 
void scenario_intersection_detection ()
 
void scenario_exact_intersection ()
 
void scenario_road_network ()
 
void scenario_in_circle_in_delaunay_context ()
 
int main ()
 

Detailed Description

Demonstrates robust geometry predicates using exact arithmetic.

This example showcases the exact orientation, intersection detection, and intersection point computation provided by point.H, all using Geom_Number (mpq_class) for exact rational arithmetic.

Scenarios

  1. Orientation classification of point triples
  2. Segment intersection detection (various configurations)
  3. Exact rational intersection point computation
  4. Road network crossing analysis

Definition in file robust_predicates_example.cc.

Function Documentation

◆ in_circle_str()

static const char * in_circle_str ( InCircleResult  r)
static

Definition at line 75 of file robust_predicates_example.cc.

References r.

Referenced by scenario_in_circle_in_delaunay_context().

◆ main()

◆ orientation_str()

static const char * orientation_str ( Orientation  o)
static

Definition at line 64 of file robust_predicates_example.cc.

Referenced by scenario_orientation().

◆ print_banner()

static void print_banner ( const char *  title)
static

Definition at line 58 of file robust_predicates_example.cc.

Referenced by main().

◆ scenario_exact_intersection()

void scenario_exact_intersection ( )

◆ scenario_in_circle_in_delaunay_context()

void scenario_in_circle_in_delaunay_context ( )

Definition at line 271 of file robust_predicates_example.cc.

References Aleph::DynList< T >::append(), Aleph::in_circle(), and in_circle_str().

Referenced by main().

◆ scenario_intersection_detection()

void scenario_intersection_detection ( )

Definition at line 118 of file robust_predicates_example.cc.

References Aleph::segments_intersect().

Referenced by main().

◆ scenario_orientation()

void scenario_orientation ( )

Definition at line 90 of file robust_predicates_example.cc.

References Aleph::orientation(), and orientation_str().

Referenced by main().

◆ scenario_road_network()