
11.3 Numerical Integration of Ordinary Differential Equations 271
! Defines equation
!===================================================
SUBROUTINE DERIVS(FF,DFF,AM)
DIMENSION FF(3),DFF(3)
DFF(1)=FF(2)
DFF(2)=FF(3)
DFF(3)=-0.5*(AM+1.)*FF(1)*FF(3)+AM*(FF(2)*FF(2)-1.)
RETURN
END SUBROUTINE
!===================================================
Program 11.3.1—(Continued)
the choice of f
0 was suitable is how f
behaves as the independent variable becomes
large. The program regards =7 to be infinity.
As long as there is a suitable first guess for the wall shear term, the procedure is
simple to use and can be made to converge rather quickly by using Newton’s method
or, even simpler, just repeating the calculation over a range of points. In problems such
as von Kármán’s rotating disk or the thermal boundary layers where there are more
than one unknown at the origin, the search is over a two-dimensional set of parameters
and becomes more difficult. A starting point would be to use the Kármán-Pohlhausen
method to calculate a first guess. Generally, if one starts close to the desired pair of
values, improving the guess, no matter how crude the method, is doable.
Another possible approach would be a version of the steepest descent method,
whereby one sets one of the parameters and then considers the results of a series of
computations performed by varying the second parameter. Finding which value of the
second parameter gives the “best result,” the first parameter could then be incremented
and then the process repeated. Defining “best result” might not, however, be obvious,
and the convergence and programming just might be challenging.
A method that has been proposed in IMSL (1987, pages 660–671, programs
BVPFD/DBVPFD) is to multiply the nonlinear terms by a parameter p and then starting
with p =0, and slowly increase p until it reaches unity—in which case the full original
equation is reached. This method is designed for two-point boundary value problems so
initial guessing of derivatives at the wall is avoided.
A method similar to this would be to insert time derivatives into each of the first-
order equations, thus making an initial value problem. The hope would be, of course,
that a steady state would eventually be reached.
Still another method for integrating a system of first-order ordinary differential equa-
tions is based on the method of cubic splines. Cubic splines became useful and popu-
lar with the advent of computer graphics. The idea is to take a function defined over an
interval and break the interval into a number of subintervals. Within each subinterval the
function is defined by a cubic polynomial. The polynomials are joined together in such
a manner that the function and its first and second derivatives are continuous throughout
the larger interval. To accomplish this, within each subinterval the function is defined by
yx =y
x
i
x
i+1
−x
3
6
i
+y
x
i+1
x −x
i
3
6
i
+
yx
i
i
−
1
6
y
x
i
i
x
i+1
−x
+
yx
i+1
i
−
1
6
y
x
i+1
i
x −x
i
(11.3.11)
where the subinterval extends from x
i
to x
i+1
and is of length
i
=x
i+1
−x
i
.