lmi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [lmi] master 548f9ab 06/23: Document known shortcomings of


From: Greg Chicares
Subject: [lmi-commits] [lmi] master 548f9ab 06/23: Document known shortcomings of a unit-testing helper
Date: Tue, 27 Jul 2021 21:59:51 -0400 (EDT)

branch: master
commit 548f9ab9f465bf625d1b9b41b1f3f18a68fe7d94
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>

    Document known shortcomings of a unit-testing helper
---
 zero_test.cpp | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/zero_test.cpp b/zero_test.cpp
index 73d7bab..d7ca7fc 100644
--- a/zero_test.cpp
+++ b/zero_test.cpp
@@ -67,6 +67,15 @@ double max_err(double zeta, double tol)
 /// Yet an IEEE 754 binary64 entity can have no more than 2^64
 /// distinct values; with an appropriate definition of "bisection",
 /// about 64 steps should suffice.
+///
+/// Known defects:
+///  - std::fabs(DBL_MAX - -DBL_MAX) overflows.
+///  - The denominator can be zero when ζ = 0, because the
+///    implementation allows 'tol' to be zero as a shorthand
+///    for the hardware minimum. (Specifying DBL_TRUE_MIN would
+///    entail a likely speed penalty even on platforms that support
+///    denormals, so this shorthand isn't merely a convenience).
+/// Such defects in a unit-testing TU needn't be fixed.
 
 int max_n_iter_bolzano(double a, double b, double tol, double zeta)
 {



reply via email to

[Prev in Thread] Current Thread [Next in Thread]