340 likes | 757 Views
Scientific Computing. Multi-Step and Predictor-Corrector Methods. Overview. One-Step Methods – use only info from previous step Euler Runge-Kutta Multistep Methods- use info from several prior steps Adam Bashforth Adam Moulton Method Predictor-Corrector Method. Multi-Step Principle.
E N D
Scientific Computing Multi-Step and Predictor-Corrector Methods
Overview • One-Step Methods – use only info from previous step • Euler • Runge-Kutta • Multistep Methods- use info from several prior steps • Adam Bashforth • Adam Moulton Method • Predictor-Corrector Method
Multi-Step Principle • To solve • We use an iteration scheme to find xi+1 in terms of previous values of xi, xi-1, xi-2, etc, and/or values of fi=f(ti, xi), fi-1, fi-2 , etc.
Multi-Step Principle The method comes from integrating the derivative to get x(t).
Multi-Step Example • Midpoint rule: • Another weighted average rule:
Multi-Step General Form • The general form for a multi-step method is • The parameters ak and bk are determined by polynomial interpolation. • If bm =0, the method is called explicit, as this formula gives xi+1 explicitly in terms of previously found values. • If bm ≠0, the method is called implicit, as xi+1 appears on both sides of the equals sign.
Multi-Step Explicit Adams Method • In this method we approximate the value of by interpolating f(t,x(t)) at the points (ti, xi), (ti-1, xi-1), …, (ti+1-m , xi+1-m). We then integrate this polynomial exactly to use in the formula for the next iterate:
Example: 3-Step Adams-Bashforth Want a formula of the type: We use the three previous values of (ti, xi) for a Lagrange interpolating polynomial for f
Example: 3-Step Adams-Bashforth Then, After a change of variables: u=(ti+1 - t)/h we get
Example: 3-Step Adams-Bashforth Then, Now, Likewise,
Example: 3-Step Adams-Bashforth So, we get, Thus,
Implicit Multi-Step Methods • Implicit multi-step methods use the value of xi+1 to find the value of xi+1. • Of course, this is impossible if we do not know xi+1, so in practice we use an explicit method to approximate (predict) xi +1 and then use an implicit method to improve (correct) the value of xi+1. • These methods again rely on polynomial interpolation approximation of f(t,x(t))
Adams-Moulton Implicit Methods Three-Point: Four Point:
Predictor-Corrector Methods • The Predictor-Corrector technique uses an explicit scheme (like the Adams-Bashforth Method) to estimate the initial guess for xi+1 and then uses an implicit technique (like the Adams-Moulton Method) to correct xi+1.
Predictor-Corrector Example • Adams third order Predictor-Corrector scheme: • Use the Adams-Bashforth three point explicit scheme for the initial value. • Use the Adams-Moulton three-point implicit method to correct.
Predictor-Corrector Example • Consider Exact Solution • Initial condition: x(0) = 1 • Step size: h = 0.1 • We will use the 3 Point Adams-Bashforth and 3 point Adams-Moulton. Both require 3 points to get started!
Predictor-Corrector Example • From the 4th order Runge Kutta • 3-point Adams-Bashforth Predictor Value:
Predictor-Corrector Example • To correct, we need f(t3 , x3*) • 3-point Adams-Moulton Corrector Value:
Predictor-Corrector Example The values for the Predictor-Corrector Scheme
Predictor-Corrector Example The predictor-corrector method produces a solution with nearly the same accuracy as the RK order 4 method. Generally, the n-step method will have truncation error of order at least n.