From 8896b77d6b2eea966f7166225ed08eb8f2df54b2 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Wed, 19 Jun 2024 07:01:09 +0100 Subject: [PATCH] drop 'continuous_' --- .../doc/Frechet_distance/Frechet_distance.txt | 8 ++++---- .../doc/Frechet_distance/PackageDescription.txt | 4 ++-- .../examples/Frechet_distance/Frechet_distance_2.cpp | 2 +- .../examples/Frechet_distance/Frechet_distance_3.cpp | 2 +- .../examples/Frechet_distance/Frechet_distance_d.cpp | 2 +- Frechet_distance/include/CGAL/Frechet_distance.h | 4 ++-- .../include/CGAL/Frechet_distance_near_neighbors_ds.h | 2 +- .../test/Frechet_distance/Frechet_distance_test.cpp | 4 ++-- 8 files changed, 14 insertions(+), 14 deletions(-) diff --git a/Frechet_distance/doc/Frechet_distance/Frechet_distance.txt b/Frechet_distance/doc/Frechet_distance/Frechet_distance.txt index 801b4f8fbec..b2905aa153c 100644 --- a/Frechet_distance/doc/Frechet_distance/Frechet_distance.txt +++ b/Frechet_distance/doc/Frechet_distance/Frechet_distance.txt @@ -30,9 +30,9 @@ The Fréchet distance is a metric and hence two polylines that are equal (disreg The package provides one function to approximate the Fréchet distance and one function to decide whether the Fréchet distance is at most a given value. -The function `continuous_Frechet_distance()` computes an approximation of the Fréchet distance between two polylines, +The function `Frechet_distance()` computes an approximation of the Fréchet distance between two polylines, up to a given approximation error. It returns an interval. -The function `continuous_Frechet_distance_less_than()` decides if the Fréchet distance +The function `Frechet_distance_less_than()` decides if the Fréchet distance between two polylines is smaller than a given bound. Both functions have as template parameter a traits class defining the dimension and the point type. @@ -50,13 +50,13 @@ the algorithm switches to the usage of square root extensions. \subsection subsecFrechetDistanceFirstExample Decision for 2D Polylines -The following example shows how we can use `continuous_Frechet_distance_less_than()` to decide whether the Fréchet distance between two polylines in the Euclidean plane is at most a given value. +The following example shows how we can use `Frechet_distance_less_than()` to decide whether the Fréchet distance between two polylines in the Euclidean plane is at most a given value. \cgalExample{Frechet_distance/Frechet_distance_2.cpp} \subsection subsecFrechetDistanceSecondExample Distance Computation for 3D Polylines -The following example shows how we can compute the Fréchet distance up to a given precision on two polylines in 3-dimensional Euclidean space using `continuous_Frechet_distance()`. +The following example shows how we can compute the Fréchet distance up to a given precision on two polylines in 3-dimensional Euclidean space using `Frechet_distance()`. \cgalExample{Frechet_distance/Frechet_distance_3.cpp} diff --git a/Frechet_distance/doc/Frechet_distance/PackageDescription.txt b/Frechet_distance/doc/Frechet_distance/PackageDescription.txt index 038ce953cc0..507322ea088 100644 --- a/Frechet_distance/doc/Frechet_distance/PackageDescription.txt +++ b/Frechet_distance/doc/Frechet_distance/PackageDescription.txt @@ -39,6 +39,6 @@ This package .... - `CGAL::Frechet_distance_traits_d` \cgalCRPSection{Functions} -- `CGAL::continuous_Frechet_distance()` -- `CGAL::continuous_Frechet_distance_less_than()` +- `CGAL::Frechet_distance()` +- `CGAL::Frechet_distance_less_than()` */ diff --git a/Frechet_distance/examples/Frechet_distance/Frechet_distance_2.cpp b/Frechet_distance/examples/Frechet_distance/Frechet_distance_2.cpp index d7f1642e163..b216e914848 100644 --- a/Frechet_distance/examples/Frechet_distance/Frechet_distance_2.cpp +++ b/Frechet_distance/examples/Frechet_distance/Frechet_distance_2.cpp @@ -11,7 +11,7 @@ using Point = Traits::Point; int main(int argc, char* argv[]) { std::vector A, B; - bool res = CGAL::continuous_Frechet_distance_less_than(A, B, 0.001); + bool res = CGAL::Frechet_distance_less_than(A, B, 0.001); std::cout << std::boolalpha << res << std::endl; return 0; } diff --git a/Frechet_distance/examples/Frechet_distance/Frechet_distance_3.cpp b/Frechet_distance/examples/Frechet_distance/Frechet_distance_3.cpp index c0f930527ca..173ecdbea0f 100644 --- a/Frechet_distance/examples/Frechet_distance/Frechet_distance_3.cpp +++ b/Frechet_distance/examples/Frechet_distance/Frechet_distance_3.cpp @@ -11,7 +11,7 @@ using Point = Traits::Point; int main(int argc, char* argv[]) { std::vector A, B; - std::pair res = CGAL::continuous_Frechet_distance(A, B, 0.000001); + std::pair res = CGAL::Frechet_distance(A, B, 0.000001); std::cout << "The Frechet distance between the polylines is between " << res.first << " and " << res.second << std::endl; return 0; } diff --git a/Frechet_distance/examples/Frechet_distance/Frechet_distance_d.cpp b/Frechet_distance/examples/Frechet_distance/Frechet_distance_d.cpp index 2760424db9f..d4355860c44 100644 --- a/Frechet_distance/examples/Frechet_distance/Frechet_distance_d.cpp +++ b/Frechet_distance/examples/Frechet_distance/Frechet_distance_d.cpp @@ -12,6 +12,6 @@ using Point = Traits::Point; int main(int argc, char* argv[]) { std::vector A, B; - bool res = CGAL::continuous_Frechet_distance_less_than(A, B, 0.001); + bool res = CGAL::Frechet_distance_less_than(A, B, 0.001); return 0; } diff --git a/Frechet_distance/include/CGAL/Frechet_distance.h b/Frechet_distance/include/CGAL/Frechet_distance.h index 1473b94ad4e..edf0a491af8 100644 --- a/Frechet_distance/include/CGAL/Frechet_distance.h +++ b/Frechet_distance/include/CGAL/Frechet_distance.h @@ -39,7 +39,7 @@ namespace CGAL * with `Traits::Point` as value type. */ template < class Traits, class PointRange> -bool continuous_Frechet_distance_less_than(const PointRange& polyline1, +bool Frechet_distance_less_than(const PointRange& polyline1, const PointRange& polyline2, const double distance, const Traits& traits = Traits()) @@ -67,7 +67,7 @@ bool continuous_Frechet_distance_less_than(const PointRange& polyline1, * with `Traits::Point` as value type. */ template -std::pair continuous_Frechet_distance(const PointRange& polyline1, +std::pair Frechet_distance(const PointRange& polyline1, const PointRange& polyline2, const double precision, const Traits& traits = Traits()) diff --git a/Frechet_distance/include/CGAL/Frechet_distance_near_neighbors_ds.h b/Frechet_distance/include/CGAL/Frechet_distance_near_neighbors_ds.h index 0a7222f2a6a..58f740b2cb0 100644 --- a/Frechet_distance/include/CGAL/Frechet_distance_near_neighbors_ds.h +++ b/Frechet_distance/include/CGAL/Frechet_distance_near_neighbors_ds.h @@ -75,7 +75,7 @@ auto FrechetDistanceNearNeighborsDS::get_close_curves( auto result = kd_tree.search(curve, distance); auto predicate = [&](PolylineID id) { - return ! continuous_Frechet_distance_less_than( + return ! Frechet_distance_less_than( curve, curves[id], distance); }; auto new_end = std::remove_if(result.begin(), result.end(), predicate); diff --git a/Frechet_distance/test/Frechet_distance/Frechet_distance_test.cpp b/Frechet_distance/test/Frechet_distance/Frechet_distance_test.cpp index e7d3d49c978..c4fae0ba900 100644 --- a/Frechet_distance/test/Frechet_distance/Frechet_distance_test.cpp +++ b/Frechet_distance/test/Frechet_distance/Frechet_distance_test.cpp @@ -168,14 +168,14 @@ void testFrechetDistance() for (auto const& query : queries) { /* std::cout - << CGAL::continuous_Frechet_distance( curves[query.id1], curves[query.id2], 0.001) << std::endl; */ timer.start(); auto decision = - CGAL::continuous_Frechet_distance_less_than( + CGAL::Frechet_distance_less_than( curves[query.id1], curves[query.id2], query.distance); timer.stop(); if (decision != query.decision) {