Subject: [Boost-bugs] [Boost C++ Libraries] #13603: sinc_pi can be more precise with Horner's method
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2018-06-14 08:03:15
#13603: sinc_pi can be more precise with Horner's method
------------------------------+--------------------------
Reporter: minorlogic@⦠| Owner: John Maddock
Type: Bugs | Status: new
Milestone: To Be Determined | Component: math
Version: Boost 1.63.0 | Severity: Optimization
Keywords: sinc_pi Horner |
------------------------------+--------------------------
double sinc1 = 1.0 + x2 * (-1.0 + x2 / 20.0) / 6.0;
double sinc2 = 1.0 - x2 /6.0 + x2*x2 / 120.0;
in some cases sinc1 provides better precision compared to sinc2
x generated with
double x = sqrt(sqrt(std::numeric_limits<double>::epsilon()));
for (int i = 0; x > sqrt(std::numeric_limits<double>::epsilon()); i++)
{
x *= 0.99876765378657564;
}
-- Ticket URL: <https://svn.boost.org/trac10/ticket/13603> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2018-06-14 08:07:34 UTC