proposal to cut out romberg and quanc8 functions



>>>>> "Robert" == Robert Dodier <robert.dodier at gmail.com> writes:

    Robert> On 1/3/07, Michel Van den Bergh <michel.vandenbergh at uhasselt.be> wrote:
    >> I assume the nesting can be achieved with the new functions using some
    >> kind of lambda construct...

    Robert> Yes, a lambda expression has the expected effect here.

    Robert> quad_qags (lambda ([y], quad_qags (lambda ([x], x^2 + y^2), x, 0,
    Robert> y)[1]), y, 0, 1);
    Robert>   => [.3333333333333333, 3.70074341541719E-15, 21, 0]

Just a note for the unwary:  The error estimate produced here
(3.7e-15) is probably way off because it doesn't take into account the
error produced by the inner quad_qags.

One nice thing about having converted the code to Lisp instead of
using an FFI: You might not be able to do nested calls like this with
the original Fortran code because recursive calls like this are
unspecified or forbidden in Fortran 77.  I think the quadpack manual
actually gives an example of this, but specifically mentions that two
different integrators are used.

Ray