[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lmi-commits] [lmi] master 623ddbd 5/8: Assert a precondition
From: |
Greg Chicares |
Subject: |
[lmi-commits] [lmi] master 623ddbd 5/8: Assert a precondition |
Date: |
Mon, 28 Jun 2021 10:29:52 -0400 (EDT) |
branch: master
commit 623ddbd0a547814d85b83dd362f67b4a110ecb1e
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>
Assert a precondition
---
zero.hpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/zero.hpp b/zero.hpp
index 46e4880..91578b3 100644
--- a/zero.hpp
+++ b/zero.hpp
@@ -24,6 +24,7 @@
#include "config.hpp"
+#include "assert_lmi.hpp"
#include "null_stream.hpp"
#include "round_to.hpp"
@@ -430,6 +431,7 @@ double brent_zero
,FunctionalType& f
)
{
+ LMI_ASSERT(0.0 <= t);
constexpr double epsilon {std::numeric_limits<double>::epsilon()};
// Returns a zero of the function f in [a,b] to within a tolerance
- [lmi-commits] [lmi] master updated (ef6c706 -> 016bf00), Greg Chicares, 2021/06/28
- [lmi-commits] [lmi] master cb924a4 1/8: Translate from Brent's ALGOL more directly, Greg Chicares, 2021/06/28
- [lmi-commits] [lmi] master dcfcc94 3/8: Rename and document a unit-test function template, Greg Chicares, 2021/06/28
- [lmi-commits] [lmi] master e995bb8 7/8: Document an important qualification for Brent's error term, Greg Chicares, 2021/06/28
- [lmi-commits] [lmi] master ed9d62d 2/8: Explain some commented-out unit tests, Greg Chicares, 2021/06/28
- [lmi-commits] [lmi] master 94d6b7b 4/8: Restructure a unit test, Greg Chicares, 2021/06/28
- [lmi-commits] [lmi] master 5848d68 6/8: Improve an error term, and rewrite a misleading comment, Greg Chicares, 2021/06/28
- [lmi-commits] [lmi] master 623ddbd 5/8: Assert a precondition,
Greg Chicares <=
- [lmi-commits] [lmi] master 016bf00 8/8: Add a function template to facilitate testing, Greg Chicares, 2021/06/28