Page 460 - Applied Numerical Methods Using MATLAB
P. 460

PROBLEMS   449
                                                                y        4
               (e) ∂u(x, y)/∂x     =− cos y,  ∂u(x, y)/∂x    =−e sin 4 − e cos y
                               x=0                      x=4
                                                                       (P9.3.10)
                                                       4        x
                    ∂u(x, y)/∂y     = cos x,  u(x, 4) = e cos x − e cos 4 (P9.3.11)
                               y=0

                                                         y        4
               (f) ∂u(x, y)/∂x    =− cos y,    u(4,y) = e cos 4 − e cos y(P9.3.12)
                               x=0
                                                             4       x
                    ∂u(x, y)/∂y    = cos x,  ∂u(x, y)/∂y    = e cos x + e sin 4
                               y=0                    y=4
                                                                       (P9.3.13)
                                                                 4
                                                         y
                             y
               (g) u(0,y) = e − cos y, ∂u(x, y)/∂x       =−e sin 4 − e cos y(P9.3.14)
                                                 x=4
                                                             4        x
                    ∂u(x, y)/∂y     = cos x,  ∂u(x, y)/∂y     = e cos x + e sin 4
                               y=0                    y=4
                                                                       (P9.3.15)
                                                                 y       4
               (h) ∂u(x, y)/∂x     =− cos y,  ∂u(x, y)/∂x     =−e sin 4 − e cos y
                               x=0                       x=4
                                                                       (P9.3.16)
                                                             4        x
                    ∂u(x, y)/∂y     = cos x,  ∂u(x, y)/∂y     = e cos x + e sin 4
                               y=0                     y=4
                                                                       (P9.3.17)
            9.4 Parabolic PDEs: Heat Equations
               Modify the program “solve_heat.m” (in Section 9.2.3) so that it can solve
               the following PDEs by using the explicit forward Euler method, the implicit
               backward Euler method, and the Crank–Nicholson method.

                    2
                   ∂ u(x, t)  ∂u(x, t)
               (a)         =             for 0 ≤ x ≤ 1, 0 ≤ t ≤ 0.1     (P9.4.1)
                     ∂x 2       ∂t
                   with the initial/boundary conditions

                                   4
                          u(x, 0) = x ,  u(0,t) = 0,    u(1,t) = 1      (P9.4.2)
                    (i) With the solution region divided into M × N = 10 × 20 sections,
                       does the explicit forward Euler method converge? What is the value
                                      2
                       of r = A t/( x) ?
                   (ii) If you increase M and N to make M × N = 20 × 40 for better
                       accuracy, does the explicit forward Euler method still converge?
                                                     2
                       What is the value of r = A t/( x) ?
                   (iii) What is the number N of subintervals along the t axis that we should
                       choose in order to keep the same value of r for M = 20? With that
                       value of r, does the explicit forward Euler method converge?
   455   456   457   458   459   460   461   462   463   464   465