[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: bug in bessel function in glibc 2.1



On Wed, 30 Jun 1999, John Lapeyre wrote:

> i replied to karl, but it looks like it didn't make it to the list
> (shoulda checked the headers before sending....).  anyway, the problem
> with bessyn under RH 6.0 stems from the yn function in libm being
> fscked somehow.  compiling and running this C code:
> 
> #include <stdio.h>
> #include <math.h>
> 
> int main(void) {
> 
>   double x;
> 
>   x = yn(2,0.2);
> 
>   printf("%12.9f\n", x);
> 
>   return 0;
> 
> }
> 
> under RH 6.0 gives -32.223870297 whereas under solaris 2.6 it
> gives -32.157144559.  i haven't tested other linux dists, but will
> tonight. i'll also post a bug report to bugzilla.redhat.com.

I believe that you're correct on this one, but only for glibc 2.1.1 (at
least on Alpha...don't have a glibc 2.1.1 system of any other arch).

Here's my results so far:

i386 glibc 2.0.7:
yn(2,0.2) = -32.157144559

alpha glibc 2.1.1:
yn(2,0.2) = -32.157110946

That's with no compiler options other than -lm.  Using -mieee (out of
curiosity) didn't yield different results.  I'll double-check that the
compiler isn't fubar'ing this somehow, but I doubt it.

C


Reply to: