Download presentation
Presentation is loading. Please wait.
Published byฮฮตฮฟฯฯฮปฮฑฮบฯฮฟฯ ฮฮฟฮพฮฑฯฮฌฯ Modified over 5 years ago
1
Theory of Approximation: Interpolation
Abhas Singh Department of Civil Engineering IIT Kanpur Acknowledgements: Profs. Saumyen Guha and Shivam Tripathi (CE)
2
Discrete Data (n + 1) observations or data pairs [(x0, y0), (x1, y1), (x2, y2) โฆ (xn, yn)] (m + 1) basis functions: ๐ 0 , ๐ 1 , ๐ 2 ,โฏ ๐ ๐ Approximating polynomial: ๐ ๐ฅ = ๐=0 ๐ ๐ ๐ ๐ ๐ ๐ฅ ๐ 0 ๐ 0 ๐ฅ 0 + ๐ 1 ๐ 1 ๐ฅ 0 + ๐ 2 ๐ 2 ๐ฅ 0 +โฏ+ ๐ ๐ ๐ ๐ ๐ฅ 0 = ๐ฆ 0 ๐ 0 ๐ 0 ๐ฅ 1 + ๐ 1 ๐ 1 ๐ฅ 1 + ๐ 2 ๐ 2 ๐ฅ 1 +โฏ+ ๐ ๐ ๐ ๐ ๐ฅ 1 = ๐ฆ 1 :::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: ๐ 0 ๐ 0 ๐ฅ ๐ + ๐ 1 ๐ 1 ๐ฅ ๐ + ๐ 2 ๐ 2 ๐ฅ ๐ +โฏ+ ๐ ๐ ๐ ๐ ๐ฅ ๐ = ๐ฆ ๐ n equations, m unknowns: m < n: over-determined system, least square regression m = n: unique solution, interpolation m > n: under-determined system
3
Interpolation Polynomials
Newtonโs Divided Difference Lagrange Polynomials Gramโs polynomials (introduced earlier) Spline Interpolation: piecewise continuous, smoothing
4
Newtonโs Divided Difference
For a net of points ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ , formulate a triangular set of basis polynomials ๐ 0 ๐ฅ =1 ๐ 1 ๐ฅ = ๐ฅโ ๐ฅ 0 ๐ 2 ๐ฅ = ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 ๐ 3 ๐ฅ = ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 ๐ฅโ ๐ฅ 2 โฎ โฎ โฎ โฎ ๐ ๐ ๐ฅ = ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐โ1 โฎ โฎ โฎ โฎ ๐ ๐ ๐ฅ = ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ โฏ ๐ฅโ ๐ฅ ๐โ1
5
Newtonโs Divided Difference
Consider a net of points ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ and the corresponding function values as ๐ 0 , ๐ 1 , ๐ 2 ,โฏ ๐ ๐ Newtonโs polynomial is: ๐ ๐ฅ = ๐ 0 + ๐ 1 ๐ฅโ ๐ฅ 0 + ๐ 2 ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 + ๐ 3 ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 ๐ฅโ ๐ฅ 2 โฏ โฏ + ๐ ๐ ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐โ1 True function: ๐ ๐ฅ =๐ ๐ฅ + ๐ ๐+1 ๐ ๐+1 ! ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐ for some ๐โ int ๐ฅ, ๐ฅ 0 , ๐ฅ 1 โฏ ๐ฅ ๐
6
Newtonโs Divided Difference
Newtonโs polynomial with the remainder term: ๐ ๐ฅ = ๐ 0 + ๐ 1 ๐ฅโ ๐ฅ 0 + ๐ 2 ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 + ๐ 3 ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 ๐ฅโ ๐ฅ 2 โฏ โฏ + ๐ ๐ ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐โ1 +๐ ๐ฅ ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐ ๐ ๐ฅ 0 = ๐ 0 = ๐ 0 ; Taking f0 on the LHS and dividing by ๐ฅโ ๐ฅ 0 ๐ ๐ฅ 0 ,๐ฅ = ๐ ๐ฅ โ๐ ๐ฅ 0 ๐ฅโ ๐ฅ 0 = ๐ 1 + ๐ 2 ๐ฅโ ๐ฅ 1 + ๐ 3 ๐ฅโ ๐ฅ 1 ๐ฅโ ๐ฅ 2 โฏ โฏ + ๐ ๐ ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐โ1 +๐ ๐ฅ ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐ ๐ ๐ฅ 0 , ๐ฅ 1 = ๐ 1 โ ๐ 0 ๐ฅ 1 โ ๐ฅ 0 = ๐ 1
7
Newtonโs Divided Difference
๐ ๐ฅ 0 ,๐ฅ = ๐ ๐ฅ โ๐ ๐ฅ 0 ๐ฅโ ๐ฅ 0 = ๐ 1 + ๐ 2 ๐ฅโ ๐ฅ 1 + ๐ 3 ๐ฅโ ๐ฅ 1 ๐ฅโ ๐ฅ 2 โฏ โฏ + ๐ ๐ ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐โ1 +๐ ๐ฅ ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐ Taking ๐ ๐ฅ 0 , ๐ฅ 1 on the LHS and dividing by ๐ฅโ ๐ฅ 1 : ๐ ๐ฅ 0 , ๐ฅ 1 ,๐ฅ = ๐ ๐ฅ 0 ,๐ฅ โ๐ ๐ฅ 0 , ๐ฅ 1 ๐ฅโ ๐ฅ 1 = ๐ 2 + ๐ 3 ๐ฅโ ๐ฅ 2 +โฏ + ๐ ๐ ๐ฅโ ๐ฅ 2 โฏ ๐ฅโ ๐ฅ ๐โ1 +๐ ๐ฅ ๐ฅโ ๐ฅ 2 โฏ ๐ฅโ ๐ฅ ๐ ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 = ๐ ๐ฅ 0 , ๐ฅ 2 โ๐ ๐ฅ 0 , ๐ฅ 1 ๐ฅ 2 โ ๐ฅ 1 = ๐ 2
8
Newtonโs Divided Difference
๐ ๐ฅ 0 , ๐ฅ 1 ,๐ฅ = ๐ ๐ฅ 0 ,๐ฅ โ๐ ๐ฅ 0 , ๐ฅ 1 ๐ฅโ ๐ฅ 1 = ๐ 2 + ๐ 3 ๐ฅโ ๐ฅ 2 +โฏ + ๐ ๐ ๐ฅโ ๐ฅ 2 โฏ ๐ฅโ ๐ฅ ๐โ1 +๐ ๐ฅ ๐ฅโ ๐ฅ 2 โฏ ๐ฅโ ๐ฅ ๐ Taking ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 on the LHS and dividing by ๐ฅโ ๐ฅ 2 : ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,๐ฅ = ๐ ๐ฅ 0 , ๐ฅ 1 ,๐ฅ โ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ๐ฅโ ๐ฅ 2 = ๐ 3 + ๐ 4 ๐ฅโ ๐ฅ 3 +โฏ + ๐ ๐ ๐ฅโ ๐ฅ 3 โฏ ๐ฅโ ๐ฅ ๐โ1 +๐ ๐ฅ ๐ฅโ ๐ฅ 3 โฏ ๐ฅโ ๐ฅ ๐ ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 , ๐ฅ 3 = ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 3 โ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ๐ฅ 3 โ ๐ฅ 2 = ๐ 3
9
Newtonโs Divided Difference
๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ1 ,๐ฅ = ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ2 ,๐ฅ โ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ2 , ๐ฅ ๐โ1 ๐ฅโ ๐ฅ ๐โ1 = ๐ ๐ ๐ ๐+1 ๐ฅโ ๐ฅ ๐ +โฆ+ ๐ ๐ ๐ฅโ ๐ฅ ๐ โฏ ๐ฅโ ๐ฅ ๐โ ๐ ๐ฅ ๐ฅโ ๐ฅ ๐ โฏ ๐ฅโ ๐ฅ ๐ ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ = ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ2 , ๐ฅ ๐ โ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ2 , ๐ฅ ๐โ1 ๐ฅ ๐ โ ๐ฅ ๐โ1 = ๐ ๐ ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ = ๐ ๐ ; ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ ,๐ฅ =๐ ๐ฅ Newtonโs polynomial without the remainder term: ๐ ๐ฅ = ๐ 0 + ๐=1 ๐ ๐ ๐ฅ 0 , ๐ฅ 1 , โฏ ๐ฅ ๐ ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐โ1
10
Recall: Properties of Divided Differences
1st Divided Difference: ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 = ๐ ๐ โ ๐ ๐โ1 ๐ฅ ๐ โ ๐ฅ ๐โ1 = ๐ ๐โ1 โ ๐ ๐ ๐ฅ ๐โ1 โ ๐ฅ ๐ =๐ ๐ฅ ๐โ1 , ๐ฅ ๐ 2nd Divided Difference: ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , ๐ฅ ๐โ2 = ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 โ๐ ๐ฅ ๐โ1 , ๐ฅ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ2 = ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 โ๐ ๐ฅ ๐ , ๐ฅ ๐โ2 ๐ฅ ๐โ1 โ ๐ฅ ๐โ2 = ๐ ๐ฅ ๐ , ๐ฅ ๐โ2 โ๐ ๐ฅ ๐โ1 , ๐ฅ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ1 ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , ๐ฅ ๐โ2 =๐ ๐ฅ ๐โ1 , ๐ฅ ๐ , ๐ฅ ๐โ2 =๐ ๐ฅ ๐โ2 , ๐ฅ ๐โ1 , ๐ฅ ๐ =๐ ๐ฅ ๐ , ๐ฅ ๐โ2 , ๐ฅ ๐โ1
11
Properties of Divided Differences
2nd Divided Difference: ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , ๐ฅ ๐โ2 = ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 โ๐ ๐ฅ ๐โ1 , ๐ฅ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ2 ๐= ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 โ๐ ๐ฅ ๐ , ๐ฅ ๐โ2 ๐ฅ ๐โ1 โ ๐ฅ ๐โ2 = ๐ ๐ โ ๐ ๐โ1 ๐ฅ ๐ โ ๐ฅ ๐โ1 โ ๐ ๐ โ ๐ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ2 ๐ฅ ๐โ1 โ ๐ฅ ๐โ2 = ๐ฅ ๐ ๐ ๐ โ ๐ฅ ๐ ๐ ๐โ1 โ ๐ฅ ๐โ2 ๐ ๐ + ๐ฅ ๐โ2 ๐ ๐โ1 โ ๐ฅ ๐ ๐ ๐ + ๐ฅ ๐ ๐ ๐โ2 + ๐ฅ ๐โ1 ๐ ๐ โ ๐ฅ ๐โ1 ๐ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ1 ๐ฅ ๐โ1 โ ๐ฅ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ2 = ๐ฅ ๐โ1 โ ๐ฅ ๐โ2 ๐ ๐ โ ๐ฅ ๐โ1 โ ๐ฅ ๐โ2 ๐ ๐โ1 โ ๐ฅ ๐ โ ๐ฅ ๐โ1 ๐ ๐โ1 + ๐ฅ ๐ โ ๐ฅ ๐โ1 ๐ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ1 ๐ฅ ๐โ1 โ ๐ฅ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ2 = ๐ ๐ โ ๐ ๐โ1 ๐ฅ ๐ โ ๐ฅ ๐โ1 โ ๐ ๐โ1 โ ๐ ๐โ2 ๐ฅ ๐โ1 โ ๐ฅ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ2 = ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 โ๐ ๐ฅ ๐โ1 , ๐ฅ ๐โ2 ๐ฅ ๐ โ ๐ฅ ๐โ2 =๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , ๐ฅ ๐โ2 + ๐ฅ ๐โ1 ๐ ๐โ1 โ ๐ฅ ๐โ1 ๐ ๐โ1
12
Newtonโs Divided Difference
Recursion Formula for Divided Difference: (Recall: discussion during Mullerโs method) The order of the points within the divided difference is immaterial. To see it generally, consider this: ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐ ,๐ฅ = ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ1 ,๐ฅ โ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ1 , ๐ฅ ๐ ๐ฅโ ๐ฅ ๐ For generalization: replace the index zero with (i + 1) evaluate the divided difference at x = xi ๐ ๐ฅ ๐+1 , ๐ฅ ๐+2 ,โฆ ๐ฅ ๐ , ๐ฅ ๐ = ๐ ๐ฅ ๐+1 , ๐ฅ ๐+2 ,โฆ ๐ฅ ๐โ1 , ๐ฅ ๐ โ๐ ๐ฅ ๐+1 , ๐ฅ ๐+2 ,โฆ ๐ฅ ๐โ1 , ๐ฅ ๐ ๐ฅ ๐ โ ๐ฅ ๐ ๐ ๐ฅ ๐ , ๐ฅ ๐+1 , โฆ ๐ฅ ๐ = ๐ ๐ฅ ๐ , ๐ฅ ๐+1 , โฆ ๐ฅ ๐โ1 โ๐ ๐ฅ ๐+1 ,โฆ ๐ฅ ๐โ1 , ๐ฅ ๐ ๐ฅ ๐ โ ๐ฅ ๐
13
Newtonโs Divided Difference
๐ ๐ฅ ๐ , ๐ฅ ๐+1 , โฆ ๐ฅ ๐ = ๐ ๐ฅ ๐ , ๐ฅ ๐+1 , โฆ ๐ฅ ๐โ1 โ๐ ๐ฅ ๐+1 ,โฆ ๐ฅ ๐โ1 , ๐ฅ ๐ ๐ฅ ๐ โ ๐ฅ ๐ = ๐ ๐ฅ ๐+1 ,โฆ ๐ฅ ๐โ1 , ๐ฅ ๐ โ๐ ๐ฅ ๐ , ๐ฅ ๐+1 , โฆ ๐ฅ ๐โ ๐ฅ ๐ โ๐ฅ ๐ Or by reversing the order of x variables, ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , โฆ ๐ฅ ๐ = ๐ ๐ฅ ๐โ1 ,โฆ ๐ฅ ๐+1 , ๐ฅ ๐ โ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , โฆ ๐ฅ ๐ ๐ฅ ๐ โ ๐ฅ ๐ = ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , โฆ ๐ฅ ๐+1 โ๐ ๐ฅ ๐โ1 ,โฆ ๐ฅ ๐+1 , ๐ฅ ๐ ๐ฅ ๐ โ๐ฅ ๐
14
Newtonโs Divided Difference
Examples: ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , โฆ ๐ฅ ๐ = ๐ ๐ฅ ๐ , ๐ฅ ๐โ1 , โฆ ๐ฅ ๐+1 โ๐ ๐ฅ ๐โ1 ,โฆ ๐ฅ ๐+1 , ๐ฅ ๐ ๐ฅ ๐ โ๐ฅ ๐ ๐=1, ๐=0:๐ ๐ฅ 1 , ๐ฅ 0 = ๐ ๐ฅ 1 โ๐ ๐ฅ ๐ฅ 1 โ๐ฅ 0 ๐=2, ๐=1:๐ ๐ฅ 2 , ๐ฅ 1 = ๐ ๐ฅ 2 โ๐ ๐ฅ ๐ฅ 2 โ๐ฅ 1 ๐=2, ๐=0:๐ ๐ฅ 2 , ๐ฅ 1 , ๐ฅ 0 = ๐ ๐ฅ 2 , ๐ฅ 1 โ๐ ๐ฅ 1 , ๐ฅ ๐ฅ 2 โ๐ฅ 0 ๐=3, ๐=1:๐ ๐ฅ 3 , ๐ฅ 2 , ๐ฅ 1 = ๐ ๐ฅ 3 , ๐ฅ 2 โ๐ ๐ฅ 2 , ๐ฅ ๐ฅ 3 โ๐ฅ 1 ๐=3, ๐=0:๐ ๐ฅ 3 , ๐ฅ 2 , ๐ฅ 1 , ๐ฅ 0 = ๐ ๐ฅ 3 , ๐ฅ 2 , ๐ฅ 1 โ๐ ๐ฅ 2 , ๐ฅ 1 , ๐ฅ ๐ฅ 3 โ๐ฅ 0
15
Newtonโs Divided Difference:Example
x0 , f(x0) f[x1, x0] f[x2, x1, x0] f[x3, x2, x1, x0] x1 , f(x1) f[x2, x1] f[x3, x2, x1] x2 , f(x2) f[x3, x2] x3 , f(x3) p(x) = f(x0) + f[x1, x0](x - x0) + f[x2, x1, x0](x - x0)(x โ x1) + f[x3, x2, x1, x0](x - x0)(x โ x1)(x โ x2)
16
Newtonโs Divided Difference: Example
1 , -48 2 9 2 2 , -46 29 17 4, 12 80 5 , 92 ๐ ๐ฅ =โ ๐ฅโ ๐ฅโ1 ๐ฅโ ๐ฅโ1 ๐ฅโ2 ๐ฅโ4 =2 ๐ฅ 3 โ5 ๐ฅ 2 +3๐ฅโ48 p(x) = f(x0) + f[x1, x0](x - x0) + f[x2, x1, x0](x - x0)(x โ x1) + f[x3, x2, x1, x0](x - x0)(x โ x1)(x โ x2)
17
Newtonโs Divided Difference: Error Estimate
Recall the Newtonโs polynomial with the remainder: ๐ ๐ฅ =๐ ๐ฅ + ๐ ๐+1 ๐ ๐+1 ! ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐ for some ๐โ int ๐ฅ, ๐ฅ 0 , ๐ฅ 1 โฏ ๐ฅ ๐ ๐ ๐ฅ =๐ ๐ฅ +๐ ๐ฅ ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐ We derived: ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ ,๐ฅ =๐ ๐ฅ If an extra-data {xn+1, f(xn+1)} is available, it is possible to make an approximate estimate of the error as: ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ , ๐ฅ ๐+1 =๐ ๐ฅ ๐+1 โ๐ ๐ฅ and the error (E) as: ๐ธโ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ , ๐ฅ ๐+1 ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐
18
Newtonโs Divided Difference
๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ1 ,๐ฅ = ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ2 ,๐ฅ โ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ2 , ๐ฅ ๐โ1 ๐ฅโ ๐ฅ ๐โ1 = ๐ ๐ ๐ ๐+1 ๐ฅโ ๐ฅ ๐ +โฆ+ ๐ ๐ ๐ฅโ ๐ฅ ๐ โฏ ๐ฅโ ๐ฅ ๐โ ๐ ๐ฅ ๐ฅโ ๐ฅ ๐ โฏ ๐ฅโ ๐ฅ ๐ ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ = ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ2 , ๐ฅ ๐ โ๐ ๐ฅ 0 , ๐ฅ 1 ,โฆ ๐ฅ ๐โ2 , ๐ฅ ๐โ1 ๐ฅ ๐ โ ๐ฅ ๐โ1 = ๐ ๐ ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ = ๐ ๐ ; ๐ ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ ,๐ฅ =๐ ๐ฅ Newtonโs polynomial without the remainder term: ๐ ๐ฅ = ๐ 0 + ๐=1 ๐ ๐ ๐ฅ 0 , ๐ฅ 1 , โฏ ๐ฅ ๐ ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 โฏ ๐ฅโ ๐ฅ ๐โ1
19
Lagrange Polynomials Unit linear polynomials for two nodes: ๐ฅ 0 , ๐ฅ 1 ๐ฟ 0 ๐ฅ = ๐ฅโ ๐ฅ 1 ๐ฅ 0 โ ๐ฅ 1 ; ๐ฟ 1 ๐ฅ = ๐ฅโ ๐ฅ 0 ๐ฅ 1 โ ๐ฅ 0 Unit quadratic for three nodes: ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ๐ฟ 0 ๐ฅ = ๐ฅโ ๐ฅ 1 ๐ฅโ ๐ฅ 2 ๐ฅ 0 โ ๐ฅ 1 ๐ฅ 0 โ ๐ฅ 2 ; ๐ฟ 1 ๐ฅ = ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 2 ๐ฅ 1 โ ๐ฅ 0 ๐ฅ 1 โ ๐ฅ 2 ๐ฟ 2 ๐ฅ = ๐ฅโ ๐ฅ 0 ๐ฅโ ๐ฅ 1 ๐ฅ 2 โ ๐ฅ 0 ๐ฅ 2 โ ๐ฅ 1 Polynomials of order n for the mesh of nodes ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ ๐ฟ ๐ ๐ฅ = ๐=0 ๐โ ๐ ๐ ๐ฅโ ๐ฅ ๐ ๐ฅ ๐ โ ๐ฅ ๐ ๐ฟ ๐ ๐ฅ ๐ = 0 ๐๐๐ ๐โ ๐ 1 ๐๐๐ ๐=๐
20
Lagrange Polynomials Polynomials to be fitted to a mesh of nodes ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ and the corresponding function values as ๐ 0 , ๐ 1 , ๐ 2 ,โฏ ๐ ๐ Lagrange polynomial is: ๐ ๐ฅ = ๐=0 ๐ ๐ ๐ ๐ฟ ๐ ๐ฅ ๐ฟ ๐ ๐ฅ = ๐=0 ๐โ ๐ ๐ ๐ฅโ ๐ฅ ๐ ๐ฅ ๐ โ ๐ฅ ๐
21
Lagrange Polynomials: Linear
22
Lagrange Polynomials: Quadratic
23
Lagrange Polynomials Polynomials to be fitted to a mesh of nodes ๐ฅ 0 , ๐ฅ 1 , ๐ฅ 2 ,โฏ ๐ฅ ๐ and the corresponding function values as ๐ 0 , ๐ 1 , ๐ 2 ,โฏ ๐ ๐ Lagrange polynomial is: ๐ ๐ฅ = ๐=0 ๐ ๐ ๐ ๐ฟ ๐ ๐ฅ ๐ฟ ๐ ๐ฅ = ๐=0 ๐โ ๐ ๐ ๐ฅโ ๐ฅ ๐ ๐ฅ ๐ โ ๐ฅ ๐
24
Lagrange Polynomial: Example
Write the cubic polynomial using Lagrange polynomials that passes through the following four points: (1 , -48), (2 , -46), (4, 12), (5 , 92)? ๐ ๐ฅ = โ48 ๐ฅโ2 ๐ฅโ4 ๐ฅโ5 1โ2 1โ4 1โ5 + โ46 ๐ฅโ1 ๐ฅโ4 ๐ฅโ5 2โ1 2โ4 2โ ๐ฅโ1 ๐ฅโ2 ๐ฅโ5 4โ1 4โ2 4โ ๐ฅโ1 ๐ฅโ2 ๐ฅโ4 5โ1 5โ2 5โ4 =4 ๐ฅโ2 ๐ฅโ4 ๐ฅโ5 โ ๐ฅโ1 ๐ฅโ4 ๐ฅโ5 โ2 ๐ฅโ1 ๐ฅโ2 ๐ฅโ ๐ฅโ1 ๐ฅโ2 ๐ฅโ4 =2 ๐ฅ 3 โ5 ๐ฅ 2 +3๐ฅโ48 Recall Newtonโs polynomial through the same set of points: ๐ ๐ฅ =โ48+2 ๐ฅโ1 +9 ๐ฅโ1 ๐ฅโ2 +2 ๐ฅโ1 ๐ฅโ2 ๐ฅโ4 =2 ๐ฅ 3 โ5 ๐ฅ 2 +3๐ฅโ48
25
Example Fit Fit an interpolation polynomial through the following four points: (1 , -48), (2 , -46), (4, 12), (5 , 92) ๐ ๐ฅ =2 ๐ฅ 3 โ5 ๐ฅ 2 +3๐ฅโ48
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.