/home66/gary/public_html/cloudy/c08_branch/source/mole_co_etc.cpp File Reference

#include "cddefines.h"
#include "physconst.h"
#include "mole.h"
#include "mole_co_priv.h"
#include "hmi.h"
#include "rfield.h"
#include "dense.h"
#include "ionbal.h"
#include "grainvar.h"
#include "timesc.h"
#include <string.h>
#include <ctype.h>

Include dependency graph for mole_co_etc.cpp:

Go to the source code of this file.

Enumerations

enum  spectype { MOLECULE, OTHER }
enum  molstate { ACTIVE, PASSIVE }

Functions

STATIC void newelement (const char label[], int ipion, int priority)
STATIC struct moleculenewspecies (const char label[7], enum spectype type, enum molstate state, realnum *location, double frac0)
STATIC struct chem_element_sfindelement (const char buf[])
STATIC int isactive (data_u *dat)
STATIC int ispassive (data_u *dat)
STATIC int isCOnet (data_u *dat)
void CO_Init (void)
moleculefindspecies (const char buf[])
COmole_rate_sCO_findrate_s (const char buf[])
double CO_findrk (const char buf[])
double CO_findrate (const char buf[])
void CO_update_species_cache (void)
double CO_sink_rate (const char chSpecies[7])
void CO_update_rks (void)
double CO_dissoc_rate (const char chSpecies[7])
double CO_source_rate (const char chSpecies[7])
void CO_punch_mol (FILE *punit, const char chSpecies[], char header[], double depth)
void CO_zero (void)

Variables

chem_element_s ** chem_element
chem_element_selement_list [LIMELM]
int32 * ipiv
realnumtot_ion
mole_priv_s mole_priv
molecule null_mole


Enumeration Type Documentation

enum molstate

Enumerator:
ACTIVE 
PASSIVE 

Definition at line 21 of file mole_co_etc.cpp.

enum spectype

Enumerator:
MOLECULE 
OTHER 

Definition at line 20 of file mole_co_etc.cpp.


Function Documentation

double CO_dissoc_rate ( const char  chSpecies[7]  ) 

Definition at line 670 of file mole_co_etc.cpp.

References coreactions, DEBUG_ENTRY, findspecies(), t_coreactions::list, t_coreactions::n, COmole_rate_s::photon, and COmole_rate_s::products.

Here is the call graph for this function:

double CO_findrate ( const char  buf[]  ) 

Definition at line 552 of file mole_co_etc.cpp.

References CO_findrate_s(), DEBUG_ENTRY, molecule::hevmol, COmole_rate_s::nrates, COmole_rate_s::rate_species, and COmole_rate_s::rk.

Referenced by CoolOxyg(), and lines_lv1_li_ne().

Here is the call graph for this function:

struct COmole_rate_s* CO_findrate_s ( const char  buf[]  ) 

Definition at line 523 of file mole_co_etc.cpp.

References DEBUG_ENTRY, lookup(), mole_priv, data_u::p, and mole_priv_s::reactab.

Referenced by CO_drive(), CO_findrate(), and CO_findrk().

Here is the call graph for this function:

double CO_findrk ( const char  buf[]  ) 

Definition at line 536 of file mole_co_etc.cpp.

References ASSERT, CO_findrate_s(), DEBUG_ENTRY, isnan, and COmole_rate_s::rk.

Referenced by IonIron(), and IonMagne().

Here is the call graph for this function:

void CO_Init ( void   ) 

called from cdInit to initialized co routines

Definition at line 44 of file mole_co_etc.cpp.

References molecule::active, ACTIVE, ASSERT, co, t_co::co_nzone, COmole, DEBUG_ENTRY, dense, t_dense::eden_f, ELECTRON_MASS, element_list, mole_priv_s::elemtab, gv, molecule::hevcol, molecule::hevmol, hmi, t_hmi::Hmolec, molecule::index, ipCARBON, ipCHLORINE, ipHELIUM, ipHYDROGEN, ipIRON, ipMAGNESIUM, ipMH2g, ipMH2p, ipMH2s, ipMH3p, ipMHm, ipNITROGEN, ipOXYGEN, ipSILICON, ipSULPHUR, isactive(), ispassive(), t_co::iteration_co, t_gv::lgDustOn, t_mole::lgElem_in_chemistry, t_mole::lgGrain_mole_deplete, LIMELM, makeplist(), MALLOC, mole, molecule::mole_mass, mole_priv, MOLECULE, molecule::n_nuclei, molecule::nElec, molecule::nelem_hevmol, newelement(), newhash(), newspecies(), null_mole, t_mole::num_comole_calc, t_mole::num_comole_tot, t_mole::num_elements, OTHER, PASSIVE, mole_priv_s::reactab, mole_priv_s::spectab, and t_dense::xIonDense.

Referenced by InitSimPostparse().

Here is the call graph for this function:

void CO_punch_mol ( FILE *  punit,
const char  chSpecies[],
char  header[],
double  depth 
)

Definition at line 748 of file mole_co_etc.cpp.

References coreactions, DEBUG_ENTRY, findspecies(), t_coreactions::list, t_coreactions::n, and COmole_rate_s::rate_species.

Here is the call graph for this function:

double CO_sink_rate ( const char  chSpecies[7]  ) 

Definition at line 595 of file mole_co_etc.cpp.

References coreactions, DEBUG_ENTRY, findspecies(), t_coreactions::list, t_coreactions::n, and COmole_rate_s::rate_species.

Here is the call graph for this function:

double CO_source_rate ( const char  chSpecies[7]  ) 

Definition at line 710 of file mole_co_etc.cpp.

References coreactions, DEBUG_ENTRY, findspecies(), t_coreactions::list, t_coreactions::n, and COmole_rate_s::products.

Here is the call graph for this function:

void CO_update_rks ( void   ) 

CO_update_rks update rate coefficients, only temp part

Definition at line 652 of file mole_co_etc.cpp.

References COmole_rate_s::a, coreactions, DEBUG_ENTRY, COmole_rate_s::fun, t_coreactions::list, t_coreactions::n, and COmole_rate_s::rk.

void CO_update_species_cache ( void   ) 

Definition at line 572 of file mole_co_etc.cpp.

References ASSERT, COmole, DEBUG_ENTRY, dense, t_dense::eden, t_dense::eden_f, molecule::hevmol, isnan, molecule::location, mole, and t_mole::num_comole_tot.

void CO_zero ( void   ) 

CO_zero allocate + initialize workspace

Definition at line 817 of file mole_co_etc.cpp.

References t_timesc::AgeCOMoleDest, cdEXIT, COmole, DEBUG_ENTRY, molecule::hevcol, molecule::hevmol, ioQQQ, lgFirstCall, MALLOC, mole, t_mole::num_comole_calc, t_mole::num_comole_tot, timesc, and molecule::xMoleFracMax.

Referenced by InitSimPostparse().

STATIC struct chem_element_s * findelement ( const char  buf[]  ) 

Definition at line 509 of file mole_co_etc.cpp.

References DEBUG_ENTRY, mole_priv_s::elemtab, lookup(), mole_priv, and data_u::p.

Referenced by newspecies().

Here is the call graph for this function:

struct molecule* findspecies ( const char  buf[]  ) 

Definition at line 495 of file mole_co_etc.cpp.

References DEBUG_ENTRY, lookup(), mole_priv, null_mole, data_u::p, and mole_priv_s::spectab.

Referenced by AgeCheck(), atmol_popsolve(), cdColm(), CO_dissoc_rate(), CO_punch_mol(), CO_sink_rate(), CO_source_rate(), DynaPunchTimeDep(), and newreact().

Here is the call graph for this function:

STATIC int isactive ( data_u dat  ) 

Definition at line 477 of file mole_co_etc.cpp.

References molecule::active, DEBUG_ENTRY, and data_u::p.

Referenced by CO_Init().

STATIC int isCOnet ( data_u dat  ) 

Definition at line 490 of file mole_co_etc.cpp.

References data_u::p.

STATIC int ispassive ( data_u dat  ) 

Definition at line 486 of file mole_co_etc.cpp.

References data_u::p.

Referenced by CO_Init().

STATIC void newelement ( const char  label[],
int  ipion,
int  priority 
)

Definition at line 299 of file mole_co_etc.cpp.

References addentry(), ASSERT, chem_element_s::chName, DEBUG_ENTRY, element_list, mole_priv_s::elemtab, chem_element_s::ipCl, chem_element_s::ipMl, chem_element_s::ipMlP, chem_element_s::ipZ, MALLOC, mole_priv, and data_u::p.

Referenced by CO_Init().

Here is the call graph for this function:

STATIC struct molecule * newspecies ( const char  label[7],
enum spectype  type,
enum molstate  state,
realnum location,
double  frac0 
)

Definition at line 320 of file mole_co_etc.cpp.

References molecule::active, ACTIVE, addentry(), ASSERT, ATOMIC_MASS_UNIT, t_dense::AtomicWeight, cdEXIT, molecule::co_save, DEBUG_ENTRY, dense, molecule::Excit, findelement(), chem_element_s::ipCl, ipHYDROGEN, chem_element_s::ipZ, molecule::label, t_mole::lgElem_in_chemistry, molecule::lgGas_Phase, LIMELM, molecule::location, MALLOC, mole, molecule::mole_mass, mole_priv, MOLECULE, molecule::n_nuclei, molecule::nElec, molecule::nElem, molecule::nelem_hevmol, t_mole::num_comole_calc, t_mole::num_comole_tot, t_mole::num_elements, data_u::p, molecule::pdr_mole_co, and mole_priv_s::spectab.

Referenced by CO_Init().

Here is the call graph for this function:


Variable Documentation

struct chem_element_s** chem_element

Definition at line 32 of file mole_co_etc.cpp.

Referenced by lgMolecAver().

struct chem_element_s* element_list[LIMELM]

Definition at line 35 of file mole_co_etc.cpp.

Referenced by CO_Init(), and newelement().

int32* ipiv

Definition at line 36 of file mole_co_etc.cpp.

Referenced by atom_levelN(), atom_pop5(), AtomSeqBeryllium(), FeIILevelPops(), hmole_step(), ion_solver(), iso_level(), oi_level_pops(), and SanityCheckBegin().

struct mole_priv_s mole_priv

Definition at line 39 of file mole_co_etc.cpp.

Referenced by CO_create_react(), CO_findrate_s(), CO_Init(), findelement(), findspecies(), newelement(), newreact(), and newspecies().

struct molecule null_mole

this includes the atomic and first ionized species of each element that can combine to form molecules. This is the number of molecules, ions, and atoms that the co network uses This is used in comole to improve the calculation, as deep in molecular regions reactions with molecules can be important to the ionization balance

Definition at line 40 of file mole_co_etc.cpp.

Referenced by atmol_popsolve(), CO_Init(), findspecies(), and newreact().

realnum* tot_ion

Definition at line 37 of file mole_co_etc.cpp.


Generated on Mon Feb 16 12:09:15 2009 for cloudy by  doxygen 1.4.7