[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-gsl] Bessel Example results
From: |
Manuel Segovia |
Subject: |
Re: [Bug-gsl] Bessel Example results |
Date: |
Tue, 03 May 2016 08:42:56 -0400 |
Alex thank You very much
Looks like the result indicated in the manual then is wrong
>> -1.775967713143382920e-01
Can you comment?
Again thank you very much
Manuel Segovia
> On May 3, 2016, at 7:39 AM, Alex Shevtsov <address@hidden> wrote:
>
> Hi Manuel,
>
> Of course it is not a bug. The spherical Bessel function j_0 = sin(x)/x, so
> you can check this value by direct calculation, which indeed gives the value
> that you get.
>
> Best wishes,
> Alex
>
>> On Tue, May 3, 2016 at 1:46 AM Manuel Segovia <address@hidden> wrote:
>> Hello
>> please check the following could this be a “bug”?
>>
>> gsl @2.1 (math, science)
>> Mac OSX “el Capitan” 10.11.4
>> i am using Clang and compile instructions are:
>> clang -L/opt/local/lib -lgsl main.o -o bessel
>>
>> # include <stdio.h>
>> # include <gsl/gsl_sf_bessel.h>
>> int main (void)
>> {
>> double x = 5.0;
>> double y = gsl_sf_bessel_j0 (x);
>> printf ("JO(%g) = %.18e\n", x , y);
>> return(0);
>> }
>> the result i get is JO(5) = -1.917848549326277019e-01
>> instead of -1.775967713143382920e-01 this is the result indicated in the gsl
>> manual 2.1 example program
>> Thanks