help-octave
[Top][All Lists]
Advanced

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

Re: Using quad() for multidimensional integration


From: Jim Van Zandt
Subject: Re: Using quad() for multidimensional integration
Date: Fri, 18 Aug 1995 08:47:26 -0400

Ted Harding writes:
>...Or at least there is a totally unnecessary
>number of calls to the function being integrated. Take the simple example
...
>i.e. 21 calls in order to integrate a quadratic! Now (if octave used, like
>matlab, Simpson's rule) Simpson's rule is theoretically EXACT IN ONE PASS
>for a quadratic.

Suppose your function is equal to a quadratic except over a small
interval.  Unless it is evaluated within that interval, the numerical
integration will reach the wrong result.  In choosing the minimum
number of points to evaluate, we face a tradeoff between a slight
increase in effort for trivial functions (which you aren't likely to
integrate numerically in the first place) versus an increased chance
of silently reaching an entirely incorrect result.  Finding Quadpack
weighted toward the former and Matlab weighted toward the latter does
not surprise me.


reply via email to

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