[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Help-gsl] Problems with gsl_integration_qagiu
From: |
Daniel Bencik |
Subject: |
[Help-gsl] Problems with gsl_integration_qagiu |
Date: |
Sat, 14 Apr 2012 22:51:04 +0200 |
Dear fellow users,
I'm writing an application on Whittle MLE estimation and for that I need
gsl_integration_qagiu. Namely, I have
double Logp_Weibull( double x, void * params )
{
double kappa = ((double*)params)[0];
double p = ((double*)params)[1];
double xi = gsl_sf_gamma( 1 + 1/kappa );
double dXiToKappa = pow(xi, kappa);
double RetVal1 = pow( log(x), p );
double RetVal2 = kappa * dXiToKappa;
double RetVal3 = pow( x, kappa - 1 );
double RetVal4 = exp( -dXiToKappa * pow(x, kappa) );
return RetVal1 * RetVal2 * RetVal3 * RetVal4;
}
then in the main code I have
int main(void)
{
gsl_function F;
double Params [2]; /* kappa, p */
F.function = &Logp_Weibull;
F.params = &Params[0];
Params[0] = kappa;
Params[1]= p;
double result;
double error;
gsl_integration_qagiu (&F, 0.0, 1.0e-08, 1.0e-08, 1000, w, &result, &error);
return 0;
}
My problem is that for kappa = 1/6 and p = 2.0 the gsl_integration_qagiu function returns
an error message "R6010 - abort() hgas been called". Is there anything I can do
about it? Trying to run the same integration in Ox produces a warning, however returns
some result of integration.
Any help (at least knowing what is happening inside) is much appreciated.
Daniel
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Help-gsl] Problems with gsl_integration_qagiu,
Daniel Bencik <=