Subject: [Boost-bugs] [Boost C++ Libraries] #13343: erf(NaN) and erfc(NaN) do not return NaN
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2017-12-14 16:49:32
#13343: erf(NaN) and erfc(NaN) do not return NaN
-----------------------------------------------+--------------------------
Reporter: Stéphane Laurent <laurent_step@â¦> | Owner: John Maddock
Type: Bugs | Status: new
Milestone: To Be Determined | Component: math
Version: Boost 1.65.0 | Severity: Problem
Keywords: |
-----------------------------------------------+--------------------------
Hello,
It is expected that erf(NaN) and erfc(NaN) are NaN, but they are not:
{{{
#include <iostream>
#include <cmath>
#include "boost/math/special_functions/erf.hpp"
int main(){
std::cout << boost::math::erf(nan("")) << "\n";
std::cout << boost::math::erfc(nan("")) << "\n";
return 0;
}
}}}
Output:
{{{
1
0
}}}
-- Ticket URL: <https://svn.boost.org/trac10/boost/ticket/13343> 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 : 2017-12-14 16:56:33 UTC