Article 5GH6Z More on why simple approximations work

More on why simple approximations work

by
John
from John D. Cook on (#5GH6Z)

A few weeks ago I wrote several blog posts about very simple approximations that are surprisingly accurate. These approximations are valid over a limited range, but with range reduction they can be used over the full range of the functions.

In this post I want to look again at

exppade1.svg

and

logpade1.svg

Pade approximation

It turns out that the approximations above are both Pade approximants [1], rational functions that match the first few terms of the power series of the function being approximated.

First few" means up to degree m + n where m is the degree of the numerator and n is the degree of the denominator. In our examples, m = n = 1, and so the series terms up to order 2 match.

Luck

The approximations I wrote about before were derived by solving for a constant that made the approximation error vanish at the ends of the interval of interest. Note that there's no interval in the definition of a Pade approximant.

Also, the constants that I derived were rounded in order to have something easy to compute mentally. The approximation for log, for example, works out to have a factor of 2.0413, but I rounded it to 2 for convenience.

And yet the end result is exactly was exactly a Pade approximant.

Exp

First let's look at the exponential function. We can see that the series for our approximation and for exp match up to x^2.

exppade3.svg

The error in the Pade approximation for exp is less than the error in the 2nd order power series approximation for all x less than around 0.78.

exppadeplot.svg

Log

Here again we see that our function and our approximation have series that agree up to the x^2 terms.

logpade2.svg

The error in the Pade approximation for log is less than the error in the 2nd order power series approximation for all x

logpadeplot.svg

[1] The other approximations I presented in that series are not Pade approximations.

The post More on why simple approximations work first appeared on John D. Cook.0SHe63R6CA8
External Content
Source RSS or Atom Feed
Feed Location http://feeds.feedburner.com/TheEndeavour?format=xml
Feed Title John D. Cook
Feed Link https://www.johndcook.com/blog
Reply 0 comments