o2scl::inte_qng_gsl< func_t > Class Template Reference

Non-adaptive integration from a to b (GSL) More...

`#include <inte_qng_gsl.h>`

Inheritance diagram for o2scl::inte_qng_gsl< func_t >:

## Public Member Functions | |

virtual int | integ_err (func_t &func, double a, double b, double &res, double &err2) |

Integrate function `func` from `a` to `b` giving result `res` and error `err` . | |

const char * | type () |

Return string denoting type ("inte_qng_gsl") | |

Public Member Functions inherited from o2scl::inte< func_t > | |

virtual double | integ (func_t &func, double a, double b) |

Integrate function `func` from `a` to `b` . | |

double | get_error () |

Return the numerically estimated error in the result from the last call to integ() More... | |

## Public Attributes | |

size_t | feval |

The number of function evalutions for the last integration. More... | |

double | min_rel_tol |

Minimum relative tolerance for integration (default ) | |

Public Attributes inherited from o2scl::inte< func_t > | |

int | verbose |

Verbosity. | |

size_t | last_iter |

The most recent number of iterations taken. | |

double | tol_rel |

The maximum relative uncertainty in the value of the integral (default ) | |

double | tol_abs |

The maximum absolute uncertainty in the value of the integral (default ) | |

bool | err_nonconv |

If true, call the error handler if the routine does not converge or reach the desired tolerance (default true) More... | |

## Additional Inherited Members | |

Protected Member Functions inherited from o2scl::inte_gsl | |

double | rescale_error (double err, const double result_abs, const double result_asc) |

QUADPACK's nonlinear rescaling of the absolute-error estimate. More... | |

Protected Attributes inherited from o2scl::inte< func_t > | |

double | interror |

The uncertainty for the last integration computation. | |

class o2scl::inte_qng_gsl< func_t >

The function integ() uses 10-point, 21-point, 43-point, and 87-point Gauss-Kronrod integration successively until the integral is returned within the accuracy specified by inte::tol_abs and inte::tol_rel. The 10-point rule is only used to estimate the error for the 21-point rule. The result of the 21-point calculation is used to estimate the error for the 43-point rule, and so forth.

The error handler is called if the 87-point integration fails to produce the desired accuracy. If inte::err_nonconv is false (the default is true), then the error handler is never called and when the desired accuracy is not obtained the result of the 87-point integration is returned along with the associated error.

The return value of the function to be integrated is ignored.

The integration fails and the error handler is called if the tolerances are too small, i.e. if either or if where .

The integration coefficients are stored in the o2scl_inte_qng_coeffs namespace.

Definition at line 255 of file inte_qng_gsl.h.

template<class func_t = funct11>

size_t o2scl::inte_qng_gsl< func_t >::feval |

Set to either 0, 21, 43, or 87, depending on the number of function evaluations that were used. This variable is zero if an error occurs before any function evaluations were performed and is never equal 10, since in the 10-point method, the 21-point result is used to estimate the error. If the function fails to achieve the desired precision, feval is 87.

Definition at line 274 of file inte_qng_gsl.h.

The documentation for this class was generated from the following file:

- /home/awsteiner/wcs/o2scl/src/inte/inte_qng_gsl.h

Documentation generated with Doxygen. Provided under the
GNU Free Documentation License (see License Information).