Tutorial 7: "Parabolic Interpolation"
Tutorial 7: "Parabolic Interpolation"
“Parabolic interpolation”
Instructed by Chhorn Sopheaktra
1. Introduction
Parabolic interpolation is a method that takes advantage of the fact that
a second-order polynomial often provides a good approximation to the shape
of f(x) near an optimum. In this lecture, we will study the concept of
parabolic interpolation and apply its algorithms in Matlab for finding
the optimum point.
2. Basic formula
f(x)
p(x)
x0 x3 x1 x2
Suppose we have three points A, B and C locate on function f(x). Then the
coordinate of each point is A(x0, f(x0)), B(x1,f(x1)) and C(x2,f(x2)). If
we create a second-order p(x)=ax2+bx+c to approximate the function f(x),
the coefficients a and b are given by:
f(x0)= ax02 +bx0 +c
f(x1)= ax12 +bx1 +c
f(x2)= ax22 +bx3 +c
Or
f(x0)(x1 - x2)+f(x1)(x2 - x0) f(x2)(x0 - x1)
a=-
(x2 - x1)(x1 - x0)(x2 - x0)
f(x0)(x21 - x22)+f(x1)(x22 - x20) f(x2)(x20 - x21)
b=
(x2 - x1)(x1 - x0)(x2 - x0)
If x3 is an optimum point of p(x), then we get:
b
p'(x3)=0 or x3
2a
f(x0)(x21 - x22)+f(x1)(x22 - x20) f(x2)(x20 - x21)
x3 =
2f(x0)(x1 - x2)+2f(x1)(x2 - x0)+2f(x2)(x0 - x1)
3. Algorithms
Define function and initial condition for parabolic interpolation
Calculate new estimator ( x3 ) using above equation
If x1>x3 set new interval as:
x2=x1
x1=x3
If x1<x3 set new interval as:
x0=x1
x1=x3
xnew xold
stopping condition a =
xold
4. Practice
Using parabolic section method to find the maximum point of function
2sin(x)-x2/10. We know that the initial points are x1=0, x1=1 and
x2=4. The maximum error must smaller that 0.001%.