cloudy  trunk
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Functions | Variables
iter_startend.cpp File Reference
#include "cddefines.h"
#include "cddrive.h"
#include "iso.h"
#include "taulines.h"
#include "hydrogenic.h"
#include "struc.h"
#include "dynamics.h"
#include "prt.h"
#include "hyperfine.h"
#include "magnetic.h"
#include "continuum.h"
#include "geometry.h"
#include "h2.h"
#include "co.h"
#include "he.h"
#include "grains.h"
#include "pressure.h"
#include "stopcalc.h"
#include "conv.h"
#include "mean.h"
#include "thermal.h"
#include "atoms.h"
#include "wind.h"
#include "opacity.h"
#include "timesc.h"
#include "trace.h"
#include "colden.h"
#include "secondaries.h"
#include "hmi.h"
#include "radius.h"
#include "phycon.h"
#include "called.h"
#include "ionbal.h"
#include "atmdat.h"
#include "lines.h"
#include "molcol.h"
#include "input.h"
#include "rt.h"
#include "iterations.h"
#include "cosmology.h"
#include "deuterium.h"
#include "mole.h"
#include "rfield.h"
#include "freebound.h"
#include "two_photon.h"
#include "dense.h"
Include dependency graph for iter_startend.cpp:

Go to the source code of this file.

Functions

void IterStart (void)
 
void IterRestart (void)
 
void IterEnd (void)
 

Variables

static double h2plus_heat_save
 
static double HeatH2Dish_used_save
 
static double HeatH2Dexc_used_save
 
static double hmihet_save
 
static double hmitot_save
 
static double H2_Solomon_dissoc_rate_used_H2g_save
 
static double deriv_HeatH2Dexc_used_save
 
static double H2_Solomon_dissoc_rate_used_H2s_save
 
static double H2_H2g_to_H2s_rate_used_save
 
static double H2_photodissoc_used_H2s_save
 
static double H2_photodissoc_used_H2g_save
 
static double UV_Cont_rel2_Draine_DB96_face
 
static double UV_Cont_rel2_Draine_DB96_depth
 
static double UV_Cont_rel2_Habing_TH85_face
 
static double ** saveMoleSource
 
static double ** saveMoleSink
 
static realnum *** SaveMoleChTrRate
 
static realnum xIonFsave [LIMELM][LIMELM+1]
 
static realnum deutDenseSave0
 
static realnum deutDenseSave1
 
static double HeatSave [LIMELM][LIMELM]
 
static realnum supsav [LIMELM][LIMELM]
 
static realnum p2nit
 
static realnum d5200r
 
static double drSave
 
static double drNextSave
 
static long int IonLowSave [LIMELM]
 
static long int IonHighSave [LIMELM]
 
static bool lgHNSAV = false
 
static double *** HOpacRatSav
 
static double ortho_save
 
static double para_save
 
static double *** hnsav
 
static double edsav
 
static realnum gas_phase_save [LIMELM]
 
static double * den_save
 

Function Documentation

void IterEnd ( void  )
void IterRestart ( void  )

IterRestart, reset values of many variables at start of iteration

Definition at line 734 of file iter_startend.cpp.

References Wind::AccelAver, Wind::AccelMax, Wind::acldr, t_opac::albedo, t_mesh::anu(), ASSERT, atoms, called, t_input::chTitle, CMB_TEMP, t_continuum::cn1216, t_continuum::cn4861, colden, t_colden::colden, t_colden::coldenH2_ov_vel, t_ionbal::CompRecoilHeatRate, t_ionbal::CompRecoilHeatRateSave, t_ionbal::CompRecoilIonRate, t_ionbal::CompRecoilIonRateSave, t_rfield::ConEmitOut, t_rfield::ConEmitReflec, t_rfield::ConInterOut, t_rfield::ConOTS_local_OTS_rate, t_rfield::ConOTS_local_photons, t_rfield::ConRefIncid, t_thermal::ConstTemp, continuum, t_rfield::convoc, cosmology, t_secondaries::csupra, d5200r, t_atoms::d5200r, DEBUG_ENTRY, molezone::den, den_save, dense, t_hmi::deriv_HeatH2Dexc_used, deriv_HeatH2Dexc_used_save, deut, deutDenseSave0, deutDenseSave1, diatoms, t_rfield::DiffuseEscape, t_geometry::DirectionalCosin, t_radius::drad, t_radius::drad_mid_zone, t_radius::drNext, drNextSave, drSave, DynaIterEnd(), dynamics, e2(), t_opac::E2TauAbsFace, t_opac::E2TauAbsOut, t_dense::eden, EdenChange(), t_dense::EdenHCorr, t_dense::EdenHCorr_f, t_dense::EdenTrue, edsav, t_rfield::EnergyBremsThin, t_opac::ExpmTau, t_opac::ExpZone, t_rfield::extin_mag_B_extended, t_rfield::extin_mag_B_point, t_rfield::extin_mag_V_extended, t_rfield::extin_mag_V_point, t_iso_sp::fb, findspecieslocal(), t_rfield::flux, t_rfield::flux_beam_const, t_rfield::flux_beam_const_save, t_rfield::flux_beam_time, t_rfield::flux_isotropic, t_rfield::flux_isotropic_save, t_rfield::flux_time_beam_save, t_rfield::flux_total_incident, fprintf(), t_thermal::FreeFreeTotHeat, gas_phase_save, geometry, t_radius::glbdst, GrainRestartIter(), h2, t_hmi::H2_H2g_to_H2s_rate_used, H2_H2g_to_H2s_rate_used_save, t_hmi::H2_photodissoc_used_H2g, H2_photodissoc_used_H2g_save, t_hmi::H2_photodissoc_used_H2s, H2_photodissoc_used_H2s_save, t_hmi::H2_Solomon_dissoc_rate_used_H2g, H2_Solomon_dissoc_rate_used_H2g_save, t_hmi::H2_Solomon_dissoc_rate_used_H2s, H2_Solomon_dissoc_rate_used_H2s_save, t_hmi::H2_total, t_hmi::H2_total_f, t_hmi::h2plus_heat, h2plus_heat_save, t_hmi::HD_total, t_secondaries::HeatEfficPrimary, t_hmi::HeatH2Dexc_used, HeatH2Dexc_used_save, t_hmi::HeatH2Dish_used, HeatH2Dish_used_save, HeatSave, t_secondaries::hetsav, hmi, t_hmi::hmihet, hmihet_save, t_hmi::hmitot, hmitot_save, hnsav, HOpacRatSav, input, t_pressure::IntegRhoGravity, ionbal, t_dense::IonHigh, IonHighSave, t_dense::IonLow, IonLowSave, ioQQQ, t_rfield::ipEnergyBremsThin, ipH1s, ipH_LIKE, ipHYDROGEN, iso_sp, iteration, lgAbort, t_dynamics::lgAdvection, t_cosmology::lgDo, t_radius::lgDrMinUsed, lgElemsConserved(), t_dense::lgElmtOn, t_trace::lgNeBug, t_pressure::lgPradCap, t_pressure::lgPradDen, t_pressure::lgSonicPoint, t_pressure::lgStrongDLimbo, t_called::lgTalk, t_thermal::lgTemperatureConstant, t_thermal::lgTemperatureConstantCommandParsed, t_dynamics::lgTimeDependentStatic, t_trace::lgTrace, t_trace::lgTrOvrd, t_thermal::lgUnstable, t_rfield::lgUSphON, Wind::lgVelPos, LIMELM, Magnetic_reinit(), MAX2, mole, mole_global, NCOLD, t_rfield::nflux_with_check, NISO, t_trace::npsbug, t_trace::nTrConvg, null_nuclide, t_mole_global::num_calc, t_iso_sp::numLevels_max, t_thermal::nUnstable, t_trace::nznbug, t_rfield::OccNumbContEmitOut, t_rfield::OccNumbDiffCont, t_rfield::OccNumbIncidCont, t_opac::OldOpacSave, opac, t_opac::opacity_abs, t_opac::opacity_abs_savzon1, t_opac::opacity_sct, t_opac::opacity_sct_savzon1, diatomics::ortho_density, diatomics::ortho_density_f, ortho_save, t_rfield::otscon, t_rfield::otslin, t_rfield::otssav, t_rfield::outlin, t_rfield::outlin_noplot, p2nit, t_atoms::p2nit, diatomics::para_density, diatomics::para_density_f, para_save, t_pressure::pbeta, t_pressure::pinzon, t_pressure::PresInteg, t_pressure::PresIntegElecThin, pressure, t_pressure::RadBetaMax, radius, t_cosmology::redshift_current, t_cosmology::redshift_start, t_cosmology::redshift_step, t_rfield::reflin, t_iso_sp::Reset(), t_rfield::resetCoarseTransCoef(), rfield, t_pressure::RhoGravity, t_pressure::RhoGravity_dark, t_pressure::RhoGravity_external, t_pressure::RhoGravity_self, RT_OTS_Update(), t_secondaries::savefi, SaveMoleChTrRate, saveMoleSink, saveMoleSource, t_secondaries::SecIon2PrimaryErg, secondaries, t_dense::SetGasPhaseDensity(), t_thermal::setHeating(), sexp(), t_mole_local::sink, SMALLFLOAT, t_mole_local::source, t_mole_local::species, t_iso_sp::st, t_opac::stimax, StopCalc, t_rfield::SummedCon, t_rfield::SummedDif, t_rfield::SummedDifSave, t_rfield::SummedOcc, supsav, t_continuum::sv1216, t_continuum::sv4861, t_opac::TauAbsFace, t_opac::TauAbsTotal, t_StopCalc::TeFloor, thermal, t_rfield::time_continuum_scale, t_opac::tmn, t_continuum::TotalLumin, t_continuum::totlsv, trace, t_deuterium::updateXMolecules(), t_dense::updateXMolecules(), UV_Cont_rel2_Draine_DB96_depth, t_hmi::UV_Cont_rel2_Draine_DB96_depth, UV_Cont_rel2_Draine_DB96_face, t_hmi::UV_Cont_rel2_Draine_DB96_face, UV_Cont_rel2_Habing_TH85_face, t_hmi::UV_Cont_rel2_Habing_TH85_face, wind, Wind::windv, Wind::windv0, t_secondaries::x12sav, t_secondaries::x12tot, t_deuterium::xIonDense, t_dense::xIonDense, xIonFsave, and t_mole_local::xMoleChTrRate.

Referenced by cloudy().

Here is the call graph for this function:

void IterStart ( void  )

IterStart, set and save values of many variables at start of iteration

Definition at line 89 of file iter_startend.cpp.

References Wind::AccelAver, Wind::acldr, t_colden::ajmmin, ASSERT, atmdat, atoms, EmissionProxy::Aul(), t_timesc::BigCOMoleForm, BIGFLOAT, called, cdEXIT, cdLine(), t_LineSave::chNormLab, t_StopCalc::chReasonStop, t_StopCalc::chStopLabel1, t_StopCalc::chStopLabel2, t_hydro::cintot, co, t_co::codfrc, t_co::codtot, colden, t_colden::colden, t_colden::coldenH2_ov_vel, t_ionbal::CompRecoilHeatRate, t_ionbal::CompRecoilHeatRateSave, t_ionbal::CompRecoilIonRate, t_ionbal::CompRecoilIonRateSave, t_rfield::comtot, t_rfield::ConEmitOut, t_rfield::ConEmitReflec, t_rfield::ConInterOut, t_rfield::ConOTS_local_OTS_rate, t_rfield::ConOTS_local_photons, conv, t_hmi::CoolH2DexcMax, t_thermal::CoolHeatMax, t_hyperfine::cooling_max, t_dynamics::CoolMax, t_secondaries::csupra, t_thermal::ctot, d5200r, t_atoms::d5200r, dBaseSpecies, t_conv::dCmHdT, DEBUG_ENTRY, den_save, dense, t_hmi::deriv_HeatH2Dexc_used, deriv_HeatH2Dexc_used_save, deut, deutDenseSave0, deutDenseSave1, diatoms, t_rfield::DiffuseEscape, t_geometry::DirectionalCosin, t_colden::dlnenCp, t_colden::dlnenHep, t_colden::dlnenHepp, t_colden::dlnenp, t_radius::dr_max_last_iter, t_radius::dr_min_last_iter, t_radius::drad, t_radius::drad_x_fillfac, t_radius::drNext, drNextSave, drSave, DynaIterStart(), dynamics, e2(), t_opac::E2TauAbsFace, t_dense::eden, t_dense::EdenMax, t_dense::EdenMin, edsav, TransitionProxy::Emis(), t_rfield::EnergyBremsThin, EXIT_FAILURE, t_opac::ExpmTau, t_opac::ExpZone, t_rfield::extin_mag_B_extended, t_rfield::extin_mag_B_point, t_rfield::extin_mag_V_extended, t_rfield::extin_mag_V_point, t_conv::failmx, t_iso_sp::fb, t_hydro::fbul, t_LineSave::findline(), fprintf(), t_he::frac_he0dest_23S, t_he::frac_he0dest_23S_photo, t_hydro::FracInd, t_thermal::FreeFreeTotHeat, t_dense::gas_phase, gas_phase_save, t_thermal::GBarMax, geometry, GrainStartIter(), t_colden::H0_21cm_lower, t_colden::H0_21cm_upper, t_colden::H0_ov_Tspin, h2, t_hmi::H2_H2g_to_H2s_rate_used, H2_H2g_to_H2s_rate_used_save, t_hmi::H2_photodissoc_used_H2g, H2_photodissoc_used_H2g_save, t_hmi::H2_photodissoc_used_H2s, H2_photodissoc_used_H2s_save, t_hmi::H2_Solomon_dissoc_rate_used_H2g, H2_Solomon_dissoc_rate_used_H2g_save, t_hmi::H2_Solomon_dissoc_rate_used_H2s, H2_Solomon_dissoc_rate_used_H2s_save, t_hmi::h2dfrc, t_hmi::h2dtot, t_hmi::h2line_cool_frac, t_hmi::h2plus_heat, h2plus_heat_save, t_hmi::h2pmax, t_atmdat::HCharCoolMax, t_atmdat::HCharHeatMax, t_hydro::HCollIonMax, he, t_secondaries::HeatEfficPrimary, t_hmi::HeatH2Dexc_used, HeatH2Dexc_used_save, t_hmi::HeatH2DexcMax, t_hmi::HeatH2Dish_used, HeatH2Dish_used_save, t_thermal::heating(), t_thermal::HeatLineMax, t_dynamics::HeatMax, HeatSave, t_secondaries::hetsav, t_atmdat::HIonFracMax, hmi, t_hmi::hmihet, hmihet_save, t_hmi::hmitot, hmitot_save, hnsav, HOpacRatSav, HS_NZ, hydro, hyperfine, t_ionbal::ifail, t_ionbal::ihthn, t_ionbal::ilt, t_ionbal::ilthn, t_ionbal::iltln, ionbal, t_dense::IonHigh, IonHighSave, t_dense::IonLow, IonLowSave, ioQQQ, t_rfield::ipEnergyBremsThin, ipH2p, ipH_LIKE, ipHYDROGEN, t_LineSave::ipNormWavL, ipRecNetEsc, ipRecRad, t_StopCalc::ipStopLin1, t_StopCalc::ipStopLin2, iso_ctrl, iso_sp, iteration, iterations, t_iterations::itermx, t_iterations::IterPrnt, lgAbort, t_dynamics::lgAdvection, t_opac::lgCaseB, t_dense::lgElmtOn, t_atmdat::lgHCaseBOK, t_hydro::lgHiPop2, lgHNSAV, t_LineSave::lgIsoContSubSignif, t_iterations::lgLastIt, t_rt::lgMaserCapHit, t_rt::lgMaserSetDR, t_LineSave::lgNormSet, t_pressure::lgPradCap, t_pressure::lgPradDen, t_prt::lgPrtLastIt, t_prt::lgPrtStart, t_pressure::lgSonicPoint, t_pressure::lgStrongDLimbo, t_called::lgTalk, t_called::lgTalkForcedOff, t_called::lgTalkSave, t_dynamics::lgTimeDependentStatic, t_trace::lgTrace, t_thermal::lgUnstable, t_geometry::lgZoneTrp, LIMELM, t_LineSave::lines, LineSave, MALLOC, mean, molcol(), mole, mole_global, t_hydro::nbul, t_conv::nChemFail, NCHLAB, NCOLD, t_hydro::ndclev, t_rfield::nflux_with_check, t_conv::nGrainFail, t_conv::nIonFail, NISO, t_hydro::nLyaHot, t_conv::nNeFail, t_conv::nPopFail, t_conv::nPreFail, t_geometry::nprint, nSpecies, t_StopCalc::nstpl, t_LineSave::nsum, t_conv::nTeFail, t_conv::nTotalFailures, t_mole_global::num_calc, t_iso_sp::numLevels_max, t_thermal::nUnstable, t_he::nzone, t_colden::OH_ov_Tspin, opac, t_opac::opacity_abs, t_opac::opacity_abs_savzon1, t_opac::opacity_sct, t_opac::opacity_sct_savzon1, diatomics::ortho_density, ortho_save, t_rfield::otscon, t_rfield::otslin, t_rfield::otssav, t_rfield::outlin, t_rfield::outlin_noplot, p2nit, t_atoms::p2nit, diatomics::para_density, para_save, t_pressure::pbeta, t_dense::pden, phycon, t_pressure::pinzon, t_hydro::pop2mx, t_thermal::power, t_pressure::PresInteg, t_pressure::PresIntegElecThin, pressure, PresTotCurrent(), prt, prt_line_err(), EmissionProxy::pump(), t_rfield::qtot, t_pressure::RadBetaMax, radius, rfield, t_colden::rjnmin, rt, t_secondaries::savefi, SaveMoleChTrRate, saveMoleSink, saveMoleSource, SDIV(), t_secondaries::SecHIonMax, t_secondaries::SecIon2PrimaryErg, secondaries, sexp(), t_mole_local::sink, t_isoCTRL::SmallA, SMALLFLOAT, t_timesc::sound, t_mole_local::source, t_mole_local::species, t_iso_sp::st, StopCalc, t_StopCalc::StopLineWl1, t_StopCalc::StopLineWl2, t_rfield::SummedDif, t_rfield::SummedDifSave, supsav, t_opac::TauAbsFace, t_opac::taumin, t_opac::TauScatFace, t_timesc::tcmptn, t_phycon::te, thermal, t_thermal::thist, t_timesc::time_H2_Dest_here, t_timesc::time_H2_Dest_longest, t_timesc::time_H2_Form_here, t_timesc::time_H2_Form_longest, t_timesc::time_therm_long, t_timesc::TimeH21cm, timesc, t_thermal::tlowst, t_hydro::TLyaMax, t_colden::tmas, t_thermal::totcol, t_colden::TotMassColl, trace, t_iso_sp::trans(), t_iso_sp::TwoNu, UV_Cont_rel2_Draine_DB96_depth, t_hmi::UV_Cont_rel2_Draine_DB96_depth, UV_Cont_rel2_Draine_DB96_face, t_hmi::UV_Cont_rel2_Draine_DB96_face, UV_Cont_rel2_Habing_TH85_face, t_hmi::UV_Cont_rel2_Habing_TH85_face, t_LineSave::WavLNorm, wind, t_colden::wmas, t_secondaries::x12sav, t_secondaries::x12tot, t_deuterium::xIonDense, t_dense::xIonDense, xIonFsave, t_dense::xMassTotal, t_mole_local::xMoleChTrRate, and t_mean::zero().

Referenced by cloudy().

Here is the call graph for this function:

Variable Documentation

realnum d5200r
static

Definition at line 67 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double* den_save
static

Definition at line 86 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double deriv_HeatH2Dexc_used_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

realnum deutDenseSave0
static

Definition at line 65 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

realnum deutDenseSave1
static

Definition at line 65 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double drNextSave
static

Definition at line 69 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double drSave
static

Definition at line 69 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double edsav
static

Definition at line 82 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

realnum gas_phase_save[LIMELM]
static

Definition at line 85 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double H2_H2g_to_H2s_rate_used_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double H2_photodissoc_used_H2g_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double H2_photodissoc_used_H2s_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double H2_Solomon_dissoc_rate_used_H2g_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double H2_Solomon_dissoc_rate_used_H2s_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double h2plus_heat_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double HeatH2Dexc_used_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double HeatH2Dish_used_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double HeatSave[LIMELM][LIMELM]
static

Definition at line 66 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double hmihet_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double hmitot_save
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double*** hnsav
static

Definition at line 82 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double*** HOpacRatSav
static

Definition at line 79 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

long int IonHighSave[LIMELM]
static

Definition at line 72 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

long int IonLowSave[LIMELM]
static

Definition at line 72 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

bool lgHNSAV = false
static

Definition at line 77 of file iter_startend.cpp.

Referenced by IterStart().

double ortho_save
static

Definition at line 81 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

realnum p2nit
static

Definition at line 67 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double para_save
static

Definition at line 81 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

realnum*** SaveMoleChTrRate
static

Definition at line 61 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double ** saveMoleSink
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double ** saveMoleSource
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

realnum supsav[LIMELM][LIMELM]
static

Definition at line 67 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double UV_Cont_rel2_Draine_DB96_depth
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double UV_Cont_rel2_Draine_DB96_face
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

double UV_Cont_rel2_Habing_TH85_face
static

Definition at line 54 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().

realnum xIonFsave[LIMELM][LIMELM+1]
static

Definition at line 64 of file iter_startend.cpp.

Referenced by IterRestart(), and IterStart().