Lecture 39 Numerical Analysis. Chapter 7 Ordinary Differential Equations.

Slides:



Advertisements
Similar presentations
Chapter 6 Differential Equations
Advertisements

SE301: Numerical Methods Topic 8 Ordinary Differential Equations (ODEs) Lecture KFUPM Read , 26-2, 27-1 CISE301_Topic8L8&9 KFUPM.
Section 7.2: Direction Fields and Euler’s Methods Practice HW from Stewart Textbook (not to hand in) p. 511 # 1-13, odd.
Chapter 7 Numerical Differentiation and Integration
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Ordinary Differential Equations Equations which are.
A second order ordinary differential equation has the general form
Ch 5.2: Series Solutions Near an Ordinary Point, Part I
ECIV 301 Programming & Graphics Numerical Methods for Engineers Lecture 31 Ordinary Differential Equations.
Initial-Value Problems
8-1 Chapter 8 Differential Equations An equation that defines a relationship between an unknown function and one or more of its derivatives is referred.
Ch 5.4: Euler Equations; Regular Singular Points
Ch 5.5: Euler Equations A relatively simple differential equation that has a regular singular point is the Euler equation, where ,  are constants. Note.
Numerical Solutions of Ordinary Differential Equations
NUMERICAL SOLUTION OF ORDINARY DIFFERENTIAL EQUATIONS
Chapter 6 Numerical Interpolation
CISE301_Topic8L31 SE301: Numerical Methods Topic 8 Ordinary Differential Equations (ODEs) Lecture KFUPM (Term 101) Section 04 Read , 26-2,
Differential Equations and Boundary Value Problems
Numerical Solution of Ordinary Differential Equation
Numerical solution of Differential and Integral Equations PSCi702 October 19, 2005.
1 Chapter 6 Numerical Methods for Ordinary Differential Equations.
PART 7 Ordinary Differential Equations ODEs
Boyce/DiPrima 9 th ed, Ch 3.1: 2 nd Order Linear Homogeneous Equations-Constant Coefficients Elementary Differential Equations and Boundary Value Problems,
Ch 8.1 Numerical Methods: The Euler or Tangent Line Method
Boyce/DiPrima 9th ed, Ch 8.4: Multistep Methods Elementary Differential Equations and Boundary Value Problems, 9th edition, by William E. Boyce and Richard.
Lecture 35 Numerical Analysis. Chapter 7 Ordinary Differential Equations.
EE3561_Unit 8Al-Dhaifallah14351 EE 3561 : Computational Methods Unit 8 Solution of Ordinary Differential Equations Lesson 3: Midpoint and Heun’s Predictor.
Modeling and simulation of systems Numerical methods for solving of differential equations Slovak University of Technology Faculty of Material Science.
Lecture 8 Numerical Analysis. Solution of Non-Linear Equations Chapter 2.
Integration of 3-body encounter. Figure taken from
Lecture 6 Numerical Analysis. Solution of Non-Linear Equations Chapter 2.
Numerical Methods.
Scientific Computing Multi-Step and Predictor-Corrector Methods.
CHAPTER 3 NUMERICAL METHODS
Lecture 22 Numerical Analysis. Chapter 5 Interpolation.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Part 7 - Chapter 25.
Ch 8.2: Improvements on the Euler Method Consider the initial value problem y' = f (t, y), y(t 0 ) = y 0, with solution  (t). For many problems, Euler’s.
Math 3120 Differential Equations with Boundary Value Problems
PHY 301: MATH AND NUM TECH Contents Chapter 10: Numerical Techniques I. Integration A.Intro B.Euler  Recall basic  Predictor-Corrector C. Runge-Kutta.
Today’s class Ordinary Differential Equations Runge-Kutta Methods
Lecture 40 Numerical Analysis. Chapter 7 Ordinary Differential Equations.
10.1 Definition of differential equation, its order, degree,
Ordinary Differential Equations
ACSL, POSTECH1 MATLAB 입문 CHAPTER 8 Numerical Calculus and Differential Equations.
1/14  5.2 Euler’s Method Compute the approximations of y(t) at a set of ( usually equally-spaced ) mesh points a = t 0 < t 1
NUMERICAL DIFFERENTIATION or DIFFERENCE APPROXIMATION Used to evaluate derivatives of a function using the functional values at grid points. They are.
This chapter is concerned with the problem in the form Chapter 6 focuses on how to find the numerical solutions of the given initial-value problems. Main.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Part 6 - Chapters 22 and 23.
CSE 330 Numerical Methods Lecture 05 Chapter 5: Numerical Differentiation Md. Omar Faruqe
CISE301_Topic8L71 CISE301: Numerical Methods Topic 8 Ordinary Differential Equations (ODEs) Lecture KFUPM (Term 101) Section 04 Read , 26-2,
Keywords (ordinary/partial) differencial equation ( 常 / 偏 ) 微分方程 difference equation 差分方程 initial-value problem 初值问题 convex 凸的 concave 凹的 perturbed problem.
Part 7 - Chapter 25.
Chapter 7 Numerical Differentiation and Integration
Numerical Analysis Lecture12.
Ordinary Differential Equations
Advanced Numerical Methods (S. A. Sahu) Code: AMC 51151
A second order ordinary differential equation has the general form
Class Notes 18: Numerical Methods (1/2)
Numerical Solutions of Ordinary Differential Equations
Solution of Equations by Iteration
Numerical Analysis Lecture 45.
Chapter 26.
Numerical Analysis Lecture 23.
Sec 21: Analysis of the Euler Method
Part 7 - Chapter 25.
Numerical Analysis Lecture 19.
Numerical Analysis Lecture 37.
Numerical Analysis Lecture 38.
Numerical Analysis Lecture 2.
Numerical Analysis Lecture 36.
Presentation transcript:

Lecture 39 Numerical Analysis

Chapter 7 Ordinary Differential Equations

Introduction Taylor Series Euler Method Runge-Kutta Method Predictor Corrector Method

PREDICTOR – CORRECTOR METHOD

The methods presented so far are called single-step methods, where we have seen that the computation of y at t n+1 that is y n+1 requires the knowledge of y n only.

In predictor-corrector methods which we will discuss now, is also known as multi-step methods. To compute the value of y at t n+1, we must know the solution y at t n, t n-1, t n-2, etc.

Thus, a predictor formula is used to predict the value of y at t n+1 and then a corrector formula is used to improve the value of y n+1. Let us consider an IVP

Using simple Euler’s and modified Euler’s method, we can write down a simple predictor-corrector pair (P – C) as

Here, y n+1 (1) is the first corrected value of y n+1. The corrector formula may be used iteratively as defined below: The iteration is terminated when two successive iterates agree to the desired accuracy

In this pair, to extrapolate the value of y n+1, we have approximated the solution curve in the interval (t n, t n+1 ) by a straight line passing through (t n, y n ) and (t n+1, y n+1 ).

The accuracy of the predictor formula can be improved by considering a quadratic curve through the equally spaced points (t n-1, y n-1 ), (t n, y n ), (t n+1, y n+1 )

Suppose we fit a quadratic curve of the form where a, b, c are constants to be determined

As the curve passes through (t n-1, y n-1 ) and (t n, y n ) and satisfies we obtain Therefore

and Which gives or

Substituting these values of a, b and c into the quadratic equation, we get That is,

Thus, instead of considering the P-C pair, we may consider the P-C pair given by The essential difference between them is, the one given above is more accurate

However, this one can not be used to predict y n+1 for a given IVP, because its use require the knowledge of past two points. In such a situation, a R-K method is generally used to start the predictor method.

Milne’s Method It is also a multi-step method where we assume that the solution to the given IVP is known at the past four equally spaced point t 0, t 1, t 2 and t 3.

To derive Milne’s predictor- corrector pair, let us consider a typical IVP

On integration between the limits t 0 and t 4, we get

But we know from Newton’s forward difference formula where

Now, by changing the variable of integration (from t to s), the limits of integration also changes (from 0 to 4), and thus the above expression becomes

which simplifies to Substituting the differences It can be further simplified to

Alternatively, it can also be written as This is known as Milne’s predictor formula.

Similarly, integrating the original over the interval t 0 to t 2 or s = 0 to 2 and repeating the above steps, we get which is known as Milne’s corrector formula.

In general, Milne’s predictor- corrector pair can be written as

From these equations, we observe that the magnitude of the truncation error in corrector formula is while the truncation error in predictor formula is Thus: TE in, c-formula is less than the TE in p-formula.

In order to apply this P – C method to solve numerically any initial value problem, we first predict the value of y n+1 by means of predictor formula, where derivatives are computed using the given differential equation itself.

Using the predicted value y n+1, we calculate the derivativ y’ n+1 rom the given differential equation and then we use the corrector formula of the pair to have the corrected value of y n+1 Using the predicted value y n+1, we calculate the derivative y’ n+1 from the given differential equation and then we use the corrector formula of the pair to have the corrected value of y n+1

This in turn may be used to obtain improved value of y n+1 by using corrector again. This in turn may be used to obtain improved value of y n+1 by using the corrector again. This cycle is repeated until we achieve the required accuracy.

Example Find y (2.0) if y ( t ) is the solution of y (0) = 2, y (0.5) = 2.636, y (1.0) = and y(1.5) = Use Milne’s P-C method.

Solution Taking t 0 = 0.0, t 1 = 0.5, t 2 = 1.0, t 3 = 1.5 y 0, y 1, y 2 and y 3, are given, we have to compute y 4, the solution of the given differential equation corresponding to t =2.0

The Milne’s P – C pair is given as

From the given differential equation, We have, We have,

Now, using predictor formula, we compute

Using this predicted value, we shall compute the improved value of y 4 from corrector formula

Using the available predicted value y 4 and the initial values, we compute

Thus, the first corrected value of y 4 is given by

Suppose, we apply the corrector formula again, then we have Finally, y (2.0) = y 4 =

Example Tabulate the solution of in the interval [0, 0.4] with h = 0.1, using Milne’s P-C method.

Solution Milne’s P-C method demand the solution at first four points t 0, t 1, t 2 and t 3. As it is not a self – starting method, we shall use R-K method of fourth order to get the required solution and then switch over to Milne’s P – C method.

Thus, taking t 0 = 0, t 1 = 0.1, t 2 = 0.2, t 3 = 0.3 we get the corresponding y values using R–K method of 4 th order; that is y 0 = 1, y 1 = , y 2 = and y 3 = (Reference Lecture 38)

Now, we compute

Using Milne’s predictor formula

Before using corrector formula, we compute

Finally, using Milne’s corrector formula, we compute

The required solution is: t y

Lecture 39 Numerical Analysis