Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Q2b Modify the template in Lab06_Q2.m using the following values Set L = 100 Discretise your domain with 250 intervals. Choose u = 1.0
Q2b Modify the template in Lab06_Q2.m using the following values Set L = 100 Discretise your domain with 250 intervals. Choose u = 1.0 Set tmax 100 Choose 3 values of a [0, 0.1, 1], integrate forward in time until t = tmax with the following CFL numbers: [0.01, 0.1, 0.5] and (i.e. you will have 9 solutions). Create a single plot with 9 subplots. Each subplot will have the solution for one CFL number and one value of a. In each subplot, plot the solution at approximately every 25 time units (i.e. at t = 0, 25, 50, 75 and 100) on the same subplot (i.e. you should have 9 subplots, each with 5 curves). The plot times can be "approximate" (e.g., 19.95 is close enough to 20). ALSO include a plot of the analytic solution of the advection-only problem at each time in a different colour in each subplot for comparison (giving 8 curves per subplot). NOTE: If q(x, 0) = f(x) is the initial condition, then the exact solution at time = t is q(x,t) = f(x-ut) 1 The CFL (or Courant) number is defined as (u At/Ax) and is related to what fraction of a grid cell "information" is advected in one timestep. MEC3456 Computer Lab 06 Page 4 of 9 Describe the key features of what you are seeing as you change a and the CFL number and suggest WHY you observe what you observe (the following hints might help you). HINTS: 1) What is the stability for the FTCS scheme for equation 3 when = 0 (i.e. pure advection)? 2) What does it mean if CFL is large and how does the change in CFL affect the solution q?
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