ASTR415/688C Spring 2005 Problem Set #7

Due May 20, 2005 (3:30 pm, no extensions)

This is an optional assignment for bonus credit only (10 marks).

Write a 1-D fluid dynamics code using either the Lax scheme or the two-step Lax-Wendroff scheme (extra credit if you do both!) to solve the fluid equations in conservative form:

where

and is the mass density, is the gas velocity (a scalar in this case), is the gas pressure, is the energy density, and is the internal specific energy. Assume an ideal gas equation of state , with adiabatic exponent = 1.4 (corresponding to an ideal diatomic gas).

Test your code by solving the classic 1-D shock tube'' problem (Sod 1978, J. Comput. Phys. 27, 1). At there is hot, dense gas with , on the left and cool, rarefied gas with , on the right. The initial gas speed is zero throughout (in these units, speed is normalized to the sound speed , where ). This nonequilibrium situation results in a shock wave propagating right with a rarefaction wave propagating left. Compare your results at with those shown in Stone & Norman 1992, ApJS 80, 753, Fig. 11 (i.e., plot , , , and as a function of at time ). HINT: let the number of grid points in be a free parameter, set assuming your domain ranges from 0 to 1 in with the discontinuity at , and choose to safely satisfy the Courant condition. Don't forget the boundary conditions! (You may assume neither wave reaches either boundary during the time interval simulated.) For what (if any!) do you get a good match with the Stone & Norman figure?

BONUS: Make a movie of the results!