Cloudy
Spectral Synthesis Code for Astrophysics
|
#include <grainvar.h>
Public Member Functions | |
GrainBin () | |
void | clear () |
ChargeBin & | chrg (long nz) |
const ChargeBin & | chrg (long nz) const |
Private Member Functions | |
void | p_clear0 () |
void | p_clear1 () |
Private Attributes | |
vector< ChargeBin > | pool |
NB NB NB NB NB NB
this is the data structure for all grain data that depends on grain type (i.e. all data that can differ from one grain bin to the next),
each data item will be referenced as: gv.bin[nd]->data_item
this structure is allocated for each grain bin at run time.
Data items that are generic for all grain types, or are summed over all grain types, should go in gv below !!
NB NB NB NB NB NB
|
inline |
|
inline |
|
private |
References asym, dstab1, dstab1_x_anu, inv_att_len, pool, pure_sc1, sd, and y0b06.
Referenced by clear().
|
private |
References avdft, avDGRatio, avdpot, avdust, AveDustZ, BolFlux, ChemEn, ChemEnH2, cnv_CM3_pGR, cnv_CM3_pH, cnv_GR_pCM3, cnv_GR_pH, cnv_H_pCM3, cnv_H_pGR, DF_STANDARD, dstAbund, dstems, dstfactor, dstpot, dstslp, dstslp2, DustDftVel, DustEnth, EnthSlp, EnthSlp2, GasHeatPhotoEl, GrainCoolTherm, GrainGasCool, GrainHeat, GrainHeatColl, GrnDpth, HeatingRate1, ichrg, le_thres, lgEverQHeat, lgPAHsInIonizedRegion, lgQHeat, lgQHTooWide, lgTdustConverged, lgUseQHeat, LowestZg, nChrg, nChrgOrg, GrainVar::nChrgRequested, NCHS, NDEMS, nDustFunc, nfill, pool, QHeatFailures, qnflux, qnflux2, qtmin, qtmin_zone1, rate_h2_form_grains_CT02, rate_h2_form_grains_ELRD, rate_h2_form_grains_HM79, rate_h2_form_grains_used, RateDn, RateUp, RSFCheck, sd, StickElecNeg, StickElecPos, tedust, TeGrainMax, and thermionic.
Referenced by clear(), and GrainBin().
double GrainBin::AccomCoef[LIMELM] |
accommodation coefficient, needed for collisional heating of grain
vector<double> GrainBin::asym |
asymmetry factor (1-g)
Referenced by p_clear0().
realnum GrainBin::atomWeight |
molecular weight per atom, in amu
realnum GrainBin::AvArea |
average grain surface area, <4pi*a^2>, in cm^2, CURRENTLY NOT USED
realnum GrainBin::avdft |
Integral(vdrift*dReff) for average drift velocity, OUTPUT ONLY
Referenced by p_clear1().
realnum GrainBin::avDGRatio |
Integral(D/G*dReff) for average dust to gas ratio, OUTPUT ONLY
Referenced by p_clear1().
realnum GrainBin::avdpot |
Integral(Vg*dReff) for average grain potential, OUTPUT ONLY
Referenced by p_clear1().
realnum GrainBin::avdust |
Integral(Tdust*dReff) for average equilibrium temperature, OUTPUT ONLY
Referenced by p_clear1().
double GrainBin::AveDustZ |
average charge per grain, in electrons
Referenced by p_clear1().
realnum GrainBin::AvRadius |
average grain radius, <a^3>/<a^2>, in cm
realnum GrainBin::AvVol |
average grain volume, <4/3pi*a^3>, in cm^3
realnum GrainBin::BandGap |
gap between valence and conduction band, in Ryd
double GrainBin::BolFlux |
heating/cooling balance, all entries are valid for current zone, actual depl, and are in erg/cm^3/s total photon flux absorbed, used for energy conservation test
Referenced by p_clear1().
double GrainBin::Capacity |
grain capacity, in Farad/grain
char GrainBin::chDstLab[13] |
general information on the grains label for the species
double GrainBin::ChemEn |
net amount of energy donated by recombining ions
Referenced by p_clear1().
double GrainBin::ChemEnH2 |
net amount of energy donated by H2 formation on grain surface
Referenced by p_clear1().
double GrainBin::cnv_CM3_pGR |
grain unit conversion, <unit>/cm^3 (actual depl) -> <unit>/grain
Referenced by p_clear1().
double GrainBin::cnv_CM3_pH |
grain unit conversion, <unit>/cm^3 (actual depl) -> <unit>/H (default depl)
Referenced by p_clear1().
double GrainBin::cnv_GR_pCM3 |
grain unit conversion, <unit>/grain -> <unit>/cm^3 (actual depl)
Referenced by p_clear1().
double GrainBin::cnv_GR_pH |
grain unit conversion, <unit>/grain -> <unit>/H (default depl)
Referenced by p_clear1().
double GrainBin::cnv_H_pCM3 |
grain unit conversion, <unit>/H (default depl) -> <unit>/cm^3 (actual depl)
Referenced by p_clear1().
double GrainBin::cnv_H_pGR |
grain unit conversion, <unit>/H (default depl) -> <unit>/grain
Referenced by p_clear1().
vector<double> GrainBin::dstab1 |
>>chng 02 dec 30, separated scattering cross section and asymmetry factor (1-g), NB NB NB – note that pure_sc1 DOES NOT contain the asymmetry factor, while gv.dstsc DOES !!! absorption cross section per grain species, for default depl
Referenced by p_clear0().
vector<double> GrainBin::dstab1_x_anu |
helper array, dstab1[i]*anu[i] for default depl
Referenced by p_clear0().
realnum GrainBin::dstAbund |
grain abundance in zone, dstfactor*GrainMetal*GrnVryDpth(radius)
Referenced by p_clear1().
double GrainBin::dstems[NDEMS] |
equilibrium temperature grain emissivity at dsttmp[], default depl, normalized per H
Referenced by p_clear1().
realnum GrainBin::dstfactor |
chemical abundances of grains in elmAbund are defined as follows: e.g. for MgSiFeO4 the oxygen abundance would be given by elmAbund[nd][7] = 4.*dustp[nd][2]*dustp[nd][3]*dustp[nd][4] chemical abundances of grains are normalized such that in any given zone the total fractional abundance of an element Z locked up in grains is given by SumFracAbund(nelem) = Sum_over_nd ( gv.bin[nd]->elmAbund[nelem]*gv.dstAbund[nd] ) grain depletion, normalization conversion factors grain depletion factor, dep from GRAINS command
Referenced by p_clear1().
double GrainBin::dstpot |
grain potential in Ryd
Referenced by p_clear1().
double GrainBin::dstslp[NDEMS] |
auxiliary array for spline interpolation
Referenced by p_clear1().
double GrainBin::dstslp2[NDEMS] |
auxiliary array for inverse spline interpolation
Referenced by p_clear1().
realnum GrainBin::DustDftVel |
grain drift grain drift velocity for this zone
Referenced by p_clear1().
double GrainBin::DustEnth[NDEMS] |
grain enthalpy at dsttmp[], in Ryd/grain
Referenced by p_clear1().
realnum GrainBin::dustp[5] |
0 = specific weight (g/cm^3), 1 = mol. weight (amu), 2 = default abundance, 3 = default depletion, 4 = fraction of the mass in this grain bin
realnum GrainBin::DustWorkFcn |
work function, in Ryd
double GrainBin::eec |
pow(dustp[0],-0.85), needed for electron esacpe length
chemical composition, abundance at default depl, see comment below
double GrainBin::EnthSlp[NDEMS] |
auxiliary array for spline interpolation
Referenced by p_clear1().
double GrainBin::EnthSlp2[NDEMS] |
auxiliary array for inverse spline interpolation
Referenced by p_clear1().
double GrainBin::eyc |
1./AvRadius + 1.e7, needed for electron yield
double GrainBin::GasHeatPhotoEl |
photoelectric heating of the gas, added in GrGH 0
Referenced by p_clear1().
double GrainBin::GrainCoolTherm |
grain cooling due to thermionic emissions, summed over charge states
Referenced by p_clear1().
double GrainBin::GrainGasCool |
gas cooling due to collisions with grains
Referenced by p_clear1().
double GrainBin::GrainHeat |
total heating of current grain type
Referenced by p_clear1().
double GrainBin::GrainHeatColl |
collisional heating of current grain type
Referenced by p_clear1().
realnum GrainBin::GrnDpth |
grain abundance scale factor in zone, GrnStdDpth(radius), used by set PAH constant / H0 commands
Referenced by p_clear1().
double GrainBin::HeatingRate1 |
quantum heating due to molecule/ion collisions, erg/H/s, default depl
Referenced by p_clear1().
long GrainBin::ichrg[NCHS] |
list of indices into pool[], the first nChrg values are in use
Referenced by chrg(), and p_clear1().
realnum GrainBin::IntArea |
integrated grain surface area Int(4pi*a^2), normalized per H, in cm^2/H
realnum GrainBin::IntRadius |
integrated grain radius Int(a), normalized per H, in cm/H
realnum GrainBin::IntVol |
integrated grain volume Int(4/3pi*a^3), normalized per H, in cm^3/H
vector<realnum> GrainBin::inv_att_len |
inverse attenuation length (in cm)
Referenced by p_clear0().
realnum GrainBin::le_thres |
threshold for using X-ray prescription for l_e, in Ryd
Referenced by p_clear1().
bool GrainBin::lgEverQHeat |
was quantum heating used in any zone ?
Referenced by p_clear1().
bool GrainBin::lgIterStart |
are we converging the grain physics for the first time this iteration?
bool GrainBin::lgPAHsInIonizedRegion |
were PAHs present in the ionized region ?
Referenced by p_clear1().
bool GrainBin::lgQHeat |
quantum heating physics is quantum heating turned on ?
Referenced by p_clear1().
bool GrainBin::lgQHTooWide |
is probability distribution too wide to fit in NQGRID array elements ?
Referenced by p_clear1().
bool GrainBin::lgTdustConverged |
is dust temperature converged ?
Referenced by p_clear1().
bool GrainBin::lgUseQHeat |
should quantum heating be used for this zone ?
Referenced by p_clear1().
long GrainBin::LowestZg |
grain charging, photoelectric effect, thermionic emissions
all charge and energy rates will be calculated by resolving the charge distribution into nChrg integral charge states. To implement this, certain parameters have been moved into the ChargeBin structure, currently limiting the maximum number of charge states the code can handle. For details see: >>refer grain physics van Hoof et al., 2001, ASP Conf. Series 247, p. 353 (astroph/0107183) lowest charge a grain can ever have, in e
Referenced by p_clear1().
mat_type GrainBin::matType |
material type, 1 = carbonaceous, 2 = silicate, 3 = PAH, etc...
long GrainBin::nChrg |
number of charge states used for the current zone
Referenced by p_clear1().
long GrainBin::nChrgOrg |
number of charge states at the start of the iteration
Referenced by p_clear1().
df_type GrainBin::nDustFunc |
grain logic has user requested custom grain abundance function ?
Referenced by p_clear1().
long GrainBin::nfill |
remember how far the flex_arr's in the ShellData were filled in
Referenced by p_clear1().
|
private |
pool for storing charge dependent data, includes currently unused bins
Referenced by chrg(), p_clear0(), and p_clear1().
vector<double> GrainBin::pure_sc1 |
scattering cross section per grain species, for default depl
Referenced by p_clear0().
long GrainBin::QHeatFailures |
counter for number of times qheat algorithm failed
Referenced by p_clear1().
long GrainBin::qnflux |
like rfield.nflux, but may point to higher energy, for phiTilde and Phi
Referenced by p_clear1().
long GrainBin::qnflux2 |
like rfield.nflux, only for max electron energy, for phiTilde and Phi
Referenced by p_clear1().
double GrainBin::qtmin |
lowest grain temperature used in calculations, set per zone
Referenced by p_clear1().
double GrainBin::qtmin_zone1 |
lowest grain temperature used in calculations, initial zone
Referenced by p_clear1().
double GrainBin::rate_h2_form_grains_CT02 |
H2 formation rate, Cazaux & Tielens 02, units s^-1, actual depl
Referenced by p_clear1().
double GrainBin::rate_h2_form_grains_ELRD |
H2 formation rate, Rollig et al. 2013 with Eley-Rideal effect,
units s^-1, actual depl
Referenced by p_clear1().
double GrainBin::rate_h2_form_grains_HM79 |
H2 physics - each has units s^-1 H2 formation rate, Hollenbach & McKee 79, units s^-1, actual depl
Referenced by p_clear1().
double GrainBin::rate_h2_form_grains_used |
H2 rate actually used, evaluated in hmole.c, units s^-1, actual depl
when multiplied with hden, this is formation rate in H2-molecules/cm^3/s
Referenced by p_clear1().
double GrainBin::RateDn |
total charging rate down, used for balance check, in e/cm^2/s
Referenced by p_clear1().
double GrainBin::RateUp |
total charging rate up, used for balance check, in e/cm^2/s
Referenced by p_clear1().
double GrainBin::RSFCheck |
grain opacities save resolution scale factor for later check
Referenced by p_clear1().
vector<ShellData> GrainBin::sd |
specific data for each atomic shell in this grain material
Referenced by p_clear0(), and p_clear1().
double GrainBin::StickElecNeg |
sticking efficiency for electrons on negative or neutral grains
Referenced by p_clear1().
double GrainBin::StickElecPos |
sticking efficiency for electrons on positive grains
Referenced by p_clear1().
realnum GrainBin::tedust |
equilibrium temperature for this zone
Referenced by p_clear1().
realnum GrainBin::TeGrainMax |
highest equilibrium temperature as a function of radius
Referenced by p_clear1().
realnum GrainBin::ThermEff |
efficiency of thermionic emission, between 0 and 1
double GrainBin::thermionic |
heating due to thermionic emission
Referenced by p_clear1().
realnum GrainBin::Tsublimat |
sublimation temperature
vector<realnum> GrainBin::y0b06 |
bulk yield for band according to Eq. 9 of WDB06
Referenced by p_clear0().
long GrainBin::ZloSave |
grain charge at the start of the iteration, in e