DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 

bessel(3M)


bessel -- Bessel functions

Synopsis

   cc [flag ...] file ...  -lm [library ...]
   

#include <math.h>

double j0(double x);

double j1(double x);

double jn(int n, double x);

double y0(double x);

double y1(double x);

double yn(int n, double x);

Description

j0 and j1 return Bessel functions of x of the first kind of orders 0 and 1, respectively. jn returns the Bessel function of x of the first kind of order n.

y0 and y1 return Bessel functions of x of the second kind of orders 0 and 1, respectively. yn returns the Bessel function of x of the second kind of order n. The value of x must be positive.

Errors

When x is zero, y0, y1, and yn return a value that will compare equal to -HUGE_VAL and set errno to EDOM.

When x is negative, y0, y1, and yn return IEEE NaN on systems that support it, otherwise -HUGE_VAL, and set errno to EDOM.

Arguments too large in magnitude cause all of these functions to return zero and to set errno to ERANGE.

On systems that support IEEE NaN, if x is a quiet NaN, that value is returned. If x is a signaling NaN, a quiet NaN is returned and the invalid operation exception is raised. In either case, errno is set to EDOM.

If the program was compiled with the -Xt compilation mode, non-positive arguments to y0, y1, and yn cause these functions to return a value that will compare equal to -HUGE and to set errno to EDOM. In addition, a message indicating DOMAIN error is printed on the standard error output. For arguments too large in magnitude, a message indicating TLOSS error is printed on the standard error output, in addition to the error behavior described above. These error handling procedures may be changed with the function matherr.

References

cc(1), matherr(3M)
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004