Assignment 3 Questions 1 and 2 Stephen Adams CS 4MN3

Slides:



Advertisements
Similar presentations
Arc-length computation and arc-length parameterization
Advertisements

Numerical Integration
Polynomial Approximation PSCI 702 October 05, 2005.
Numerical Differentiation and Quadrature (Integration) 1Daniel Baur / Numerical Methods for Chemical Engineers / Numerical Quadrature Daniel Baur ETH Zurich,
Today’s class Romberg integration Gauss quadrature Numerical Methods
MATH 685/ CSI 700/ OR 682 Lecture Notes
Selected from presentations by Jim Ramsay, McGill University, Hongliang Fei, and Brian Quanz Basis Basics.
Chapter 18 Interpolation The Islamic University of Gaza
1 Chapter 4 Interpolation and Approximation Lagrange Interpolation The basic interpolation problem can be posed in one of two ways: The basic interpolation.
1 Curve-Fitting Spline Interpolation. 2 Curve Fitting Regression Linear Regression Polynomial Regression Multiple Linear Regression Non-linear Regression.
ES 240: Scientific and Engineering Computation. InterpolationPolynomial  Definition –a function f(x) that can be written as a finite series of power functions.
Experimental Modeling
ECIV 301 Programming & Graphics Numerical Methods for Engineers Lecture 30 Numerical Integration & Differentiation.
MANE 4240 & CIVL 4240 Introduction to Finite Elements Numerical Integration in 1D Prof. Suvranu De.
Revision.
The Islamic University of Gaza Faculty of Engineering Civil Engineering Department Numerical Analysis ECIV 3306 Chapter 22 Integration of Equations.
ECIV 301 Programming & Graphics Numerical Methods for Engineers Lecture 23 CURVE FITTING Chapter 18 Function Interpolation and Approximation.
ECIV 301 Programming & Graphics Numerical Methods for Engineers Lecture 24 Regression Analysis-Chapter 17.
ECIV 301 Programming & Graphics Numerical Methods for Engineers REVIEW II.
CISE-301: Numerical Methods Topic 1: Introduction to Numerical Methods and Taylor Series Lectures 1-4: KFUPM.
1 Chapter 5 Numerical Integration. 2 A Review of the Definite Integral.
3. Numerical integration (Numerical quadrature) .
MECN 3500 Inter - Bayamon Lecture Numerical Methods for Engineering MECN 3500 Professor: Dr. Omar E. Meza Castillo
1 Chapter 7 NUMERICAL INTEGRATION. 2 PRELIMINARIES We use numerical integration when the function f(x) may not be integrable in closed form or even in.
1 Numerical Analysis Lecture 12 Numerical Integration Dr. Nader Okasha.
Numerical Differential & Integration. Introduction If a function f(x) is defined as an expression, its derivative or integral is determined using analytical.
CMPS1371 Introduction to Computing for Engineers NUMERICAL METHODS.
MA2213 Lecture 4 Numerical Integration. Introduction Definition is the limit of Riemann sums I(f)
CISE-301: Numerical Methods Topic 1: Introduction to Numerical Methods and Taylor Series Lectures 1-4: KFUPM CISE301_Topic1.
CISE301_Topic11 CISE-301: Numerical Methods Topic 1: Introduction to Numerical Methods and Taylor Series Lectures 1-4:
EE 3561_Unit_1(c)Al-Dhaifallah EE 3561 : - Computational Methods in Electrical Engineering Unit 1: Introduction to Computational Methods and Taylor.
Introduction to Numerical Analysis I MATH/CMPSC 455 Fall 2011 Instructor: Xiaozhe Hu (Shawn)
Lecture 22 - Exam 2 Review CVEN 302 July 29, 2002.
Splines and applications
1. Interpolating polynomials Polynomial of degree n,, is a linear combination of Definitions: (interval, continuous function, abscissas, and polynomial)
By Adam Mallen.  What is it?  How is it different from regression?  When would you use it?  What can go wrong?  How do we find the interpolating.
Computer Programming (TKK-2144) 13/14 Semester 1 Instructor: Rama Oktavian Office Hr.: M.13-15, W Th , F
Mohiuddin Ahmad SUNG-BONG JANG Interpolation II (8.4 SPLINE INTERPOLATION) (8.5 MATLAB’s INTERPOLATION Functions)
L5 – Curves in GIS NGEN06 & TEK230: Algorithms in Geographical Information Systems by: Sadegh Jamali (source: Lecture notes in GIS, Lars Harrie) 1 L5-
Cubic Spline Interpolation. Cubic Splines attempt to solve the problem of the smoothness of a graph as well as reduce error. Polynomial interpolation.
Spline Interpolation A Primer on the Basics by Don Allen.
By: Mark Coose Joetta Swift Micah Weiss. What Problems Can Interpolation Solve? Given a table of values, find a simple function that passes through the.
6. Numerical Integration 6.1 Definition of numerical integration. 6.2 Reasons to use numerical integration. 6.3 Formulas of numerical Integration. 6.4.
1/7  4.6 Adaptive Quadrature Methods Chapter 4 Numerical Differentiation and Integration -- Adaptive Quadrature Methods   /2  /4  /8 Predict the.
1 Chapter 4 Interpolation and Approximation Lagrange Interpolation The basic interpolation problem can be posed in one of two ways: The basic interpolation.
Math 495B Polynomial Interpolation Special case of a step function. Frederic Gibou.
Quadrature – Concepts (numerical integration) Don Allen.
Interpolation - Introduction
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Chapter 20 Numerical Integration of Functions.
CHEM-E7130 Process Modeling Lecture 6
ECE3340 Numerical Fitting, Interpolation and Approximation
NUMERICAL INTEGRATION
Curve-Fitting Spline Interpolation
Chapter 15 Curve Fitting : Splines
Chapter 22.
Interpolation.
Class Notes 18: Numerical Methods (1/2)
Chapter 7 Numerical Differentiation and Integration
Spline Interpolation Class XVII.
NUMERICAL INTEGRATION
POLYNOMIAL INTERPOLATION
5.3 Higher-Order Taylor Methods
Basis Expansions and Generalized Additive Models (1)
ANSWER THE FOLLOWING BRIEFLY BUT COMPREHENSIVELY.
SKTN 2393 Numerical Methods for Nuclear Engineers
Interpolation Theory Section 1
Introduction CSE 541.
CISE-301: Numerical Methods Topic 1: Introduction to Numerical Methods and Taylor Series Lectures 1-4: KFUPM CISE301_Topic1.
Numerical Integration
Presentation transcript:

Assignment 3 Questions 1 and 2 Stephen Adams 0386110 CS 4MN3 March 17, 2009

Q1: Runge’s Phenomenon Clearly shown in the Cauchy-Lorentz function (Its importance in physics is due to it being the solution to the differential equation describing forced resonance) variable in denominator = full set of derivatives important because error is bound by derivatives Consider Clearly grows as higher order approximations are used

Q1: Runge’s Phenomenon Red = exact Blue = 5th order i.p. Green = 9th order i.p. Can be countered with non-equidistant intervals or by use of splines.

Natural Cubic Spline A spline is a special piecewise polynomial especially useful for interpolation and curve smoothing Splines work well with both uniform and non-uniform node distributions Advantages to a degree 3 spline are curve is highly flexible (due to extra critical point) can be reverse-engineered from a real solution to provide real co-efficients avoids Runge’s phenomenon

Construction Given function F: define the set S of cubic polynomials S1(x1)…Sn(xn) for each xi, x=[0,n] F(xi) = Si(xi) x=[1,n-1] Si(xi)’, Si(xi)’’ are continuous s’’(0) = s’’(xn) = 0 (eg linear)

Natural? s’’(0) = s’’(xn) = 0 (eg linear) This condition completes the set of equations and leads to a tridiagonal system that can be easily solved to provide the co-efficients of the polynomials Question 1 stores the co-efficient vectors as they are re-used frequently (why recalculate all the time?)

Q2: Error function The Gauss error function occours frequently in probability and differential equations. It is very sensitive about x = 0

IEEE Floats, lots near 0 How close to 0 that the problem exists is implementation dependant but consider IEEE-754 SP range 0, +/-2[-128,127] ~half are on [0,1) or (-1,0] IEEE-754 DP range 0, +/-2[-1024, 1023] 2-1024 is very close to 0 … denorms are even worse … 2-1074

QuadR Quadr is designed to perform adaptive quadrature using the rectangle rule (see also quad for Simpson’s rule) If the width of the rectangle is allowed to go to 0, then we have exactly the integral Here the function value is computed for the mid-point of each rectangle, which can be prohibitive

Adaptive Quadrature Adaptive techniques attempt to reduce the prohibitive cost by employing wide rectangles on areas where the function has low order (or linear) derivatives This allows more precision in sensitive areas of the function Determining overall error can be tested by several techniques, such as using multiple quadrature approaches or comparing to a table of known values.

Sources used Wikipedia Course notes Wolfram Mathworld Mathworks.com