y1
Compute the Bessel function of the second kind, of order 1. x > 0
Interface Definition
C interface:
float y1f(float x);
double y1(double x);
Parameters
Parameter |
Type |
Description |
Input/Output |
|---|---|---|---|
x |
|
Floating-point value of the input data. |
Input |
Return Value
- The order-1 second-kind Bessel function value y is returned. y ∈ (–∞, +1).
- If the input x is ±0, the return value is –∞.
- If the input x is less than 0, the return value is NaN.
- If the input x is +∞, the return value is 0.
- If the input x is NaN, the return value is NaN.
Dependency
C: "km.h"
Example
C interface:
double x1 = 0.0, x2 = -0.0, x3 = 1.5, x4 = -2.5;
// special handing
double a = INFINITY, b = -INFINITY, c = NAN;
// print result
printf("y1(0.0) = %.15f\n", y1(x1));
printf("y1(-0.0) = %.15f\n", y1(x2));
printf("y1(1.5) = %.15f\n", y1(x3));
printf("y1(-2.5) = %.15f\n", y1(x4));
printf("y1(INFINITY) = %.15f\n", y1(a));
printf("y1(-INFINITY) = %.15f\n", y1(b));
printf("y1(NAN) = %.15f\n", y1(c));
/*
* y1(0.0) = -inf
* y1(-0.0) = -inf
* y1(1.5) = -0.412308626973911
* y1(-2.5) = nan
* y1(INFINITY) = 0.000000000000000
* y1(-INFINITY) = nan
* y1(NAN) = nan
*
* */
Parent topic: Special Functions