1. Trang chủ
  2. » Công Nghệ Thông Tin

A textbook of Computer Based Numerical and Statiscal Techniques part 36 docx

10 316 0
Tài liệu đã được kiểm tra trùng lặp

Đang tải... (xem toàn văn)

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 10
Dung lượng 110,34 KB

Các công cụ chuyển đổi và chỉnh sửa cho tài liệu này

Nội dung

Using Picard’s method of successive approximation to with y0 = 0, obtain y.25, y.3 and y1 correct to 3 decimal places... Now we shall obtain exact value.. When x=0.1,y=1.11034 These resu

Trang 1

( ).4 21 2 1.084( ) ( ) (.2 2 8536) ( ) (.2 3 4.67744) ( ) (.2 4 6.992576) ( ) (.2 5 40.21655)

= 45068 = 451 Ans

7.3 PICARD’S METHOD OF SUCCESSIVE APPROXIMATIONS

Consider first order differential equation

( ),

dy

f x y

with the initial condition

y y= 0 at x x= 0 Integrating (1) with respect to x between x0 and x, we have

( )

,

y dy= x f x y dx

or ( )

0

0 x ,

x

Now, we solve (2) by the method of successive approximation to find out the solution of (1) The first approximate solution (approximation) y1 of y is given by

0

x

y = +yf x y dx Similarly, the second approximation y2 is given by

y2 = y0+z f x y dx

x

x

, 1

0 b g

for the nth aproximation y n is given by

y n = y0 + f x y n dx

x

x

, –1

0 b g

with y x( )0 =y0

Hence, this method gives a sequence of approximation y y1, 2 y n and it can be proved f x y( ), is bounded in some regions containing the point ( ,x y0 0) and if f x y( ), satisfies the Lipchitz condition, namely

f x yf x yk y y− where k is a constant Then the sequence

1, 2

y y converges to the sol (2).

Example 6 Use Picard’s method to obtain y for x = 0.2 Given

dy

x y

dx= − with initial condition y = 1 when x = 0.

Trang 2

Sol Here, f x y( ), = −x y, x0=0, y0=1

We have first approximation,

0x , 1 0x 1

y = +yf x y dx= +∫ xdx = 1 – x + x

2 2

Second approximation,

y2= +y0 ∫0x f x y dx( , 1) = +1 ∫0x(x y dx− 1)

2

0

2

= − +1 2− 3

6

x

x x

Third approximation,

y3 = y0 x f x y dx2 x x y dx

6

2 3 0

zx xxx x dx

= 1 – x + x2 – x x

3 4

6 + 24

Fourth approximation,

y4 = 0 ( 3) ( 3)

0x , 1 0x

y +∫ f x y dx = +∫ x y dx

=

3 4 2

0

3 24

=

2

1

x x

Fifth Approximation,

y5 = 0 ( 4) ( 4)

0x , 1 0x

y +∫ f x y dx = +∫ x ydx

=

2 0

3 12 120

=

2

1

x x

1 82,

y = y2=.83867, y3=.83740

y4=.83746, y5=.83746

Thus, y=.837 when x=.2 Ans

Trang 3

Example 7 Find the solution of dy =1+ xy, y(0) = 1

dx which passess through (0, 1) in the interval

(0, 0.5) such that the value of y is correct to three decimal places (use the whole interval as one interval only) Take h = 0.1.

Sol The given initial value problem is

dy

f x y xy y

i.e., y y= =0 1 at x = x0 = 0

Here,

2

1 1

2

x

y = + +x

= + + 2 + 3+ 4

2 1

x x x

3 1

4 3

105 384

y =y + + When x=0,y=1.000

x=0.1,y1=1.105,y2=1.1053

x=0.2,y1+1.220,y2=1.223=y3 (correct up to 3 decimals)

x=0.3, y=1.355 as y2=1.355=y3 (correct up to 3 decimals)

x=0.4,y=1.505

x=0.5,y=1.677 as y4= =y3 1.677 Thus,

We have numerically solved the given differential equation for x=0.1, 0.2, 0.3, 0.4 and 0.5

Example 8 Using Picard’s method of successive approximation to with y(0) = 0, obtain y(.25), y(.3) and y(1) correct to 3 decimal places.

Sol Here, ( ) =

+

2 2

1

x

f x y

y x0=0 and y0=0 The first approximation y1 of y is given by

1 0 0

0 1 3

y = + dx=

+

Trang 4

Similarly, the second approximation y2 of y is given by

2

3 0

0

x

= +

+

3

x

=

3

3 1 3

xx

3

3

x

We see that y1 and y2 agree to first term, namely

3

3

x

Neglecting

9

81

x

, we obtain the range

in which the result is correct to 3 decimal places, i.e., we put

1 9 .0005

81x

which yield x ≤ 7

Hence, we obtain ( ) ( )1 3

3

( ) ( )1 3

3

( ) ( )1 3 1 1 3

Example 9 Use Picard’s method to obtain y for x = 0.1 Given that dy =3x + y ; y =1 2

dx at x = 0.

f x y x y x y

First approximation, y1= +y0 ∫0x f x y( , 0)dx

0

1 x 3x 1 dx

= 1 + x + 3

2

2

x

1

y = + +x x + x + x + x

y = + +x x + x + x + x + x + x

32x 240x 400x 4400x

When, x=0.1, we have

1 1.115,

y = y2=1.1264, y3=1.12721

Thus, y=1.127 when x=0.1 Ans

Trang 5

Example 10 Obtain y when x = 0.1, x = 0.2 Given that dy x y;

dx= + y(0) = 1, Check the result with exact value.

Sol We have, dy f x y( ), x y x; 0 0

Now First approximation,

1 0

2

y = +∫ +x dx= + +x

Second approximation,

2 2

0

Third approximation,

3 4 2

3 1

x x

y = + + +x x + When x=.1, y1=1.105

2 1.11016

y =

3 1.11033

3 1.2427

y =

We can continue further to get the better approximations Now we shall obtain exact value

dy y x

dx− = is the given differential equation General sol is

yex= −ex(1+ +x) c (IF e= −x) Putting y=1,x=0 we obtain, c=2

When x=0.1,y=1.11034

These results reveal that the approximations obtained for x=0.1 is correct to four decimal places while that for x=0.2is correct to 3 decimal places

Example 11 If dy dx y x=y x−+ Find the value of y at x = 0.1 using Picard’s method Given that y(0) = 1.

Sol First approximation,

0

1 0

1 1

1

0

2

1

x

dx x

+

1 x 2log 1 x

Trang 6

Second approximation,

2

0

1 2log 1

x

= + −

which is difficult to integrate

Thus, when, x=0.1,y1= −1 0.1 2 log 1.1+ ( )=0.9828 Ans

Here in this example, only I approximation can be obtained and so it gives that approximate

value of y for x=0.1

Example 12 Find the series expansion that gives y as a function of x in the neighbourhood of

x = 0, when dy x2 y2,

dx= + with y(0) = 0.

0

f x y = +x y x = and y0=0 The nth approximation y n of y is given by

0

x

y = +yf x ydx

As an initial approximation, it is given that y0=0 Then, the first approximation y1 is given by

2 1

0

3

y = +∫ x + dx = ⋅ Similarly, the second approximation y2 is given by

2

2 2

0

0

yx   dx

Likewise, the higher order approximations are given as

2

2 3

0

2

y x

dx

x

0

0

2

2079 59535

F

z

=1 + + + +

3

1 63

2 2079

13 218295

If the series is truncated after the third term and used to approximate y to 4 decimal places,

then using the first neglected term, namely 13

218295

15

x as an approximation of the error, we have

13

218295

15

x ≤ 00005

Taking logarithm, we obtain

15 log x ≤ log .00005 218295

13

or x ≤ 988

Trang 7

Thus, x x x

3 7

11

3 63

2 2079 + + represents y correct to 4 decimal places In the range |x| ≤ 988

i.e –0.988 x ≤ 0.988

Example 13 Integrate the differential equation dy

dx = x sin πy with y = 1

2 at x = 0, by Picard’s method of successive approximations.

y = y 0 + f x y dx

x

x

,

b g

0

Sol The first approximation y1 of y is obtained by substituting y = 1

2 In the right hand

member of (1) i.e., we have

y1 = 1 2

1 2

0

+zx xsinFHG IKJπ dx = 1

2 2

2 +x

Similarly, the second and third approximation y2 and y3 are given as

y2 = 1 2

1 2

2

0

T|

U V|

W|

zx xsin π.e jx dx = 1

2 +zx xcosπx dx

2 4 0

2 2 48

2 2 6 + x – π x +

2

1

1

0 0

RS|

1

2 2 6 2 0

RS|

2 2 48

2 2 6 + x – π x +

We observe that y2 agree with y3 upto and including term in x6

We can use the relation y = 1

2 2

2 +x with the knowledge that the error is approximately –x

6

5 .

Thus, we can find y1 and y2 correct to 4 decimal places with h = 0.1.

7.4 EULER’S METHOD

The oldest and simplest method was derived by Euler In this method, we determine the change

y is y corresponding to small increment in the argument x Consider the differential equation

dy f x y( ),

with the initial condition y x( )0 =y0

Trang 8

Integrating (1) w.r.t x between x0 and x1, we get

( )

,

y dy= x f x y dx

0

x

Now, replacing f x y( ), by the approximation f x y( 0, 0), we get

0

1 0 x 0, 0

x

y = +yf x y dx

= +y0 f x y( 0, 0)(x1−x0)

y1= +y0 hf x y( 0, 0) (3 x1 – x0 = ∆x = h)

This is the formula for first approximation y1 of y.

Similarly, second approximation y2 is given by

y2= +y1 hf x y( 1, 1)

In general,

y n+1= +y n hf x y( n, n)

7.5 EULER’S MODIFIED METHOD

Instead of approximating f x y( ), by f x y( 0, 0) in equation (2) Let the integral is approximated by Trapezoidal rule to botain

1 0 [ ( 0, 0) ( 1 1)]

2

h

f x y f x y

We obtain the iteration formula,

2

n

y + = +yf x y +f x y

where, y1(n) is the nth approximation to y1

The above iteration formula can be started by y1(1) from Euler’s method

y1(0) = y0 + h(x0,y0)

Example 14 Using Euler’s method, compute y(0.5) for differential equation

dy y2 x2,

dx= − with y = 1 when x = 0

Sol Let 0.5 0.1

5

h= =

0 0, 0 1, ,

x = y = f x y =yx

Using Euler’s method we have

y n+1= +y n hf x y( n, n)

Trang 9

But considering n=0,1, 2, in succession, we get

1 0 0, 0

y = +y hf x y

= +1 0.1 1( 2− =0) 1.10000

2 1 1, 1

y = +y hf x y

1.10000 0.1 1.10000 0.1 =1.22000

y3= +y2 hf x y( 2, 2)

1.22000 0.1 1.22 0.2 

4 3 3, 3

y = +y hf x y

=1.36484 0.1[(1.36484) _ 0.3 ]+ 2 ( )2 =1.54212

5 4 4, 4

y =y +hf x y

1.54212 0.1 1.54212 0.4 =1.76393 Hence, the value of y at x=0.5 is 1.76393. Ans

Example 15 Using Euler’s method, compute y(0.04) for the differential equation.

y 1 = –y with y(0) = 1 (Take h = 0.01)

Sol Using Euler’s method

y n+1= +y n hf x y( n, n)

By considering n=0,1, 2, in succession, we obtain

1 0 0, 0

y = +y hf x y

= +1 0.01 1( )− =0.99

2 1 1, 1

y = +y hf x y

=0.99 0.01 0.99+ (− )=0.9801

3 0.9801 0.01 0.9801 0.970299

4 0.970299 0.01 0970299 0960596

Hence, the value of y(0.04) is 0.960596 Ans

Example 16 Find the solution of differential equation

dy xy

dx= with y(1) = 5

in the interval 1,1.5] using h = 0.1.

Sol As per given we have

1 1,

x = y0=5, f xy( )=xy

Using Euler’s method

y n+1= +y n hf x y( n, n)

Trang 10

Now, by considering n=0,1, 2 in succession, we get

For n=0 y1= +y0 0.1f x y( 0, 0)

= +5 0.1 1 5( )× =5.5 For n=1 y2= +y1 0.1f x y( 1, 1)

=5.5 0.1 1.1 5.5+ ( × )=6.105 For n=2 y3= +y2 0.1f x y( 2, 2)

=6.105 0.1 1.2 6.105+ ( × )=6.838 For n=3 y4= +y3 0.1f x y( 3, 3)

=6.838 0.1 1.3 6.838+ ( × )=7.727 For n=4 y5 = y4 + 0.1 f(x4, y4)

=7.727 0.1 1.4 7.727+ ( × )=8.809 Hence, the value of y( )1.5 is 8.809 Ans

Example 17 Given y y x

y x

′ = + with y 0 = 1 find y for x = 0.1 in four steps by Euler’s method.

Sol Let 0.1 0.025

4

h= = , given y0=1, where x=0

We know that

y n+1= +y n hf x y( n, n)

By putting n=0,1, 2, 3,we obtain

y1= +y0 hf x y( 0, 0)

(1 0)

1 0.025

1 0

= +

+ =1.025

Again, y2=y1 +hf x y( 1, 1)

(1.025 0.025)

1.025 0.025

1.025 0.025

+ (where x1= + = +x0 h 0 0.025 ⇒ =x1 0.025) = 1.0488

y2 = 1.0488

Now again y3 = y2 + hf(x2, y2) (where x2 = x0 + 2h = 0 + 2 × 0.025 = 0.05)

=1.0488 + 0.025 1 0488 0 05

1 0488 0 05

4 3 3, 3

y = +y hf x y (where x3=x0+3h= + ×0 3 0.025 0.075= )

Ngày đăng: 04/07/2014, 15:20

TỪ KHÓA LIÊN QUAN

TÀI LIỆU CÙNG NGƯỜI DÙNG

TÀI LIỆU LIÊN QUAN