At Mon, 25 Oct 2010 19:51:49 -0500, Raymond Rogers wrote: > > Below is a program demonstrating what I think is a bogus error estimate > for gsl_sf_hyperg_U_e(4.111,.11,6.4) > The output with gsl 1.14 is: > Values a0,a1,a2,b,x 4.109000e+00, > 4.110000e+00, 4.111000e+00 1.100000e-01, 6.400000e+00 > Values hyperg_U_e result.val = 6.439287e-05, > 6.422378e-05, 6.405513e-05 > Error return hyperg_U_e result.err= 1.217053e-18, > 6.422378e-05, 1.224921e-18 > hyperg_U = 6.422378e-05
Thanks for the bug report, you are right. I've found the problem and committed a fix. -- Brian Gough ------------------------------------------------------------ revno: 4693 committer: Brian Gough <[email protected]> branch nick: trunk timestamp: Fri 2010-10-29 22:16:02 +0100 message: fix bad error term for hyperg_U_small_a_bgt0(a=0,b,x) diff: === modified file 'specfunc/ChangeLog' --- specfunc/ChangeLog 2010-08-31 18:14:47 +0000 +++ specfunc/ChangeLog 2010-10-29 21:16:02 +0000 @@ -1,3 +1,8 @@ +2010-10-29 Brian Gough <[email protected]> + + * hyperg_U.c (hyperg_U_small_a_bgt0): corrected result->err for + case where a==0.0 + 2010-08-31 Brian Gough <[email protected]> * beta_inc.c (gsl_sf_beta_inc_e): ignore underflow error when term === modified file 'specfunc/hyperg_U.c' --- specfunc/hyperg_U.c 2010-03-02 14:05:27 +0000 +++ specfunc/hyperg_U.c 2010-10-29 21:16:02 +0000 @@ -771,7 +771,7 @@ { if(a == 0.0) { result->val = 1.0; - result->err = 1.0; + result->err = 0.0; *ln_multiplier = 0.0; return GSL_SUCCESS; } === modified file 'specfunc/test_hyperg.c' --- specfunc/test_hyperg.c 2010-08-27 09:05:07 +0000 +++ specfunc/test_hyperg.c 2010-10-29 21:16:02 +0000 @@ -583,6 +583,10 @@ TEST_SF(s, gsl_sf_hyperg_U_int_e, (3, 7, -0.5, &r), 2824, TEST_TOL0, GSL_SUCCESS); TEST_SF(s, gsl_sf_hyperg_U_int_e, (5, 12, -1.7, &r), -153.262676210016018065768591104, TEST_TOL2, GSL_SUCCESS); + /* Bug report from Raymond Rogers */ + + TEST_SF(s, gsl_sf_hyperg_U_e, (4.11, 0.11, 6.4, &r), 6.422378238765078623739153038e-5, TEST_TOL2, GSL_SUCCESS); + /* 2F1 */ TEST_SF(s, gsl_sf_hyperg_2F1_e, (1, 1, 1, 0.5, &r), 2.0, TEST_TOL0, GSL_SUCCESS); _______________________________________________ Bug-gsl mailing list [email protected] http://lists.gnu.org/mailman/listinfo/bug-gsl
