Post Reply 
HP71B Integral Questions
02-06-2020, 11:16 PM
Post: #12
RE: HP71B Integral Questions
(02-06-2020 06:53 PM)Wes Loewer Wrote:  A couple of notes on the 3/2*u-1/2*u³ substitution.

If I understand correctly (and please correct me if I'm wrong), it's not this substitution that prevents the end points from being evaluated. The reason the endpoints are not evaluated is because the Romberg variation used is based on rectangle midpoint evaluations rather than something like a trapezoid (trapezium) method which does evaluate endpoints.

A simple test showed that HP71B INTEGRAL do extrapolations from trapezoids, not mid-points rule.

>10 DISP INTEGRAL(-1, 1, 1E-5, 1/SQRT(1-IVAR^2)), IBOUND
>RUN
3.14156045534              -3.1415397954E-5

this failure to converge (65535 sample points !) is due to missing end points evaluation.

\(\large \int _{-1} ^1 f(x) dx
= \int _{-1} ^ 1 {3 \over 2}(1-u^2) f \left({ u (3-u^2) \over 2} \right) du
= \int _{-1} ^ 1 g(u) du \)

\(f(x) = {1\over\sqrt{1-x^2}}\quad → \quad
g(u) = {3 (1-u^2) \over \sqrt{(4-u^2)(1-u^2)^2}}\)

\(\displaystyle{\lim_{u^2 \to 1^-} g(u)} = \displaystyle{\lim_{u^2 \to 1^-}{3\over\sqrt{4-u^2}}} = \sqrt3 ≠ 0\)

Quote:So then the question was "Why make this substitution if the intervals are already nonuniform?"

It does matter, even if gaussian quadrature do not evaluate end points.
u-transformation changes the overall shape of the integrand, affecting all sample points.

try above f(x) and g(u) (with 1-u^2 cancelled)

XCas> f(x) := 1/sqrt(1-x*x)
XCas> g(x) := 3/sqrt(4-x*x)
XCas> time(gaussquad(f(x), x = -1 .. 1))      → 0.0065
XCas> time(gaussquad(g(x), x = -1 .. 1))     → 0.00054
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
HP71B Integral Questions - Albert Chan - 02-02-2020, 03:31 PM
RE: HP71B Integral Questions - Albert Chan - 02-03-2020, 01:58 PM
RE: HP71B Integral Questions - J-F Garnier - 02-03-2020, 03:00 PM
RE: HP71B Integral Questions - Albert Chan - 02-03-2020, 04:15 PM
RE: HP71B Integral Questions - Albert Chan - 02-03-2020, 11:15 PM
RE: HP71B Integral Questions - J-F Garnier - 02-05-2020, 08:43 AM
RE: HP71B Integral Questions - Albert Chan - 02-05-2020, 05:09 PM
RE: HP71B Integral Questions - Wes Loewer - 02-06-2020, 06:53 PM
RE: HP71B Integral Questions - Albert Chan - 02-06-2020 11:16 PM
RE: HP71B Integral Questions - Wes Loewer - 02-07-2020, 03:49 AM
RE: HP71B Integral Questions - Albert Chan - 02-07-2020, 08:14 AM
RE: HP71B Integral Questions - J-F Garnier - 02-07-2020, 08:23 AM
RE: HP71B Integral Questions - Wes Loewer - 02-07-2020, 01:19 PM
RE: HP71B Integral Questions - Albert Chan - 02-07-2020, 05:08 PM
RE: HP71B Integral Questions - J-F Garnier - 02-07-2020, 05:54 PM
RE: HP71B Integral Questions - Wes Loewer - 02-07-2020, 08:16 PM
RE: HP71B Integral Questions - Wes Loewer - 02-07-2020, 08:12 PM
RE: HP71B Integral Questions - J-F Garnier - 02-05-2020, 06:20 PM
RE: HP71B Integral Questions - Albert Chan - 02-05-2020, 07:52 PM
RE: HP71B Integral Questions - J-F Garnier - 02-06-2020, 08:37 AM
RE: HP71B Integral Questions - Wes Loewer - 02-08-2020, 10:46 AM
RE: HP71B Integral Questions - J-F Garnier - 02-08-2020, 10:59 AM
RE: HP71B Integral Questions - Wes Loewer - 02-08-2020, 03:04 PM
RE: HP71B Integral Questions - Albert Chan - 02-09-2020, 01:43 PM
RE: HP71B Integral Questions - Wes Loewer - 02-09-2020, 08:33 PM
RE: HP71B Integral Questions - Albert Chan - 02-10-2020, 01:33 PM
RE: HP71B Integral Questions - Wes Loewer - 02-09-2020, 09:03 PM
RE: HP71B Integral Questions - Albert Chan - 02-11-2020, 05:03 PM
RE: HP71B Integral Questions - Albert Chan - 02-11-2020, 11:57 PM
RE: HP71B Integral Questions - Albert Chan - 02-21-2020, 11:23 PM



User(s) browsing this thread: 6 Guest(s)