73.1 Functions and Variables for romberg

romberg(expr, x, a, b)
returns an estimate of the integral integrate(expr, x, a, b).
expr must be an expression which evaluates to a floating point value
when x is bound to a floating point value.

romberg(F, a, b)
returns an estimate of the integral integrate(F(x), x, a, b)
where x represents the unnamed, sole argument of F;
the actual argument is not named x.
F must be a Maxima or Lisp function which returns a floating point value
when the argument is a floating point value.
F may name a translated or compiled Maxima function.

The accuracy of romberg is governed by the global variables
rombergabs and rombergtol.
romberg terminates successfully when
the absolute difference between successive approximations is less than rombergabs,
or the relative difference in successive approximations is less than rombergtol.
Thus when rombergabs is 0.0 (the default)
only the relative error test has any effect on romberg.

romberg halves the stepsize at most rombergit times before it gives up;
the maximum number of function evaluations is therefore 2^rombergit.
If the error criterion established by rombergabs and rombergtol
is not satisfied, romberg prints an error message.
romberg always makes at least rombergmin iterations;
this is a heuristic intended to prevent spurious termination when the integrand is oscillatory.

romberg repeatedly evaluates the integrand after binding the variable
of integration to a specific value (and not before).
This evaluation policy makes it possible to nest calls to romberg,
to compute multidimensional integrals.
However, the error calculations do not take the errors of nested integrations
into account, so errors may be underestimated.
Also, methods devised especially for multidimensional problems may yield
the same accuracy with fewer function evaluations.

The accuracy of romberg is governed by the global variables
rombergabs and rombergtol.
romberg terminates successfully when
the absolute difference between successive approximations is less than rombergabs,
or the relative difference in successive approximations is less than rombergtol.
Thus when rombergabs is 0.0 (the default)
only the relative error test has any effect on romberg.

romberg halves the stepsize at most rombergit times before it gives up;
the maximum number of function evaluations is therefore 2^rombergit.
romberg always makes at least rombergmin iterations;
this is a heuristic intended to prevent spurious termination when the integrand is oscillatory.

The accuracy of romberg is governed by the global variables
rombergabs and rombergtol.
romberg terminates successfully when
the absolute difference between successive approximations is less than rombergabs,
or the relative difference in successive approximations is less than rombergtol.
Thus when rombergabs is 0.0 (the default)
only the relative error test has any effect on romberg.