Hi!
I'm using the GSL library version 1.9 (Debian package libgsl0-1.9-3).
It seems to me that gsl_cdf_beta_Pinv yields strange results:
gsl_cdf_beta_P(0.2053056, 2133, 10000 - 2133 + 1)
result: 0.0249996 (this is correct)
gsl_cdf_beta_Pinv(0.025, 2133, 10000 - 2133 + 1)
result: 0.172583 (the correct result should be 0.2053056)
gsl_cdf_beta_P(0.172583, 2133, 10000 - 2133 + 1)
result: 6.43881e-26 (this is correct and illustrates the problem)
I've attached a small test programm. You can compile it with
g++ -lgsl -lgslcblas test.cpp
I hope you'll be able to reproduce the problem.
Kind regards,
Sebastian Queißer
#include <gsl/gsl_cdf.h>
#include <iostream>
using namespace std;
int main(int argc, char *argv[])
{
int x = 2133;
int n = 10000;
cout << gsl_cdf_beta_P(gsl_cdf_beta_Pinv(0.025, x, n - x + 1), x, n - x + 1) << endl;
return 0;
}
_______________________________________________
Bug-gsl mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-gsl