Opened 10 years ago

Closed 10 years ago

#7416 closed Bugs (fixed)

::boost::math::asinh ignores supplied policy for huge negative arguments

Reported by: Oleksii <oleksii.taran@…> Owned by: John Maddock
Milestone: To Be Determined Component: math
Version: Boost Development Trunk Severity: Problem
Keywords: math asinh ignore policy Cc:

Description

Sample code:

#include <boost/math/special_functions/asinh.hpp>

int main()
{
        using namespace ::boost::math::policies;

        // should not throw
        // but throws "numeric overflow" error
        ::boost::math::asinh(-INFINITY, make_policy(overflow_error<ignore_error>()));

        return 0;
}

Patch with possible fix attached

Attachments (2)

asinh_negative_infinity_showcase.cpp (261 bytes ) - added by Oleksii <oleksii.taran@…> 10 years ago.
Sample code that shows bug
asinh_ignore_policy_fix.patch (470 bytes ) - added by Oleksii <oleksii.taran@…> 10 years ago.
Patch with possible fix

Download all attachments as: .zip

Change History (3)

by Oleksii <oleksii.taran@…>, 10 years ago

Sample code that shows bug

by Oleksii <oleksii.taran@…>, 10 years ago

Patch with possible fix

comment:1 by John Maddock, 10 years ago

Resolution: fixed
Status: newclosed

(In [80695]) Fix improper overflow error handling in asinh.hpp. Update asinh and acosh test cases. Add fixes to release notes and regenerate docs. Fixes #7416.

Note: See TracTickets for help on using tickets.