octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #62412] quadcc does not warn when quadrature f


From: Michael Leitner
Subject: [Octave-bug-tracker] [bug #62412] quadcc does not warn when quadrature fails to converge
Date: Thu, 5 May 2022 11:01:58 -0400 (EDT)

Follow-up Comment #12, bug #62412 (project octave):

I think if it is only a question of complex integrands, then any integrator
should do: just call it once with the real part of the integrand and once with
the imaginary part, and combine those two afterwards. In fact, one could argue
that one should do this always, even when calling the integrators themselves:
why should it not be possible to integrate, e.g., sqrt(x^2-1) from -2 to 2? Of
course, it is different if you are talking about integration over paths in the
complex plane.

I looked into quadv.m, and unless I am strongly mistaken, it computes its
internal error incorrectly (or put more positively, with wildly optimistic
assumptions), see the FIXME in line 193. So in general it doesn't even follow
its tolerance target. And with respect to its ability to handle vector-valued
integrands: I think it would not be hard at all to modify quadgk to allow
vector-valued integrands.

It seems that in quadgk the errors are really just the sums of the absolute
differences in the Gauss and Kronrod steps of the accepted subintervals. Thus,
it can often be the case that this is a very conservative estimate if there is
cancellation.




    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?62412>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]