The Museum of HP Calculators

HP Forum Archive 20

[ Return to Index | Top of Index ]

Numerical Integration
Message #1 Posted by Namir on 21 Nov 2011, 2:38 p.m.

Hi All,

I posted an article (as a pdf file) on my web site. You can download it if you click here.

The article is a result of some basic investigation to enhance the Trapezoidal method by using additional points inside each integration interval. My new approach produces some improvements over the basic Trapezoidal rule using weights with points inside the interval. Interestingly, the new method does very well when these weights match those of Simpson's rule, Simpson's 3/8 rule, and other similar methods. The article explains how you can mix the Trapezoidal method with better methods when the scheme of the latter are applied to each integration interval in an isolated or compartmentalized manner. The article shows the source code for VBA functions that implement the various algorithms covered by the article.

Namir

      
Re: Numerical Integration
Message #2 Posted by Allen on 22 Nov 2011, 7:56 a.m.,
in response to message #1 by Namir

Thank you for the interesting article! You are the quintessential quadrature expert.

            
Re: Numerical Integration
Message #3 Posted by Namir on 22 Nov 2011, 8:07 a.m.,
in response to message #2 by Allen

Glad you enjoyed the article. I was just asking some basic questions about numerical integration.

Namir

            
Re: Numerical Integration
Message #4 Posted by Namir on 22 Nov 2011, 9:27 a.m.,
in response to message #2 by Allen

I updated the article to correct a mistake and clarify a few things.

Namir

      
Re: Numerical Integration
Message #5 Posted by Mike Morrow on 22 Nov 2011, 7:37 p.m.,
in response to message #1 by Namir

How does it compare to Gauss-Kronrod quadrature? The implementation of G-K quadrature on the fx-115/991ES seems to give much better and faster results than the quadrature methods of the various HP calculators, including the HP 50g and my beloved HP 42S.

            
Re: Numerical Integration
Message #6 Posted by Namir on 22 Nov 2011, 10:59 p.m.,
in response to message #5 by Mike Morrow

The Gauss-Kronrod quadrature is a better method.

      
Re: Numerical Integration
Message #7 Posted by Allen on 22 Nov 2011, 9:57 p.m.,
in response to message #1 by Namir

I wonder if you have considered using something other than the monomial basis for your objective function for your numeric integration??

For example, whether using uniform weighting or individual weights, you can use the method of undetermined coefficients to solve the abscissa locations. For example to find a three point, equal-weighted solution on the following range:

With 4 unknowns, you can just use this equation:

to find +/-inv(sqrt(2)), and 0 are the nodes, with the weight w=2/3.

Any number of weights or points can be calculated this way, but this only uses the monomial basis. With a different (perhaps higher-order?) basis function, Could it be more accurate??

Edited: 22 Nov 2011, 10:07 p.m.

            
Re: Numerical Integration
Message #8 Posted by Namir on 23 Nov 2011, 9:14 a.m.,
in response to message #7 by Allen

I really have not seen any numerical integration algorithm with a single weight. Being a pragmatic person, if you can find a method with a constant weight and it works well, that is fine.

Namir

                  
Re: Numerical Integration
Message #9 Posted by Allen on 23 Nov 2011, 8:37 p.m.,
in response to message #8 by Namir

I was just reading about this method last week. The key is using the monomial basis to actually move the nodes around to compensate for the equal weight. I first heard about Chebyshev Quadrature in the book I am reading. It's simpler numerically than Simpson and a few other methods because you save n-multiplications by factoring out the weighting function from the summation. It's interesting to solve, too.

I hope you all have a Merry Thanksgiving!!


[ Return to Index | Top of Index ]

Go back to the main exhibit hall