diff options
author | Arnur Nigmetov <a.nigmetov@gmail.com> | 2017-03-05 23:28:44 +0100 |
---|---|---|
committer | Arnur Nigmetov <a.nigmetov@gmail.com> | 2017-03-05 23:28:44 +0100 |
commit | 404048e9cca7fa77d2004875ffdae1eab39d49f4 (patch) | |
tree | d19df23dfc924388fbe6c8fce17e04a4bf801b90 | |
parent | 27480d978d17b06bb1a68dbffcc9dd1208ea8254 (diff) |
Bug in exact version of bottleneck fixed"
Allow for machine arithmetic errors when searching for candidates for distance
(increase the width of the stripes slightly).
-rw-r--r-- | geom_bottleneck/bottleneck/src/bottleneck.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/geom_bottleneck/bottleneck/src/bottleneck.cpp b/geom_bottleneck/bottleneck/src/bottleneck.cpp index cd1a470..8365878 100644 --- a/geom_bottleneck/bottleneck/src/bottleneck.cpp +++ b/geom_bottleneck/bottleneck/src/bottleneck.cpp @@ -158,7 +158,7 @@ double bottleneckDistExact(DiagramPointSet& A, DiagramPointSet& B, const int dec { constexpr double epsilon = 0.001; auto interval = bottleneckDistApproxInterval(A, B, epsilon); - const double delta = 0.5 * (interval.second - interval.first); + const double delta = 0.50001 * (interval.second - interval.first); const double approxDist = 0.5 * ( interval.first + interval.second); const double minDist = interval.first; const double maxDist = interval.second; |