The Mathematics of Financial Modelingand Investment Management

(Brent) #1

9-DifferntEquations Page 254 Wednesday, February 4, 2004 12:51 PM


254 The Mathematics of Financial Modeling and Investment Management

h 4 = –h[xi()+ k 3 ]

xi+ 1 )= xi
1
( ()+ ---(k 1 + 2 k 2 + 2 k 3 + k 4 )
6

yi+ 1 )= yi
1
( ()+ ---(h 1 + 2 h 2 + 2 h 3 + h 4 )
6

Exhibits 9.3 and 9.4 illustrate the results of this method in the two cases
f′= fand f′′+ f= 0.
As mentioned above, this numerical method depends critically on our
having as givens (1) the initial values of the solution and (2) its first deriv-
ative. Suppose that instead of initial values two boundary values were
given, for instance the initial value of the solution and its value 1,000
steps ahead, that is, f(0) = f 0 , f(0 + 1,000∆x) = f 1000. Conditions like these
are rarely used in the study of dynamical systems as they imply foresight,

EXHIBIT 9.3 Numerical Solution of the Equation f ′= f with the Runge-Kutta
Method After 10 Steps
Free download pdf