(1)
In fitting an entire region, the only function that can be fitted by an arbitrarily large polynomial is a polynomial, but see LagPoly.doc - _lag_int_error .htm. This is the simplest approximating function and one that many others relate to. Its derivatives are easy
(2)
The integrals are also very easy
(3)
Polynomials are frequently re-summed as orthogonal polynomials. These are usually orthogonal over some reasonable range, with a weighting function.
The Tchebyshev polynomials are particularly interesting.
The Tchebyshev polynomial has the property that it is always less than or equal to 1.
so that
This means that the in the expansion.
the error in approximating the function is approximately equal the last term dropped. A good rule of thumb is to assume that it is less than the last term held. There is a sub industry called Chebyshev economization in which a polynomial expansion is made about xi which is more accurate than needed near xi in order to maximize its range. It is then re-expanded as the above. The coefficients larger than those needed for the desired accuracy are dropped. Then the series is rewritten as a lower order polynomial.
The expansion in Laguerre Polynomials begins with the orthogonality relation
(4)
The first 6 of these are
(5)
And z in terms of these is
(6)
These are closely related to Slater type functions
These are cubic polynomials with discontinuities in the third derivative.
Define
(7)
A linear spline is the smoothest possible function going through a set of data points.
(8)
A cubic spline can be defined as
(9)
With c1=1 and x1 this is
33
The cubic spline is the function representing the data with the smoothest possible second derivatives.[1][2] For pictures and more details see ../ligo/nlfit/stanfita.htm#Splines
In addition splines can be made to do as they are told. My favorite spline is
(10)
This function is exactly zero for x > 0 and exactly 1 for x < -1
..\ligo\class2K\amoeba\spline.htm
These are almost magic in that the poles in the denominator allow very close approximation to many functions of physical interest. They can also be extremely frustating due to these poles in the denominator.
(11)
As xè0 ,
while as xèinfinity
The book is full of quasi-theorems, quasi-corollaries and such. The fact is that the denominator introduces poles in the imaginary plane. This in principle allows the function to represent functions of physical interest extremely well. It has been used to deduce phase changes by setting the upper limit to the gas region and the lower to the crystal. In the case of Helium this reduced the chi-square by two orders of magnitude.
(12)
These have the advantage that they can be analytically integrated over r1,r2, r12 when they are used to approximate wave functions.
(13)
open(1,file='bump.out')
h=.01
do i=1,300
x=-1.5+(i-.5)*h
sp=0
if(x.lt.1.and.x.gt.-1)sp=((1-x)*(1+x))**3
write(1,*)x,sp
enddo
end
This one has the advantage that it is exactly zero for x>1 and for x<-1.
Phase corrected
The “Fast Fourier Transform” makes it possible to make fits with these far faster than with any other functions.
The data look like a Fermi function. Try the form
Eqn 1
[1] J. C. Hollady, "A Smoothest Curve Approximation", Math. Tables and Aids to Computation, 11, 233-243 (1957)
[2] J. H.
Ahlberg, E. N. Nilson and J.E. Walsh, The
Theory of Splines and Their Applications.
[3] G. A. Baker, Pade Approximants, Cambridge University Press QC20.7.P3 B35 1996 -- not checked out