sci.math #137006 (9 + 914 more) | | \-(1)
From: bw946@freenet.uchsc.edu (Raymond K. | |-(1)
+ Petry) | \-(1)--(1)
[1] Re: Q: Simpsons's rule |-( )--[1]
Harold Atkinson (hrat@server.uwindsor.ca) wrote:
: Fredrik Anton Sten Hanssen wrote:
: > I am working within the field of neurophysiology. When analyzing some
: > waveforms my software (from Datawave Technologies) uses Simpson's rule for
: > calculating an area.
: >
: > What does this rule say?
: Simpson's rule is a technique for approximating definite integrals of
: functions for which the fundamental theorem of calculus. It is based
: on approximating the graph of the function by arcs of a parabola.
Simpson's rule applies to sinusoidal estimations (numerical approximations)
as Mr. Simpson used it ... indeed it implicitly presumes certain harmonic
structure in the data set, which you may not find outside sinusoial data ...
the normal curve, for example, is not well approximated by Simpson's rule.
You can check for yourself ... if you had an even number of points, you'd
need Newton's rule [3 9 9 3]/8 at one tail end, and Simpson's [1 4 2 4 ...]/3
for the remainder ... but which end? but if you try both ends, and average
the two tries, all your Simpson's in the middle disappears [... 1 1 1 ...].
Most mathematicians are idiots [idea-ots] outside their specific researches:
ask Kaczinski what he thinks about that ....
--
Cordially and sincerely, your Mr. Raymond Kenneth Petry, CS, The Follower and
Principal Successor to Rev. Mary Baker Eddy mailto:lambhorn@mail.serve.com
The Son Dey School of Christ Science http://www.serve.com/lambhorn
55...5^KEY mod @20-11=4475961518,7357040702 P*Q=@40-11,3077950491,7493976207
End of article 137006 (of 137750) -- what next? [npq]
Article 78430 of sci.math:
Path: news.sri.ucl.ac.be!jussieu.fr!math.ohio-state.edu!howland.reston.ans.net!torn!hone!informer1.cis.McMaster.CA!mcmail.CIS.McMaster.CA!not-for-mail
From: kovarik@mcmail.cis.McMaster.CA (Zdislav V. Kovarik)
Newsgroups: sci.math
Subject: Re: Q: Simpsons's rule
Date: 14 May 1996 22:24:27 -0400
Organization: McMaster University, Hamilton, Ontario, Canada.
Lines: 112
Message-ID: <4nbf8r$ho3@mcmail.CIS.McMaster.CA>
References: <4n07pb$gmt@dartvax.dartmouth.edu> <4n7h2v$1sk@dartvax.dartmouth.edu> <4n7pek$cmi@mcmail.CIS.McMaster.CA> <4napqu$j0b@dartvax.dartmouth.edu>
NNTP-Posting-Host: mcmail.cis.mcmaster.ca
In article <4napqu$j0b@dartvax.dartmouth.edu>,
Benjamin J. Tilly wrote:
>In article <4n7pek$cmi@mcmail.CIS.McMaster.CA>
>kovarik@mcmail.cis.McMaster.CA (Zdislav V. Kovarik) writes:
>
>> In article <4n7h2v$1sk@dartvax.dartmouth.edu>,
>> Benjamin J. Tilly wrote:
>> [...]
>> >> >I challenge you to come up with a natural cubic polynomial to associate
>> >> >with Simpson's rule. A quadratic interpolation function comes from the
>> >> >derivation.
>>
>> (Sorry for a repetition if someone else did it here:)
>>
>> Let us try to fit a cubic polynomial p(x) through the data
>>
>> p(a-h) = y_-1
>> p(a) = y_0
>> p(a+h) = y_1
>> p'(a) = s
>>
>> That is 4 pieces of data, consistent and uniquely solvable, just as
>> prescribed for cubics, and the solution is...
>>
>Is "s" given in the initial data set? I maintain that it is not given,
>and it is not used. Without adding in dependence extra data that does
>not get used (and is usually not provided) there is no natural way to
>associate a unique third degree polynomial with the method.
>
>This trick is useful in the proof of how good the convergence is, but
>it does not allow the data used in the method give the polynomial.
>(Which is also, in real life, the data given. In fact if you were to
>work out from the data usually available an interpolation, then the one
>equivalent to Simpson's rule has degree 2.)
>
>Ben Tilly
(1) Too much of a big deal is made of Simpson's Rule anyway; I just
answered (holding my nose) a question "what is the linear combination
of f(a-h), f(a), f'(a) and f(a+h) which approximates the integral of f
over the interval [a-h, a+h] , and gives an exact answer if f is a
cubic polynomial?"
(1a) That the coefficient at f'(a) comes out as 0 in that linear
combination is a bonus, not a cause for protests.
(1b) Here is a scenario when the derivative is readily available: suppose
f(x) = (g(x)^2, g is a solution of a differential equation (so that
differentiation is a matter of a function call), and f is to be
integrated. (Then I'd use a more efficient formula; I did say
that Simpson's Rule is overrated.)
That also points to the limited meaning of the requirement that the
osculatory polynomial be "natural". It is natural in some situations
but not in others. (What is "natural" in Calculus, anyway?)
(2) The speculation about "what's given in real life" seems to originate
in confusing different sets of assumptions, and switching from one to
another without warning.
Let me include the composite Simpson's rule into the discussion
because that is its customary form. So, f is given on an odd number
of equidistant points A = x_0 < x_1 <...< x_n = B , n even,
x_(j+1) - x_j = (B-A)/n. Maybe we have means how to make the tables
{(x_j, f(x_j)): j=0,...,n} for different values of n.
-> One extreme: Nothing else is known about f, except perhaps that f is
continuous in [A, B]. Then Simpson's Rule is _exactly_ as good as
Trapezoidal Rule, and we need not bother with parity and with the
{1,4,2,4,...,4,1} pattern.
-> Another extreme: f is infinitely differentiable (in an open interval
containing [A,B], and there is no predictable relation between
endpoint derivatives of f; then Romberg's scheme (never mind that
the derivatives are not used: it's their existence that guarantees
the speed of convergence) of sufficiently high order is much faster
than Simpson's Rule -- which is the second stage of Romberg's scheme,
right after Trapezoidal Rule.
(That's the way I present Simpson's Rule in class:
Trapez(h) := (1/2) * (Trapez(2*h) + Midpoint(2*h)),
Simpson(h) := Trapez(h) + (1/3)*(Trapez(h) - Trapez(2*h)),
good-bye to {1,4,2,4,2,...,2,4,1} pattern!)
-> Special case of this extreme: f is periodic with period (B-A); then
nothing, including Simpson's Rule (in the point evaluation class),
beats Trapezoidal Rule, refined, say, by interval halving. (The proof
uses Euler-Maclaurin formula).
(3) There is a little-publicized endpoint correction for Trapezoidal Rule
which is asymptotically just as powerful as Simpson's Rule, without
having to maintain an even number of intervals:
Trapez_corr(h)
= Trapez(h) - (h/12) * (f(x_n) - f(x_(n-1) - f(x_1) +f(x_0))
which is of order O(h^4) as long as f has continuous fourth derivative
on the interval [A, B]. (That's an intermediate scenario between the
above two extremes.)
(For n=2, we get Simpson's Rule again, but who needs it now?)
(4) A situation easy to run into but where Simpson's Rule doesn't live up to
the O(h^4) expectations: a cubic spline with equidistant nodes. It has
possible jump discontinuities in the third derivative, so the fourth
order error formula does not apply. Fortunately, the spline can be
integrated directly and exactly, from Trapezoidal Rule with
first-derivative endpoint correction.
Thanks for everyone's patience if you read this far,
ZVK (Slavek).
Article 78503 of sci.math:
Path: news.sri.ucl.ac.be!jussieu.fr!math.ohio-state.edu!howland.reston.ans.net!swrinde!newsfeed.internetmci.com!newsfeeder.servtech.com!news1.io.org!news
From: trebla@io.org (Albert Y.C. Lai)
Newsgroups: sci.math
Subject: Re: Q: Simpsons's rule
Date: Wed, 15 May 1996 14:04:42 -0400
Organization: Internex Online (io.org), Toronto, Ontario, Canada
Lines: 8
Message-ID: <6yhmxs9YeL6f090yn@io.org>
References: <4n07pb$gmt@dartvax.dartmouth.edu>
<4n7h2v$1sk@dartvax.dartmouth.edu> <4n7pek$cmi@mcmail.CIS.McMaster.CA>
<4napqu$j0b@dartvax.dartmouth.edu> <4nbf8r$ho3@mcmail.CIS.McMaster.CA>
NNTP-Posting-Host: dream.net6a.io.org
In article <4nbf8r$ho3@mcmail.CIS.McMaster.CA>,
kovarik@mcmail.cis.McMaster.CA (Zdislav V. Kovarik) wrote:
>Thanks for everyone's patience if you read this far,
Your article is eye-opening.
--
Albert Y.C. Lai trebla@io.org http://www.io.org/~trebla/