Vous êtes sur la page 1sur 21

Appendix B ORDINARY DIFFERENTIAL EQUATIONS AND SPECIAL FUNCTIONS

B.1 INTRODUCTION This appendix summarizes methods for solving the types of ordinary differential equations which are encountered most frequently in transport problems. In some cases the solutions involve special functions, whose properties are also discussed. It is assumed that the reader is already familiar with these methods, and what is presented is intended only as a concise review. Additional explanation may be found in Hildebrand (1976) or in any introductory text on differential equations, such as Rabenstein (1966). Abramowitz and Stegun (1970) is an authoritative and comprehensive source for the properties of special functions. In each equation the unknown function is denoted as y(x). In general, the first consideration is whether the equation is linear or nonlinear. Except for separable first-order equations, only linear differential equations are discussed. For an equation to be linear, the coefficients of y and its derivatives all must be independent of y, and there can be no nonlinear functions of y such as ey. Except for first-order separable equations, and ones which contain a small parameter and therefore permit use of perturbation methods (see Chapter 4), there are few ways to find analytical solutions to nonlinear problems; numerical methods are usually needed. If the differential equation is linear, the next consideration is whether the coefficients of y and its derivatives are constants or functions of x. If each is constant, the solution procedure is straightforward; if one or more depends on x, success or failure in obtaining a useful analytical result may hinge on the extent to which that equation has been studied previously, and its solutions documented. The defining feature of many special functions (such as Bessel functions)

is that they are solutions to certain differential equations. Making good use of available knowledge requires familiarity with the differential equations that give rise to well-known special functions. Several such second-order equations will be discussed. Whether the coefficients are constant or not, a differential equation is either homogeneous or nonhomogeneous. In a homogeneous equation y(x) appears in each term, and a hallmark of such equations is that one possible solution is y = 0. The general solution of an nthorder, linear homogeneous equation is a sum of n fundamental solutions. Each fundamental solution is weighted by a constant, and the n constants are evaluated by applying the boundary conditions. Transport models usually involve boundary-value problems (where boundary conditions are imposed at two locations) rather than initial-value problems (where all information is at one position, typically x = 0). If the equation is nonhomogeneous, the general solution is the homogeneous part plus a particular solution (i.e., any solution to the full equation, boundary conditions aside). The particular solution is chosen only to satisfy the differential equation; the n constants in the homogeneous solution are determined still by the boundary conditions. First-order differential equations (separable or linear) are discussed in Section B.2 and nth-order equations with constant coefficients are reviewed in Section B.3. Fundamental solutions for equations with constant coefficients are tabulated for convenient reference, as are common forms of particular solutions. The remainder of this appendix concerns linear differential equations with variable coefficients, and the corresponding special functions. The equations selected are ones which arise repeatedly in this book. The differential equations that yield cylindrical or spherical Bessel functions, and the properties of those functions, are the subject of Section B.4. Certain other equations with variable coefficients are discussed in

Section B.5. Except for the nth-order equidimensional equation (Section B.5), those with variable coefficients are all second order, and only their homogeneous forms are discussed. A few less-common differential equations are mentioned as they appear in various problems and are not included here. If an equation of interest is not found, it may be worthwhile to consult the extensive compilation of solutions in Kamke (1943).

B.2 FIRST-ORDER EQUATIONS Separable A separable first-order equation has the form

dy f (x) = . dx g( y)

(B.2-1)

Unless g is a constant, this differential equation will be nonlinear. However, it can always be integrated as

g dy = f dx .
result is

(B.2-2)

Whether the resulting solution is implicit or explicit depends on g(y). If g(y) = yb with b > 0, the

y(x) = (b + 1) f dx
where C is a constant.

1/ (b+1)

+C

(B.2-3)

Linear Linear first-order equations are of the form


dy + a1 (x)y = h(x) . dx

(B.2-4)

Such equations are exceptional in that no special procedure is needed if they are nonhomogeneous (i.e., if h 0). With the function p(x) evaluated as
p(x) = exp a1 (x)dx

(B.2-5)

the general solution is

y(x) =

C 1 + p(x)h(x)dx p(x) p(x)

(B.2-6)

where C again is a constant.

B.3 EQUATIONS WITH CONSTANT COEFFICIENTS A linear, nth-order equation with constant coefficients can always be written as

dny d n 1 y dy + a1 n 1 + ... + an 1 + an y = h(x) . n dx dx dx

(B.3-1)

If h(x) = 0, the equation is homogeneous. Associated with Eq. (B.3-1) is a characteristic equation, the n roots of which determine the general solution to the homogeneous differential equation. The characteristic equation, which is obtained by inserting erx into Eq. (B.3-1), is

r n + a1r n 1 + ... + an 1r + an = 0 .

(B.3-2)

The solutions which correspond to different types of roots are summarized in Table B-1, in which Ci and Di are constants. It is assumed here that the coefficients ai are all real, in which case there are always n real solutions. Repeated or complex conjugate roots each yield more than one fundamental solution, as shown. For r = 1, as with d2y/dx2 - y = 0, the two fundamental solutions can be written either as (ex, e-x) or (sinhx, coshx). The exponentials tend to be more convenient for infinite or semi-infinite domains, and the hyperbolic functions better for finite domains.

Table B-1. General Solutions for Homogeneous Differential Equations with Constant Coefficients Root of Characteristic Equation r a single root (real) r an m-fold root (real) r = a bi (complex, each a single root) r = a bi (complex, each an m-fold root) Homogeneous Solution

Cerx
erx C0 + C1 x + ... + Cm 1 x m 1
eax ( C cosbx + D sin bx )

(A)

)
)

(B) (C)

eax cosbx C0 + C1 x + ... + Cm 1 x m 1

+eax sin bx D0 + D1 x + ... + Dm 1 x m 1

(D)

If the differential equation is nonhomogeneous, a particular solution must be added to the homogeneous solution. If h(x) happens to be a solution of some linear, homogeneous differential equation with constant coefficients, then the method of undetermined coefficients can be used to find the particular solution, as summarized below. If not, a more general but usually lengthier procedure called variation of parameters can be used. Variation of parameters will yield the particular solution for any linear equation (Hildebrand, 1976; Rabenstein, 1966). Particular solutions corresponding to various functions h(x) are shown in Table B-2. After substituting the trial particular solution into the differential equation, the constants are chosen so that the nonhomogeneous form of Eq. (B.3-1) is satisfied. If any term in the given form of the particular solution appears also in the homogeneous solution, the entire particular solution must be multiplied by xk, where k is the smallest positive integer that prevents the duplication. If h(x) consists of a sum of terms, the solutions corresponding to each may be added

to find the complete particular solution. If h(x) = c, a constant, then the particular solution is simply y = c/an.

Table B-2. Particular Solutions for Nonhomogeneous Differential Equations with Constant Coefficients Nonhomogeneous Term, h(x) Particular Solution

Cx m Cx m eax Cx m eax cosbx or Cx m eax sin bx

A0 + A1 x + ... + Am x m

(A)

(A

+ A1 x + ... + Am x m eax
m ax 1 m

(B)

( A + A x + ... + A x ) e cosbx + ( B + B x + ... + B x ) e sin bx


0 m ax 0 1 m

(C)

B.4 BESSEL AND SPHERICAL BESSEL EQUATIONS Bessel Functions The general form of Bessels equation is
x d dy 2 2 2 x dx + m x v y = 0 dx

(B.4-1)

where m is a parameter and is any real constant. The form usually encountered, as with conduction or diffusion problems in cylindrical coordinates, has = 0. Setting = 0 and dividing by x2 gives
1 d dy x + m2 y = 0 . x dx dx

(B.4-2)

The solutions of Bessels equation have been studied extensively (Watson, 1944). The two linearly independent solutions to Eq. (B.4-1) are written as J(mx) and Y(mx), and are known as Bessel functions of order of the first and second kind, respectively. The solutions to Eq. (B.42) are Bessel functions of order zero, J0(mx) and Y0(mx). Bessel functions of integer order are widely available in spreadsheet programs and other software for personal computers, making calculations with them routine. As discussed shortly, the derivatives and integrals of J0 and Y0 can each be expressed in terms of the corresponding Bessel functions of order one. Accordingly, familiarity with the properties of J0, J1, Y0, and Y1 is sufficient for the problems encountered in this book. Graphs of these functions are shown in Fig. B-1. All four functions are oscillatory, although with variable periods and amplitudes, and have infinitely many roots. Two values worth noting are J0(0) = 1 and J1(0) = 0. An important distinction between Bessel functions of the first and second kinds is that J0(0) and J1(0) are finite, whereas Y0(0) and Y1(0) are not. Numerous Bessel-function identities may be found in Watson (1944) and Abramowitz and Stegun (1970). Ones which are helpful in evaluating derivatives and integrals are

dJ 0 (mx) = mJ1 (mx) , dx dY0 (mx) = mY1 (mx) , dx

d xJ (mx) = mxJ 0 (mx) dx 1 d xY (mx) = mxY0 (mx) . dx 1

(B.4-3a,b)

(B.4-4a,b)

Using Eq. (B.4-3b), the integral of xJ0 over the interval [0, L] is

J 0 (mx)x dx =
0

L J (mL) m 1

(B.4-5)

which is useful in constructing Fourier-Bessel series (Chapter 5). Also needed for such series is the definite integral of xJ02, which is given by
7

2 J 0 (mx)x dx = 0

m2 2 J 0 (mL) + J12 (mL) . 2

(B.4-6)

This last identity can be derived from Eqs. (B.4-2) and (B.4-3a), as detailed in Section 4.7 of the first edition of this book.

Modified Bessel Functions A differential equation closely related to Bessels equation, but with very different solutions, is the modified Bessels equation. Its general form is
x d dy 2 2 2 x dx m x + v y = 0 dx

(B.4-7)

where again m is a parameter and is any real constant. Equations (B.4-1) and (B.4-7) differ only in the sign of the m2x2 term. The solutions of Eq. (B.4-7) are written as I(mx) and K(mx), and are called modified Bessel functions of order of the first and second kind, respectively. As with Bessel functions, software for computing modified Bessel functions of integer order is widely available. The differential equation with = 0 again is the one of greatest interest. For that case Eq. (B.4-7) can be rewritten as
1 d dy x m2 y = 0 . x dx dx

(B.4-8)

Modified Bessel functions of orders zero and one are plotted in Fig. B-2. The most obvious difference between Bessel functions and modified Bessel functions is that the latter do not oscillate or have multiple roots. The limiting values of the modified Bessel functions are
I 0 (0) = 1 , I1 (0) = 0 , I 0 () = , I1 () = K 0 (0) = , K1 (0) = , K 0 () = 0 , K1 () = 0 .

(B.4-9) (B.4-10)

Identities which are helpful in evaluating derivatives and integrals are

dI 0 (mx) = mI1 (mx) , dx

d xI (mx) = mxI 0 (mx) dx 1 d xK (mx) = mxK 0 (mx) dx 1


.

(B.4-11a,b)

dK 0 (mx) = mK1 (mx) , dx

(B.4-12a,b)

As with Bessel functions, differentiation or integration of modified Bessel functions of order zero requires knowledge only of the corresponding functions of order one.

Spherical Bessel Functions The spherical Bessels equation is written generally as


d 2 dy 2 2 x dx + m x n(n + 1) y = 0 dx

(B.4-13)

where m is any real constant and n is a non-negative integer. The solutions, called spherical Bessel functions, may be expressed in terms of Bessel functions of order n + (1/2). Accordingly, their properties are covered in discussions of Bessel functions of fractional order (Watson, 1944; Abramowitz and Stegun, 1970). The form of Eq. (B.4-13) encountered in conduction or diffusion problems in spherical coordinates is that with n = 0, or
1 d 2 dy 2 2 x dx + m y = 0 . x dx

(B.4-14)

In this case no special functions are required. The general solution of Eq. (B.4-14) is

y(mx) = A

sin mx cos mx +B mx mx

(B.4-15)

where A and B are constants. In that they are oscillatory functions with infinitely many roots, the fundamental solutions in Eq. (B.4-15) are somewhat akin to the Bessel functions J0 and Y0. In

this case the periods are constant and only the amplitudes vary. Also, as with Y0, one of the solutions is unbounded at x = 0. That is, for x 0, sin(mx)/mx 1 but cos(mx)/mx . The spherical Bessel functions of order zero are plotted in Fig. B-3.

Modified Spherical Bessel Functions A differential equation closely related to Eq. (B.4-13) is the modified spherical Bessels equation,
d 2 dy 2 2 x dx m x + n n + 1 y = 0 . dx

(B.4-16)

As with the corresponding equations for cylindrical problems, Eqs. (B.4-13) and (B.4-16) differ only in the sign of the m2x2 term. The solutions to Eq. (B.4-16), called modified spherical Bessel functions, are expressible in terms of modified Bessel functions of order n + (1/2). The most commonly encountered form of the differential equation is that with n = 0, in which case
1 d 2 dy x m2 y = 0 . x 2 dx dx

(B.4-17)

The general solution to this equation is expressible in terms of elementary functions as

sinh mx cosh mx emx e mx y(mx) = A +B =C +D . mx mx mx mx

(B.4-18)

When using the hyperbolic form of Eq. (B.4-18), both solutions are unbounded at x = but one is finite at x = 0. That is, for x 0, sinh(mx)/mx 1 but cosh(mx)/mx . The hyperbolic forms of the modified spherical Bessel functions of order zero are shown in Fig. B-3. When using the exponential form of Eq. (B.4-18), both solutions are unbounded at x = 0 but one is finite at x = . Accordingly, the hyperbolic solutions are best for finite domains that include x = 0, and the exponential ones are preferred for semi-infinite domains that exclude the origin.

10

The correspondence between the solutions of the ordinary or modified spherical Bessels equations and those of the analogous equations in Cartesian coordinates (d2y/dx2 m2y = 0) is noteworthy. In each case the spherical solution is the Cartesian one divided by x. This underlies a transformation that is sometimes used in solving spherical conduction or diffusion problems, in which there is a change in the dependent variable given by (r,t) = (r,t)/r. This transforms a problem for (r,t) involving the spherical 2 operator into a problem for (r,t) involving the Cartesian one. Also needed sometimes is the modified spherical Bessels equation with n = 1, which is
d 2 dy x m2 x 2 + 2 y = 0 dx dx

(B.4-19)

This is encountered, for example, in certain spherical problems involving diffusion with firstorder reactions. Again, the solutions can be expressed in terms of elementary functions. The general solution is
sinh mx cosh mx sinh mx cosh mx y(mx) = A + 2 + B mx (mx)2 . mx (mx)

(B.4-20)

Neither of the fundamental solutions is finite at x = 0 or x = . In unbounded domains, the exponential form of the general solution is preferable, which is
y(mx) = C e mx 1 e mx 1 . 1 +D 1+ mx mx mx mx

(B.4-21)

Although both solutions are still unbounded at x = 0, one remains finite now at x = .

B.5 OTHER EQUATIONS WITH VARIABLE COEFFICIENTS Equidimensional Equations

11

An nth-order equidimensional equation (also called an Euler equation or Cauchy-type equation) has the form
n 1 dny y dy n 1 d x + b1 x + ... + bn 1 x + bn y = h(x) . n n 1 dx dx dx n

(B.5-1)

The characteristic equation is

[ r(r 1)...(r n + 1)] + b1 [ r(r 1)...(r n + 2)] + ... + bn 1r + bn = 0 .

(B.5-2)

In the simplest situations (single roots, all real), the homogeneous solutions are of the form Cxr. The solutions for various types of roots are summarized in Table B-3. Particular solutions for certain nonhomogeneous equidimensional equations are given in Table B-4. In the last entry, k is the smallest positive integer that will prevent the particular solution from duplicating any part of the homogeneous solution. As with any other linear differential equation, if h(x) consists of a sum of terms, the solutions corresponding to each may be added to find the complete particular solution. Also, if h(x) = c (a constant), the particular solution is just y = c/bn.

Table B-3. General Solutions for Homogeneous Equidimensional Equations Root of Characteristic Equation r a single root (real) r an m-fold root (real) r = a bi (complex, each a single root) r = a bi (complex, each an m-fold root) Homogeneous Solution

Cx r
x r C0 + C1 ln x + ... + Cm 1 ( ln x )
x a [ C cos(b ln x) + D sin(b ln x)]
m 1

(A)

(B) (C)

x a cos(b ln x) C0 + C1 ln x + ... + Cm 1 (ln x)m 1 +x a sin(b ln x) D0 + D1 ln x + ... + Dm 1 (ln x)m 1

(D)

12

Table B-4. Particular Solutions for Nonhomogeneous Equidimensional Equations Nonhomogeneous Term, h(x) xs xs (s r) (s = r) Particular Solution

Ax s
Ax s (ln x)k

(A) (B)

Error Function A differential equation which arises in similarity solutions to transient diffusion or conduction problems (Chapter 4) is

d2y dy + 2x = 0. 2 dx dx

(B.5-3)

This is equivalent to a first-order linear equation governing the function dy/dx, so that dy/dx is found as in Section B.1. Another integration gives the general solution as

y(x) = a e x dx + b
2

(B.5-4)

where a and b are constants. To obtain a form that is more convenient computationally, Eq. (B.5-4) is rewritten using a definite integral as

y(x) y(0) = a e s ds
2

(B.5-5)

where y(0) takes the place of b. The error function, which arises in probability theory and is widely available in commercial software, is defined as

erf (x)

e
0

s2

ds .

(B.5-6)

13

Because erf(x) contains the same definite integral as Eq. (B.5-5), the solution to Eq. (B.5-3) can be rewritten as

y(x) = Aerf (x) + B


where A and B are constants. The complementary error function is

(B.5-7)

erfc(x)

e
x

s2

ds = 1 erf (x) .

(B.5-8)

With erfc(x) being linearly related to erf(x). the general solution to Eq. (B.5-3) can be written also as

y(x) = Cerfc(x) + D
where C and D are constants.

(B.5-9)

Whether erf or erfc is more convenient for a particular problem will depend on the boundary conditions. The limiting values (for positive arguments) are

erf (0) = 0 , erf () = 1 , erfc(0) = 1 , erfc() = 0 .

(B.5-10)

The error function and complementary error function are plotted in Fig. B-4. Although not shown, erf may also have negative arguments; it is an odd function [erf(-x) = -erf(x)].

Gamma and Incomplete Gamma Functions A more general version of Eq. (B.5-3) is

d2y dy + nx n 1 =0 2 dx dx

(B.5-11)

where n is any positive integer. Following the same reasoning as with error functions, the solution may be written as a definite integral of exp(-xn). That integral can be evaluated using incomplete gamma functions, as will be described.
14

The gamma function, (z), is defined generally as

(z) t z 1et dt
0

(B.5-12)

where z may be complex (Abramowitz and Stegun, 1970, p. 255). However, specializing by making the substitutions t = sn and z = 1/n, where n is a positive integer, it is found that

e
0

sn

ds =

(1 / n) . n

(B.5-13)

Four values are (1) = 1, (1/2) =

, (1/3) = 2.67894, and (1/4) = 3.62560. If the

integration is terminated at s = x, the result is an incomplete gamma function. For fractional arguments, the incomplete gamma function has normalized and non-normalized forms denoted as P(1/n, x) and (1/n, x), respectively. They are related to the integral in Eq. (B.5-13) as
P(1 / n, x) = n (1 / n, x) sn e ds = (1 / n) . (1 / n) 0
x

(B.5-14)

Thus, P varies from 0 to 1 as x goes from 0 to , similar to the error function. Indeed, P(1/2, x) = erf(x). It follows that the general solution of Eq. (B.5-11) may be written as

y(x) = AP(1 / n, x) + B

(B.5-15)

which is analogous to Eq. (B.5-7). As with the error function, incomplete gamma functions have applications in probability theory. However, software for them is less widely available. The definition in Eq. (B.5-12) indicates that incomplete gamma functions may be used to evaluate a much broader class of definite integrals. For example, setting z = k/n gives
n (k / n, x) k 1 s n P(k / n, x) = s e ds = (k / n) . (k / n) 0
x

(B.5-16)

15

Legendre Polynomials Certain conduction or diffusion problems in spherical coordinates lead to Legendres equation,
d 2 dy 1 x + (n + 1)ny = 0 dx dx

(B.5-17)

where n is a non-negative integer. The solutions of Eq. (B.5-17) are detailed in Hobson (1955). In the usual applications of Legendres equation the interval for x is [-1,1], and it is found that nontrivial solutions which are bounded at x = 1 exist only if n is as stated above. Moreover, there is only one such bounded solution for a given value of n. It is
y(x) = APn (x)

(B.5-18)

where A is a constant and the functions Pn(x) are Legendre polynomials. (The other linearly independent solution of Eq. (B.5-17), which is unbounded at x = 1 and therefore not of interest here, involves what are called Legendre polynomials of the second kind.) The first two Legendre polynomials are P0(x) = 1 and P1(x) = x, and the remainder can be generated using the recursion relation,

Pn+1 (x) =

(2n + 1)xPn (x) nPn1 (x) . n +1

(B.5-19)

Alternatively, they can be computed using Rodrigues formula,

1 dn (x 2 1) n . Pn (x) = n n 2 n! dx

(B.5-20)

The first six Legendre polynomials are given in Table B-5. They are standardized such that Pn(1) = 1. The functions with even and odd values of n contain only even and odd powers of x, respectively. Accordingly, even-numbered Legendre polynomials are even functions [Pn(x) = Pn(-x)] and odd-numbered ones are odd functions [Pn(x) = -Pn(-x)].

16

Table B-5. Legendre Polynomials n Pn(x) 0 1 1 x 2


1 3x 2 1 2

1 5x 3 3x 2

1 35x 4 30x 2 + 3 8

1 63x 5 70x 3 + 15x 8

References Abramowitz, M. and I. A. Stegun. Handbook of Mathematical Functions. U.S. Department of Commerce, National Bureau of Standards, Washington, DC, 1970. Hildebrand, F.B., Advanced Calculus for Applications, Second Edition. Prentice-Hall, Englewood Cliffs, NJ, 1976. Hobson, E. W. The Theory of Spherical and Ellipsoidal Harmonics. Chelsea, New York, 1955. Kamke, E. Differentialgleichungen, Vol. 1. Akademische Verlagsgesellschaft Becker & Erler Kom.-Ges., Leipzig, Germany, 1943. Rabenstein, A. L. Introduction to Ordinary Differential Equations. Academic Press, New York, 1966. Watson, G. N. A Treatise on the Theory of Bessel Functions, Second Edition. Cambridge University Press, London, 1944.

17

1 J0(x) 0.5 J1(x)

0 Y0(x) -0.5 Y1(x)

-1 0 2 4 6 x 8 10 12

Figure B-1. Bessel functions of orders 0 and 1.

18

2 K1(x) K0(x) 1

I0(x) I1(x)

0 0 1 x 2 3

Figure B-2. Modified Bessel functions of orders 0 and 1.

19

2.5 2 cosh(x)/x 1.5 1 0.5 0 -0.5 0 1 2 x 3 4 5 sinh(x)/x

sin(x)/x cos(x)/x

Figure B-3. Spherical Bessel functions and modified spherical Bessel functions of order 0.

20

1 0.8 0.6 0.4 0.2 0 0 0.5 1 x 1.5 2 erfc(x)

erf(x)

Figure B-4. Error function and complementary error function.

21

Vous aimerez peut-être aussi