03.03.2014 Views

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

10.2. RUNGE-KUTTA METHODS 131<br />

Example 10.5. Consider the ODE from Example 1<strong>0.1</strong>:<br />

{ dx(t)<br />

dt<br />

= x,<br />

x(0) = 1.<br />

The actual solution is x(t) = e t . Euler’s Method underestimates x(t), as shown in Figure 1<strong>0.1</strong>.<br />

Using Backwards Euler’s Method, gives the approximation:<br />

PSfrag replacements<br />

x(t + h) = x(t) + hx(t + h),<br />

x(t + h) = x(t)<br />

1 − h .<br />

Using Backwards Euler’s Method gives an overestimate, as shown in Figure 10.5. This is because<br />

each step proceeds on the tangent line to a curve ke t to a point on that curve. Generally Backwards<br />

Euler’s Method is preferred over vanilla Euler’s Method because it gives equivalent stability for<br />

larger stepsize h. This effect is not evident in this case.<br />

40<br />

Backwards Euler approximation<br />

Actual<br />

35<br />

30<br />

25<br />

20<br />

15<br />

10<br />

5<br />

0<br />

0 0.5 1 1.5 2 2.5 3<br />

Figure 10.5: Backwards Euler’s Method applied to approximate x ′ = x, x(0) = 1. The approximation<br />

is an overestimate, as each step is to a point on a curve ke t , through the tangent at that<br />

point. Compare this figure to Figure 1<strong>0.1</strong>, which shows the same problem approximated by Euler’s<br />

Method, with the same stepsize, h = 0.3.<br />

10.2 Runge-Kutta <strong>Methods</strong><br />

Recall the ODE problem: find some x(t) such that<br />

{ dx(t)<br />

dt<br />

= f (t, x(t)) ,<br />

x(a) = c,

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!