Lecture VIII. Global Approximation Methods: I

Size: px
Start display at page:

Download "Lecture VIII. Global Approximation Methods: I"

Transcription

1 Lecture VIII Global Approximation Methods: I Gianluca Violante New York University Quantitative Macroeconomics G. Violante, Global Methods p. 1 /29

2 Global function approximation Global methods: function interpolation over the entire domain First choice: type of approximation 1. Interpolation I: finite element methods Splines (e.g., B-splines, cubic splines, Schumaker splines) 2. Interpolation II: spectral methods Orthogonal polynomials (e.g., Chebyshev, Lagrange, etc...) Second choice: how to minimize residuals between true function and interpolant 1. Collocation 2. Least squares 3. Galerkin method G. Violante, Global Methods p. 2 /29

3 Interpolation Today, one dimension. We want to represent a real-valued function f on [a,b] with a computationally tractable function Interpolation is a form of function approximation in which the approximating (interpolant) and the true function must agree, i.e. they must have same value, at a finite number of points. In some cases additional restrictions are imposed on the interpolant. E.g., f evaluated at a finite number of points may have to agree with that of the underlying function. Other examples include additional constraints imposed on the interpolant such as monotonicity, convexity, or smoothness requirements. In general, interpolation is any method that takes information at a finite set of points, X, and finds a function which satisfies that information at X. G. Violante, Global Methods p. 3 /29

4 Interpolation We want to approximate a known function f (x). The interpolant ˆf is chosen to be a linear combination of a collection of basis functions {φ j (x)} n j=0 where n is the order/degree of interpolation Basis functions: linearly independent functions that span the family of functions chosen for the interpolation (the function space) any function in the space can be obtained as a linear combination of basis functions, just as every vector in a vector space can be obtained as a linear combination of basis vectors. In general we are interested in the space of continuous or continuously differentiable functions. G. Violante, Global Methods p. 4 /29

5 Interpolation Thus, for a given family of basis function {φ j } n j=0 we have: f(x) ˆf(x) n w j φ j (x) j=0 We have reduced the problem of characterizing an infinite-dimensional object, f, to the problem of determining the n weights (or coefficients) {w j } There is arbitrariness in interpolation: there are arbitrarily many functions passing through a finite number of points. Which basis? Choices: spectral or finite element methods depending whether the basis functions are nonzero over the entire domain of the true function (except possibly at a finite number of points) or nonzero only on a subinterval of the domain. G. Violante, Global Methods p. 5 /29

6 Finite element methods Use local basis These are called splines An order n spline consists of a series of n th order polynomial segments spliced together so as to preserve continuity of derivatives of order n 1 or less. The points at which the pieces are spliced together are called knots or breakpoints. By convention the first and last knots are the two extremes of the function domain. G. Violante, Global Methods p. 6 /29

7 Splines An order n spline with K +1 knots has K(n+1) parameters. The simplest way to proceed (Judd calls it the kindergarten procedure of connecting the dots ) is to use linear B-splines, where B stands for basic. Suppose we have a grid with knots x 0 <...x k <... < x K and we want to approximate a function f (x). B 0 splines are defined as right-continuous step functions B 0 k(x) = { 1 if x k x < x k+1 0 otherwise So interpolant is: ˆf (x) = K 1 k=0 [ ] f (xk )+f (x k+1 ) B 0 2 k(x) G. Violante, Global Methods p. 7 /29

8 Linear B-splines B 1 splines implement piece-wise linear interpolation B 1 k(x) = x x k 1 x k x k 1 if x k 1 x < x k x k+1 x x k+1 x k if x k x < x k+1 0 elsewhere and each one looks like a tent-function with peak at x k equal to one, thus the weight of the interpolant must be f (x k ) The interpolant is therefore defined as: ˆf (x) = K f (x k )Bk(x) 1 k=0 You can also obtain the same weights from 2K conditions: ˆf at knots equal to f(x) (K + 1 conditions), and interpolant continuous at interior knots (K 1 conditions) G. Violante, Global Methods p. 8 /29

9 Linear spline Basis Functions on [0, 1] G. Violante, Global Methods p. 9 /29

10 Linear B-splines It is easy to see that for any given point x on an interval [x k,x k+1 ] there are only two nonzero basis at x, B k (x) and B k+1 (x). To locate the knots (k,k +1) that bracket x you use a bracketing algorithm that essentially proceeds by bisection. Thus ˆf (x) = f (x k ) x k+1 x x k+1 x k +f (x k+1 ) x x k x k+1 x k = f (x k ) x k+1 x x k +x k x k+1 x k +f (x k+1 ) x x k x k+1 x k = f (x k )+[f (x k+1 ) f (x k )] x x k x k+1 x k that is a familiar formula for linear interpolation of decision rules (see later...) G. Violante, Global Methods p. 10 /29

11 Linear Spline approximation (7 knots) x 0 =a x 1 x 2 x 3 x 4 x 5 x 6 =b G. Violante, Global Methods p. 11 /29

12 Pros and cons of linear splines Pros: Preserves monotonicity and concavity of f. We can exploit information about f clustering points more closely together in areas of high curvature or areas where we know a kink exists in order to increase our accuracy. We can capture binding inequality constraints very well. Cons: The approximated function is not differentiable at the knots (they become kinks). ˆf = 0 where it exists (it does not exist at the knots). Function not smooth. G. Violante, Global Methods p. 12 /29

13 Cubic splines Cubic spline (n = 3), has 4K coefficients to be determined ˆf (xk ) = f (x k ) (K +1 conditions) Continuity of ˆf at interior points Continuity of ˆf at interior points Continuity of ˆf at interior points (K 1 conditions) (K 1 conditions) (K 1 conditions) ˆf (x 0 ) = ˆf (x K ) = 0 (2 conditions) These last two can be modified to something else depending on what is suitable in the particular case at hand, they are ad-hoc and they can be more than 2. G. Violante, Global Methods p. 13 /29

14 Cubic spline Basis Functions on [0,1] G. Violante, Global Methods p. 14 /29

15 Cubic spline Basis Functions on [0,1] Spline 1: Piecewise Linear Interpolation Spline 2: Piecewise Cubic Interpolation Data G. Violante, Global Methods p. 15 /29

16 Pros and cons of cubic splines Pros: Easy to compute: interpolant matrix very sparse, easy to invert. Smooth approximation Cons: It may not be able to handle constraints well It does not preserve monotonicity and concavity of f G. Violante, Global Methods p. 16 /29

17 Schumaker splines So far: linear interpolation preserves shape (monotonicity and concavity), but not differentiability. Cubic splines preserves differentiability, but not shape. Schumaker quadratic splines preserve both (Schumaker, 1983, SIAM Journal on Numerical Analysis). By shape we mean that in those intervals where the data is monotonically increasing or decreasing, the spline has the same property. Similarly for convexity or concavity. Idea: add knots to a subinterval by means of an algorithm G. Violante, Global Methods p. 17 /29

18 Solving the income fluctuation problem V (a,y j ) = max {c,a } u(c)+β s.t. y i Y π(y i y j )V (a,y i ) c+a Ra+y j a a The Euler equation, once we substitute in the budget constraint, reads: u c (Ra+y j a ) βr π(y i y j )u c (Ra +y i a ) 0. y i Y where the strict inequality holds when the constraint binds. G. Violante, Global Methods p. 18 /29

19 Policy function iteration with linear interpolation 1. Construct a grid on the asset space {a 0,a 2,...,a m } with a 0 = a = Guess an initial vector of decision rules for a on the grid points, call it â 0 (a i,y j ), where the subscript 0 denotes the initial iteration 3. For each point (a i,y j ) on the grid, check whether the borrowing constraint binds. I.e. check whether: u c (Ra i +y j a 0 ) βr y Y π(y y j )u c (Ra 0 +y â 0 (a 0,y )) > If this inequality holds, the borrowing constraint binds. Then, set a 0(a i,y j ) = a 0 and repeat this check for the next grid point. If the equation instead holds with the < inequality, we have an interior solution (it is optimal to save for the household) and we proceed to the next step. G. Violante, Global Methods p. 19 /29

20 Policy function iteration with linear interpolation 5. For each point (a i,y j ) on the grid, use a nonlinear equation solver to find the solution a of the nonlinear equation u c (Ra i +y j a ) βr y Y π(y y j )u c (Ra +y â 0 (a,y )) = 0 (a) Need to evaluate the function â 0 (a,y ) outside grid points: assume it is piecewise linear. (b) Every time the solver calls an a which lies between grid points, do as follows. First, find the pair of adjacent grid points {a i,a i+1 } such that a i < a < a i+1, and then compute (â0 â 0 (a,y ) = â 0 (a i,y )+(a (a i+1,y ) â 0 (a i,y ) ) a i ) a i+1 a i (c) If the solution of the nonlinear equation is a, then set a 0(a i,y j ) = a and iterate on the next grid point. G. Violante, Global Methods p. 20 /29

21 Policy function iteration with linear interpolation 6. Check convergence by comparing a 0(a i,y j ) â 0 (a i,y j ) through some pre-specified norm. For example, declare convergence at iteration n when max i,j { a n(a i,y j ) â n (a i,y j ) } < ε for some small number ε which determines the degree of tolerance in the solution algorithm. 7. If convergence is achieved, stop. Otherwise, go back to point 3 with the new guess â 1 (a i,y j ) = a 0(a i,y j ). Note that the most time-consuming step in this procedure is 5, the root-finding problem. We now discuss how to avoid it. G. Violante, Global Methods p. 21 /29

22 Endogenous grid method (EGM) EGM is much faster than the traditional method because it does not require the use of a nonlinear equation solver The essential idea of the method is to construct a grid on a, next period s asset holdings, rather than on a, as is done in the standard algorithm. The method also requires the policy function to be at least weakly monotonic in the state Recall the Euler equation: u c (c(a,y)) βr y Y π(y y)u c (c(a,y )). As usual, we start from a guess ĉ 0 (a,y) and iterate on the Euler Equation until the decision rule for consumption that we solve for is essentially identical to the one in the previous iteration. G. Violante, Global Methods p. 22 /29

23 EGM: Algorithm 1. Construct a grid for (a,y) 2. Guess a policy function ĉ 0 (a i,y j ). If y is persistent, a good initial guess is to set ĉ 0 (a i,y j ) = ra i +y j which is the solution under quadratic utility if income follows a random walk. 3. Fix y j. Instead of iterating over {a i }, we iterate over {a i }. For any pair {a i,y j} on the mesh construct the RHS of the Euler equation [call it B(a i,y j)] B(a i,y j ) βr y Y π(y y j )u c (ĉ 0 (a i,y )) where the RHS of this equation uses the guess ĉ 0 on the grid G. Violante, Global Methods p. 23 /29

24 EGM: Algorithm 4. Use the Euler equation to solve for the value c(a i,y j) that satisfies u c ( c(a i,y j )) = B(a i,y j ) and note that it can be done analytically, e.g. for u c (c) = c γ we have c(a i,y j) = [B(a i,y j)] 1 γ. Here algorithm becomes much more efficient because it does not require a nonlinear solver. 5. From the budget constraint: c(a i,y j )+a i = Ra i +y j solve for a (a i,y j) the value of assets today that would lead the consumer to have a i assets tomorrow if her income shock was y j today. This yields c(a i,y j) = c(a i,y j), a function not defined on the grid points. This is the endogenous grid and it changes on each iteration. G. Violante, Global Methods p. 24 /29

25 EGM: Algorithm 6. Let a 0 be the value of asset holdings that induces the borrowing constraint to bind next period, i.e., the value for a that solves that equation at the point a 0, the lower bound of the grid. 7. Now we need to update our guess defined on the original grid. To get new guess ĉ 1 (a i,y j ) on grid points a i > a 0 we can use simple linear interpolation methods using values for { c(a n,y j ),c ( )} a n+1,y j on the two most adjacent values { } a n,a n+1 that bracket ai. If some points a i are beyond a m, the upper bound of the endogenous grid, just extend linearly the function G. Violante, Global Methods p. 25 /29

26 EGM: Algorithm To update the consumption policy function on grid values a i < a 0, we use the budget constraint: ĉ 1 (a i,y j ) = Ra i +y j a 0 since we cannot use the Euler equation as the borrowing constraint is binding for sure next period: the reason is that we found it was binding at a 0, therefore a fortiori it will be binding for a i < a Check convergence as before. G. Violante, Global Methods p. 26 /29

27 Envelope condition method (ECM) It is an alternative method that, in some cases, like the EGM, avoids the use of nonlinear solvers 1. Construct a grid on a with K +1 points: call it A. 2. Guess a value function ˆV 0 (a,y j ) = K k=0 w0 kj B k(a) where B k are cubic splines. 3. Compute the derivative of the value function on the nodes of A: ˆV 0 (a i,y j ) = K wkjb 0 k(a i ) k=0 Note: if you wish to use B 1 splines instead, you need to use a different grid in the above step because ˆV 0 is not differentiable on the nodes of the original grid A G. Violante, Global Methods p. 27 /29

28 Envelope Condition Method (ECM) 5. For any pair {a i,y j } on A Y construct the envelope condition: ˆV 0 (a i,y j ) = u c (Ra i +y j â 0 (a i,y j ))R from which we can obtain: â 0 (a i,y j ) = Ra i +y j u 1 c ( ) ˆV 0 (a i,y j ) R On each point of the grid we must verify if the borrowing constraint binds and if it does, we set â 0 (a i,y j ) = Update the value function from the Bellman equation. For each point of the grid A compute: ˆV 1 (a i,y j ) = u(ra i +y j â 0 (a i,y j ))+β y j Y π(y j y j ) ˆV 0 (â 0 (a i,y j ),y j ) G. Violante, Global Methods p. 28 /29

29 Envelope Condition Method (ECM) In practice, need to solve (K +1)J equations in (K +1)J { } coefficients wkj 1 of the type: K wkjb 1 k (a i ) = u(ra i +y j â 0 (a i,y j )) k=0 +β K π(y j y j ) wkj 0 B k(â 0 (a i,y j )) y j Y k=0 for all gridpoints, i = 0,1,...K and j = 1,2,...,J It is a linear system of equations G. Violante, Global Methods p. 29 /29

Lecture X. Global Approximation Methods

Lecture X. Global Approximation Methods Lecture X Global Approximation Methods Gianluca Violante New York University Quantitative Macroeconomics G. Violante, Global Methods p. 1 /14 Envelope condition method (ECM) It is an alternative method

More information

CS 450 Numerical Analysis. Chapter 7: Interpolation

CS 450 Numerical Analysis. Chapter 7: Interpolation Lecture slides based on the textbook Scientific Computing: An Introductory Survey by Michael T. Heath, copyright c 2018 by the Society for Industrial and Applied Mathematics. http://www.siam.org/books/cl80

More information

Natural Quartic Spline

Natural Quartic Spline Natural Quartic Spline Rafael E Banchs INTRODUCTION This report describes the natural quartic spline algorithm developed for the enhanced solution of the Time Harmonic Field Electric Logging problem As

More information

Linear Interpolating Splines

Linear Interpolating Splines Jim Lambers MAT 772 Fall Semester 2010-11 Lecture 17 Notes Tese notes correspond to Sections 112, 11, and 114 in te text Linear Interpolating Splines We ave seen tat ig-degree polynomial interpolation

More information

Computational Physics PHYS 420

Computational Physics PHYS 420 Computational Physics PHYS 420 Dr Richard H. Cyburt Assistant Professor of Physics My office: 402c in the Science Building My phone: (304) 384-6006 My email: rcyburt@concord.edu My webpage: www.concord.edu/rcyburt

More information

Mar. 20 Math 2335 sec 001 Spring 2014

Mar. 20 Math 2335 sec 001 Spring 2014 Mar. 20 Math 2335 sec 001 Spring 2014 Chebyshev Polynomials Definition: For an integer n 0 define the function ( ) T n (x) = cos n cos 1 (x), 1 x 1. It can be shown that T n is a polynomial of degree n.

More information

lecture 10: B-Splines

lecture 10: B-Splines 9 lecture : -Splines -Splines: a basis for splines Throughout our discussion of standard polynomial interpolation, we viewed P n as a linear space of dimension n +, and then expressed the unique interpolating

More information

February 2017 (1/20) 2 Piecewise Polynomial Interpolation 2.2 (Natural) Cubic Splines. MA378/531 Numerical Analysis II ( NA2 )

February 2017 (1/20) 2 Piecewise Polynomial Interpolation 2.2 (Natural) Cubic Splines. MA378/531 Numerical Analysis II ( NA2 ) f f f f f (/2).9.8.7.6.5.4.3.2. S Knots.7.6.5.4.3.2. 5 5.2.8.6.4.2 S Knots.2 5 5.9.8.7.6.5.4.3.2..9.8.7.6.5.4.3.2. S Knots 5 5 S Knots 5 5 5 5.35.3.25.2.5..5 5 5.6.5.4.3.2. 5 5 4 x 3 3.5 3 2.5 2.5.5 5

More information

Lecture 6: Interpolation

Lecture 6: Interpolation Lecture 6: Interpolation Fatih Guvenen January 10, 2016 Fatih Guvenen ( ) Lecture 6: Interpolation January 10, 2016 1 / 25 General Idea Suppose you are given a grid (x 1, x 2,..., x n ) and the function

More information

Interpolation by Spline Functions

Interpolation by Spline Functions Interpolation by Spline Functions Com S 477/577 Sep 0 007 High-degree polynomials tend to have large oscillations which are not the characteristics of the original data. To yield smooth interpolating curves

More information

APPM/MATH Problem Set 4 Solutions

APPM/MATH Problem Set 4 Solutions APPM/MATH 465 Problem Set 4 Solutions This assignment is due by 4pm on Wednesday, October 16th. You may either turn it in to me in class on Monday or in the box outside my office door (ECOT 35). Minimal

More information

Polynomials tend to oscillate (wiggle) a lot, even when our true function does not.

Polynomials tend to oscillate (wiggle) a lot, even when our true function does not. AMSC/CMSC 460 Computational Methods, Fall 2007 UNIT 2: Spline Approximations Dianne P O Leary c 2001, 2002, 2007 Piecewise polynomial interpolation Piecewise polynomial interpolation Read: Chapter 3 Skip:

More information

Value Function Iteration versus Euler equation methods

Value Function Iteration versus Euler equation methods Value Function Iteration versus Euler equation methods Wouter J. Den Haan London School of Economics c by Wouter J. Den Haan Overview 1 How to do value function iteration (VFI) 2 equation methods 1 convergence

More information

Consider functions such that then satisfies these properties: So is represented by the cubic polynomials on on and on.

Consider functions such that then satisfies these properties: So is represented by the cubic polynomials on on and on. 1 of 9 3/1/2006 2:28 PM ne previo Next: Trigonometric Interpolation Up: Spline Interpolation Previous: Piecewise Linear Case Cubic Splines A piece-wise technique which is very popular. Recall the philosophy

More information

A Linear Programming Approach to Concave Approximation and Value Function Iteration

A Linear Programming Approach to Concave Approximation and Value Function Iteration A Linear Programming Approach to Concave Approximation and Value Function Iteration Ronaldo Carpio Takashi Kamihigashi May 18, 2015 Abstract A basic task in numerical computation is to approximate a continuous

More information

Maximizing an interpolating quadratic

Maximizing an interpolating quadratic Week 11: Monday, Apr 9 Maximizing an interpolating quadratic Suppose that a function f is evaluated on a reasonably fine, uniform mesh {x i } n i=0 with spacing h = x i+1 x i. How can we find any local

More information

Interactive Graphics. Lecture 9: Introduction to Spline Curves. Interactive Graphics Lecture 9: Slide 1

Interactive Graphics. Lecture 9: Introduction to Spline Curves. Interactive Graphics Lecture 9: Slide 1 Interactive Graphics Lecture 9: Introduction to Spline Curves Interactive Graphics Lecture 9: Slide 1 Interactive Graphics Lecture 13: Slide 2 Splines The word spline comes from the ship building trade

More information

Rational Bezier Surface

Rational Bezier Surface Rational Bezier Surface The perspective projection of a 4-dimensional polynomial Bezier surface, S w n ( u, v) B i n i 0 m j 0, u ( ) B j m, v ( ) P w ij ME525x NURBS Curve and Surface Modeling Page 97

More information

Interpolation - 2D mapping Tutorial 1: triangulation

Interpolation - 2D mapping Tutorial 1: triangulation Tutorial 1: triangulation Measurements (Zk) at irregular points (xk, yk) Ex: CTD stations, mooring, etc... The known Data How to compute some values on the regular spaced grid points (+)? The unknown data

More information

Lecture 9. Curve fitting. Interpolation. Lecture in Numerical Methods from 28. April 2015 UVT. Lecture 9. Numerical. Interpolation his o

Lecture 9. Curve fitting. Interpolation. Lecture in Numerical Methods from 28. April 2015 UVT. Lecture 9. Numerical. Interpolation his o Curve fitting. Lecture in Methods from 28. April 2015 to ity Interpolation FIGURE A S Splines Piecewise relat UVT Agenda of today s lecture 1 Interpolation Idea 2 3 4 5 6 Splines Piecewise Interpolation

More information

Lecture 25: Bezier Subdivision. And he took unto him all these, and divided them in the midst, and laid each piece one against another: Genesis 15:10

Lecture 25: Bezier Subdivision. And he took unto him all these, and divided them in the midst, and laid each piece one against another: Genesis 15:10 Lecture 25: Bezier Subdivision And he took unto him all these, and divided them in the midst, and laid each piece one against another: Genesis 15:10 1. Divide and Conquer If we are going to build useful

More information

Lecture 9: Introduction to Spline Curves

Lecture 9: Introduction to Spline Curves Lecture 9: Introduction to Spline Curves Splines are used in graphics to represent smooth curves and surfaces. They use a small set of control points (knots) and a function that generates a curve through

More information

What is Multigrid? They have been extended to solve a wide variety of other problems, linear and nonlinear.

What is Multigrid? They have been extended to solve a wide variety of other problems, linear and nonlinear. AMSC 600/CMSC 760 Fall 2007 Solution of Sparse Linear Systems Multigrid, Part 1 Dianne P. O Leary c 2006, 2007 What is Multigrid? Originally, multigrid algorithms were proposed as an iterative method to

More information

99 International Journal of Engineering, Science and Mathematics

99 International Journal of Engineering, Science and Mathematics Journal Homepage: Applications of cubic splines in the numerical solution of polynomials Najmuddin Ahmad 1 and Khan Farah Deeba 2 Department of Mathematics Integral University Lucknow Abstract: In this

More information

Justify all your answers and write down all important steps. Unsupported answers will be disregarded.

Justify all your answers and write down all important steps. Unsupported answers will be disregarded. Numerical Analysis FMN011 2017/05/30 The exam lasts 5 hours and has 15 questions. A minimum of 35 points out of the total 70 are required to get a passing grade. These points will be added to those you

More information

8 Piecewise Polynomial Interpolation

8 Piecewise Polynomial Interpolation Applied Math Notes by R. J. LeVeque 8 Piecewise Polynomial Interpolation 8. Pitfalls of high order interpolation Suppose we know the value of a function at several points on an interval and we wish to

More information

Convergence of C 2 Deficient Quartic Spline Interpolation

Convergence of C 2 Deficient Quartic Spline Interpolation Advances in Computational Sciences and Technology ISSN 0973-6107 Volume 10, Number 4 (2017) pp. 519-527 Research India Publications http://www.ripublication.com Convergence of C 2 Deficient Quartic Spline

More information

Scientific Computing: Interpolation

Scientific Computing: Interpolation Scientific Computing: Interpolation Aleksandar Donev Courant Institute, NYU donev@courant.nyu.edu Course MATH-GA.243 or CSCI-GA.22, Fall 25 October 22nd, 25 A. Donev (Courant Institute) Lecture VIII /22/25

More information

Evaluating the polynomial at a point

Evaluating the polynomial at a point Evaluating the polynomial at a point Recall that we have a data structure for each piecewise polynomial (linear, quadratic, cubic and cubic Hermite). We have a routine that sets evenly spaced interpolation

More information

PRIMAL-DUAL INTERIOR POINT METHOD FOR LINEAR PROGRAMMING. 1. Introduction

PRIMAL-DUAL INTERIOR POINT METHOD FOR LINEAR PROGRAMMING. 1. Introduction PRIMAL-DUAL INTERIOR POINT METHOD FOR LINEAR PROGRAMMING KELLER VANDEBOGERT AND CHARLES LANNING 1. Introduction Interior point methods are, put simply, a technique of optimization where, given a problem

More information

Math 226A Homework 4 Due Monday, December 11th

Math 226A Homework 4 Due Monday, December 11th Math 226A Homework 4 Due Monday, December 11th 1. (a) Show that the polynomial 2 n (T n+1 (x) T n 1 (x)), is the unique monic polynomial of degree n + 1 with roots at the Chebyshev points x k = cos ( )

More information

Curve and Surface Fitting with Splines. PAUL DIERCKX Professor, Computer Science Department, Katholieke Universiteit Leuven, Belgium

Curve and Surface Fitting with Splines. PAUL DIERCKX Professor, Computer Science Department, Katholieke Universiteit Leuven, Belgium Curve and Surface Fitting with Splines PAUL DIERCKX Professor, Computer Science Department, Katholieke Universiteit Leuven, Belgium CLARENDON PRESS OXFORD 1995 - Preface List of Figures List of Tables

More information

Today s class. Roots of equation Finish up incremental search Open methods. Numerical Methods, Fall 2011 Lecture 5. Prof. Jinbo Bi CSE, UConn

Today s class. Roots of equation Finish up incremental search Open methods. Numerical Methods, Fall 2011 Lecture 5. Prof. Jinbo Bi CSE, UConn Today s class Roots of equation Finish up incremental search Open methods 1 False Position Method Although the interval [a,b] where the root becomes iteratively closer with the false position method, unlike

More information

Four equations are necessary to evaluate these coefficients. Eqn

Four equations are necessary to evaluate these coefficients. Eqn 1.2 Splines 11 A spline function is a piecewise defined function with certain smoothness conditions [Cheney]. A wide variety of functions is potentially possible; polynomial functions are almost exclusively

More information

Advanced Operations Research Techniques IE316. Quiz 1 Review. Dr. Ted Ralphs

Advanced Operations Research Techniques IE316. Quiz 1 Review. Dr. Ted Ralphs Advanced Operations Research Techniques IE316 Quiz 1 Review Dr. Ted Ralphs IE316 Quiz 1 Review 1 Reading for The Quiz Material covered in detail in lecture. 1.1, 1.4, 2.1-2.6, 3.1-3.3, 3.5 Background material

More information

A new 8-node quadrilateral spline finite element

A new 8-node quadrilateral spline finite element Journal of Computational and Applied Mathematics 195 (2006) 54 65 www.elsevier.com/locate/cam A new 8-node quadrilateral spline finite element Chong-Jun Li, Ren-Hong Wang Institute of Mathematical Sciences,

More information

Deficient Quartic Spline Interpolation

Deficient Quartic Spline Interpolation International Journal of Computational Science and Mathematics. ISSN 0974-3189 Volume 3, Number 2 (2011), pp. 227-236 International Research Publication House http://www.irphouse.com Deficient Quartic

More information

Iterative Algorithms I: Elementary Iterative Methods and the Conjugate Gradient Algorithms

Iterative Algorithms I: Elementary Iterative Methods and the Conjugate Gradient Algorithms Iterative Algorithms I: Elementary Iterative Methods and the Conjugate Gradient Algorithms By:- Nitin Kamra Indian Institute of Technology, Delhi Advisor:- Prof. Ulrich Reude 1. Introduction to Linear

More information

Introduction to Optimization Problems and Methods

Introduction to Optimization Problems and Methods Introduction to Optimization Problems and Methods wjch@umich.edu December 10, 2009 Outline 1 Linear Optimization Problem Simplex Method 2 3 Cutting Plane Method 4 Discrete Dynamic Programming Problem Simplex

More information

Curve fitting using linear models

Curve fitting using linear models Curve fitting using linear models Rasmus Waagepetersen Department of Mathematics Aalborg University Denmark September 28, 2012 1 / 12 Outline for today linear models and basis functions polynomial regression

More information

Generalised Mean Averaging Interpolation by Discrete Cubic Splines

Generalised Mean Averaging Interpolation by Discrete Cubic Splines Publ. RIMS, Kyoto Univ. 30 (1994), 89-95 Generalised Mean Averaging Interpolation by Discrete Cubic Splines By Manjulata SHRIVASTAVA* Abstract The aim of this work is to introduce for a discrete function,

More information

Mathematical Programming and Research Methods (Part II)

Mathematical Programming and Research Methods (Part II) Mathematical Programming and Research Methods (Part II) 4. Convexity and Optimization Massimiliano Pontil (based on previous lecture by Andreas Argyriou) 1 Today s Plan Convex sets and functions Types

More information

Solving Systems of Spline Equations: A Linear Programming-based Approach

Solving Systems of Spline Equations: A Linear Programming-based Approach Engineering, Test & Technology Boeing Research & Technology Solving Systems of Spline Equations: A Linear Programming-based Approach Thomas Grandine Senior Technical Fellow Support and Analytics Technology

More information

Asymptotic Error Analysis

Asymptotic Error Analysis Asymptotic Error Analysis Brian Wetton Mathematics Department, UBC www.math.ubc.ca/ wetton PIMS YRC, June 3, 2014 Outline Overview Some History Romberg Integration Cubic Splines - Periodic Case More History:

More information

CS321 Introduction To Numerical Methods

CS321 Introduction To Numerical Methods CS3 Introduction To Numerical Methods Fuhua (Frank) Cheng Department of Computer Science University of Kentucky Lexington KY 456-46 - - Table of Contents Errors and Number Representations 3 Error Types

More information

Remark. Jacobs University Visualization and Computer Graphics Lab : ESM4A - Numerical Methods 331

Remark. Jacobs University Visualization and Computer Graphics Lab : ESM4A - Numerical Methods 331 Remark Reconsidering the motivating example, we observe that the derivatives are typically not given by the problem specification. However, they can be estimated in a pre-processing step. A good estimate

More information

SPLINE APPROXIMATION VIA THE CONTROL POLYGON

SPLINE APPROXIMATION VIA THE CONTROL POLYGON SPLINE APPROXIMATION VIA THE CONTROL POLYGON by Håkon Mørk THESIS for the degree of MASTER S DEGREE IN APPLIED MATHEMATICS AND MECHANICS (Master i Anvendt matematikk og mekanikk) Faculty of Mathematics

More information

Solve Non-Linear Parabolic Partial Differential Equation by Spline Collocation Method

Solve Non-Linear Parabolic Partial Differential Equation by Spline Collocation Method Solve Non-Linear Parabolic Partial Differential Equation by Spline Collocation Method P.B. Choksi 1 and A.K. Pathak 2 1 Research Scholar, Rai University,Ahemdabad. Email:pinalchoksey@gmail.com 2 H.O.D.

More information

An introduction to interpolation and splines

An introduction to interpolation and splines An introduction to interpolation and splines Kenneth H. Carpenter, EECE KSU November 22, 1999 revised November 20, 2001, April 24, 2002, April 14, 2004 1 Introduction Suppose one wishes to draw a curve

More information

Moving Beyond Linearity

Moving Beyond Linearity Moving Beyond Linearity The truth is never linear! 1/23 Moving Beyond Linearity The truth is never linear! r almost never! 1/23 Moving Beyond Linearity The truth is never linear! r almost never! But often

More information

Handout 4 - Interpolation Examples

Handout 4 - Interpolation Examples Handout 4 - Interpolation Examples Middle East Technical University Example 1: Obtaining the n th Degree Newton s Interpolating Polynomial Passing through (n+1) Data Points Obtain the 4 th degree Newton

More information

Fall CSCI 420: Computer Graphics. 4.2 Splines. Hao Li.

Fall CSCI 420: Computer Graphics. 4.2 Splines. Hao Li. Fall 2014 CSCI 420: Computer Graphics 4.2 Splines Hao Li http://cs420.hao-li.com 1 Roller coaster Next programming assignment involves creating a 3D roller coaster animation We must model the 3D curve

More information

60 2 Convex sets. {x a T x b} {x ã T x b}

60 2 Convex sets. {x a T x b} {x ã T x b} 60 2 Convex sets Exercises Definition of convexity 21 Let C R n be a convex set, with x 1,, x k C, and let θ 1,, θ k R satisfy θ i 0, θ 1 + + θ k = 1 Show that θ 1x 1 + + θ k x k C (The definition of convexity

More information

Reals 1. Floating-point numbers and their properties. Pitfalls of numeric computation. Horner's method. Bisection. Newton's method.

Reals 1. Floating-point numbers and their properties. Pitfalls of numeric computation. Horner's method. Bisection. Newton's method. Reals 1 13 Reals Floating-point numbers and their properties. Pitfalls of numeric computation. Horner's method. Bisection. Newton's method. 13.1 Floating-point numbers Real numbers, those declared to be

More information

PS Geometric Modeling Homework Assignment Sheet I (Due 20-Oct-2017)

PS Geometric Modeling Homework Assignment Sheet I (Due 20-Oct-2017) Homework Assignment Sheet I (Due 20-Oct-2017) Assignment 1 Let n N and A be a finite set of cardinality n = A. By definition, a permutation of A is a bijective function from A to A. Prove that there exist

More information

COMPUTATIONAL INTELLIGENCE (INTRODUCTION TO MACHINE LEARNING) SS18. Lecture 2: Linear Regression Gradient Descent Non-linear basis functions

COMPUTATIONAL INTELLIGENCE (INTRODUCTION TO MACHINE LEARNING) SS18. Lecture 2: Linear Regression Gradient Descent Non-linear basis functions COMPUTATIONAL INTELLIGENCE (INTRODUCTION TO MACHINE LEARNING) SS18 Lecture 2: Linear Regression Gradient Descent Non-linear basis functions LINEAR REGRESSION MOTIVATION Why Linear Regression? Simplest

More information

Introduction to Programming for Engineers Spring Final Examination. May 10, Questions, 170 minutes

Introduction to Programming for Engineers Spring Final Examination. May 10, Questions, 170 minutes Final Examination May 10, 2011 75 Questions, 170 minutes Notes: 1. Before you begin, please check that your exam has 28 pages (including this one). 2. Write your name and student ID number clearly on your

More information

Contents. I The Basic Framework for Stationary Problems 1

Contents. I The Basic Framework for Stationary Problems 1 page v Preface xiii I The Basic Framework for Stationary Problems 1 1 Some model PDEs 3 1.1 Laplace s equation; elliptic BVPs... 3 1.1.1 Physical experiments modeled by Laplace s equation... 5 1.2 Other

More information

1.2 Numerical Solutions of Flow Problems

1.2 Numerical Solutions of Flow Problems 1.2 Numerical Solutions of Flow Problems DIFFERENTIAL EQUATIONS OF MOTION FOR A SIMPLIFIED FLOW PROBLEM Continuity equation for incompressible flow: 0 Momentum (Navier-Stokes) equations for a Newtonian

More information

CS-184: Computer Graphics

CS-184: Computer Graphics CS-184: Computer Graphics Lecture #12: Curves and Surfaces Prof. James O Brien University of California, Berkeley V2007-F-12-1.0 Today General curve and surface representations Splines and other polynomial

More information

NOTATION AND TERMINOLOGY

NOTATION AND TERMINOLOGY 15.053x, Optimization Methods in Business Analytics Fall, 2016 October 4, 2016 A glossary of notation and terms used in 15.053x Weeks 1, 2, 3, 4 and 5. (The most recent week's terms are in blue). NOTATION

More information

Module 2: Single Step Methods Lecture 4: The Euler Method. The Lecture Contains: The Euler Method. Euler's Method (Analytical Interpretations)

Module 2: Single Step Methods Lecture 4: The Euler Method. The Lecture Contains: The Euler Method. Euler's Method (Analytical Interpretations) The Lecture Contains: The Euler Method Euler's Method (Analytical Interpretations) An Analytical Example file:///g /Numerical_solutions/lecture4/4_1.htm[8/26/2011 11:14:40 AM] We shall now describe methods

More information

and the crooked shall be made straight, and the rough ways shall be made smooth; Luke 3:5

and the crooked shall be made straight, and the rough ways shall be made smooth; Luke 3:5 ecture 8: Knot Insertion Algorithms for B-Spline Curves and Surfaces and the crooked shall be made straight, and the rough ways shall be made smooth; uke 3:5. Motivation B-spline methods have several advantages

More information

Monotonic Cubic Spline Interpolation

Monotonic Cubic Spline Interpolation Monotonic Cubic Spline Interpolation George Wolberg Itzik Alfy Department of Computer Science City College of New York / CUNY New York, NY wolberg@cs-mailengrccnycunyedu Abstract This paper describes the

More information

Lecture 8. Divided Differences,Least-Squares Approximations. Ceng375 Numerical Computations at December 9, 2010

Lecture 8. Divided Differences,Least-Squares Approximations. Ceng375 Numerical Computations at December 9, 2010 Lecture 8, Ceng375 Numerical Computations at December 9, 2010 Computer Engineering Department Çankaya University 8.1 Contents 1 2 3 8.2 : These provide a more efficient way to construct an interpolating

More information

Splines. Parameterization of a Curve. Curve Representations. Roller coaster. What Do We Need From Curves in Computer Graphics? Modeling Complex Shapes

Splines. Parameterization of a Curve. Curve Representations. Roller coaster. What Do We Need From Curves in Computer Graphics? Modeling Complex Shapes CSCI 420 Computer Graphics Lecture 8 Splines Jernej Barbic University of Southern California Hermite Splines Bezier Splines Catmull-Rom Splines Other Cubic Splines [Angel Ch 12.4-12.12] Roller coaster

More information

Chapter 13. Boundary Value Problems for Partial Differential Equations* Linz 2002/ page

Chapter 13. Boundary Value Problems for Partial Differential Equations* Linz 2002/ page Chapter 13 Boundary Value Problems for Partial Differential Equations* E lliptic equations constitute the third category of partial differential equations. As a prototype, we take the Poisson equation

More information

Sung-Eui Yoon ( 윤성의 )

Sung-Eui Yoon ( 윤성의 ) CS480: Computer Graphics Curves and Surfaces Sung-Eui Yoon ( 윤성의 ) Course URL: http://jupiter.kaist.ac.kr/~sungeui/cg Today s Topics Surface representations Smooth curves Subdivision 2 Smooth Curves and

More information

COMPUTATIONAL INTELLIGENCE (CS) (INTRODUCTION TO MACHINE LEARNING) SS16. Lecture 2: Linear Regression Gradient Descent Non-linear basis functions

COMPUTATIONAL INTELLIGENCE (CS) (INTRODUCTION TO MACHINE LEARNING) SS16. Lecture 2: Linear Regression Gradient Descent Non-linear basis functions COMPUTATIONAL INTELLIGENCE (CS) (INTRODUCTION TO MACHINE LEARNING) SS16 Lecture 2: Linear Regression Gradient Descent Non-linear basis functions LINEAR REGRESSION MOTIVATION Why Linear Regression? Regression

More information

Diffusion Wavelets for Natural Image Analysis

Diffusion Wavelets for Natural Image Analysis Diffusion Wavelets for Natural Image Analysis Tyrus Berry December 16, 2011 Contents 1 Project Description 2 2 Introduction to Diffusion Wavelets 2 2.1 Diffusion Multiresolution............................

More information

An introduction to mesh generation Part IV : elliptic meshing

An introduction to mesh generation Part IV : elliptic meshing Elliptic An introduction to mesh generation Part IV : elliptic meshing Department of Civil Engineering, Université catholique de Louvain, Belgium Elliptic Curvilinear Meshes Basic concept A curvilinear

More information

INTERPOLATION BY QUARTIC SPLINE

INTERPOLATION BY QUARTIC SPLINE INTERPOLATION BY QUARTIC SPLINE K.K.Nigam 1, Y.P. Dubey 2, Brajendra Tiwari 3, Anil Shukla 4 1 Mathematics Deptt., LNCT Jabalpur, MP, (India) 2 Sarswati Institution of Engg. & Technology, Jabalpur MP,

More information

Concept of Curve Fitting Difference with Interpolation

Concept of Curve Fitting Difference with Interpolation Curve Fitting Content Concept of Curve Fitting Difference with Interpolation Estimation of Linear Parameters by Least Squares Curve Fitting by Polynomial Least Squares Estimation of Non-linear Parameters

More information

EC422 Mathematical Economics 2

EC422 Mathematical Economics 2 EC422 Mathematical Economics 2 Chaiyuth Punyasavatsut Chaiyuth Punyasavatust 1 Course materials and evaluation Texts: Dixit, A.K ; Sydsaeter et al. Grading: 40,30,30. OK or not. Resources: ftp://econ.tu.ac.th/class/archan/c

More information

A general matrix representation for non-uniform B-spline subdivision with boundary control

A general matrix representation for non-uniform B-spline subdivision with boundary control A general matrix representation for non-uniform B-spline subdivision with boundary control G. Casciola a, L. Romani a a Department of Mathematics, University of Bologna, P.zza di Porta San Donato 5, 40127

More information

x n x n stepnumber k order r error constant C r+1 1/2 5/12 3/8 251/720 abs. stab. interval (α,0) /11-3/10

x n x n stepnumber k order r error constant C r+1 1/2 5/12 3/8 251/720 abs. stab. interval (α,0) /11-3/10 MATH 573 LECTURE NOTES 77 13.8. Predictor-corrector methods. We consider the Adams methods, obtained from the formula xn+1 xn+1 y(x n+1 y(x n ) = y (x)dx = f(x,y(x))dx x n x n by replacing f by an interpolating

More information

Lecture 2 September 3

Lecture 2 September 3 EE 381V: Large Scale Optimization Fall 2012 Lecture 2 September 3 Lecturer: Caramanis & Sanghavi Scribe: Hongbo Si, Qiaoyang Ye 2.1 Overview of the last Lecture The focus of the last lecture was to give

More information

Chapter 18. Geometric Operations

Chapter 18. Geometric Operations Chapter 18 Geometric Operations To this point, the image processing operations have computed the gray value (digital count) of the output image pixel based on the gray values of one or more input pixels;

More information

MATH 2400, Analytic Geometry and Calculus 3

MATH 2400, Analytic Geometry and Calculus 3 MATH 2400, Analytic Geometry and Calculus 3 List of important Definitions and Theorems 1 Foundations Definition 1. By a function f one understands a mathematical object consisting of (i) a set X, called

More information

Lecture 2.2 Cubic Splines

Lecture 2.2 Cubic Splines Lecture. Cubic Splines Cubic Spline The equation for a single parametric cubic spline segment is given by 4 i t Bit t t t i (..) where t and t are the parameter values at the beginning and end of the segment.

More information

Lecture 23: Starting to put it all together #2... More 2-Point Boundary value problems

Lecture 23: Starting to put it all together #2... More 2-Point Boundary value problems Lecture 23: Starting to put it all together #2... More 2-Point Boundary value problems Outline 1) Our basic example again: -u'' + u = f(x); u(0)=α, u(l)=β 2) Solution of 2-point Boundary value problems

More information

Lecture 7: Support Vector Machine

Lecture 7: Support Vector Machine Lecture 7: Support Vector Machine Hien Van Nguyen University of Houston 9/28/2017 Separating hyperplane Red and green dots can be separated by a separating hyperplane Two classes are separable, i.e., each

More information

(Sparse) Linear Solvers

(Sparse) Linear Solvers (Sparse) Linear Solvers Ax = B Why? Many geometry processing applications boil down to: solve one or more linear systems Parameterization Editing Reconstruction Fairing Morphing 2 Don t you just invert

More information

Lacunary Interpolation Using Quartic B-Spline

Lacunary Interpolation Using Quartic B-Spline General Letters in Mathematic, Vol. 2, No. 3, June 2017, pp. 129-137 e-issn 2519-9277, p-issn 2519-9269 Available online at http:\\ www.refaad.com Lacunary Interpolation Using Quartic B-Spline 1 Karwan

More information

Finite Element Analysis Prof. Dr. B. N. Rao Department of Civil Engineering Indian Institute of Technology, Madras. Lecture - 24

Finite Element Analysis Prof. Dr. B. N. Rao Department of Civil Engineering Indian Institute of Technology, Madras. Lecture - 24 Finite Element Analysis Prof. Dr. B. N. Rao Department of Civil Engineering Indian Institute of Technology, Madras Lecture - 24 So in today s class, we will look at quadrilateral elements; and we will

More information

The Fundamentals of Economic Dynamics and Policy Analyses: Learning through Numerical Examples. Part II. Dynamic General Equilibrium

The Fundamentals of Economic Dynamics and Policy Analyses: Learning through Numerical Examples. Part II. Dynamic General Equilibrium The Fundamentals of Economic Dynamics and Policy Analyses: Learning through Numerical Examples. Part II. Dynamic General Equilibrium Hiroshi Futamura The objective of this paper is to provide an introductory

More information

REGULAR GRAPHS OF GIVEN GIRTH. Contents

REGULAR GRAPHS OF GIVEN GIRTH. Contents REGULAR GRAPHS OF GIVEN GIRTH BROOKE ULLERY Contents 1. Introduction This paper gives an introduction to the area of graph theory dealing with properties of regular graphs of given girth. A large portion

More information

Topology optimization in B-spline space

Topology optimization in B-spline space Topology optimization in B-spline space Xiaoping Qian Mechanical, Materials, and Aerospace Engineering Department Illinois Institute of Technology Chicago, IL 60062, USA Email: qian@iit.edu Highlights

More information

Know it. Control points. B Spline surfaces. Implicit surfaces

Know it. Control points. B Spline surfaces. Implicit surfaces Know it 15 B Spline Cur 14 13 12 11 Parametric curves Catmull clark subdivision Parametric surfaces Interpolating curves 10 9 8 7 6 5 4 3 2 Control points B Spline surfaces Implicit surfaces Bezier surfaces

More information

Finite Element Methods

Finite Element Methods Chapter 5 Finite Element Methods 5.1 Finite Element Spaces Remark 5.1 Mesh cells, faces, edges, vertices. A mesh cell is a compact polyhedron in R d, d {2,3}, whose interior is not empty. The boundary

More information

Fitting to a set of data. Lecture on fitting

Fitting to a set of data. Lecture on fitting Fitting to a set of data Lecture on fitting Linear regression Linear regression Residual is the amount difference between a real data point and a modeled data point Fitting a polynomial to data Could use

More information

TO DUY ANH SHIP CALCULATION

TO DUY ANH SHIP CALCULATION TO DUY ANH SHIP CALCULATION Ship Calculattion (1)-Space Cuvers 3D-curves play an important role in the engineering, design and manufature in Shipbuilding. Prior of the development of mathematical and computer

More information

EECS 556 Image Processing W 09. Interpolation. Interpolation techniques B splines

EECS 556 Image Processing W 09. Interpolation. Interpolation techniques B splines EECS 556 Image Processing W 09 Interpolation Interpolation techniques B splines What is image processing? Image processing is the application of 2D signal processing methods to images Image representation

More information

Important Properties of B-spline Basis Functions

Important Properties of B-spline Basis Functions Important Properties of B-spline Basis Functions P2.1 N i,p (u) = 0 if u is outside the interval [u i, u i+p+1 ) (local support property). For example, note that N 1,3 is a combination of N 1,0, N 2,0,

More information

Computational Economics and Finance

Computational Economics and Finance Computational Economics and Finance Part I: Elementary Concepts of Numerical Analysis Spring 2016 Outline Computer arithmetic Error analysis: Sources of error Error propagation Controlling the error Rates

More information

Parameterization of triangular meshes

Parameterization of triangular meshes Parameterization of triangular meshes Michael S. Floater November 10, 2009 Triangular meshes are often used to represent surfaces, at least initially, one reason being that meshes are relatively easy to

More information

Polynomial Approximation and Interpolation Chapter 4

Polynomial Approximation and Interpolation Chapter 4 4.4 LAGRANGE POLYNOMIALS The direct fit polynomial presented in Section 4.3, while quite straightforward in principle, has several disadvantages. It requires a considerable amount of effort to solve the

More information

Introduction to Mathematical Programming IE406. Lecture 20. Dr. Ted Ralphs

Introduction to Mathematical Programming IE406. Lecture 20. Dr. Ted Ralphs Introduction to Mathematical Programming IE406 Lecture 20 Dr. Ted Ralphs IE406 Lecture 20 1 Reading for This Lecture Bertsimas Sections 10.1, 11.4 IE406 Lecture 20 2 Integer Linear Programming An integer

More information

CS-184: Computer Graphics. Today

CS-184: Computer Graphics. Today CS-84: Computer Graphics Lecture #5: Curves and Surfaces Prof. James O Brien University of California, Berkeley V25F-5-. Today General curve and surface representations Splines and other polynomial bases

More information

The use of the Spectral Properties of the Basis Splines in Problems of Signal Processing

The use of the Spectral Properties of the Basis Splines in Problems of Signal Processing The use of the Spectral Properties of the Basis Splines in Problems of Signal Processing Zaynidinov Hakim Nasiritdinovich, MirzayevAvazEgamberdievich, KhalilovSirojiddinPanjievich Doctor of Science, professor,

More information