提交 bbfbc7ed 编写于 作者: N nsz

math: add dummy tgamma and tgammaf implementations

上级 1b229a20
#include <math.h>
// FIXME: use lanczos approximation
double __lgamma_r(double, int *);
double tgamma(double x)
{
int sign;
double y;
y = exp(__lgamma_r(x, &sign));
if (sign < 0)
y = -y;
return y;
}
#include <math.h>
// FIXME: use lanczos approximation
float __lgammaf_r(float, int *);
float tgammaf(float x)
{
int sign;
float y;
y = exp(__lgammaf_r(x, &sign));
if (sign < 0)
y = -y;
return y;
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册