This is the mail archive of the
gsl-discuss@sources.redhat.com
mailing list for the GSL project.
problems with error handling
- From: Daniel Rohe <d dot rohe at fkf dot mpg dot de>
- To: gsl list <gsl-discuss at sources dot redhat dot com>
- Date: Sun, 07 Apr 2002 14:01:36 +0200
- Subject: problems with error handling
for some reason I don't get the error handling to work.
here's my actual code:
...
static int status;
status = gsl_integration_qagp( ... );
if( GSL_SUCCESS != status )
{
if( GSL_EDIVERGE == status )
{
printf("error in gsl_qagp - cooper: integral divering. xi_0 =
%.6f\tepsilon_0 = %.6f , lambda_limits = (%.6f,%.6f)\n",
xi_0,epsilon_0,lambda_limits[0],lambda_limits[1]);
}
else
{
printf("error in gsl_qagp\n");
}
exit(42);
}
...
but all that happens if the error occurs is
>gsl: qagp.c:504: ERROR: integral is divergent, or slowly convergent
Abort
I guess I'm making a silly mistake once more. can anyone give me a hint?
thanks,
daniel