Numerical Methods I: Polynomial Interpolation

Similar documents
Numerical Methods I: Interpolation (cont ed)

Numerical Methods I: Numerical Integration/Quadrature

Interpolation. Chapter Interpolation. 7.2 Existence, Uniqueness and conditioning

Outline. 1 Interpolation. 2 Polynomial Interpolation. 3 Piecewise Polynomial Interpolation

Lecture 10 Polynomial interpolation

Scientific Computing: An Introductory Survey

Chapter 4: Interpolation and Approximation. October 28, 2005

Piecewise Polynomial Interpolation

Piecewise Polynomial Interpolation

Global polynomial interpolants suffer from the Runge Phenomenon if the data sites (nodes) are not chosen correctly.

1 Review of Interpolation using Cubic Splines

Polynomials. p n (x) = a n x n + a n 1 x n 1 + a 1 x + a 0, where

Interpolation. 1. Judd, K. Numerical Methods in Economics, Cambridge: MIT Press. Chapter

Cubic Splines; Bézier Curves

Cubic Splines MATH 375. J. Robert Buchanan. Fall Department of Mathematics. J. Robert Buchanan Cubic Splines

Data representation and approximation

Numerical Methods I: Eigenvalues and eigenvectors

Applied Math 205. Full office hour schedule:

3.1 Interpolation and the Lagrange Polynomial

Lectures 9-10: Polynomial and piecewise polynomial interpolation

Function approximation

INTERPOLATION. and y i = cos x i, i = 0, 1, 2 This gives us the three points. Now find a quadratic polynomial. p(x) = a 0 + a 1 x + a 2 x 2.

We consider the problem of finding a polynomial that interpolates a given set of values:

(0, 0), (1, ), (2, ), (3, ), (4, ), (5, ), (6, ).

Lecture Note 3: Interpolation and Polynomial Approximation. Xiaoqun Zhang Shanghai Jiao Tong University

Numerical Analysis: Approximation of Functions

University of Houston, Department of Mathematics Numerical Analysis, Fall 2005

you expect to encounter difficulties when trying to solve A x = b? 4. A composite quadrature rule has error associated with it in the following form

Lecture Note 3: Polynomial Interpolation. Xiaoqun Zhang Shanghai Jiao Tong University

CS412: Introduction to Numerical Methods

Improved Lebesgue constants on the triangle

Polynomial Interpolation

Applied Numerical Analysis Quiz #2

Computational Physics

CS 323: Numerical Analysis and Computing

November 20, Interpolation, Extrapolation & Polynomial Approximation

Scientific Computing

Chapter 3 Interpolation and Polynomial Approximation

Function Approximation

Exam 2. Average: 85.6 Median: 87.0 Maximum: Minimum: 55.0 Standard Deviation: Numerical Methods Fall 2011 Lecture 20

Geometric Interpolation by Planar Cubic Polynomials

Interpolation. Escuela de Ingeniería Informática de Oviedo. (Dpto. de Matemáticas-UniOvi) Numerical Computation Interpolation 1 / 34

Statistical Methods for Data Mining

The Normal Equations. For A R m n with m > n, A T A is singular if and only if A is rank-deficient. 1 Proof:

Interpolation and Approximation

5.1 introduction problem : Given a function f(x), find a polynomial approximation p n (x).

Numerical Methods I Orthogonal Polynomials

Chapter 1 Numerical approximation of data : interpolation, least squares method

One dimension and tensor products. 2.1 Legendre and Jacobi polynomials

Polynomial Interpolation with n + 1 nodes

Interpolation & Polynomial Approximation. Hermite Interpolation I

Introduction Linear system Nonlinear equation Interpolation

Statistical Methods for SVM

Interpolation Theory

Outline. 1 Boundary Value Problems. 2 Numerical Methods for BVPs. Boundary Value Problems Numerical Methods for BVPs

Interpolation and extrapolation

Examination paper for TMA4215 Numerical Mathematics

Application of modified Leja sequences to polynomial interpolation

UNIT-II INTERPOLATION & APPROXIMATION

Solving Integral Equations by Petrov-Galerkin Method and Using Hermite-type 3 1 Elements

Arsène Pérard-Gayot (Slides by Piotr Danilewski)

Outline. 1 Numerical Integration. 2 Numerical Differentiation. 3 Richardson Extrapolation

Numerical Methods I: Orthogonalization and Newton s method

SMOOTH APPROXIMATION OF DATA WITH APPLICATIONS TO INTERPOLATING AND SMOOTHING. Karel Segeth Institute of Mathematics, Academy of Sciences, Prague

2. Interpolation. Closing the Gaps of Discretization...

Mathematics for Engineers. Numerical mathematics

Curve Fitting and Interpolation

Convergence for periodic Fourier series

Interpolation and polynomial approximation Interpolation

Numerical Analysis: Interpolation Part 1

Two hours. To be provided by Examinations Office: Mathematical Formula Tables. THE UNIVERSITY OF MANCHESTER. 29 May :45 11:45

CS 323: Numerical Analysis and Computing

2.29 Numerical Fluid Mechanics Fall 2009 Lecture 13

Applied Numerical Analysis (AE2220-I) R. Klees and R.P. Dwight

CS 450 Numerical Analysis. Chapter 8: Numerical Integration and Differentiation

7-7 Multiplying Polynomials

Polynomial Interpolation

A comparison of interpolation grids over the triangle or the tetrahedron

Preliminary Examination in Numerical Analysis

Jim Lambers MAT 460/560 Fall Semester Practice Final Exam

A note on accurate and efficient higher order Galerkin time stepping schemes for the nonstationary Stokes equations

SYSTEMS OF NONLINEAR EQUATIONS

Interpolation and the Lagrange Polynomial

Chordal cubic spline interpolation is fourth order accurate

LECTURE 16 GAUSS QUADRATURE In general for Newton-Cotes (equispaced interpolation points/ data points/ integration points/ nodes).

ON A WEIGHTED INTERPOLATION OF FUNCTIONS WITH CIRCULAR MAJORANT

Math 365 Homework 5 Due April 6, 2018 Grady Wright

Orthogonal polynomials

Cubic Splines. Antony Jameson. Department of Aeronautics and Astronautics, Stanford University, Stanford, California, 94305

MATH ASSIGNMENT 07 SOLUTIONS. 8.1 Following is census data showing the population of the US between 1900 and 2000:

Lagrange Interpolation and Neville s Algorithm. Ron Goldman Department of Computer Science Rice University

2

Solving Fredholm integral equations with application of the four Chebyshev polynomials

LEAST SQUARES APPROXIMATION

Math 365 Monday 3/25/19. 1 x n n 1. 1 x = X. a k x k (Considered formally, i.e. without consideration of convergence.)

A THEORETICAL INTRODUCTION TO NUMERICAL ANALYSIS

Non-polynomial Least-squares fitting

Numerical Marine Hydrodynamics

GENERALIZED GAUSS RADAU AND GAUSS LOBATTO FORMULAE

Input: A set (x i -yy i ) data. Output: Function value at arbitrary point x. What for x = 1.2?

Transcription:

1/31 Numerical Methods I: Polynomial Interpolation Georg Stadler Courant Institute, NYU stadler@cims.nyu.edu November 16, 2017

lassical polynomial interpolation Given f i := f(t i ), i =0,...,n, we would like to find a polynomial P 2 P n such that P (t i )=f i. Interpolation is thus a map from R n+1! P n. Theorem: Given nodes (t i,f i ), 0 apple i apple n, withpairwisedistinct nodes t i, then there exists a unique interpolating polynomial P 2 P n. To compute that polynomial, we have to choose a basis in P n. 2/31

lassical polynomial interpolation 3/31 Monomial basis: 1,t,t 2... leads to system with Vandermonde matrix V n. I det(v n )= Q n i=0 Q n j=i+1 (t i t j ) 6= 0 I For larger n, this can be a poorly conditioned system.

lassical polynomial interpolation 4/31 Lagrange basis L i defined by L i (t j )= ij. I Simple interpolant: P (t) = P n i=0 f il i (t) I Not always practical. I Lagrange polynomials form an orthogonal basis in P n w.r. to the inner product (P, Q) := nx P (t i )Q(t i ) i=0

lassical polynomial interpolation 5/31 The Newton basis! 0,...,! n is given by Yi 1! i (t) := (t t j ) 2 P i. j=0 This polynomials are linearly independent as their degree increases. The coe cients in this basis can be computed e ciently (more later).

Tow (slightly) di erent perspectives 6/31 Interpolation can be seen as map between : R n+1 7! P n or as map between functions: : C([a, b]) 7! P n. is function evaluation at the nodes, followed by.

Conditioning Theorem: Let a apple t 0 <...<t n apple b be pairwise distinct and L i be the corresponding Lagrange polynomials. Then the absolute condition number of the polynomial interpolation: : C([a, b])! P n w.r. to the supremum norm is the Lebesgue constant apple abs = n = max t2[a,b] nx L i (t). Note that the Lebesgue constant depends on n and the location of the t i. i=1 7/31

Conditioning 8/31

9/31 Classical polynomial interpolation Conditioning Lebesgue constants for di erent orders: n 5 10 15 20 An for equidistant nodes 3.106292 29.890695 512.052451 10986.533993 An for Chebyshev nodes 2.104398 2.489430 2.727778 2.900825 Chebyshev nodes are the roots of the Chebyshev polynomials: 2i +1 t i = cos 2n +2, for i =0,...,n

10 / 31 Classical polynomial interpolation Conditioning Lebesgue constant for n = 10, uniformvs.chebyshevnodes:

11 / 31 Classical polynomial interpolation Conditioning Lebesgue constant for n = 40, uniformvs.chebyshevnodes:

ermite interpolation 12 / 31 Assume a = t 0 apple t 1 apple...apple t n = b with possibly duplicated nodes. If the node t i occurs k times, the corresponding node values correspond to f(t i ),f 0 (t i ),...,f k 1 (t i ). The Hermite interpolation polynomial p(x) is a polynomial of order n, which coincides with the nodal values (and, for duplicated nodes, derivatives at nodal values) at the nodes.

ermite interpolation Theorem: (somewhat loosely formulated version) Given n +1 nodes and nodal values (possibly of derivatives), then there exists a unique interpolating Hermite polynomial p 2 P n. Examples: I All t 0 =...= t n. I Cubic Hermite interpolation: Nodes: t 0 = t 1 <t 2 = t 3, Values: f(t 0 ),f 0 (t 0 ),f(t 1 ),f 0 (t 1 ). I locally cubic Hermite interpolation. 13 / 31

Newton polynomial basis 14 / 31 The Newton basis! 0,...,! n is given by Yi 1! i (t) := (t t j ) 2 P i. j=0 The leading coe cient a n of the interpolation polynomial of f P (f t 0,...,t n )=a n x n +... is called the n-th divided di erence, [t 0,...,t n ]f := a n.

Newton polynomial basis 15 / 31 Theorem: For f 2 C n, the interpolation polynomial P (f t 0,...,t n ) is given by P (t) = nx [t 0,...,t i ]f! i (t). i=0 If f 2 C n+1,then f(t) =P (t)+[t 0,...,t n,t]f! n+1 (t). This property allows to estimate the interpolation error.

Newton polynomial basis 16 / 31

Divided di erences 17 / 31 The divided di erences [t 0,...,t n ]f satisfy the following properties: I [t 0,...,t n ]P =0for all P 2 P n 1. I If t 0 =...= t n : nodes. [t 0,...,t n ]f = f (n) (t 0 ) n!

Divided di erences 18 / 31 I The following recurrence relation holds for t i 6= t j (nodes with a hat are removed): [t 0,...,t n ]f = [t 0,...,ˆt i,...,t n ]f [t 0,..., ˆt j,...,t n ]f t j t i I If f 2 C n [t 0,...,t n ]f = 1 n! f (n) ( ) with an a apple apple b, and the divided di erences depend continuously on the nodes.

Divided di erences 19 / 31 Let us use divided di erences to compute the coe cients for the Newton basis for the cubic interpolation polynomial p that satisfies p(0) = 1, p(0.5) = 2, p(1) = 0, p(2) = 3. t i 0 [t 0 ]f =1 0.5 [t 1 ]f =2 [t1]f [t 0 t 1 ]f = t 1 [t0]f t 0 =2 1 [t 2 ]f =0 [t2]f [t 1 t 2 ]f = t 2 [t1]f t 1 = 4 [t 0 t 1 t 2 ]f = 6 2 [t 3 ]f =3 [t3]f [t 2 t 3 ]f = t 3 [t2]f t 2 =3 [t 1 t 2 t 3 ]f = 14 3 Thus, the interpolating polynomial is 16 3 p(t) =1 + 2t + ( 6)t(t 0.5) + 16 t(t 0.5)(t 1). 3

Divided di erences 20 / 31 Let us now use divided di erences to compute the coe cients for the Newton basis for the cubic interpolation polynomial p that satisfies p(0) = 1, p 0 (0) = 2, p 00 (0) = 1, p(1) = 3. t i 0 [t 0 ]f =1 0 [t 0 ]f =1 [t 0 t 1 ]f = p 0 (0) = 2 0 [t 0 ]f =1 [t 1 t 2 ]f = p 0 (0) = 2 [t 0 t 1 t 2 ]f = p00 (0) 2! = 1 2 [t3]f [t0]f 1 1 [t 3 ]f =3 [t 2 t 3 ]f = t 3 t 0 =2 0 2 Thus, the interpolating polynomial is p(t) =1 + 2t + 1 2 t2 + ( 1 2 )t3

Approximation error If f 2 C (n+1),then 21 / 31 f(t) P (f t 0,...,t n )(t) = f (n+1) ( ) (n + 1)!! n+1(t) for an appropriate = (t), a< <b. In particular, the error depends on the choice of the nodes. For Taylor interpolation, i.e., t 0 =...= t n,thisresultsin: f(t) P (f t 0,...,t n )(t) = f (n+1) ( ) (n + 1)! (t t 0) n+1

Approximation error 22 / 31 Consider functions {f 2 C n+1 ([a, b]) : sup f n+1 ( ) apple M(n + 1)!} 2[a,b] for some M>0, then the approximation error depends on! n (t), and thus on t 0,...,t n. Thus, one can try to minimize max! n+1(t), aappletappleb which is achieved by choosing the nodes as the roots of the Chebyshev polynomial of order (n + 1).

Approximation error 23 / 31 Summary on pointwise convergence: I If an interpolating polynomial is close/converges to the original function depends on the regularity of the function and the choice of interpolation nodes I For a good choice of interpolation nodes, fast convergence can be obtained for almost all functions

Interpolation/Least square approximation/splines 24 / 31 I Polynomial interpolation I Least squares with polynomials I Splines (i.e., piecewise polynomial interpolation):