Answered step by step
Verified Expert Solution
Question
1 Approved Answer
This question considers a 1-D diffusion equation with spatially varying diffusion: ar du at with F(x, t) = -K(D)r' (6) and where K(x) is a
This question considers a 1-D diffusion equation with spatially varying diffusion: ar du at with F(x, t) = -K(D)r' (6) and where K(x) is a prescribed function. (a) Show that a discretisation of Eq. (6) using a forward difference approximation to the time derivative and a centred difference approximation to the space derivative may be written 7 uit! = u; + h (63+4 (45+1 u;) *;-(4 u;-1)], (7) where kj = (Lj), and 7 and h are the time and spatial steps. This method is called Forwards Time, Centred Space (FTCS). (b) For the general case of spatially varying K, determine a matrix formulation of the FTCS scheme Eq. (7) of the form u+1 = Mu", (8) where u" = (u, u,..., u)is a vector of dependent variable values at time step n. Assume Dirichlet boundary conditions w = a and u1 = b. Clearly show the form of the matrix M, and briefly explain how the boundary con- ditions are being imposed in the matrix formulation. (c) Assume that you are solving the problem in the general case with spatially varying K, using Eq. (7) on a spatial grid with L = 100 points, and using a time step 71. Your solution is stable and accurate. (1) You increase the resolution of your grid to L = 200 points. What time step T2 should you choose to ensure stability? (ii) You increase the resolution of your grid to L = 200 points, and you also halve all values of k(2). In this case, what time step 72 should you choose to ensure stability? (9) This question considers a 1-D diffusion equation with spatially varying diffusion: ar du at with F(x, t) = -K(D)r' (6) and where K(x) is a prescribed function. (a) Show that a discretisation of Eq. (6) using a forward difference approximation to the time derivative and a centred difference approximation to the space derivative may be written 7 uit! = u; + h (63+4 (45+1 u;) *;-(4 u;-1)], (7) where kj = (Lj), and 7 and h are the time and spatial steps. This method is called Forwards Time, Centred Space (FTCS). (b) For the general case of spatially varying K, determine a matrix formulation of the FTCS scheme Eq. (7) of the form u+1 = Mu", (8) where u" = (u, u,..., u)is a vector of dependent variable values at time step n. Assume Dirichlet boundary conditions w = a and u1 = b. Clearly show the form of the matrix M, and briefly explain how the boundary con- ditions are being imposed in the matrix formulation. (c) Assume that you are solving the problem in the general case with spatially varying K, using Eq. (7) on a spatial grid with L = 100 points, and using a time step 71. Your solution is stable and accurate. (1) You increase the resolution of your grid to L = 200 points. What time step T2 should you choose to ensure stability? (ii) You increase the resolution of your grid to L = 200 points, and you also halve all values of k(2). In this case, what time step 72 should you choose to ensure stability? (9)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started