0% found this document useful (0 votes)
21 views20 pages

CVNG1010 P2.2a

This document provides an overview of interpolation methods that will be covered in the CVNG 1010 IT for Engineers course. It introduces interpolation as estimating values between data points and describes how polynomials can be used to interpolate data. Specifically, it discusses Newton's divided difference method for interpolating data using linear, quadratic, and general nth order polynomials. Examples are provided to demonstrate estimating values using linear and quadratic interpolation and calculating coefficients for polynomials. The document outlines the learning objectives for students which include describing interpolation functions and using Newton's divided difference and Lagrange methods to interpolate data.

Uploaded by

Ellesha Jackson
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
21 views20 pages

CVNG1010 P2.2a

This document provides an overview of interpolation methods that will be covered in the CVNG 1010 IT for Engineers course. It introduces interpolation as estimating values between data points and describes how polynomials can be used to interpolate data. Specifically, it discusses Newton's divided difference method for interpolating data using linear, quadratic, and general nth order polynomials. Examples are provided to demonstrate estimating values using linear and quadratic interpolation and calculating coefficients for polynomials. The document outlines the learning objectives for students which include describing interpolation functions and using Newton's divided difference and Lagrange methods to interpolate data.

Uploaded by

Ellesha Jackson
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

CVNG 1010 |

University of the
West Indies
St. Augustine

CVNG 1010
IT FOR ENGINEERS

Dr. Jovanca Smith


Lecturer
Department of Civil and Environmental Engineering
University of the West Indies
St. Augustine

1
CVNG 1010 |
University of the
West Indies
St. Augustine

At the end of this session students will be able to:

1. Describe the purpose of interpolating functions

2. Use the Newton’s Divided Difference to interpolate


functions

3. Use the Lagrange Interpolating Polynomial method to


interpolate functions

4. Solve coefficients of interpolating polynomials using


simultaneous equations
2
CVNG 1010 |
University of the
West Indies
St. Augustine

Interpolation

A method used to estimate intermediate values between


precise data points.

There are numerous methods used in numerical


modeling to interpolate data points.

For a given polynomial f(x) = a0 + a1x + a2x2 + …+ anxn


with n+1 data points, there is only 1 polynomial of order
n that passes through all the points.

3
CVNG 1010 |
University of the
West Indies
St. Augustine

Interpolation
There is only one first order polynomial (straight line)
that connects 2 points. Likewise, there is only one
parabola that connects a set of three points.

In polynomial interpolation, one must determine the


unique nth order polynomial that fits n + 1 data
points.

1st order 2nd order 3rd order 4


CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

First order: Linear Interpolation


Simplest form of the interpolation. Two data points are
connected with a straight line.
From similar triangles

Also, (𝑓 𝑥! − 𝑓 𝑥" ) / 𝑥! − 𝑥"


is a finite divided difference approximation
of the first derivative in addition to
representing the slope connecting points 5
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

First order: Linear Interpolation

EXAMPLE 1
Estimate the natural logarithm of 2 using linear
interpolation. First, perform the computation by
interpolating between ln 1 = 0 to ln 6 = 1.791759. Then
repeat the procedure, but use a smaller interval from ln 1
to ln 4 = 1.386294. The true value of ln 2 is 0.6931472.

6
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

First order: Linear Interpolation

EXAMPLE

33.3% error

48.3% error

7
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

Quadratic Interpolation
Introducing some curvature can reduce the error of
using a linear function. With 3 available data points this
is accomplished with a second order polynomial.

Multiply terms

In parabolic form

where

8
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

Quadratic Interpolation
To determine the values of the coefficients substitute x = x0 into the equation

Substitute b0 into the equation for x = x1


As with linear interpolation, b1
still represents the slope of
the line connection x0 and x1.

Finally, substitute b0 and b1 into the equation for x = x2

9
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

Quadratic Interpolation

EXAMPLE 2: Repeat example 1 using the quadratic


interpolation.

18.4% error
33.3% error

10
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

General Form

The analysis can be generalized to fit a nth order


polynomial to n + 1 data points.

Data points are used to


evaluate the coefficients

11
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

General Form

The bracketed functions evaluations are finite divided


differences.
First finite divided difference

Second finite divided difference

nth finite
divided
difference
12
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

General Form

Newton’s divided-difference interpolating polynomial.

Note:
§ Data points need not be equally spaced
§ Abscissa (x coordinate) values need not be in ascending order
§ Higher order differences are computed by taking differences of lower-order
differences

13
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

General Form

Table shows the recursive nature (higher order


differences computed by taking differences of lower
order differences) of the finite divided differences.

14
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

General Form
EXAMPLE 3: Repeat example 2 adding a fourth point, x3
= 5 and f(x3) = 1.609438 using the third order Newton’s
interpolating polynomial.

9.3% error

15
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials


In class assignment:
Estimate the natural logarithm of 2 using linear interpolation. The following
points are provided: ln 1 = 0, ln 4 = 1.386294 , ln 6 = 1.791759, ln 5 =
1.609438.

16
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

Errors

Like the Taylor Series Expansion, the finite divided


difference terms are added sequentially to capture the
higher-order behavior of the underlying function.

These terms represent approximations of the higher-


order derivatives. Hence, for a nth order polynomial
with n+1 data points, a nth order interpolating
polynomial will give the exact results.
17
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

Errors
The truncation error is given as

Since the unknown value f(x) is part of the equation, it cannot be used to solve
for the error.

If another data point f(xn+1) is available, the equation can be used to estimate the
error

18
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

Truncation Errors
EXAMPLE 4: Estimate the error for the second-order
polynomial interpolation using the data point x3 = 5 and
f(x3) = 1.609438.

Without knowing the true value we can estimate the error.


Error is the same order of magnitude as the true error.
19
CVNG 1010 |
University of the
West Indies
St. Augustine

Newton’s Divided Difference Interpolating Polynomials

Truncation Errors
The example shows the error estimate of the nth order
polynomial is equivalent to the differences between the
(n+1)th order and the nth order.
The error represents a future
Validity of this prediction minus a present
approach based on prediction. For a rapidly
the fact that the convergent series the
series is strongly estimate can be less than
convergent the true error.

Higher order interpolating polynomials are ill conditioned (highly sensitive to


errors)
20

You might also like