Professional Documents
Culture Documents
The differential equation in section one is of first order and has 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 specified conditions are on the same end point. 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 first-order differential equations, only one condition is specified, so there is no distinction
between initial-value and boundary-value problems. We will consider second-order equations
with two boundary values of the form
y ''=f ( x,y,y' ) , a≤x≤b
together with the boundary conditions
y ( a)=α and y ( b )= β,
In this section, we shall see the Finite Difference and the Shooting Methods for solving equation
yi
are as under
1
y 'i= ( y −y )
2 h i+1 i−1
1
y ''i = 2 ( y i+1−2 y i + y i−1 )
h
Note:- The accuracy of this method depends on the size of the subinterval h. As we reduce h, the
Solution: - To solve this problem we can apply the approximation of the derivatives to the given
equation, we obtain
y n+1−2y n + y n−1 y n+1− y n−1
( 1+ x 2 ) + 2x n − y n =x 2n
n h2 2h
Since h = ¼ it implies that the range of x is divided into four parts by 5 node points.
Thus x0 = 0, x1 = 0.25, x2 = 0.5, x3 = 0.75 and x4 = 1 and the boundary condition y(0) = 1 and
y(1) = 0 simply transform to y0 = 1 and y4 = 0. Now the reasonable thing to do as in the theory
above is to substitute n = 1, 2, 3 to find y1 = y(x1), y2 = y(x2) and y3 = y(x3). Hence, we obtain
With n = 1, the formula above becomes
y 2−2y 1 + y 0 y 2− y 0
( 1+ x 2 ) + 2x 1 − y 1=x 21
1 h2 2h
1 2 y 2 −2y 1 +1 1 y 2 −1 1 2
( ( ) )(
1+
4 1 2
) ( ( ))
+2 ()
4 1
− y 1=
4 ()
()
4
2
4
After simplifying we get
288y 2 −560y 1=−255 ( i)
( ( ) )(
1+
2 1 2
) ( )
+2
2( )21 − y 2=
2 ()
() 4 (4 )
After simplifying
( ( ) )(
1+
4 1 2
) ( ( ))
+2()
4 1
− y3=
4 ()
() 4
2
4
Simplifying gives
784y 3 −352y 2 =−9 ( iii )
Thus we have a system of 3 equations in three unknowns y1, y2 and y3. The matrix form of these
three equations (i), (ii) and (iii), is written as:
( y1 ¿)( y2 ¿ ) ¿¿¿
¿
Thus the values corresponding to y1, y2, y3 are the results of the differential equation at points x1,
x2, x3.
2. Solve the boundary value problem, y ''−4 y=−4 x satisfying the boundary conditions
y(0) = 0 and y(1) = 2, use a step length
a. h =1/2
b. h=1/4
c. h=1/8
3. Solve the boundary value problem, y ''=−3 y '+2 y +2 x+3 satisfying the boundary
conditions y(0) = 2 and y(1) = 1, use a step length h=0.2.
Solution: -
Using the approximation for y'' the given equation can be rewritten as
,
y n+1−2y n + y n−1
2
=2y 3n (∗)
h
1 1 1
a ) See that x 0 =−1 , x 1 =− , x 2 =0 , y 0= and y 2= and we need to find
2 2 3
1
( )
y 1 = y (x 1 )= y − , that is substituting n=1 in (∗)
2
3
4 ( y 2 −2 y 1 + y 0 )=2 y 1
20
2 y31 +8 y 1 − =0
6
y 1 =0 .363038 (Using Newton−Raphson Method )
2 1 1 1
b ) See that x 0=−1, x 1 =− , x 2 =− , x3 =0 , y 0 = and y 3= and we need to find
3 3 2 3
2 1
( ) ( )
y 1 = y (x 1 )= y − and y 2 = y (x 2 )= y − that is substituting n=1 and n=2 in (∗)
3 3
9( y 2 −2 y 1 + y 0 )=2 y 31
9( y 3 −2 y 2 + y 1 )=2 y 32
9( y 2 −2 y 1 +0 .5 )=2 y 31
9 (13 −2 y + y )=2 y
2 1
3
2
9
f ( y1 , y 2 ) = 2 y 31 +18 y 1 −9 y 2 − =0
2
g( y 1 , y 2 ) = 2 y 32 +18 y 2−9 y 1 −3 =0
An initial approximation to the solution is obtained from the rough graphs of f and g as (0.3,
0.3) and after three iterations on applying Newton-Raphson’s Method for system of non linear
16( y 2 −2 y 1 + y 0 )=2 y 31
16( y 3 −2 y 2 + y 1 )=2 y 32
16( y 4 −2 y 3 + y 2 )=2 y33
16( y 2 −2 y 1 +0 .5 )=2 y 31
16 ( y 3 −2 y 2 + y 1 ) =2 y 32
1
16 ( 3 )
−2 y 3 + y 2 =2 y 33
y 2 =0 . 40016 and y 3=0. 36374 .Compare this answer with actual solution of the given
1
y ( x )=
B.V.P x+3 .