d****n 发帖数: 1637 | 1 /*working with larger numbers but still die */
/**C(80, 20) is okay, which was not ok in previous version**/
#include
#include
#include
float
gammln (float xx)
//Returns the value ln[Ãxx)] for xx > 0.
{
//Internal arithmetic will be done in double precision, a nicety that
//you can omit if five-figure
//accuracy is good enough.
double x, y, tmp, ser;
static double cof[6] = { 76.18009172947146, -86.50532032941677,
24.01409824083091, -1.231739572450155,
... 阅读全帖 |
|
d****n 发帖数: 1637 | 2 /*working with larger numbers but still die */
/**C(80, 20) is okay, which was not ok in previous version**/
#include
#include
#include
float
gammln (float xx)
//Returns the value ln[Ãxx)] for xx > 0.
{
//Internal arithmetic will be done in double precision, a nicety that
//you can omit if five-figure
//accuracy is good enough.
double x, y, tmp, ser;
static double cof[6] = { 76.18009172947146, -86.50532032941677,
24.01409824083091, -1.231739572450155,
... 阅读全帖 |
|