wiki:1DPulsedJets

Version 8 (modified by ehansen, 13 years ago) ( diff )

Z Cooling


The Physics of Z Cooling

Z cooling is an energy loss due to forbidden line emission. The routines use Pat Hartigan's cooling table Zcooling.tab. The table does not include recombination or permitted line emission.

PHcooling.tab

Understanding the format of this table is crucial to interpolating correctly. There are a few properties that this table must have:

1.) It must be ordered as log(ne), T, log(X), (9 species cooling fractions), cooling rate. Where ne is the electron density, T is temperature, X is ionization fraction, and the 9 species cooling fractions are the fractions of how much each species contributes to the cooling rate. Note that here log refers to the base 10 logarithm. The 9 species are ordered as follows: OI, OII, NI, NII, SII, FeII, SIII, MgII, CII.

2.) The step sizes of log(ne), T, and log(X) must remain constant. In other words, each column is evenly spaced.

Also, it is important to note that the cooling rate has units of erg * cm-3 * nH-2. So before the rate can be added to the change in energy, dqdt(iE), it must be multiplied by nH2 where nH is the number density of hydrogen.

Zcooling.tab

PHcooling.tab contains a lot of data that is not needed. Reading in this data one line at a time is inefficient, especially when astrobear is being run on multiple processors. This is why a separate script called ph2zformat.s is used to reformat PHcooling.tab into Zcooling.tab before running astrobear. Remember that PHcooling.tab still requires the aforementioned properties in order to be reformatted correctly. Zcooling.tab has the following format:

nDensities
nTemps
nXs
lognemin
lognemax
tempmin
tempmax
logxmin
logxmax
coolingrate(1,1,1)
coolingrate(2,1,1)

coolingrate(nDensities,nTemps,nxs)

Where nDensities, nTemps, and nXs are the number of unique values for log(ne), T, and log(X) respectively. So if these parameters are equal to 40, 30, and 21, then there are a total of 25,200 cooling rates (40*30*21 = 25200). lognemin is the minimum value of the log(ne) column in PHcooling.tab, and the other minimum and maximum values are defined in the same way. Now the data does not need to be read in one line at a time for 25,200 or so values. The entire array of cooling rates can be read in with a single READ statement. No iteration or nested DO loops required.


The Interpolation


Attachments (9)

Download all attachments as: .zip

Note: See TracWiki for help on using the wiki.