You are on page 1of 4

Taylor Series

A little more math

Earlier I introduced three techniques that use linear extrapolation


• Secant
• Regula-Falsi
• Newton-Raphson

Why “linear extrapolation”?


It is easy to solve a linear function.
Assumption: Most functions can be approximated as linear over small ranges, which is great
since it is easy to find the root of a linear function. Since two of the following methods totally
depend on a linear approximation being reasonable, the behavior of those algorithms can become
quite pathological if the initial guess is too far from the root. Those two are the secant and basic
Newton-Raphson methods. The regula-falsi method has a backup plan when chaos is about to
happen.
Taylor series = polynomial approximation of a function. Depending on how many
terms are taken, the approximation is linear, quadratic, cubic, etc.

For example, a quadratic Taylor series of a function f(x) about the point “ ” is

The general formula for a function f(x) is

Another way of expressing the Taylor series is

Assume you have the value of , but you want the value of .

As an example, let’s approximate a well-known function, f(x) = sin(x).


The first three distinct approximations about x=0 (i.e. a=0 in the formula above) are

C:\W\Whit\Teaching\_Classes\222_Notes\2_NonlinearEquation_4\3a_linearExtrap.docx
Because of the anti-symmetry of the function at x=0, only the odd functions are
non-zero.
Here is a plot of the sine function along with the three approximations.

More terms give more accuracy. However, close to x=0, even a linear approximation is
quite accurate.

As a further example, consider the Taylor series about . At this location, the
function is neither even nor odd, so we have non-zero polynomial approximations of
every order. Here are the approximations up to a cubic approximation.

C:\W\Whit\Teaching\_Classes\222_Notes\2_NonlinearEquation_4\3a_linearExtrap.docx
Now the approximations are very good near .

It is possible to use a higher order Taylor series approximation when searching for roots
of a single nonlinear equation, but it is not convenient. For systems of nonlinear
equations, it is not feasible.
Using linear extrapolation to solve a nonlinear equation

Assume we wish to find the solutions for the equation . Here are the steps.

1) Make an “educated guess” for a solution.


2) Calculate a linear Taylor series expansion about that guess and set it to zero.

3) Solve this linear approximation for the correction to the guess.

C:\W\Whit\Teaching\_Classes\222_Notes\2_NonlinearEquation_4\3a_linearExtrap.docx
4) New guess for the solution (root) is .
5) Repeat steps until the absolute value of the residual is less than the specified
tolerance.
This iterative process can be expressed concisely as

Note that the correction to the current approximate solution is

You will see that the secant, regula-falsi, and Newton-Raphson methods can all be
written in this form. The difference is how the slope is calculated.

C:\W\Whit\Teaching\_Classes\222_Notes\2_NonlinearEquation_4\3a_linearExtrap.docx

You might also like