Diffusion / Conduction

Consider a (1-dimensional) diffusion process, with (constant) diffusivity D > 0, for the concentration u(x,t) in an interval a ≤ x ≤ b, during some time 0 ≤ t ≤ t_{end}. Initialy, the concentration profile is u_{0}(x), a ≤ x ≤ b, and the ends are impermeable. 1. State precisely and fully the mathematical problem (PDE, IC, BCs) modeling this process. 2. Implement the explicit Finite Volume scheme for this problem, for a mesh of M uniform control volumes in the interval [a,b], up to a time t_{end}. Your code should read values forMM, tfrom a data file, where MM = number of nodes_{end}, factor, dtout, D, a, bper unit length. Then dx = 1/MM and M = (b-a)/dx = (b-a)*MM. For stability of the explicit scheme, the time-step dt is determined as: dt = factor * dt_{expl}, where dt_{expl}= dx^{2}/(2D). 3. Take a=0.0, b=4.0, and consider the initial profile ("square bump"): u_{0}(x) = 5 for 1 ≤ x ≤ 2, u_{0}(x) = 0 otherwise. a. Using MM=8 (so M=4*8=32), D=0.1, factor=0.95, tend=6, dtout=2, calculate and plot the profiles at times: 0., 2., 4., 6. on the same plot (mark which curve is at what time).What is happening to the "bump" ?b. Calculate the area under the profile at time=0. and time=6. (can use Trapezoidal Rule Quadrature, see below).Do they agree ? should they ? What does this area represent physically ?Now let's examine the effect of various parameters. For each of the runs listed bellow, do the following: — plot the initial and final (at t_{end}) profiles on one plot; — on the plot, mark the parameter values that generated it — comment as to what you think is happening and why, how it compares with the other cases, observations, remarks. Here are the cases to examine. c. Effect of the time-step: dx = 1/16 (i.e. MM=16), D = 0.1, tend = 1., dtout=1 , (c1) factor = 0.90 (c2) factor = 0.99 (c3) factor = 1.0 (c4) factor = 1.05 d. Effect of the mesh: D=0.1, tend=1., dtout=1, factor=0.99, (d1) dx = 1/ 8 (i.e. MM= 8) (d2) dx = 1/16 (i.e. MM=16) (d3) dx = 1/32 (i.e. MM=32) e. Effect of diffusivity: dx=1/8, tend=1., dtout=1, factor=0.90, (e1) D = 0.1 (e2) D = 0.5 What to submit: 1. By M Sep 4 (midnight): Put your code into a txt file "lab2.txt", and submit as email ATTACHMENT to alexiades@utk.edu , (and to yourself) with Subject: M578 lab2 code. 2. On R Sep 7: Submit on PAPER: your answers to the questions in parts 1, 3a,b, the plots and comments for 3c,d,e, and your code. (In the next Lab, you will test the code against an exact solution).

so keep it simple, understandable, and efficient !