CS412: Introduction to Numerical Methods

Similar documents
CS 323: Numerical Analysis and Computing

CS 323: Numerical Analysis and Computing

Midterm Review. Igor Yanovsky (Math 151A TA)

CS 323: Numerical Analysis and Computing

5. Hand in the entire exam booklet and your computer score sheet.

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

Mathematics for Engineers. Numerical mathematics

3.1 Interpolation and the Lagrange Polynomial

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

Jim Lambers MAT 460/560 Fall Semester Practice Final Exam

INTRODUCTION TO COMPUTATIONAL MATHEMATICS

NUMERICAL METHODS. x n+1 = 2x n x 2 n. In particular: which of them gives faster convergence, and why? [Work to four decimal places.

CS 257: Numerical Methods

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

Introductory Numerical Analysis

Chapter 1: Introduction and mathematical preliminaries

Math 128A: Homework 2 Solutions

Calculus of Variations

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

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

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

Notes for Chapter 1 of. Scientific Computing with Case Studies

GENG2140, S2, 2012 Week 7: Curve fitting

Homework and Computer Problems for Math*2130 (W17).

Arithmetic and Error. How does error arise? How does error arise? Notes for Part 1 of CMSC 460

Review. Numerical Methods Lecture 22. Prof. Jinbo Bi CSE, UConn

1 Review of Interpolation using Cubic Splines

Computer Arithmetic. MATH 375 Numerical Analysis. J. Robert Buchanan. Fall Department of Mathematics. J. Robert Buchanan Computer Arithmetic

Nonlinearity Root-finding Bisection Fixed Point Iteration Newton s Method Secant Method Conclusion. Nonlinear Systems

MAT 460: Numerical Analysis I. James V. Lambers

BACHELOR OF COMPUTER APPLICATIONS (BCA) (Revised) Term-End Examination December, 2015 BCS-054 : COMPUTER ORIENTED NUMERICAL TECHNIQUES

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

Math 365 Homework 5 Due April 6, 2018 Grady Wright

Scientific Computing: An Introductory Survey

Review all the activities leading to Midterm 3. Review all the problems in the previous online homework sets (8+9+10).


Applied Math 205. Full office hour schedule:

Lecture 7: Numerical Tools

MA/OR/ST 706: Nonlinear Programming Midterm Exam Instructor: Dr. Kartik Sivaramakrishnan INSTRUCTIONS

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

Unit 1 Vocabulary. A function that contains 1 or more or terms. The variables may be to any non-negative power.

Introduction CSE 541

Computational Methods CMSC/AMSC/MAPL 460. Solving nonlinear equations and zero finding. Finding zeroes of functions

2-2: Evaluate and Graph Polynomial Functions

Lecture 10 Polynomial interpolation

Math Numerical Analysis Mid-Term Test Solutions

CHAPTER 4. Interpolation

ECE 204 Numerical Methods for Computer Engineers MIDTERM EXAMINATION /8:00-9:30

BSM510 Numerical Analysis

ECE580 Exam 1 October 4, Please do not write on the back of the exam pages. Extra paper is available from the instructor.

Math 131 Exam 1 October 4, :00-9:00 p.m.

Numerical Methods. King Saud University

A THEORETICAL INTRODUCTION TO NUMERICAL ANALYSIS

Tu: 9/3/13 Math 471, Fall 2013, Section 001 Lecture 1

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

Lectures 9-10: Polynomial and piecewise polynomial interpolation

NUMERICAL AND STATISTICAL COMPUTING (MCA-202-CR)

PowerPoints organized by Dr. Michael R. Gustafson II, Duke University

Notes on floating point number, numerical computations and pitfalls

Numerical Methods I: Polynomial Interpolation

THE SECANT METHOD. q(x) = a 0 + a 1 x. with

Interpolation. Chapter Interpolation. 7.2 Existence, Uniqueness and conditioning

SPLINE INTERPOLATION

UNIT-II INTERPOLATION & APPROXIMATION

Final Year M.Sc., Degree Examinations

Solutions 2. January 23, x x

Math 7824 Spring 2010 Numerical solution of partial differential equations Classroom notes and homework

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

Scientific Computing: An Introductory Survey

University of Connecticut Department of Mathematics

CS 450 Numerical Analysis. Chapter 5: Nonlinear Equations

FALL 2018 MATH 4211/6211 Optimization Homework 4

Numerical Algorithms. IE 496 Lecture 20

Test 2. Monday, November 12, 2018

Numerical Analysis Preliminary Exam 10 am to 1 pm, August 20, 2018

Introduction and mathematical preliminaries

MA2501 Numerical Methods Spring 2015

Algebra 2 CP Semester 1 PRACTICE Exam

Applied Numerical Analysis Quiz #2

Chapter 6. Nonlinear Equations. 6.1 The Problem of Nonlinear Root-finding. 6.2 Rate of Convergence

CS 154 Introduction to Automata and Complexity Theory

MAT 107 College Algebra Fall 2013 Name. Final Exam, Version X

Review for Cumulative Test 2

MIDTERM SOLUTIONS: FALL 2012 CS 6375 INSTRUCTOR: VIBHAV GOGATE

Evaluate and simplify.

Q 0 x if x 0 x x 1. S 1 x if x 1 x x 2. i 0,1,...,n 1, and L x L n 1 x if x n 1 x x n

A Partial List of Topics: Math Spring 2009

1 Motivation for Newton interpolation

Nonlinearity Root-finding Bisection Fixed Point Iteration Newton s Method Secant Method Conclusion. Nonlinear Systems

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

Curve Fitting and Interpolation

Lösning: Tenta Numerical Analysis för D, L. FMN011,

Analysis Methods in Atmospheric and Oceanic Science

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

Numerical Analysis. EE, NCKU Tien-Hao Chang (Darby Chang)

CISE-301: Numerical Methods Topic 1:

Numerical techniques to solve equations

Deterministic Global Optimization for Dynamic Systems Using Interval Analysis

8.3 Numerical Quadrature, Continued

Numerical Analysis: Interpolation Part 1

Transcription:

CS412: Introduction to Numerical Methods MIDTERM #1 2:30PM - 3:45PM, Tuesday, 03/10/2015 Instructions: This exam is a closed book and closed notes exam, i.e., you are not allowed to consult any textbook, your class notes, homeworks, or any of the handouts from us. You are not permitted to refer to any other material either (including, of course, online material). No use of computers, cell phones, etc. is permitted. Name University ID Part #1 Part #2 Part #3 Part #4 Part #5 TOTAL 1

1. [30% = 5 questions 6% each] MULTIPLE CHOICE SECTION. Circle or underline the correct answer (or answers). No justification is required for your answer(s). (a) In scientific notation, x = ±a 2 b, where a is the mantissa and b is the exponent. In single precision, we store k = 23 binary digits, and the exponent b ranges between 126 b 127. The largest number we can thus represent is: i. (2 2 22 ) 2 127 ii. (2 2 23 ) 2 127 iii. (2 2 23 ) 2 126 (b) The machine epsilon ε is defined as the smallest positive number that would actually achieve 1 + ε 1. With single precision numbers, i. ε = 2 23 (if by convention we always use truncation) ii. ε = 2 23 (if by convention we always use rounding) iii. ε = 2 24 (if by convention we always use rounding) (c) In practice, Secant s method is preferred over Newton s method because: i. It is always guaranteed to converge, while Newton s method is not. ii. It is computationally cheaper than Newton s method. iii. It does not require computing the derivative. (d) In practice, the order of convergence of Newton s method is: i. always 2, if f does not have a multiple root. ii. somewhere between 1 and 2, if f does not have a multiple root, because it is not always guaranteed to converge and so is used in combination with bisection search. iii. 1 if the unknown function f has a multiple root and its explicit formula is known. (e) Which of the following are valid reasons for using piecewise polynomial interpolation, as opposed to using a single polynomial? i. In the monomial basis, piecewise polynomials are cheaper to compute than high-degree polynomials. ii. Piecewise polynomials can be extended to include more data points, while it is impossible to update a single polynomial interpolant incrementally to include additional points. iii. High-degree polynomials can suffer from global changes when a single data point is perturbed, while piecewise polynomials only change locally. 2

2. [24% = 3 questions 8% each] SHORT ANSWER SECTION. Answer each of the following questions in no more than 2-3 sentences. (a) Even if the cost of solving a linear system was cheap, what would be a good reason to still not use Vandermonde interpolation? (b) Describe two benefits of using Chebyshev points for polynomial interpolation. (c) Give an example to show that Hermite interpolation does not guarantee continuity of the second derivative between piecewise polynomials. 3

3. [14%] Use Lagrange interpolation to find a cubic polynomial in the monomial basis that interpolates the following four data points: ( 4, 3), ( 2, 1), (0, 2), (1, 1) Reminder: Lagrange polynomials are given by the formula: j i l i (x) = (x x j) j i (x i x j ) 4

4. [12%] Using any of the methods we discussed in class, find a cubic polynomial s(x) in the monomial basis, defined over [0, 1], that satisfies: s(0) = 1 s (0) = 1 s(1) = 2 s (1) = 3 Note: In case you decide to use the Hermite basis polynomials, those are given below: h 00 (x) = 2x 3 3x 2 + 1 h 01 (x) = 2x 3 + 3x 2 h 10 (x) = x 3 2x 2 + x h 11 (x) = x 3 x 2 5

5. [20%] Consider a piecewise quadratic polynomial function s(x) that interpolates the n data points (x 1, y 1 ),..., (x n, y n ). In each subinterval I k = [x k, x k+1 ], we define s(x) as a quadratic polynomial s k (x) = a (k) 2 x 2 + a (k) 1 x + a (k) 0, such that: For k = 1, 2,..., n 2, s k (x) should interpolate points (x k, y k ), (x k+1, y k+1 ) and (x k+2, y k+2 ), s n 1 (x) should interpolate (x n 2, y n 2 ), (x n 1, y n 1 ) and (x n, y n ). Derive a bound for the interpolation error f(x) s(x). You may assume that the length h k = x k+1 x k of each subinterval is constant and equal to h. Note: You may find the following theorem useful. Theorem 1. Let x 0 < x 1 <... < x n 1 < x n y n = f(x n ), k = 0, 1,..., n, where f is a function which is n-times differentiable with continuous derivatives P n (x) is a polynomial that interpolates (x 0, y 0 ), (x 1, y 1 )..., (x n, y n ) then for any x (x 0, x n ), there exists a θ = θ(x) (x 0, x n ) such that f(x) P n (x) = f (n+1) (θ) (n + 1)! (x x 0)(x x 1 )... (x x n ) 6

7

8