Documentos de Académico
Documentos de Profesional
Documentos de Cultura
TER
11
Boundary-Value Problems
for Ordinary
Differential Equations
Introduction
A common problem in civil engineering concerns the deection of a beam of rectangular
cross section subject to uniform loading while the ends of the beam are supported so that
they undergo no deection.
S
0
w(x)
Suppose that l, q, E, S, and I represent, respectively, the length of the beam, the
intensity
of the uniform load, the modulus of elasticity, the stress at the endpoints, and the
central moment of inertia. The differential equation approximating the physical
situation is of the form 2
d w
S
qx
dx2
(x) =
EI
w(x) +
2EI
(x l),
where w(x) is the deection a distance x from the left end of the beam. Since no deection
occurs at the ends of the beam, there are two boundary conditions
w(0) = 0 and w(l) = 0.
When the beam is of uniform thickness, the product EI is
constant. In this case the exact solution is easily obtained.
When the thickness is not uniform, the moment of inertia I
is a function of x, and approximation techniques are
required. Problems of this type are considered in Exercises
7 of Section 11.3 and 6 of Section 11.4.
The differential equations in Chapter 5 are of rst order and
have one initial condition to satisfy. Later in the chapter we
saw that the techniques could be extended to systems of
equations and then to higher-order equations, but all the
specied conditions are on the same endpoint. These are
initial-value problems. In this chapter we show how to
approximate the solution to boundary-value problems,
differential equations with conditions imposed at different
points. For rst-order differential equations, only one
condition is specied, so there is no distinction between
671
initial-value and boundary-value problems. We will be
considering second-order equations with two boundary
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
values.
it.
672
CHAPTER
11
for a x b,
(11.1)
(11.2)
fy (x, y, y) =| cos y| 1.
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
673
Corollary 11.2
satises
(i) p(x), q(x), and r(x) are continuous on [a, b],
(ii) q(x) > 0 on [a, b].
Then the boundary-value problem has a unique solution.
To approximate the unique solution to this linear problem, we rst consider the
initialvalue problems
y = p(x)y + q(x)y + r(x), with a x b, y(a) = , and y(a) = 0,
(11.3)
and
y = p(x)y + q(x)y, with a x b,
(11.4)
Theorem 5.17 in Section 5.9 (see page 329) ensures that under the hypotheses in
Corollary 11.2, both problems have a unique solution.
Let y1 (x) denote the solution to (11.3), and let y2 (x) denote the solution to (11.4). Assume
that y2 (b) = 0. (That y2 (b) = 0 is in conict with the hypotheses of Corollary 11.2 is
considered in Exercise 8.) Dene
y1 (b)
y(x) = y1 (x) +
y2(b)
(11.5)
y2 (x).
Then y(x) is the solution to the linear boundary problem (11.3). To see this, rst note that
y1 (b)
y(x) = y1(x) +
y2 ( b)
y2 (x)
and
y(x) = y1 (x) +
y1 (b)
y2 ( b)
y
2 (x).
Substituting for y
1 (x) and y2 (x) in this equation gives
y1 (b)
= p(x)
y1+
y1 (b)
y2 ( b)
y2 ( b)
y2
p(x)y 2+ q(x)y2
+ q(x)
y1 +
y1 (b)
y2 (b)
y2 + r(x)
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
674
CHAPTER
11
Moreover,
y(a) = y1 (a) +
y1 (b)
y2(b)
y2 (a) = +
y1 (b)
y2(b)
0=
and
y(b) = y1 (b) +
y1 (b)
y2(b)
Linear Shooting
This shooting hits the target
after one trial shot. In the next
section we see that nonlinear
problems require multiple shots.
The Shooting method for linear equations is based on the replacement of the linear
boundary- value problem by the two initial-value problems (11.3) and (11.4). Numerous
methods are available from Chapter 5 for approximating the solutions y1 (x) and y2 (x), and
once these
approximations are available, the solution to the boundary-value problem is approximated
using Eq. (11.5). Graphically, the method has the appearance shown in Figure 11.1.
Figure
11.1
y
y2(x)
y1(b)
y2(x)
y(x) y1(x)
y (b)
y1(x)
11.1
Linear Shooting
To approximate the solution of the boundary-value problem
y + p(x)y + q(x)y + r(x) = 0,
(Note: Equations (11.3) and (11.4) are written as rst-order systems and solved.)
INPUT endpoints a, b; boundary conditions , ; number of subintervals N .
OUTPUT approximations w1,i to y(xi ); w2,i to y(xi ) for each i = 0, 1, ... , N .
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
675
Step 1 Set h = (b a)/N ;
u1,0 = ; u2,0 = 0; v1,0 = 0; v2,0 = 1.
Step 2 For i = 0, ... , N 1 do Steps 3 and 4.
(The Runge-Kutta method for systems is used in Steps 3 and 4.)
Step 3
Set x = a + ih.
Step 4
2,2
2k
k1,1 = hv2,i ;
k1,2 = h p(x)v2,i + q(x)v1,i ;
k2,1 = h v2,i + 2 k1,2 1;
1
k2,2 = h p(x + h/2) v2,i + 2 k1,2 + q(x
+ h/2) v1,i + 2 k1,1 ;
1
k3,2 = h p(x + h/2) v2,i + 2 k2,2 + q(x
+ h/2) v1,i + 2 k2,1 ;
2k2,2 +
u1,N
v 1,N
2k3,2 + k4,2 .
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
x2
c2
10
3
sin(ln x)
10
cos(ln x),
where
1
c2 =
70
and
11
c1 =
10
c2 1.1392070132.
Solution Applying Algorithm 11.1 to this problem requires approximating the solutions to
sin(ln x)
x2
and
2
2
y2 = y2 + 2 y2 , for 1 x 2, with y2 (1) = 0 and y2 (1) = 1.
The results of the calculations, using Algorithm 11.1 with N = 10 and h = 0.1, are
given in Table 11.1. The value listed as u1,i approximates y1 (xi ), the value v1,i
approximates
y2 (xi ), and wi approximates
y(xi ) = y1 (xi ) + 2 y1 (2)
y2(2)
Table
11.1
xi
1.0
1.1
1.2
1.3
1.4
1.5
1.6
1.7
1.8
1.9
2.0
u1,i y1 (xi )
v1,i y2 (xi )
1.00000000
1.00896058
1.03245472
1.06674375
1.10928795
1.15830000
1.21248372
1.27087454
1.33273851
1.39750618
1.46472815
0.00000000
0.09117986
0.16851175
0.23608704
0.29659067
0.35184379
0.40311695
0.45131840
0.49711137
0.54098928
0.58332538
wi y(xi )
1.00000000
1.09262917
1.18708471
1.28338227
1.38144589
1.48115939
1.58239245
1.68501396
1.78889854
1.89392951
2.00000000
y2 (xi ).
y(xi )
1.00000000
1.09262930
1.18708484
1.28338236
1.38144595
1.48115942
1.58239246
1.68501396
1.78889853
1.89392951
2.00000000
|y(xi ) wi |
1.43 107
1.34 107
9.78 108
6.02 108
3.06 108
1.08 108
5.43 1010
5.05 109
4.41 109
The accurate results in this example are due to the fact that the fourth-order RungeKutta method gives O(h4 ) approximations to the solutions of the initial-value
problems. Unfortunately, because of roundoff errors, there can be problems hidden in
this technique.
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
677
v 1,N
u1,N
v 1,N
v1,i ,
v2,i ,
y =p(x)y + q(x)y,
If this reverse shooting technique still gives cancellation of signicant digits and if
increased precision does not yield greater accuracy, other techniques must be
used. Some of these are presented later in this chapter. In general, however, if u1,i
O(hn ) approximations
to y1 (xi ) and
and yv21,i(xare
for each i = 0, 1, ... , N , then w1,i will be an O(hn )
i ), respectively,
approximation to y(xi ). In particular,
v1,i
v1,N
0 x 1,
y(0) = 0,
y(1) = 2,
has the solution y(x) = e (e 1)1 (e e2x ) + x. Use the Linear Shooting
the solution, and compare the results to the actual method
solution.to approximate
2
a.
2.
With h = 1 ;
b.
2x
With h = 1 .
0 x ,
y(0) = 0.3, 2 y
= 0.1
has the solution y(x) = 10 (sin x + 3 cos x). Use the Linear Shooting method to approximate the
3.
With h = ;
b.
With h = .
Use the Linear Shooting method to approximate the solution to the following boundary-value
problems.
a. y = 3y + 2y + 2x + 3, 0 x 1, y(0) = 2, y(1) = 1; use h = 0.1.
1
b. y = 4x1 y 2x2 y + 2x2 ln x, 1 x 2, y(1) = , y(2)
= ln 2; use h = 0.05.
2
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
678
CHAPTER
Equations
11
4.
y = (x + 1)y + 2y + (1 x2 )ex ,
y = x1y + 3x2 y + x1 ln x 1,
Although q(x) < 0 in the following boundary-value problems, unique solutions exist and are given.
Use the Linear Shooting Algorithm to approximate the solutions to the following problems, and
compare the results to the actual solutions.
a.
b.
y + y = 0, 0 x
cos x + (
2 1) sin x.
y + 4y = cos x,
= 1, y( ) 4= 1; use h =
,
y(0)
4
0 x 4 , y(0) = 0, y( 4 ) = 0; use h =
20
;
actual solution
y(x) =
20
2
2x + 3 cos x.1
13 cos 2x sin
6
c.
d.
y = 2y y + xex x,
x
y(x) = 1 x3 ex 6 5 xex + 2e
x 2.
3
5.
6.
7.
Use the Linear Shooting Algorithm to approximate the solution y = e10x to the boundary-value
problem
y = 100y, 0 x 1, y(0) = 1, y(1) = e10 . Use h = 0.1 and 0.05.
Write the second-order initial-value problems (11.3) and (11.4) as rst-order systems, and derive
the
equations necessary to solve the systems using the fourth-order Runge-Kutta method for systems.
Let u represent the electrostatic potential between two concentric metal spheres of radii R1 and R2
(R1 < R2 ). The potential of the inner sphere is kept constant at V1 volts, and the potential of the
outer sphere is 0 volts. The potential in the region between the two spheres is governed by
Laplaces
equation, which, in this particular application, reduces to
d2 u
dr2
2 du
r dr
= 0,
R1 r R2 ,
u(R1 ) = V1 ,
u(R2 ) = 0.
a.
b.
V1 R1 R2 r
u(r) =
R2 R
.
1
8.
Show that, under the hypothesis of Corollary 11.2, if y2 is the solution to y = p(x)y + q(x)y and
y2 (a) = y2 (b) = 0, then y2 0.
9.
10.
0 x b,
y(0) = 0,
y(b) = B.
0 x b,
y(0) = 0,
y(b) = B.
(11.6)
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
679
is similar to the linear technique, except that the solution to a nonlinear problem cannot be
expressed as a linear combination of the solutions to two initial-value problems. Instead,
we approximate the solution to the boundary-value problem by using the solutions to a
sequence of initial-value problems involving a parameter t. These problems have the form
y = f (x, y, y),
(11.7)
y = f (x, y, y ), fordetermines
a x b, with y(a) = and y(a) = t0 .
the initial elevation at which the object is red from the
point (a, ) and along the curve described by the solution
to the initial-value problem:
Figure
11.2
y
(b, )
y(b, t0)
y(x, t0)
Slope t0
(a, )
satises the hypotheses of Theorem 11.1. If y(x, t) denotes the solution to the initialvalue
problem (11.7), we next determine t with
y(b, t) = 0.
(11.8)
This is a nonlinear equation in the variable t. Problems of this type were considered in
Chapter 2, and a number of methods are available.
To use the Secant method to solve the problem, we need to choose initial
approximations
t0 and t1 , and then generate the remaining terms of the sequence by
= tk1
k1 )
y(b, tk2 )
k = 2, 3, ... .
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
680
CHAPTER
Equations
11
Figure
11.3
y
(b, )
y(b, t2)
y(b, t3)
y(b, t1)
y(x, t2)
y(b, t0)
y(x, t3)
y(x, t1)
y(x, t0)
(a, )
a
Newton Iteration
To use the more powerful Newtons method to generate the sequence {tk }, only one initial
approximation, t0 , is needed. However, the iteration has the form
y(b, tk1 )
tk = tk1
,
(11.9)
dy
dt (b, tk1 )
and it requires the knowledge of (dy/dt)(b, tk1 ). This presents a difculty because an
explicit representation for y(b, t) is not known; we know only the values y(b, t0 ), y(b, t1 ),
... , y(b, tk1 ).
Suppose we rewrite the initial-value problem (11.7), emphasizing that the solution
depends on both x and the parameter t:
y(x, t) = f (x, y(x, t), y(x, t)), for a x b, with y(a, t) = and y(a, t) = t. (11.10)
We have retained the prime notation to indicate differentiation with respect to x. We need
to determine (dy/dt)(b, t) when t = tk1 , so we rst take the partial derivative of (11.10)
with respect to t. This implies that
f
y(x, t), y(x, t))
yt (x, t) = (x,
t
f
x
x
+
f
y
(x, t)
(x, t).
t y
f
y
f
y(x, t), y(x, t)) (x, t) + (x, y(x, t), y(x, t))
yt (x, t) = (x,
y
t
y
for a x b. The initial conditions give
y
(a, t) = 0
t
and
(x,yt),
t
(11.11)
y t (a, t) = 1.
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
681
If we simplify the notation by using z(x, t) to denote ( y/ t)(x, t) and assume that
the order of differentiation of x and t can be reversed, (11.11) with the initial
conditions becomes the initial-value problem
f
f
(x, y, y)z(x, t) + (x, y, y)z(x, t), for a x b,
y
y
with z(a, t) = 0 and z(a, t) = 1.
Newtons method therefore requires that two initial-value problems, (11.10) and
(11.12), be solved for each iteration. Then from Eq. (11.9), we have
z(x, t) =
y(b, tk1 )
tk = tk1
z(b, tk1 )
(11.12)
(11.13)
Of course, none of these initial-value problems is solved exactly; the solutions are
approximated by one of the methods discussed in Chapter 5. Algorithm 11.2 uses the RungeKutta method of order four to approximate both solutions required by Newtons method.
A similar procedure for the Secant method is considered in Exercise 5.
ALGORITH
M
11.2
(Note: Equations (11.10) and (11.12) are written as rst-order systems and
solved.)
INPUT endpoints a, b; boundary conditions , ; number of subintervals
N 2; toler- ance TOL; maximum number of iterations M .
OUTPUT approximations w1,i to y(xi ); w2,i to y(xi ) for each i = 0, 1, ... , N
or a message that the maximum number of iterations was exceeded.
Step 1 Set h = (b a)/N ;
kTK
= 1;
= ( )/(b a).
(Note: TK could also be input.)
Step 2
Step 3
u2 = 1.
Set x = a + (i 1)h.
Step 6
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
682
CHAPTER
Equations
11
k1,1 = hu2 ;
1,2
k = h[fy (x, w1,i1 , w2,i1 )u1
+fy (x, w1,i1 , w2,i1 )u2 ];
k2,1 = h u2 + 2 k1,2 1;
k3,1 = h u2 + 2 k2,2 1;
1
2 2,2
[k
u2 = u2 +
[k
+ 1,1 + 2,1 +
+ k
+ 2k + 2k2,2
6 1,2
2k
2k
];3,1
4,1
].3,2
4,2
3,2
w1,N
Set TK = TK
Step 10
;
u1
(Newtons method is used to compute TK.)
k = k + 1.
Step 11 OUTPUT (Maximum number of
iterations exceeded); (The procedure was
unsuccessful.)
STOP.
The value t0 = TK selected in Step 1 is the slope of the straight line through (a, )
and (b, ). If the problem satises the hypotheses of Theorem 11.1, any choice of t0 will
give convergence, but a good choice of t0 will improve convergence, and the procedure will
Example 1
even work for many problems that do not satisfy these hypotheses. One such example
can
be found in Exercise 3(d).
Apply the Shooting method with Newtons Method to the boundary-value problem
1
43
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.
683
y(x) = x2 + 16/x.
Solution We need approximate solutions to the initial-value problems
and
f
f
1
z + z = (yz + yz), for 1 x 3, with z(1) = 0 and z(1) = 1,
y
8
y
at each step in the iteration. If the stopping technique in Algorithm 11.2 requires
z =
Table
11.2
xi
w1,i
y(xi )
1.0
1.1
1.2
1.3
1.4
1.5
1.6
1.7
1.8
1.9
2.0
2.1
2.2
2.3
2.4
2.5
2.6
2.7
2.8
2.9
17.000000
15.755495
14.773389
13.997752
13.388629
12.916719
12.560046
12.301805
12.128923
12.031081
12.000023
12.029066
12.112741
12.246532
12.426673
12.650004
12.913847
13.215924
13.554282
13.927236
17.000000
15.755455
14.773333
13.997692
13.388571
12.916667
12.560000
12.301765
12.128889
12.031053
12.000000
12.029048
12.112727
12.246522
12.426667
12.650000
12.913845
13.215926
13.554286
13.927241
3.0
14.333327
14.333333
|w1,i y(xi )|
4.06 105
5.60 105
5.94 105
5.71 105
5.23 105
4.64 105
4.02 105
3.14 105
2.84 105
2.32 105
1.84 105
1.40 105
1.01 105
6.68 106
3.61 106
9.17 107
1.43 106
3.46 106
5.21 106
6.69 106
Although Newtons method used with the shooting technique requires the solution of
an additional initial-value problem, it will generally give faster convergence than the
Secant method. However both methods are only locally convergent because they
require good initial approximations.
For a general discussion of the convergence of the shooting techniques for nonlinear
problems, the reader is referred to the excellent book by Keller [Keller, H]. In that
reference, more general boundary conditions are discussed. It is also noted that the
shooting technique for nonlinear problems is sensitive to roundoff errors, especially if
the solution y(x) and
z(x, t) are rapidly increasing functions of x on [a, b].
Copyright 2010 Cengage Learning. All Rights Reserved. May not be copied, scanned, or duplicated, in whole or in part. Due to electronic rights, some third party content may be suppressed from the eBook and/or eChapter(s).
Editorial review has deemed that any suppressed content does not materially affect the overall learning experience. Cengage Learning reserves the right to remove additional content at any time if subsequent rights restrictions require
it.