bugGNU Scientific Library - Bugs: bug #29773, ...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #29773: gsl_complex_pow_real(gsl_complex_rect(0,0),0) returns (0,0)

Submitted by:  Rhys Ulerich <rhysu>
Submitted on:  Tue 04 May 2010 03:31:33 PM UTC  
 
Category: Accuracy problemSeverity: 3 - Normal
Operating System: Ubuntu 8.04+Status: Fixed
Assigned to: -Deleted Account- <bjg>Open/Closed: Closed
Release: 1.14

Fri 07 May 2010 12:04:34 PM UTC, comment #2:

I extended the automatically generated test cases to include a number of pow_real tests.

-Deleted Account- <bjg>In charge of this item.
Thu 06 May 2010 02:39:21 PM UTC, comment #1:

Patches applied in
commit 804b03d5d1ce2127a88f8d4dc5136d8eed9d2097
and
commit 24aa81aa88c909f1a45da1d0ef725f74f569bac0

Rhys Ulerich <rhysu>
Project Administrator
Tue 04 May 2010 03:31:33 PM UTC, original submission:

gsl_complex_pow_real incorrectly returns that (0+0i)^0 = (0+0i). Based on the consistency with gsl_sf_pow_int and gsl_complex_pow, it should return (1+0i) for these inputs.

Simple standalone test case attached. Problem is reproducible from at least 1.12 onward and with both the GNU and Intel compilers.

Original discussion at http://www.cygwin.com/ml/gsl-discuss/2010-q2/msg00004.html

Rhys Ulerich <rhysu>
Project Administrator

 

Attached Files
file #20460:  0001-capture-complex_pow_real-bug-29773.patch added by rhysu (2KiB - text/x-patch - 0001 captures the problem in a test case. 0002 fixes it.)
file #20461:  0002-Fix-29773-gsl_complex_pow_real-has-0-0i-0-1.patch added by rhysu (882B - text/x-patch - 0001 captures the problem in a test case. 0002 fixes it.)
file #20427:  testcase.c added by rhysu (256B - text/x-csrc - Standalone test case)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by rhysu (Submitted the item)
  • -unavailable- added by rhysu
  •  

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 12 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Thu 06 May 2010 02:45:33 PM UTCrhysuOpen/ClosedOpen=>Closed
    Thu 06 May 2010 02:45:21 PM UTCrhysuStatusIn Progress=>Fixed
    Thu 06 May 2010 02:43:13 PM UTCbjgStatusFixed=>In Progress
      Assigned torhysu=>bjg
      Open/ClosedClosed=>Open
    Thu 06 May 2010 02:39:21 PM UTCrhysuStatusNone=>Fixed
      Assigned toNone=>rhysu
      Open/ClosedOpen=>Closed
    Thu 06 May 2010 02:46:28 AM UTCrhysuAttached File-=>Added 0001-capture-complex_pow_real-bug-29773.patch, #20460
      Attached File-=>Added 0002-Fix-29773-gsl_complex_pow_real-has-0-0i-0-1.patch, #20461
    Tue 04 May 2010 03:31:33 PM UTCrhysuAttached File-=>Added testcase.c, #20427
      Carbon-Copy-=>Added rhysu

    Back to the top


    Powered by Savane 3.1-cleanup1