Opened 14 years ago

Last modified 12 years ago

#2769 new Bugs

x86_64 + g++: wrong results for sin()

Reported by: anonymous Owned by: Boris Gubenko
Milestone: Component: interval
Version: Boost 1.34.1 Severity: Problem
Keywords: x86_64 interval transcendental Cc:

Description

When using boost's interval library under x86_64-Linux with g++ we encountered strange results for sin(): For example for an interval [-2.1,-2.1] sin() returns [nan,nan].

Attachments (1)

interval_test.cpp (703 bytes ) - added by anonymous 14 years ago.
c++-File depicting the problem

Download all attachments as: .zip

Change History (4)

by anonymous, 14 years ago

Attachment: interval_test.cpp added

c++-File depicting the problem

comment:1 by smr@…, 12 years ago

Seems to still be a problem in Boost 1.42: see the report from Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=584325

comment:2 by Jeremiah Willcock, 12 years ago

The underlying C cos function has problems as well, even outside Boost.Interval. This bug appears to be a manifestation of something like http://sourceware.org/bugzilla/show_bug.cgi?id=3976 (which also applies to many other functions). According to that discussion, though, the standard library is not required to respect round-down or round-up for transcendental functions at all.

in reply to:  2 comment:3 by Dean Michael Berris, 12 years ago

Replying to jewillco:

According to that discussion, though, the standard library is not required to respect round-down or round-up for transcendental functions at all.

Looks like this should be marked as wontfix?

Note: See TracTickets for help on using tickets.