Examples for finite difference method for

solving PDEof parabolic type

Problem 1.Solve the equation:

,,

which, forsatisfies the following conditions:

1.1.

1.2.

1.3.

1.4.

1.5.

1.6.

а) For the obvious stable difference scheme and.

б) For the non-obvious scheme and .

Solution:

а) From (11) 1.1.

For 1.2.For1.3.

For1.4.For1.5.

For1.6.

For1.2-1.6 the indices change as in 1.1:

b) In (12) forwe have:

,for the system is solved by means of 3-diagonal matrices methods (for example the expulsion method). Conditions 1.1.–1.6 are added to the system above.

We will write down the system in a matrix form for 1.1. when.

In the right-hand side (initial conditions)

(boundary conditions)

By analogy the same refers to, for which only the right-hand parts of the systems are changed.

(tables with the solutions)

Problem 2.Find the approximate solution of the equation

,by steponx, which satisfies the following initial and boundary conditions:

2.1.

2.2.

2.3.

2.4.

а) When there is used a stable DS with and, and we work with 5 digits after the decimal point.

б) Write the non-obvious scheme byandand work out the difference equations system for all the grid knots.

Solution:

а) By substituting the partial derivatives in the equation with difference relations from (7), (10), we obtain:

for

.

We make an allowance regardingthe layer solution :

From 2.1. we use

We fill in the results in the table:

x
t / 0 / 0,1 / 0,2 / 0,3 / 0,4 / 0,5 / 0,6
0
0,005
0,01 / 0
0,00001
0,00005 / -0,00033
-0,00031
-0,00027 / -0,00267
-0,00264
-0,00259 / -0,009
-0,00898
-0,00893 / -0,02133
-0,02131
-0,02126 / -0,04167
-0,04164
-0,0416 / -0,072
-0,07199
-0,07195

Forthe table:

x
t / 0 / 0,1 / 0,2 / 0,3 / 0,4 / 0,5 / 0,6
0,005
0,01 / 0,00001 / -0,00032
-0,00028 / -0,00265
-0,00262 / -0,00899
-0,00895 / -0,02132
-0,02128 / -0,04165
-0,04162

By means of comparison we find that the error is of order , which is theoretically grounded.

b) The non-obvious scheme (12) for

under the conditions 2.2..

By analogy with Problem 1 b)we write down:

In order to solve the system we make useof the expulsion method, which is stable for these values of the 3-diagonal matrix elements.

Problem 3. (For individual work)

Solve the equation:

,

which satisfies the following conditions:

а) using an obvious DS for

b) using anon-obvious DS for

There is known the exact solution .

Author: Lyuba Popova

PU „P. Hilendarski”

1