X i t react. ~min i max i. R ij smallest. X j. Physical processes by characteristic timescale. largest. t diff ~ L2 D. t sound. ~ L a. t flow.

Similar documents
Photoionized Gas Ionization Equilibrium

CHAPTER 22. Astrophysical Gases

NUMERICAL METHODS IN ASTROPHYSICS An Introduction

Outline of lectures. Adding more physics. Doing Better: source terms in CTU unsplit integrator

Theory of optically thin emission line spectroscopy

Numerical Solutions for Hyperbolic Systems of Conservation Laws: from Godunov Method to Adaptive Mesh Refinement

Ay Fall 2004 Lecture 6 (given by Tony Travouillon)

Butcher tableau Can summarize an s + 1 stage Runge Kutta method using a triangular grid of coefficients

6. Interstellar Medium. Emission nebulae are diffuse patches of emission surrounding hot O and

Notes on Photoionized Regions Wednesday, January 12, 2011

Modeling, Simulating and Rendering Fluids. Thanks to Ron Fediw et al, Jos Stam, Henrik Jensen, Ryan

Computational Astrophysics 7 Hydrodynamics with source terms

The family of Runge Kutta methods with two intermediate evaluations is defined by

Physics and Chemistry of the Interstellar Medium

6. Stellar spectra. excitation and ionization, Saha s equation stellar spectral classification Balmer jump, H -

Diffusion / Parabolic Equations. PHY 688: Numerical Methods for (Astro)Physics

Index. higher order methods, 52 nonlinear, 36 with variable coefficients, 34 Burgers equation, 234 BVP, see boundary value problems

Thermal Equilibrium in Nebulae 1. For an ionized nebula under steady conditions, heating and cooling processes that in

The RAMSES code and related techniques 4. Source terms

Some fundamentals. Statistical mechanics. The non-equilibrium ISM. = g u

Topics ASTR 3730: Fall 2003

Gas Dynamics: Basic Equations, Waves and Shocks

2. Basic assumptions for stellar atmospheres

Last Time... We discussed energy sources to a shell of stellar material:

23 Astrophysics 23.5 Ionization of the Interstellar Gas near a Star

The Interstellar Medium

while the Planck mean opacity is defined by

Astronomy 8824: Numerical Methods Notes 2 Ordinary Differential Equations

Advection / Hyperbolic PDEs. PHY 604: Computational Methods in Physics and Astrophysics II

The Diffuse ISM Friday, February 11, 2011

Finite volumes for complex applications In this paper, we study finite-volume methods for balance laws. In particular, we focus on Godunov-type centra

Lec 3. Radiative Processes and HII Regions

6. Stellar spectra. excitation and ionization, Saha s equation stellar spectral classification Balmer jump, H -

2. Basic Assumptions for Stellar Atmospheres

Computational Fluid Dynamics. PHY 688: Numerical Methods for (Astro)Physics

6. Stellar spectra. excitation and ionization, Saha s equation stellar spectral classification Balmer jump, H -

Numerical modelling of phase change processes in clouds. Challenges and Approaches. Martin Reitzle Bernard Weigand

Opacity. requirement (aim): radiative equilibrium: near surface: Opacity

The Center for Astrophysical Thermonuclear Flashes. FLASH Hydrodynamics

Photoionization Modelling of H II Region for Oxygen Ions

X-ray Radiation, Absorption, and Scattering

The Chemical Kinetics Time Step a detailed lecture. Andrew Conley ACOM Division

The RAMSES code and related techniques I. Hydro solvers

Ordinary Differential Equations II

Astrophysics of Gaseous Nebulae and Active Galactic Nuclei

ASTR 610 Theory of Galaxy Formation Lecture 14: Heating & Cooling

The inverse process is recombination, and in equilibrium

The Birth Of Stars. How do stars form from the interstellar medium Where does star formation take place How do we induce star formation

M.Phys., M.Math.Phys., M.Sc. MTP Radiative Processes in Astrophysics and High-Energy Astrophysics

PDE Solvers for Fluid Flow

a few more introductory subjects : equilib. vs non-equil. ISM sources and sinks : matter replenishment, and exhaustion Galactic Energetics

Ordinary Differential Equations

Split explicit methods

Chapter 3C. 3-4C. Ionization

2. Basic assumptions for stellar atmospheres

Fluid Animation. Christopher Batty November 17, 2011

LECTURE NOTES. Ay/Ge 132 ATOMIC AND MOLECULAR PROCESSES IN ASTRONOMY AND PLANETARY SCIENCE. Geoffrey A. Blake. Fall term 2016 Caltech

NUMERICAL METHODS FOR ENGINEERING APPLICATION

Chapter 1. Introduction

Astr 5465 March 6, 2018 Abundances in Late-type Galaxies Spectra of HII Regions Offer a High-Precision Means for Measuring Abundance (of Gas)

Model of Hydrogen Deficient Nebulae in H II Regions at High Temperature

Astr 2310 Thurs. March 23, 2017 Today s Topics

2. Basic assumptions for stellar atmospheres

Ordinary differential equations - Initial value problems

Astrophysics with the Computer: Propagation of Ionization Fronts in Interstellar Gas

CHAPTER 27. Continuum Emission Mechanisms

Atomic Physics 3 ASTR 2110 Sarazin

Computational Astrophysics

New Results from 3-D supernova models with spectral neutrino diffusion

Advanced Stellar Astrophysics

The Virial Theorem for Stars

Radiative & Magnetohydrodynamic Shocks

Riemann Solvers and Numerical Methods for Fluid Dynamics

MOX EXPONENTIAL INTEGRATORS FOR MULTIPLE TIME SCALE PROBLEMS OF ENVIRONMENTAL FLUID DYNAMICS. Innsbruck Workshop October

Supernovae. Supernova basics Supernova types Light Curves SN Spectra after explosion Supernova Remnants (SNRs) Collisional Ionization

Stellar evolution Part I of III Star formation

An Overview of Fluid Animation. Christopher Batty March 11, 2014

ASTRONOMY QUALIFYING EXAM August Possibly Useful Quantities

Plasma Spectroscopy Inferences from Line Emission

80 2 Observational Cosmology L and the mean energy

AG Draconis. A high density plasma laboratory. Dr Peter Young Collaborators A.K. Dupree S.J. Kenyon B. Espey T.B.

Star Formation and Protostars

Chapter 9. The Formation and Structure of Stars

Ordinary Differential Equations II

Partitioned Methods for Multifield Problems

Lecture 4: Absorption and emission lines

Computational Fluid Dynamics-1(CFDI)

CHAPTER 4. Basics of Fluid Dynamics

Joint ICTP-IAEA Workshop on Fusion Plasma Modelling using Atomic and Molecular Data January 2012

Emitted Spectrum Summary of emission processes Emissivities for emission lines: - Collisionally excited lines - Recombination cascades Emissivities

CS520: numerical ODEs (Ch.2)

The Role of a Strong Far-Infrared Radiation Field in Line Excitation and Cooling of Photodissociation Regions and Molecular Clouds

9.1 Introduction. 9.2 Static Models STELLAR MODELS

(c) (a) 3kT/2. Cascade

THIRD-YEAR ASTROPHYSICS

Astronomy 1504 Section 002 Astronomy 1514 Section 10 Midterm 2, Version 1 October 19, 2012

Atomic Transitions II & Molecular Structure

7. Non-LTE basic concepts

Numerical Methods for Engineers and Scientists

[Toward] Simulating Cosmological Reionization with Enzo

Transcription:

Physical processes by characteristic timescale Diffusive timescale t diff ~ L2 D largest Sound crossing timescale t sound ~ L a Flow timescale t flow ~ L u Free fall timescale Cooling timescale Reaction timescale t ff ~ 1 G t cool ~ X i t react ~min i X i ~ 1 max i j X j R ij smallest

Continuity equation source terms Multiple fluid components 1 2 3... N f = X 1 X 2 X 3... X N f =1} X i i i t i u =0 X i t u X i=0 Reactions that convert one fluid component into another N X i t u X = f i j=1 X i X j R ij Mass diffusion usually negligible in astrophysical settings t u = [ D ]

Importance of conservation in continuity equations The sum X i =1 is not always preserved by an update step: Interpolants: different flattening of the X i Source terms: not always guaranteed to preserve sum Solutions: Rescaling X i X i j X j Restricting X i min[1,max 0, X i ] Problem: no error control Solving only N f 1 equations N f 1 X N f =1 j =1 Problem: error tends to accumulate in the assumed fluid abundance X j Flatten all abundances when X i 1, otherwise none of them Problem: reduces spatial order, leads to numerical mixing

Momentum equation source terms Gravitational forces and viscosity u uu P= g D t = [G D ] For momentum equation these terms can be written as the divergence of a conserved flux. Can also have true momentum source terms: e.g., AGN jets modelled as pistons

Energy equation source terms Energy sources/sinks gravity, radiation E t t u P u= [ E P u]= u g Thermal conduction and viscous heating t u P u= [ K ] 1 2 D 2 D ij = u i x j u j x i 2 3 ij u Equation of state,t, X 1,..., X N f for ideal gases: Dalton's law of partial pressures P=P 1,T P 2, T... P N f, T

Unsplit methods Solve the advection, diffusion, and source terms together e.g., upwind differencing for advection, FTCS for diffusion, and FT for source: q i n 1 =q i n t q t where s = 1 if u i n < 0, s = 0 if u i n > 0 n x [ qu i s = qu x D 2 q x 2 n qu i s 1 D x n q i 1 n] 2 q n n i q i 1 i Advantage: Disadvantage: avoids errors introduced by operator splitting difficult to develop Godunov type methods and multidimensional methods; usually no exact solution to Riemann problem

Split (fractional step) methods Apply difference operators for each piece of physics in sequence. Consider D = D 1 + D 2 + D 3 First order (time): D[q] = D 1 [D 2 [D 3 [q]]] + O( t) Second order (time) Strang splitting: With operator splitting we cannot do better than the time accuracy of the splitting method, no matter what the accuracy of the component operators is. Solve the advection part of our equation with a standard CFD method, with the diffusion terms split off and solved with a parabolic solver, and the source terms split off and solved with an ordinary differential equation solver: q t D[q] = D 1 1/2 [D 2 1/2 [D 3 1/2 [D 3 1/2 [D 2 1/2 [D 1 1/2 [q]]]]]] + O( t 2 ) qu = x D 2 q x 2 { q qu = t x q t =D 2 q x 2 d q d t =

Stiffness Often have very different timescales for flow and source terms. e.g., thermonuclear runaway in a white dwarf (Type Ia supernova) nuclear burning timescale ( 12 C + 12 C) sound crossing timescale If we stick to explicit time integration schemes, we are forced to integrate on the shortest timescale in order to maintain numerical stability! Yet doing everything implicitly causes problems when shock waves are involved. So commonly we: t burn ~ 4 1018 ~ n 1 cm 3 sec ~ 10 12 sec t sound ~ R a ~ 6 108 cm 2 10 2 c ~ 1 sec Use explicit methods for longest timescale physics (advection, diffusion) Use implicit methods for shortest timescale physics (reactions, diffusion) Set timestep using explicit method and then sub cycle the implicit method

Sub cycling q(x,t) source term q n+1 q n+2 q n advection total t t n t n+1 t n+2 t n,1 t n,2 t n,3 t n,4 t n,5 t n,6 t n,7 Intervals t n between Intervals t n,m between determined by stability needs of explicit scheme determined by accuracy needs of implicit scheme; last interval set to make t n,mmax = t n+1 Cannot have t n max m t n,m causes advection and source terms to decouple

Explicit ODE methods Consider the system of linear ordinary differential equations with A symmetric and positive definite (all positive eigenvalues). The number of elements in the vector q is the number of simultaneous source term equations we are solving. One such system is solved for every zone in our grid. Forward Euler (explicit) differencing gives For stability, the timestep must satisfy d q dt = A q q m 1 = I A t q m 1 max t 1 t 2 max where max is the maximum eigenvalue of A.

Runge Kutta methods Explicit ODE integration schemes that achieve higher order than forward Euler by computing derivatives at intermediate points Combine with adaptive step size control for robust integration to modest accuracy (~ 10 4 ) either by halving t or by combining different orders to get error estimate ( embedding ) Second order Runge Kutta (midpoint method): k 1 = t f t m,q m q(t) k 2 = t f t m 1 2 t,qm 1 2 k 1 q m 1 =q m k 2 O t 3 Fourth order Runge Kutta method: k 1 = t f t m, q m k 2 = t f t m 1 2 t, qm 1 2 k 1 k 3 = t f t m 1 2 t, qm 1 2 k 2 k 4 = t f t m t, q m k 3 q m q m+1 t q m 1 =q m 1 6 k 1 1 3 k 2 1 3 k 3 1 6 k 4 O t 5 t m t m+1/2 t m+1 k 1 k 2 k 3 k 4

Bulirsch Stoer method Can also use midpoint method on successively smaller intervals t and use Richardson extrapolation to estimate solution at t 0. q(t) 2 steps q m 4 steps 6 steps steps m+1 q t m t m+1 t Advantage: much more efficient than Runge Kutta for large systems & high accuracy Disadvantage: not as robust for nonsmooth or singular source terms

Implicit and semi implicit ODE methods Backward Euler (implicit) differencing gives which is unconditionally stable, since for all eigenvalues and timesteps t. For nonlinear systems of equations we use Newton's method: q m 1 =q m A q m 1 t q m 1 = I A t 1 q m 1 t 1 1 d q dt =f q qm 1 =q m f q m 1 t q m 1 =q m t[ I t f q m] 1 f q m f/ q is the Jacobian matrix. This type of method is called semi implicit.

Rosenbrock methods Semi implicit generalization of Runge Kutta methods. Look for a solution of the form where f I t q m k i = t f qm s is the order of the method. q m 1 =q m i=1 s i 1 j=1 c i k i ij k j t f q m i 1 j=1 ij k j By combining third and fourth order methods, can obtain an estimate of truncation error to use for adaptive step size control. Method is not guaranteed to be stable (semi implicit), but fairly robust nevertheless, even for nonsmooth right hand sides (e.g., from tabular interpolation). For large vectors q (> 10 elements) and high accuracy (< 10 5 ), methods based on Richardson extrapolation are more efficient.

Intermission

Reaction networks example: diffuse gas + radiation Partially or fully ionized diffuse gas experiences several types of reaction: Photoionization: X + X + + e Recombination: X + + e X + Photon absorption: X + X* Photon emission: X* X + Stimulated emission: X* + X + 2 Collisional excitation: X + e X* + e Collisional ionization: X + e X + + 2e + Charge exchange: X + p X + + H Dielectronic recombination: X+ + e X* Bremsstrahlung: X + e X + e +... Again, we treat different elements and ionization states as different fluids: H 0, H +, H, He 0, He +, He ++,... Overall charge neutrality gives free electron number density: n e = i Z i n i In optically thin limit all radiation escapes; in optically thick limit it is absorbed; in other regimes we need to keep track of radiation field and do radiation transfer

Thermal and ionization equilibrium If we have local thermodynamic equilibrium conditions (necessary for a fluid approach!), the Boltzmann relation gives relative abundances of excited states: n i = n g U i e E / kt i i n i n U i g i E i = number density of atomic/ionic species in ith excited state = total number density of species = partition function for ith state = statistical weight for ith state = energy of ith state relative to ground state If we have ionization equilibrium conditions, we can use Saha equation to determine ionic abundances rather than following them separately: n i 1 n e n i = 2U i 1 U i 2 m kt e h 2 3 /2 e / kt i n i n e U i i = number density of ions in ionization state i = free electron number density = partition function for ionization state i = ionization energy of for ionization state i Then we just track the atomic abundances and use the Saha equation whenever we need an ionic abundance.

Collisional ionization equilibrium A common situation in the intergalactic medium is collisional ionization equilibrium, in which atoms are collisionally ionized and radiatively recombine. If the gas is optically thin, this causes a net loss of energy from the gas. Treat this situation using: One continuity equation for each element (or a single metallicity for all of them) Ionization fraction is a known function of temperature and abundances use to determine n e (needed for emissivity and equation of state) n X,i n X, i T, n H, n H, n He, n He, n He,... P= n e X,i n X, i kt Radiative cooling via a local energy sink term cooling rate is a known function of density, temperature, and abundances: d dt = T, n H,...

Radiative cooling rate for collisionally ionized gas Primordial abundances (from Black 1981) 22 total excitation ionization recombination bremsstrahlung (erg s 1 cm 3 ) 23 H H He + log /n H 2 24 He + H 25 He He He + 4 5 6 7 8 log T (K)

Photoionization equilibrium Another common situation: a source of ultraviolet photons ionizes nearby gas; medium is optically thick to recombination photons ( Strömgren sphere ) In the interior of the nebula the ionization state is set by the equilibrium between: Photoionization by photons from central source and from locally produced recombination photons Collisional ionization by local free electrons Recombination Neutral gas Ionized gas O star 5 pc The size of the nebula increases with time unless collisional processes produce radiation that can escape. 0.01 pc Inside cloud treat using: Ionic abundances from photoionization equilibrium given known external photon source: varying optical depth to known source, local recombination radiation produces local re ionization ( on the spot approximation) Net heating source term for energy equation includes collisional cooling effects Near the edge of the cloud finite optical depth to local recombination photons must be taken into account

Photoionization equilibrium 2 Case 1: no external radiation field, optically thin, collisional cooling only T decreases with time (( )) Case 2: known external radiation field, net photoionization energy input exceeds collisional cooling rate T increases with time Case 3: known external radiation field, collisional cooling rate exceeds net photoionization energy input T decreases with time (( )) Case 4: known external radiation field, net photoionization energy input balances collisional cooling thermal equilibrium (( ))

Cooling curves including photoionization Representative curves for uniform external J = 10 22 ( L / ) erg s 1 cm 2 sr 1 Hz 1 (N. Katz) At lower density, almost complete ionization so gas transparent to recombination photons, allowing them to act as a coolant At higher density, recombination photons are locally absorbed cooling occurs by collisionally excited line emission and bremsstrahlung n H = 2.89 10 6 cm 3 n H = 2.89 10 3 cm 3 22 22 (erg s 1 cm 3 ) 23 Heating 23 log /n H 2 24 24 25 4 5 6 7 8 log T (K) 25 Equilibrium temperature 4 5 6 7 8 log T (K)