Cloudy
Spectral Synthesis Code for Astrophysics
|
Go to the source code of this file.
Classes | |
class | chem_element |
class | chem_nuclide |
class | element_pointer_value_less |
class | molecule |
class | t_mole_global |
class | molezone |
class | t_mole_local |
Typedefs | |
typedef map< int, shared_ptr < chem_nuclide > >::iterator | isotopes_i |
typedef vector< shared_ptr < chem_nuclide > > | ChemNuclideList |
typedef vector< shared_ptr < chem_element > > | ChemElementList |
typedef molecule::nNucsMap::iterator | nNucs_i |
typedef molecule::nNucsMap::reverse_iterator | nNucs_ri |
typedef molecule::nNucsMap::const_reverse_iterator | nNucs_cri |
Enumerations | |
enum | mole_state { MOLE_NULL, MOLE_PASSIVE, MOLE_ACTIVE } |
Functions | |
bool | operator< (const chem_nuclide &a, const chem_nuclide &b) |
bool | operator> (const chem_nuclide &a, const chem_nuclide &b) |
bool | operator<= (const chem_nuclide &a, const chem_nuclide &b) |
bool | operator>= (const chem_nuclide &a, const chem_nuclide &b) |
bool | operator== (const chem_nuclide &a, const chem_nuclide &b) |
bool | operator!= (const chem_nuclide &a, const chem_nuclide &b) |
void | mole_drive (void) |
void | mole_create_react (void) |
mole_reaction * | mole_findrate_s (const char buf[]) |
bool | exists (const molecule *m) |
molecule * | findspecies (const char buf[]) |
molecule * | findspecies_validate (const char buf[]) |
molezone * | findspecieslocal (const char buf[]) |
molezone * | findspecieslocal_validate (const char buf[]) |
shared_ptr< chem_nuclide > | findnuclide (const char buf[]) |
bool | exists (const molezone *m) |
void | total_molecule_elems (realnum total[LIMELM]) |
void | total_molecule_deut (realnum &total) |
realnum | total_molecules (void) |
realnum | total_molecules_gasphase (void) |
realnum | species_gasphase_density (const string &chSpecies) |
void | mole_make_list (void) |
void | mole_make_groups (void) |
void | mole_cmp_num_in_out_reactions (void) |
bool | lgDifferByExcitation (const molecule &mol1, const molecule &mol2) |
void | mole_update_species_cache (void) |
void | mole_update_sources (void) |
void | mole_rk_bigchange (void) |
void | create_isotopologues (ChemNuclideList &atoms, vector< int > &numAtoms, string atom_old, string atom_new, string embellishments, vector< string > &newLabels) |
void | create_isotopologues_one_position (unsigned position, ChemNuclideList &atoms, vector< int > &numAtoms, string atom_old, string atom_new, string embellishments, string &newLabel) |
bool | parse_species_label (const char label[], ChemNuclideList &atomsLeftToRight, vector< int > &numAtoms, string &embellishments) |
bool | parse_species_label (const char mylab[], ChemNuclideList &atomsLeftToRight, vector< int > &numAtoms, string &embellishments, bool &lgExcit, int &charge, bool &lgGas_Phase) |
double | hmrate4 (double a, double b, double c, double te) |
void | ParseChemistry (Parser &p) |
bool | isSpecies (const string &chSpecies) |
bool | isMolecule (const string &chSpecies) |
void | test_isMolecule () |
void | getMolecules (vector< string > &allMolecules) |
Variables | |
static const double | SMALLABUND = 1e-24 |
ChemNuclideList | nuclide_list |
ChemElementList | element_list |
chem_nuclide * | null_nuclide |
molecule * | null_mole |
t_mole_global | mole_global |
molezone * | null_molezone |
t_mole_local | mole |
typedef vector< shared_ptr<chem_element> > ChemElementList |
typedef vector< shared_ptr<chem_nuclide> > ChemNuclideList |
typedef map<int, shared_ptr<chem_nuclide> >::iterator isotopes_i |
typedef molecule::nNucsMap::const_reverse_iterator nNucs_cri |
typedef molecule::nNucsMap::iterator nNucs_i |
typedef molecule::nNucsMap::reverse_iterator nNucs_ri |
enum mole_state |
void create_isotopologues | ( | ChemNuclideList & | atoms, |
vector< int > & | numAtoms, | ||
string | atom_old, | ||
string | atom_new, | ||
string | embellishments, | ||
vector< string > & | newLabels | ||
) |
References create_isotopologues_one_position(), DEBUG_ENTRY, and fixit.
Referenced by mole_generate_isotopologue_reactions(), and newspecies().
void create_isotopologues_one_position | ( | unsigned | position, |
ChemNuclideList & | atoms, | ||
vector< int > & | numAtoms, | ||
string | atom_old, | ||
string | atom_new, | ||
string | embellishments, | ||
string & | newLabel | ||
) |
References ASSERT, and DEBUG_ENTRY.
Referenced by create_isotopologues(), and mole_generate_isotopologue_reactions().
|
inline |
References null_mole.
Referenced by dBaseAbund(), mole_check_reverse_reactions(), newelement(), newreact(), and newspecies().
|
inline |
References null_molezone.
shared_ptr<chem_nuclide> findnuclide | ( | const char | buf[] | ) |
References DEBUG_ENTRY, nuclide_list, nuclidetab, and NULL.
Referenced by mole_effects(), mole_generate_isotopologue_reactions(), mole_h_rate_diagnostics(), parse_species_label(), and PrtZone().
molecule* findspecies | ( | const char | buf[] | ) |
version for species we know are valid, but may not be present in calculation
References DEBUG_ENTRY, null_mole, and mole_priv::spectab.
Referenced by t_mole_local::chem_heat(), ConvBase(), CoolHeatError(), database_readin(), t_mole_local::dissoc_rate(), findspecieslocal(), diatomics::init(), isMolecule(), iso_allocate(), isSpecies(), lgElemsConserved(), lgNetEdenSrcSmall(), t_mole_global::make_species(), mole_make_list(), mole_save(), parse_reaction(), parse_udfa(), prt_smooth_predictions(), radius_increment(), SaveDo(), t_mole_local::sink_rate_tot(), t_mole_local::source_rate_tot(), species_gasphase_density(), and states_nelemfill().
molecule* findspecies_validate | ( | const char | buf[] | ) |
version for user-supplied species which may not be valid
References cdEXIT, DEBUG_ENTRY, EXIT_FAILURE, fprintf(), ioQQQ, and mole_priv::spectab.
Referenced by findspecieslocal_validate().
molezone* findspecieslocal | ( | const char | buf[] | ) |
version for species we know are valid, but may not be present in calculation
References DEBUG_ENTRY, findspecies(), molecule::index, mole, null_molezone, and t_mole_local::species.
Referenced by AgeCheck(), t_gaunt::brems_sum_ions(), cdColm(), check_co_ion_converge(), ConvBase(), CoolEvaluate(), dBaseAbund(), DynaPunchTimeDep(), getLevelsGeneric(), GrainCollHeating(), diatomics::H2_PunchDo(), diatomics::H2_X_coll_rate_evaluate(), HeatSum(), InitSimPostparse(), IonHydro(), iso_level(), iter_end_check(), IterRestart(), lines_molecules(), mole_effects(), diatomics::mole_H2_form(), mole_h_fixup(), mole_h_rate_diagnostics(), mole_h_reactions(), OpacityAddTotal(), PrtAllTau(), PrtComment(), PrtZone(), radius_increment(), radius_next(), RT_continuum(), RT_OTS(), RT_tau_inc(), SaveDo(), SaveLineData(), SecIoniz(), t_mole_local::set_ion_locations(), and ShowMe().
molezone* findspecieslocal_validate | ( | const char | buf[] | ) |
version for user-supplied species which may not be valid
References DEBUG_ENTRY, findspecies_validate(), molecule::index, mole, and t_mole_local::species.
Referenced by iter_end_check(), radius_first(), and radius_next().
void getMolecules | ( | vector< string > & | allMolecules | ) |
getMolecules - Get a list of all active molecules.
allMolecules | [in,out] List of molecule strings. |
References DEBUG_ENTRY, isMolecule(), t_mole_global::list, and mole_global.
Referenced by t_mean::setup_molecules(), and test_cdTemp_molecules().
|
inline |
References min(), pow(), and sexp().
Referenced by ChargTranEval(), and ion_photo().
bool isMolecule | ( | const string & | chSpecies | ) |
isMolecule - Tell if the input string corresponds to a valid & active molecule.
chSpecies | [in] Species string |
References DEBUG_ENTRY, findspecies(), molecule::isMolecule(), and molecule::label.
Referenced by cdTemp(), getMolecules(), and test_isMolecule().
bool isSpecies | ( | const string & | chSpecies | ) |
isSpecies - Tell if the input string corresponds to a valid & active species.
chSpecies | [in] Species string |
References DEBUG_ENTRY, findspecies(), molecule::isMolecule(), molecule::isMonatomic(), and molecule::label.
Referenced by cdTemp().
References molecule::label.
Referenced by register_reaction_vectors().
void mole_cmp_num_in_out_reactions | ( | void | ) |
References CHARS_SPECIES, DEBUG_ENTRY, fprintf(), ioQQQ, t_mole_global::list, mole_global, t_mole_global::num_total, and mole_priv::reactab.
void mole_create_react | ( | void | ) |
mole_create_react build reaction structures
References canonicalize_reaction_label(), cdEXIT, DEBUG_ENTRY, dense, deut, EXIT_FAILURE, fixit, fprintf(), hmi, ipHELIUM, t_deuterium::lgElmtOn, t_dense::lgElmtOn, t_mole_global::lgFederman, t_hmi::lgLeiden_Keep_ipMH2s, t_mole_global::lgLeidenHack, t_mole_global::lgProtElim, mole, mole_check_reverse_reactions(), mole_generate_isotopologue_reactions(), mole_global, newreact(), nuclide_list, t_mole_global::offReactions, t_mole_local::old_zone, parse_base(), parse_udfa(), plot_sparsity(), pow(), mole_priv::reactab, t_mole_local::reaction_rks, read_data(), register_reaction_vectors(), and UDFA.
Referenced by InitSimPostparse().
void mole_drive | ( | void | ) |
mole_drive main driver for chemical equilibrium routines
References DEBUG_ENTRY, mole_effects(), mole_ion_trim(), mole_solve(), mole_update_limiting_reactants(), mole_update_rks(), mole_update_species_cache(), and MOLETOLER.
Referenced by ConvBase().
mole_reaction* mole_findrate_s | ( | const char | buf[] | ) |
References canonicalize_reaction_label(), DEBUG_ENTRY, NULL, and mole_priv::reactab.
Referenced by t_mole_local::findrate(), t_mole_local::findrk(), mole_get_equilibrium_condition(), and t_mole_local::sink_rate().
void mole_make_groups | ( | void | ) |
References ASSERT, DEBUG_ENTRY, groupspecies, LIMELM, t_mole_global::list, mole_global, t_mole_global::num_calc, and t_mole_global::num_compacted.
Referenced by t_mole_global::init().
void mole_make_list | ( | void | ) |
References ASSERT, molecule::charge, DEBUG_ENTRY, findspecies(), isactive(), molecule::isMonatomic(), ispassive(), molecule::lgGas_Phase, t_mole_global::list, mole_global, molecule::nNuclide, t_mole_global::num_calc, t_mole_global::num_total, t_mole_global::sort(), and mole_priv::spectab.
Referenced by t_mole_global::init().
void mole_rk_bigchange | ( | void | ) |
References ASSERT, DEBUG_ENTRY, fprintf(), mole_reaction::index, ioQQQ, mole_reaction::label, mole, nzone, t_mole_local::old_reaction_rks, t_mole_local::old_zone, mole_priv::reactab, and t_mole_local::reaction_rks.
Referenced by ZoneEnd().
void mole_update_sources | ( | void | ) |
References DEBUG_ENTRY, mole_eval_sources(), mole_global, mole_update_species_cache(), and t_mole_global::num_total.
Referenced by ConvBase().
void mole_update_species_cache | ( | void | ) |
References ASSERT, GrainVar::bin, DEBUG_ENTRY, fprintf(), t_mole_local::grain_area, t_mole_local::grain_density, t_mole_local::grain_saturation, gv, ioQQQ, GrainVar::lgDustOn(), t_mole_global::list, mole, mole_global, NULL, t_mole_global::num_total, t_mole_local::set_isotope_abundances(), and t_mole_local::species.
Referenced by diatomics::H2_LevelPops(), mole_drive(), and mole_update_sources().
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
bool parse_species_label | ( | const char | label[], |
ChemNuclideList & | atomsLeftToRight, | ||
vector< int > & | numAtoms, | ||
string & | embellishments | ||
) |
Referenced by mole_generate_isotopologue_reactions(), and newspecies().
bool parse_species_label | ( | const char | mylab[], |
ChemNuclideList & | atomsLeftToRight, | ||
vector< int > & | numAtoms, | ||
string & | embellishments, | ||
bool & | lgExcit, | ||
int & | charge, | ||
bool & | lgGas_Phase | ||
) |
References ASSERT, CHARS_ISOTOPE_SYM, dense, findnuclide(), fprintf(), ioQQQ, t_dense::lgElmtOn, t_trace::lgTraceMole, NULL, and trace.
void ParseChemistry | ( | Parser & | p | ) |
References cdEXIT, DEBUG_ENTRY, Symbol::EOSTAT, Symbol::ERROR, EXIT_FAILURE, fprintf(), Parser::getSymbol(), ioQQQ, Symbol::NAME, t_mole_global::offReactions, Symbol::OPERATOR, Symbol::STRING, Symbol::toktype, and Symbol::value.
Referenced by ParseCommands().
realnum species_gasphase_density | ( | const string & | chSpecies | ) |
species_gasphase_density - Report gas phase density of requested species
chSpecies | [in] species to process |
References DEBUG_ENTRY, findspecies(), molecule::index, mole, and t_mole_local::species.
Referenced by t_mean::MeanInc().
void test_isMolecule | ( | ) |
test_isMolecule() - Test function isMolecule()
References cdEXIT, DEBUG_ENTRY, EXIT_SUCCESS, fprintf(), ioQQQ, isMolecule(), t_mole_global::list, and mole_global.
void total_molecule_deut | ( | realnum & | total | ) |
References DEBUG_ENTRY, deut, t_deuterium::lgElmtOn, t_mole_global::list, mole, mole_global, NULL, t_mole_global::num_calc, and t_mole_local::species.
Referenced by t_deuterium::updateXMolecules().
void total_molecule_elems | ( | realnum | total[LIMELM] | ) |
References ASSERT, DEBUG_ENTRY, ipHYDROGEN, LIMELM, t_mole_global::list, mole, mole_global, NULL, t_mole_global::num_calc, and t_mole_local::species.
Referenced by t_dense::updateXMolecules().
realnum total_molecules | ( | void | ) |
References DEBUG_ENTRY, t_mole_global::list, mole, mole_global, NULL, t_mole_global::num_calc, and t_mole_local::species.
realnum total_molecules_gasphase | ( | void | ) |
References DEBUG_ENTRY, t_mole_global::list, mole, mole_global, NULL, t_mole_global::num_calc, and t_mole_local::species.
Referenced by SumDensities().
ChemElementList element_list |
Referenced by t_mole_global::make_species(), newelement(), and SetIsotopeFractions().
t_mole_local mole |
Referenced by AbundChange(), t_gaunt::brems_sum_ions(), ChemImportance(), ConvBase(), ConvIterCheck(), CoolEvaluate(), DynaStartZone(), eden_sum(), ElectronFractions(), fill_array(), fill_ext_src_and_snk(), find_solution(), findspecieslocal(), findspecieslocal_validate(), funjac(), diatomics::H2_LevelPops(), diatomics::H2_PunchDo(), diatomics::H2_X_sink_and_source(), HomogeneousSource(), diatomics::init(), InitSimPostparse(), iso_allocate(), iso_level(), isSpeciesActive(), iter_end_check(), IterRestart(), IterStart(), lgNetEdenSrcSmall(), lgNucleiConserved(), lines(), lines_molecules(), matchGeneric(), t_mean::MeanMoleculeTemp(), molcol(), mole_create_react(), mole_dominant_rates(), mole_effects(), mole_eval_balance(), mole_eval_dynamic_balance(), mole_eval_sources(), diatomics::mole_H2_form(), mole_h_fixup(), mole_h_rate_diagnostics(), mole_print_species_reactions(), mole_return_cached_species(), mole_rk_bigchange(), mole_save(), mole_solve(), mole_update_limiting_reactants(), mole_update_rks(), mole_update_species_cache(), PrintRates(), PrtComment(), PrtZone(), radius_increment(), radius_next(), RT_tau_reset(), SaveDo(), SaveSpecies(), ScaleAllDensities(), GroupMap::setup(), species_gasphase_density(), states_nelemfill(), total_molecule_deut(), total_molecule_elems(), total_molecules(), total_molecules_gasphase(), GroupMap::updateMolecules(), and zero().
t_mole_global mole_global |
Referenced by AbundChange(), atmdat_readin(), t_gaunt::brems_sum_ions(), ChargTranEval(), ChemImportance(), diatomics::Cont_Diss_Heat_Rate(), ConvBase(), ConvInitSolution(), ConvIterCheck(), CoolEvaluate(), DynaCreateArrays(), DynaIonize(), DynaNewStep(), DynaSaveLast(), DynaStartZone(), eden_sum(), ElectronFractions(), funjac(), getMolecules(), grouped_elems(), diatomics::H2_X_sink_and_source(), diatomics::init(), init_struc(), InitSimPostparse(), ion_photo(), ion_trim(), ion_trim2(), isSpeciesActive(), iter_end_check(), IterRestart(), IterStart(), lgNucleiConserved(), t_mole_global::make_species(), matchGeneric(), diatomics::Mol_Photo_Diss_Rates(), molcol(), mole_cmp_num_in_out_reactions(), mole_create_react(), mole_effects(), mole_eval_balance(), mole_eval_dynamic_balance(), mole_h_fixup(), mole_h_rate_diagnostics(), mole_h_reactions(), mole_make_groups(), mole_make_list(), mole_return_cached_species(), mole_solve(), mole_update_limiting_reactants(), mole_update_sources(), mole_update_species_cache(), newreact(), newspecies(), OpacityAddTotal(), OpacityCreateAll(), ParseCommands(), ParseDont(), ParseElement(), ParseSet(), ParseSpecies(), plot_sparsity(), PrtComment(), PrtZone(), radius_increment(), radius_next(), RT_tau_reset(), SaveDo(), SaveSpecies(), ScaleAllDensities(), t_mole_local::set_ion_locations(), setProperties(), GroupMap::setup(), speciesCheck(), speciesOff(), test_isMolecule(), total_molecule_deut(), total_molecule_elems(), total_molecules(), total_molecules_gasphase(), and GroupMap::updateMolecules().
ChemNuclideList nuclide_list |
Referenced by findnuclide(), funjac(), grouped_elems(), lgElemsConserved(), lgNucleiConserved(), t_mole_global::make_species(), mole_create_react(), mole_eval_sources(), mole_h_rate_diagnostics(), mole_ion_trim(), mole_solve(), newisotope(), t_mole_local::set_ion_locations(), t_mole_local::set_isotope_abundances(), GroupMap::setup(), and GroupMap::updateMolecules().
molecule* null_mole |
molezone* null_molezone |
chem_nuclide* null_nuclide |
Referenced by molecule::heavyAtom(), IterRestart(), molcol(), mole_update_limiting_reactants(), and molezone::zero().
|
static |