Professional Documents
Culture Documents
Linear Algebra, Numerical and Complex Analysis
Linear Algebra, Numerical and Complex Analysis
MA11004
SECTIONS 1 and 2
Dr. Jitendra Kumar
Professor
Department of Mathematics
Indian Institute of Technology Kharagpur
West Bengal 721302, India
Webpage: http://www.facweb.iitkgp.ac.in/~jkumar/
Polynomial Interpolation
Polynomial Interpolation
Interpolation is a process of estimating values between known data points or approximating complicated
functions by simple polynomials or determining a polynomial that fits a set of given points.
Applications :
1. Constructing the function when it is not given explicitly and only the values of function are given at
some points.
Suppose that 𝑓 is defined and continuous on [𝑎, 𝑏]. For each 𝜖 > 0, there exists a
𝑓 𝑥 −𝑃 𝑥 < 𝜖; ∀ 𝑥 ∈ 𝑎, 𝑏 .
Taylor’s polynomials agree as closely as possible with a given function at a specific point,
so they concentrate their accuracy near that point.
For ordinary computation purposes it is more efficient to use methods that include
information at various points.
Dr. Jitendra Kumar – IIT KHARAGPUR 5
Existence and uniqueness for polynomial interpolation
For (𝑛 + 1) data points there is one and only one polynomial of order ≤ 𝑛 that passes through all the points.
For example, there is only one straight line (a first order polynomial) that passes through two points.
𝑓 𝑥 = 𝑎0 + 𝑎1 𝑥 + 𝑎2 𝑥 2
If the given polynomial passes through the given data points then it must satisfy them, i.e.,
𝑓 𝑥0 = 𝑎0 + 𝑎1 𝑥0 + 𝑎2 𝑥02
1 𝑥0 𝑥02 𝑎0 𝑓(𝑥0 )
𝑓 𝑥1 = 𝑎0 + 𝑎1 𝑥1 + 𝑎2 𝑥12 ⟺ 1 𝑥1 𝑥12 𝑎1 = 𝑓(𝑥1 )
1 𝑥2 𝑥22 𝑎2 𝑓(𝑥2 )
𝑓 𝑥2 = 𝑎0 + 𝑎1 𝑥2 + 𝑎2 𝑥22
1 𝑥0 𝑥02
Det 1 𝑥1 𝑥12 = (𝑥0 − 𝑥1 )(𝑥1 − 𝑥2 )(𝑥2 − 𝑥0 ) ≠ 0 if 𝑥0 , 𝑥1 , 𝑥2 are distinct.
1 𝑥2 𝑥22
Whether they are solved with an elimination method or with a more efficient algorithm,
the resulting coefficient can be highly inaccurate, in particular for, large 𝑛.
Let 𝑥0 , 𝑥1 , … , 𝑥𝑛 be (𝑛 + 1) points and let 𝑥 be a point belonging to the domain of a given function 𝑓.
Assume that 𝑓 ∈ 𝐶 𝑛+1 𝐼𝑥 , where 𝐼𝑥 is the smallest interval containing the nodes 𝑥0 , 𝑥1 , … , 𝑥𝑛 and 𝑥.
𝜉 𝑓 𝑛+1
𝐸𝑛 𝑥 = 𝑓 𝑥 − 𝑃𝑛 𝑥 = 𝑥 − 𝑥0 𝑥 − 𝑥1 ⋯ (𝑥 − 𝑥𝑛 ) where 𝜉 ∈ 𝐼𝑥 .
𝑛+1 !
𝑓 𝑛+1𝜉
𝐸𝑛 𝑥 = 𝑓 𝑥 − 𝑃𝑛 𝑥 = 𝑥 − 𝑥0 𝑥 − 𝑥1 ⋯ (𝑥 − 𝑥𝑛 ) where 𝜉 ∈ 𝐼𝑥 .
𝑛+1 !
Proof : Note that the result is obviously true if 𝑥 coincides with any of the interpolating nodes.
𝑤𝑛+1 𝑡 𝐸𝑛 𝑥
𝐺 𝑡 = 𝐸𝑛 𝑡 − ; 𝑡 ∈ 𝐼𝑥
𝑤𝑛+1 𝑥
𝑤𝑛+1 𝑥𝑖 𝐸𝑛 𝑥
𝐺 𝑥𝑖 = 𝐸𝑛 𝑥𝑖 − = 0; 𝑖 = 0, 1, 2, … , 𝑛.
𝑤𝑛+1 𝑥
𝑤𝑛+1 𝑥 𝐸𝑛 𝑥
𝐺 𝑥 = 𝐸𝑛 𝑥 − =0
𝑤𝑛+1 𝑥
𝑛+1 𝑛+1
⇒𝐺 has atleast one zero, which we denote by 𝜉, i.e., 𝐺 𝜉 =0
𝑛+1
𝑛+1 (𝑛+1) 𝑤𝑛+1 𝑡 𝐸𝑛 𝑥
⟹𝐺 𝑡 = 𝐸𝑛 𝑡 −
𝑤𝑛+1 𝑥
𝑛+1 𝑛+1
𝑤𝑛+1 𝑡 = 𝑛+1 ! & 𝐺 𝜉 =0
𝑛+1
𝑛 + 1 ! 𝐸𝑛 (𝑥) 𝑓 𝑛+1 𝜉
⟹ 0=𝑓 𝜉 − ⟹ 𝐸𝑛 𝑥 = 𝑤 (𝑥)
𝑤𝑛+1 (𝑥) 𝑛 + 1 ! 𝑛+1
Polynomial Interpolation
Polynomial interpolation is the method of determining a polynomial that fits a set of given points
Although there is a unique 𝑛th order polynomial that fits (𝑛 + 1) data points, there are a variety of
ℎ ℎ
The Central difference operator: 𝛿𝑓 𝑥𝑖 = 𝑓 𝑥𝑖 + − 𝑓 𝑥𝑖 −
2 2
ℎ
Let 𝑓𝑖 = 𝑓 𝑥𝑖 𝑓𝑖+1 = 𝑓 𝑥𝑖 + ℎ 𝑓 1 = 𝑓 𝑥𝑖 +
𝑖+2 2
∆𝑓𝑖 = 𝛻𝑓𝑖+1 = 𝛿𝑓 1
𝑖+2
𝛻 ≡ 1 − 𝐸 −1 𝛻𝑓𝑖 = 𝑓𝑖 − 𝐸 −1 𝑓𝑖
1 1 1 1
− −2
𝛿 ≡𝐸 −𝐸2 2 𝛿𝑓𝑖 = 𝐸 2 𝑓𝑖 −𝐸 𝑓𝑖
∆2 𝑓 𝑥𝑖 = ∆ ∆𝑓 𝑥𝑖
= ∆ 𝑓𝑖+1 − 𝑓𝑖
= 𝑓𝑖+2 − 2𝑓𝑖+1 + 𝑓𝑖
= 𝑓𝑖 − 2𝑓𝑖−1 + 𝑓𝑖−2
𝑥0 𝑓0 𝑥0 𝑓0 𝛻𝑓1
∆𝑓0 2
∆ 𝑓0 𝛻 2 𝑓2
𝑥1 𝑓1 ∆3 𝑓0 𝑥1 𝑓1 𝛻 3 𝑓3
∆𝑓1 𝛻𝑓2
∆2 𝑓1 𝛻 2 𝑓3
𝑥2 𝑓2 𝑥2 𝑓2 𝛻𝑓3
∆𝑓2
𝑥3 𝑓3 𝑥3 𝑓3
∆3 𝑓𝑖 = ∆2 𝑓𝑖+1 − ∆2 𝑓𝑖 𝛻 3 𝑓𝑖 = 𝛻 2 𝑓𝑖 − 𝛻 2 𝑓𝑖−1
2
𝑥 𝑓(𝑥) ∆Τ𝛻 ∆2 Τ𝛻
Δ𝑓0 = 1 Δ2 𝑓0 = −2
0 1
1
1 2 −2
−1
2 1 𝛻𝑓2 = −1 𝛻 2 𝑓2 = −2
1. Linear Interpolation : The simplest way to connect two data points with a straight line.
Given that : 𝑥0 𝑥1
approximating
𝑓 𝑥0 𝑓 𝑥1 polynomial
𝑃1 𝑥1 = 𝑓 𝑥1 = 𝑏0 + 𝑏1 𝑥1 − 𝑥0
𝑥0 𝑥1
𝑓 𝑥1 − 𝑓(𝑥0 )
⇒ 𝑏1 =
𝑥1 − 𝑥0
𝑏0 = 𝑓 𝑥0
𝑓 𝑥1 − 𝑓(𝑥0 )
𝑏1 =
𝑥1 − 𝑥0
𝑓 𝑥0 + ℎ − 𝑓(𝑥0 ) ∆𝑓0
𝑏1 = =
ℎ ℎ
∆𝑓0
Interpolating Polynomial 𝑃1 𝑥 = 𝑓 𝑥0 + (𝑥 − 𝑥0 )
ℎ
𝑥0 𝑥1 𝑥2
Suppose 3 data points are given:
𝑓 𝑥0 𝑓 𝑥1 𝑓 𝑥2
𝑃2 𝑥 = 𝑏0 + 𝑏1 𝑥 − 𝑥0 + 𝑏2 𝑥 − 𝑥0 𝑥 − 𝑥1
𝑓 𝑥1 − 𝑓(𝑥0 )
At the point 𝑥 = 𝑥1 : 𝑏1 =
𝑥1 − 𝑥0
∆𝑓0
In the case of equidistant data points : 𝑏1 =
ℎ
Δ𝑓0
At the point 𝑥 = 𝑥2 : 𝑓 𝑥2 = 𝑓 𝑥0 + 𝑥2 − 𝑥0 + 𝑏2 𝑥2 − 𝑥0 𝑥2 − 𝑥1
ℎ
⇒ 𝑓 𝑥2 = 𝑓 𝑥0 + 2𝑓 𝑥1 − 2𝑓 𝑥0 + 2! ℎ2 𝑏2
𝑓 𝑥2 − 2𝑓 𝑥1 + 𝑓(𝑥0 ) ∆2 𝑓0
⇒ = 𝑏2 ⇒ 𝑏2 =
2! ℎ2 2! ℎ2
Interpolating polynomial :
∆𝑓0 ∆2 𝑓0
𝑃2 𝑥 = 𝑓 𝑥0 + 𝑥 − 𝑥0 + (𝑥 − 𝑥0 )(𝑥 − 𝑥1 )
ℎ 2! ℎ2
Generalized Formula :
We can now write the Newton’s forward difference formula based on (𝑛 + 1) nodal points 𝑥0 , 𝑥1 , … , 𝑥𝑛 as:
∆𝑓0 ∆2 𝑓0 ∆𝑛 𝑓0
𝑃𝑛 𝑥 = 𝑓 𝑥0 + 𝑥 − 𝑥0 + 𝑥 − 𝑥0 𝑥 − 𝑥1 2
+ ⋯ + 𝑥 − 𝑥0 𝑥 − 𝑥1 𝑥 − 𝑥𝑛−1
ℎ 2! ℎ 𝑛! ℎ𝑛
𝑥 − 𝑥0
If we put = 𝑢 then it takes the following form:
ℎ
𝑥 − 𝑥0
𝑓 𝑥 = 𝑓 𝑥0 + ℎ = 𝑓 𝑥0 + 𝑢ℎ
ℎ
= 𝐸 𝑢 𝑓 𝑥0
= 1 + ∆ 𝑢 𝑓 𝑥0
Neglecting the difference ∆𝑛+1 𝑓0 and higher order differences , we get the above generalized
formula.
𝑥 − 𝑥𝑛
𝑓 𝑥 = 𝑓 𝑥𝑛 + ℎ = 𝑓 𝑥𝑛 + ℎ𝑢 = 𝐸 𝑢 𝑓 𝑥𝑛 = 1 − 𝛻 −𝑢 𝑓 𝑥𝑛 𝛻 ≡ 1 − 𝐸 −1
ℎ
Neglecting the difference 𝛻 𝑛+1 𝑓(𝑥𝑛 ) and higher order differences, we get:
∆𝑓0 ∆2 𝑓0 ∆𝑛 𝑓0
𝑃𝑛 𝑥 = 𝑓 𝑥0 + 𝑥 − 𝑥0 + 𝑥 − 𝑥0 𝑥 − 𝑥1 + ⋯ + 𝑥 − 𝑥0 𝑥 − 𝑥1 𝑥 − 𝑥𝑛−1
ℎ 2! ℎ2 𝑛! ℎ𝑛
𝛻𝑓𝑛 𝛻 2 𝑓𝑛
𝑃𝑛 𝑥 = 𝑓𝑛 + 𝑥 − 𝑥𝑛 + 𝑥 − 𝑥𝑛 𝑥 − 𝑥𝑛−1 2
+⋯
ℎ 2! ℎ
𝛻 𝑛 𝑓𝑛
+ 𝑥 − 𝑥𝑛 𝑥 − 𝑥𝑛−1 … 𝑥 − 𝑥1
𝑛! ℎ𝑛
𝑥 0 1 2
𝑓(𝑥) 1 2 1
0 1
1 −2
1 2
−1
2 1
0 1
(𝑥 − 𝑥0 ) (𝑥 − 𝑥0 )(𝑥 − 𝑥1 ) 2 1 −2
1 2
𝑃2 𝑥 = 𝑓0 + ∆𝑓0 + ∆ 𝑓0 −1
ℎ 2! ℎ2 2 1
= 1 + 𝑥 − 𝑥2 + 𝑥
= 1 + 2𝑥 − 𝑥 2
0 1
1 −2
(𝑥 − 𝑥2 ) (𝑥 − 𝑥2 )(𝑥 − 𝑥1 ) 2 1 2
𝑃2 𝑥 = 𝑓2 + 𝛻𝑓2 + 𝛻 𝑓2 −1
ℎ 2! ℎ2 2 1
= 1 − 𝑥 + 2 − (𝑥 2 − 3𝑥 + 2)
= 1 + 2𝑥 − 𝑥 2
0 1
1 −2
1 2 −1 12
2 1 10
9
3 10
= 1 + 2𝑥 − 𝑥 2 + 2𝑥 𝑥 2 − 3𝑥 + 2
= 2𝑥 3 − 7𝑥 2 + 6𝑥 + 1
𝑥 4 6 8 10
𝑦 1 3 8 16
Hence evaluate the interpolating polynomial for 𝑥 = 5.
𝑥 𝑦 ∆𝑦 ∆2 𝑦 ∆3 𝑦
4 1
2 3 0
6 3
8 8 5 3
10 16 8
11 3 2
=6− 𝑥+ 𝑥
4 8
11 3
𝑃 5 =6− × 5 + × 25 = 1.625
4 8
Note : In this example, given 4 data points we get only a second degree polynomial.
𝑥 1 2 3 4 5
𝑦 1 −1 1 −1 1
Difference Table:
𝑥 𝑓(𝑥) 𝛻𝑓 𝛻2𝑓 𝛻 3 𝑓3 𝛻 4 𝑓3
1 1 −2
2 −1 4 −8
2 −4 16
3 1 −2 8
4
4 −1 2
5 1
𝑐) Compare the actual error at different points of your choice with the error bound.
𝑥 𝑓(𝑥) ∆𝑓 ∆2 𝑓
0 1
0.6487 0.4208
0.5 1.6487
1 2.7183 1.0696
0.6487 0.4208
𝑃2 𝑥 = 1 + 𝑥 − 0 + 𝑥−0 𝑥 − 0.5
0.5 2 × 0.52
1
= 1 + 1.2974 𝑥 + 𝑥 2 − 𝑥 × 0.8416
2
= 0.8416𝑥 2 + 0.8766𝑥 + 1
𝑥
1 1
max 𝑒 − 𝑃2 𝑥 ≤ max 𝑒 𝑡 max 𝑥−0 𝑥− 𝑥−1
𝑥∈[0,1] 6 𝑡∈ 0,1 𝑥∈ 0,1 2
1 1
= ×𝑒× 𝑥−0 𝑥− 𝑥−1 = 0.0218
6 2 𝑥=
3± 3
6
1 1 1
Let 𝑔 = 𝑥 𝑥 − 𝑥−1 ⟹ 𝑔′ = 𝑥− 𝑥−1 +𝑥 𝑥−1 +𝑥 𝑥− =0
2 2 2
1
1 3± 9−4×3× 3± 3
2
⟹ 3𝑥 2 − 3𝑥 + = 0 ⟹ 𝑥 = =
2 2×3 6
max 𝑒 𝑥 − 𝑃2 𝑥 ≤ 0.0218
𝑥∈[0,1]
∆𝑓0 ∆2 𝑓0 ∆𝑛 𝑓0
𝑃𝑛 𝑥 = 𝑓 𝑥0 + 𝑥 − 𝑥0 + 𝑥 − 𝑥0 𝑥 − 𝑥1 2
+ ⋯ + 𝑥 − 𝑥0 𝑥 − 𝑥1 𝑥 − 𝑥𝑛−1
ℎ 2! ℎ 𝑛! ℎ𝑛
𝛻𝑓𝑛 𝛻 2 𝑓𝑛
𝑃𝑛 𝑥 = 𝑓𝑛 + 𝑥 − 𝑥𝑛 + 𝑥 − 𝑥𝑛 𝑥 − 𝑥𝑛−1 +⋯
ℎ 2! ℎ2
𝛻 𝑛 𝑓𝑛
+ 𝑥 − 𝑥𝑛 𝑥 − 𝑥𝑛−1 … 𝑥 − 𝑥1
𝑛! ℎ𝑛
Note that both formulas were derived taking equidistant nodal points!
Dr. Jitendra Kumar – IIT KHARAGPUR 45
Newton’s Divided - Difference Interpolating Polynomial
𝑃1 𝑥 = 𝑏0 + 𝑏1 𝑥 − 𝑥0
At the point 𝑥 = 𝑥0 : 𝑓 𝑥0 = 𝑏0
At the point 𝑥 = 𝑥1 : 𝑓 𝑥1 = 𝑏0 + 𝑏1 𝑥1 − 𝑥0
𝑓 𝑥1 − 𝑓(𝑥0 )
⇒ 𝑏1 = = 𝑓 𝑥1 , 𝑥0 divided difference
𝑥1 − 𝑥0
𝑃1 𝑥 = 𝑓 𝑥0 + 𝑓[𝑥1 , 𝑥0 ](𝑥 − 𝑥0 )
At the point 𝑥 = 𝑥0 : 𝑏0 = 𝑓 𝑥0
𝑓 𝑥2 − 𝑓(𝑥1 ) 𝑓 𝑥1 − 𝑓(𝑥0 )
− 𝑓 𝑥2 , 𝑥1 − 𝑓[𝑥1 , 𝑥0 ]
𝑥2 − 𝑥1 𝑥1 − 𝑥0
At the point 𝑥 = 𝑥2 : 𝑏2 = =
𝑥2 − 𝑥0 𝑥2 − 𝑥0
= 𝑓[𝑥2 , 𝑥1 , 𝑥0 ]
𝑃𝑛 𝑥 = 𝑓 𝑥0 + 𝑥 − 𝑥0 𝑓 𝑥1 , 𝑥0 + 𝑥 − 𝑥0 𝑥 − 𝑥1 𝑓 𝑥2 , 𝑥1 , 𝑥0 + ⋯
+ 𝑥 − 𝑥0 𝑥 − 𝑥1 … 𝑥 − 𝑥𝑛−1 𝑓 𝑥𝑛 , 𝑥𝑛−1 , … , 𝑥0
𝑃1 𝑥 = 𝐿𝑖 𝑥 𝑓(𝑥𝑖 )
𝑃1 𝑥 = 𝑓 𝑥0 + 𝑓[𝑥1 , 𝑥0 ](𝑥 − 𝑥0 ) 𝑖=0
𝑓 𝑥1 − 𝑓 𝑥0
𝑃1 𝑥 = 𝑓 𝑥0 + 𝑥 − 𝑥0
𝑥1 − 𝑥0
(𝑥 − 𝑥1 ) (𝑥 − 𝑥0 )
= 𝑓 𝑥0 + 𝑓(𝑥1 )
(𝑥0 −𝑥1 ) (𝑥1 −𝑥0 )
𝐿0 (𝑥) 𝐿1 (𝑥)
𝑃𝑛 𝑥 = 𝐿𝑖 𝑥 𝑓(𝑥𝑖 )
𝑖=0
𝑛
𝑥 − 𝑥𝑗 𝑥 − 𝑥0 𝑥 − 𝑥1 … 𝑥 − 𝑥𝑖−1 𝑥 − 𝑥𝑖+1 … (𝑥 − 𝑥𝑛 )
𝐿𝑖 𝑥 = ෑ =
𝑥𝑖 − 𝑥𝑗 𝑥𝑖 − 𝑥0 𝑥𝑖 − 𝑥1 … 𝑥𝑖 − 𝑥𝑖−1 𝑥𝑖 − 𝑥𝑖+1 … (𝑥𝑖 − 𝑥𝑛 )
𝑗=0
𝑗≠𝑖
Lagrange’s polynomial of degree 𝑛
(𝑥 − 𝑥1 )(𝑥 − 𝑥2 ) (𝑥 − 2)(𝑥 − 4) 1
𝐿0 𝑥 = = = 𝑥−2 𝑥−4
𝑥0 − 𝑥1 (𝑥0 − 𝑥2 ) (1 − 2)(1 − 4) 3
(𝑥 − 𝑥0 )(𝑥 − 𝑥2 ) (𝑥 − 1)(𝑥 − 4) 1
𝐿1 𝑥 = = =− 𝑥−1 𝑥−4
𝑥1 − 𝑥0 (𝑥1 − 𝑥2 ) (2 − 1)(2 − 4) 2
(𝑥 − 𝑥0 )(𝑥 − 𝑥1 ) (𝑥 − 1)(𝑥 − 2) 1
𝐿2 𝑥 = = = (𝑥 − 1)(𝑥 − 2)
𝑥2 − 𝑥0 (𝑥2 − 𝑥1 ) (4 − 1)(4 − 2) 6
2
Lagrange interpolating polynomial : 𝑃2 𝑥 = 𝐿𝑖 𝑥 𝑓(𝑥𝑖 )
𝑖=0
1 1 1
𝑃2 𝑥 = 𝑥 − 2 𝑥 − 4 × 1 − 𝑥 − 1 𝑥 − 4 × 3 + 𝑥 − 1 𝑥 − 2 × 3
3 2 6
1 2 3 1
= 𝑥 − 6𝑥 + 8 − 𝑥 2 − 5𝑥 + 4 + 𝑥 2 − 3𝑥 + 2
3 2 2
2 2 7
= − 𝑥 + 4𝑥 −
3 3
Divided-Difference table
1 1
2 2
2 3 −
0 3
4 3
2
= 1 + 2 𝑥 − 1 − (𝑥 − 1)(𝑥 − 2)
3
2 2 7
= − 𝑥 + 4𝑥 −
3 3
0 1
13
1 14 −6 1
1 0
2 15 −2 1 0
−5 0
4 5 2 1
5 6 1
6
6 19 13
= 1 + 13 𝑥 − 6 𝑥 𝑥 − 1 + 1(𝑥)(𝑥 − 1)(𝑥 − 2)
= 𝑥 3 − 9𝑥 2 + 21𝑥 + 1
0 1
13
1 14 −6 1
1 0
2 15 −2 1 0
−5 0
4 5 2 1
5 6 1
6
6 19 13
𝑥– 1 𝑥– 2 𝑥– 4 𝑥– 5 𝑥– 6 𝑥 𝑥– 2 𝑥– 4 𝑥– 5 𝑥– 6
= ×1 + × 14
(−1)(−2)(−4)(−5)(−6) 1 − 0 1 − 2 1 − 4 (1 − 5)(1 − 6)
𝑥 𝑥 –1 𝑥 – 4 𝑥 – 5 𝑥 – 6 𝑥 𝑥 –1 𝑥 –2 𝑥 – 5 𝑥 – 6
+ × 15 + ×5
2 − 0 2 − 1 2 − 4 (2 − 5)(2 − 6) 4 − 0 4 − 1 4 − 2 (4 − 5)(4 − 6)
𝑥 𝑥 –1 𝑥 –2 𝑥 –4 𝑥 – 6 𝑥 𝑥 –1 𝑥 –2 𝑥 –4 𝑥 –5
+ ×6+ × 19
5 − 0 5 − 1 5 − 2 (5 − 4)(5 − 6) 6 − 0 6 − 1 6 − 2 (6 − 4)(6 − 5)
= 𝑥 3 − 9𝑥 2 + 21𝑥 + 1
𝑃𝑛 𝑥 = 𝑓 𝑥0 + 𝑥 − 𝑥0 𝑓 𝑥1 , 𝑥0 + 𝑥 − 𝑥0 𝑥 − 𝑥1 𝑓 𝑥2 , 𝑥1 , 𝑥0 + ⋯
+ 𝑥 − 𝑥0 𝑥 − 𝑥1 … 𝑥 − 𝑥𝑛−1 𝑓 𝑥𝑛 , 𝑥𝑛−1 , … , 𝑥0
Lagrange Interpolating Polynomial
𝑛 𝑛
𝑥 − 𝑥𝑗
𝑃𝑛 𝑥 = 𝐿𝑖 𝑥 𝑓(𝑥𝑖 ) 𝐿𝑖 𝑥 = ෑ
𝑥𝑖 − 𝑥𝑗
𝑖=0 𝑗=0
𝑗≠𝑖