360 likes | 815 Views
Explosions and Shock Waves. 10 February 2003 Astronomy G9001 - Spring 2003 Prof. Mordecai-Mark Mac Low. Shock Waves in the ISM. supernova remnants stellar wind bubbles H II regions stellar jets spiral arms accretion flows thermal instability. point blast waves. Point Explosions.
E N D
Explosions and Shock Waves 10 February 2003 Astronomy G9001 - Spring 2003 Prof. Mordecai-Mark Mac Low
Shock Waves in the ISM • supernova remnants • stellar wind bubbles • H II regions • stellar jets • spiral arms • accretion flows • thermal instability point blast waves
Point Explosions • Sedov’s dimensional analysis • relevant physical variables are E, ρ0, R, t • combine to find a dimensionless constant
Blast Wave Equation of Motion Cioffi, McKee, and Bertschinger (1988)
Similarity Solutions Ryu & Vishniac 1987 • The interior structure of an adiabatic blast wave from a point explosion has no intrinsic scale. • Specification of the time or radius determines the rest of the structure. • Non-dimensionalization of equations of gas flow allows derivation.
Dynamical Overstability ram thermal Vishniac (1983)
Development and Saturation • Vishniac overstability occurs (Ryu & Vishniac 1987, 1988) • for γ < 1.2 in blast waves • for γ < 1.1 in shells • Growth rate of t1/2 • Saturates when flows in shell become supersonic (ML & Norman 1992) • Transonic turbulence in shell
Experimental Verification • Laser vaporization of foam target • Nitrogen has γ=1.4 (adiabatic diatomic gas) • Xenon has many lines, so can radiatively cool with effective γ~1.05 N2 Xe Grun et al. 1991 (PRL)
Nonlinear Thin Shell Instability ram • Nonlinear instability • Displacements must be as large as layer thickness • Occurs in shock-bounded layer if thin ram Vishniac (1994)
Nonlinear Development • Leads to steadily thickening turbulent layer (Blondin & Marks 1996)
Explosions in a Stratified Medium • Explosions in exponentially stratified medium formally reach infinite velocity in finite time (Kompaneets 1959) • Explosions in medium with ρ~1/r2expand at constant rate. In steeper power laws they accelerate, in shallower they decelerate (see Ostriker & McKee 1988, Koo & McKee 1990)
stable unstable g g decelerating accelerating v v g g v v g g Rayleigh-Taylor instabilities in shells
Supernova Remnants • developmental stages • numerical solution (Cioffi, McKee & Bertschinger 1988)
Stellar Wind Bubbles • Double shock structure, separated by a contact discontinuity • Outer shell quickly cools, interior only cools if very dense • Hot interior = pressure driven (R~t3/5) • Cold interior = mntm driven (R~t1/2)
Stellar Wind Bubbles • Similarity solution for shell structure (Castor, McCray & Weaver 1976, Weaver et al. 1977) • Interior dominated by conductive evaporation ρ T shell center
Hot ISM • To explain observed hot medium, consider filling factor of supernova remnants • Cox & Smith (1975), McKee & Ostriker (1977) • How to compute expansion of SNRs in clumpy, inhomogeneous medium? • MO77 assumed dense, round clouds embedded in low-density intercloud gas • SNRs expand quickly through low-density gas, so they found very high filling factors.
Multiple Supernovae: Superbubbles • Most Type II SNe from massive stars occur in OB associations • Later SNe occur within earlier SNRs • Later blast waves quickly decelerate to sound speed of hot interior, maintaining pressure (ML & McCray 1988) • Multiple SNR expands like wind-driven bubble with Lmech=NSNESN/ΔtSN
Multiple Supernovae: Turbulence ML, Avillez, Balsara, Kim 2001, astro-ph • Computational model of disk • 1 x 1 x 20 kpc2 • SN driving • vertical strat. • 1.25 pc res • radiative cooling
Galactic Fountain • Hot gas in plane must rise • Shapiro & Field (1976) computed consequences • Gas at 106 K allowed to radiatively cool • Incorporating self-photoionization gives good match to column densities of C IV, N V, and O VI (Shapiro & Benjamin 1991) • Result of cooling shown numerically to be falling, dense clouds (Avillez 2000)
Starburst winds • With sufficiently high star formation (and SN) rate, hot gas entirely escapes potential • X-ray and Hα emission observed many kpc away from starburst galaxies • Winds may energize, pollute nearby IGM, but can’t sweep away rest of ISM (ML & Ferrara 1999, Fujita et al. in prep) • winds accelerate down steepest density gradients • far more energy required to sweep ISM than just the gravitational binding energy suggested by Dekel & Silk (1986)
Where to go next? • Current plan is to devote one more week to ZEUS-3D, examining MHD problems • Then spend similar amounts of time on • Flashcode (AMR, Riemann solver, MPI) • GADGET (SPH, self-gravity methods, MPI) • Cloudy (photoionization computations) • Alternatives: • spend more time on ZEUS-3D • study ZEUS-MP as an example of an MPI code instead of one of the other codes (based on ZEUS-3D so some things familiar)
Multidimensional Computations • Directional splitting • XYZ XZY YZX... • Centering • velocities are face centered, not edge centered
Different coordinate systems • Non-cartesian rectilinear coordinate systems in ZEUS: all difference equations in covariant form.
Ratioed grids • ZEUS includes ratioed grids (see sample prob). • add multiple ggen namelists • set lgrid=.f. until last one, then .t. • x1rat=1.03 is a typical value • To compute grid sizes • Best not to exceed 10:1 zone aspect ratioes. • dxmax=(dxmin)n
Parallelization • Additional issues: • How to coordinate multiple processors • How to minimize communications • Common types of parallel machines • shared memory, single program • eg SGI Origin 2000, dual or quad proc PCs • multiple memory, multiple program • eg Beowulf Linux clusters, Cray T3E, ASCI systems
Shared Memory • Multiple processors share same memory • Only one processor can access memory location at a time • Synchronization by controlling who reads, writes shared memory U of Minn Supercomputing Inst.
Shared Memory • Advantages • Easy for user • Speed of memory access • Disadvantages • Memory bandwidth limited. • Increase of processors without increase of bandwidth will cause severe bottlenecks
Distributed Memory • Multiple processors with private memory • Data shared across network • User responsible for synchronization U of Minn Supercomputing Inst.
Distributed Memory • Advantages • Memory scalable with number of processors. More processors, more memory. • Each processor can read its own memory quickly • Disadvantages • Difficult to map data structure to memory organization • User responsible for sending and receiving data among processors • To minimize overhead, data should be transferred early and in large chunks.
Shared memory data parallel loop level parallelization Implementation OpenMP Fortran90 High Performance Fortran (HPF) Examples ZEUS-3D Distributed memory block parallel tiled grids Implementation Message Passing Interface (MPI) Parallel Virtual Machine (PVM) Examples ZEUS-MP Flashcode GADGET Methods
OpenMP • Designate inner loops that can be distributed across processors with DOACROSS command. • Dependencies between loop instances prevent parallelization • Execution of each loop usually depends on values from neighboring parts of grid. • ZEUS-3D only parallelizes out to 8-10 processors with OpenMP
Cache Optimization • Modern processors retrieve 64 bytes or more at a time from main memory • However it takes hundreds of cycles • Cache is small amount of very fast memory on microprocessor chip • Retrievals from cache take only a few cycles. • If successive operations can work on cached data, speed much higher • Fastest changing array index should be inner loop, even if code rearrangement required
Parallel ZEUS-3D • To run ZEUS-3D in parallel, set the variable iutask = 1 in setup block, recompile. • inserts DOACROSS directives • compiles with parallel flags turned on if OS supports them. • Set the number of processors for the job (usually with an environment variable) • Run is otherwise similar to serial.
Use of IDL pause • Quick and dirty movies for i=1,30 do begin & $ a=sin(findgen(10000.)) & $ hdfrd,f=’zhd_’+string(i,form=’(i3.3)’)+’aa’,d=d,x=x & $ plot,x,d[4].dat & end • Scaling, autoscaling, logscaling 2D arrays tvscl,alog(d) tv,bytscl(d,max=dmax,min=dmin) • Array manipulation, resizing tvscl,rebin(d,nx,ny,/s) ; nx, ny multiple tvscl,rebin(reform(d[j,*,*]),nx,ny,/s)
More IDL • plots, contours plot,x,d[i,*,k],xtitle=’Title’,psym=-3 oplot,x,d[i+10,*,k] contour,reform(d[i,*,*]),nlev=10 • slicer3D dp = ptr_new(alog10(d)) slicer3D,dp • Subroutines, functions