y0
Bessel 0阶第二类函数,x > 0。
接口定义
C interface:
float y0f(float x);
double y0(double x);
参数
参数名 |
类型 |
描述 |
输入/输出 |
---|---|---|---|
x |
|
表示输入数据的浮点值。 |
输入 |
返回值
- 返回以0阶第二类贝塞尔函数值y,y ∈ (-∞, +1)。
- 输入x为±0,返回-∞。
- 输入x<0,返回nan。
- 输入x为+∞,返回0。
- 输入x为nan,返回nan。
依赖
C: "km.h"
示例
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("y0(0.0) = %.15f\n", y0(x1)); printf("y0(-0.0) = %.15f\n", y0(x2)); printf("y0(1.5) = %.15f\n", y0(x3)); printf("y0(-2.5) = %.15f\n", y0(x4)); printf("y0(INFINITY) = %.15f\n", y0(a)); printf("y0(-INFINITY) = %.15f\n", y0(b)); printf("y0(NAN) = %.15f\n", y0(c)); /* * y0(0.0) = -inf * y0(-0.0) = -inf * y0(1.5) = 0.382448923797759 * y0(-2.5) = nan * y0(INFINITY) = 0.000000000000000 * y0(-INFINITY) = nan * y0(NAN) = nan * * */
父主题: 特殊函数