sjut/mat210/interpolation/lagrangian 2013-14s2

11

Click here to load reader

Upload: john-ham

Post on 23-Jun-2015

74 views

Category:

Education


0 download

DESCRIPTION

Lecture notes on Lagrangian Interpolation based on Autar Kaw's textbook and course, http://nm.mathforcollege.com

TRANSCRIPT

Page 1: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

St. John's University of Tanzania

MAT210 NUMERICAL ANALYSIS2013/14 Semester II

INTERPOLATIONLagrangian Interpolation

Kaw, Chapter 5.04

Page 2: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 2 of 11

● Interpolation of functions● Approximating a complex or unknown function

with a simpler function– simpler function usually a polynomial

● Direct Method & Newton Divided Difference● Two approaches for finding the same nth order

polynomial fit for all points in an data set● Lagrangian Inteprolation

● A 3rd way, but based on a weighted average of the function values for points in the data set

Introduction

Page 3: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 3 of 11

General Form

f n(x)=∑i=0

i=n

Li(x ) f (x i)

Li (x)= ∏j=0, j≠i

i=n x−x j

x i−x j

The Lagrange elementary polynomials (Li) are the weights

Page 4: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 4 of 11

Example: Velocity

Page 5: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 5 of 11

Linear

Page 6: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 6 of 11

The Formula

f 1(x )=L0(x) f (x0)+L1(x) f (x1)

L0(x)=x−x1x0−x1

L1(x)=x−x0x1−x0

Notice the sign in the denominator

Page 7: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 7 of 11

Find v(16)

● Two closest points t=15 and t=20

Same as Direct

Page 8: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 8 of 11

Quadratic

Page 9: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 9 of 11

Quadratic v(16) ● Use t=10,15,20 as before

Same as Direct

Page 10: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 10 of 11

The Error is the Error● The equations are the same, just found in

different ways and kept in different forms

|ϵa|=| vquadratic−v linear

vquadratic|

Same as Direct

Page 11: SJUT/Mat210/Interpolation/Lagrangian 2013-14S2

MAT210 2013/14 Sem II 11 of 11

In Conclusion● The methods so far are Polynomial

Interpolation Methods and create one nth degree polynomial for all n points.● Direct: Curve fitting by solving n+1

simultaneous equations● NDD: Can be linked to Taylor Series and is

recursve● Lagrangian: Something a weighted average of

function values based on relative distance from the point of interest