Go to the source code of this file.
Data Structures | |
struct | t_save |
Functions | |
void | SaveDo (const char *chTime) |
void | Save1Line (transition *t, FILE *io, realnum xLimit, long index, realnum DopplerWidth) |
NORETURN void | SaveLineData (FILE *io) |
void | save_opacity (FILE *io, long int np) |
void | SaveSpecial (FILE *io, const char *chTime) |
void | Save1LineData (transition *t, FILE *io, bool lgCS_2) |
void | save_line (FILE *ip, const char *chDo, bool lgEmergent) |
void | save_average (long int ipPun) |
void | save_colden (FILE *ioPUN) |
void | Save_Line_RT (FILE *ip) |
void | saveFITSfile (FILE *io, int option) |
void | SaveHeat (FILE *io) |
void | CoolSave (FILE *io) |
Variables | |
static const long | LIMPUN = 100L |
static const long | MAX_HEADER_SIZE = 20000L |
static const long | VERSION_TRNCON = 20100901L |
EXTERN struct t_save | save |
void CoolSave | ( | FILE * | io | ) |
CoolSave save coolants, called by punch_do
io |
Definition at line 16 of file cool_save.cpp.
References CALLOC, t_thermal::chClntLab, t_thermal::collam, conv, t_dynamics::Cool(), t_thermal::cooling, t_thermal::ctot, DEBUG_ENTRY, t_radius::depth_mid_zone, dynamics, t_dynamics::Heat(), t_thermal::heatnt, t_thermal::htot, IPRINT, t_conv::lgConvEden, t_conv::lgConvIoniz, t_conv::lgConvPres, t_conv::lgConvTemp, MAX2, MIN2, t_thermal::ncltot, phycon, radius, save, SDIV(), sign(), spsort(), t_phycon::te, thermal, and t_save::WeakHeatCool.
Referenced by ConvInitSolution(), and SaveDo().
void Save1Line | ( | transition * | t, | |
FILE * | io, | |||
realnum | xLimit, | |||
long | index, | |||
realnum | DopplerWidth | |||
) |
save one line, called by SaveLineStuff
t | ||
io | ||
xLimit | ||
index | ||
DopplerWidth |
Definition at line 3847 of file save_do.cpp.
References AnuUnit(), t_save::chConPunEnr, t_elementnames::chElementSym, t_elementnames::chIonStage, chLineLbl(), t_emission::dampXvel, elementnames, transition::Emis, transition::EnergyWN, t_quantumState::g, t_emission::gf, transition::Hi, t_quantumState::IonStg, t_save::ipConPun, lgPopsFirstCall, lgSaveOpticalDepths, transition::Lo, t_quantumState::nelem, t_quantumState::Pop, prt_wl(), save, t_emission::TauIn, WAVNRYD, and transition::WLAng.
Referenced by FeIIPunchLineStuff(), H2_PunchLineStuff(), and SaveLineStuff().
void Save1LineData | ( | transition * | t, | |
FILE * | io, | |||
bool | lgCS_2 | |||
) |
Save1LineData data for save one line
t | ||
io | ||
lgCS_2 | this flag says whether collision strength should be punched - should be false for multi level atoms since sums are not done properly |
Definition at line 282 of file save_linedata.cpp.
References t_emission::Aul, chIonLbl(), t_collision::col_str, transition::Coll, COLL_CONST, DEBUG_ENTRY, transition::Emis, t_quantumState::g, t_emission::gf, transition::Hi, transition::ipCont, transition::Lo, phycon, PrintEfmt, prt_wl(), t_phycon::sqrte, and transition::WLAng.
Referenced by FeIIPunData(), H2_Punch_line_data(), and SaveLineData().
void save_average | ( | long int | ipPun | ) |
save_average parse save average command, or actually do the save output
ipPun | - array index for file for final save output |
Definition at line 213 of file save_average.cpp.
References cdColm(), cdEXIT, cdIonFrac(), cdTemp(), t_save::chAverageSpeciesLabel, t_save::chAverageType, DEBUG_ENTRY, ioQQQ, t_save::ipPnunit, t_save::nAverage2ndPar, t_save::nAverageIonList, t_save::nAverageList, save, and TotalInsanity().
Referenced by SaveDo().
void save_colden | ( | FILE * | ioPUN | ) |
save_colden parse save column density command, or actually do the save lines output
ip | the file we will write to |
Definition at line 92 of file save_colden.cpp.
References cdColm(), chElement, colden, DEBUG_ENTRY, ionstage, ioQQQ, MAX2, nColdenEntered, and SMALLFLOAT.
Referenced by SaveDo().
void save_line | ( | FILE * | ip, | |
const char * | chDo, | |||
bool | lgEmergent | |||
) |
save_line do the save output
ip | the file we will write to | |
chDo | ||
intrinsic | or emergent emission |
Definition at line 109 of file save_line.cpp.
References ASSERT, cdEmis(), cdEmis_ip(), cdEXIT, cdLine(), chPLab, DEBUG_ENTRY, t_radius::depth_mid_zone, h2, ioQQQ, ipLine, lgAbort, t_h2::lgH2ON, lgRelativeIntensity, LineSave, MAX2, nLinesEntered, NPUNLM, t_LineSave::nsum, nzone, radius, SMALLFLOAT, and wavelength.
Referenced by SaveDo().
void Save_Line_RT | ( | FILE * | ip | ) |
Save_Line_RT parse the save line rt command - read in a set of lines
ip | the file we will write to | |
*chJob |
Definition at line 358 of file save_line.cpp.
References cdEXIT, chLabel, chLineLbl(), DEBUG_ENTRY, dense, t_radius::depth_mid_zone, t_dense::eden, ioQQQ, lgMustPrintHeader, LIMLINE, line_RT_ipHi, line_RT_ipISO, line_RT_ipLo, line_RT_nelem, line_RT_type, nLine, opac, t_opac::opacity_abs, t_opac::opacity_sct, phycon, radius, t_radius::Radius_mid_zone, StatesElemNEW, t_phycon::te, and Transitions.
Referenced by SaveDo().
void save_opacity | ( | FILE * | io, | |
long int | np | |||
) |
save_opacity save total opacity in any element, save opacity command
io | ||
np |
Definition at line 22 of file save_opacity.cpp.
References abund, t_rfield::anu, t_rfield::AnuOrg, AnuUnit(), AS_LOCAL_ONLY, ASSERT, cdEXIT, t_rfield::chContLabel, t_elementnames::chElementNameShort, t_elementnames::chElementSym, t_save::chOpcTyp, t_Heavy::chShell, continuum, DEBUG_ENTRY, dense, t_iso::DepartCoef, elementnames, EVRYD, FILENAME_PATH_LENGTH_2, t_rfield::fine_anu, t_rfield::fine_opac_zone, t_opac::FreeFreeOpacity, t_dense::gas_phase, Heavy, Singleton< t_yield >::Inst(), Singleton< T >::Inst(), t_opac::iophe1, ioQQQ, t_opac::ipElement, ipFineCont(), ipH1s, ipH_LIKE, ipHE_LIKE, t_Heavy::ipHeavy, ipHELIUM, ipHYDROGEN, t_iso::ipIsoLevNIonCon, ipLITHIUM, t_iso::ipOpac, iso, t_continuum::KshellLimit, t_abund::lgAGN, t_opac::lgRedoStatic, LIMELM, MAX2, MIN2, t_yield::nelec_eject(), t_rfield::nfine, t_rfield::nflux, t_Heavy::nsShells, t_rfield::nupper, opac, t_opac::opacity_abs, t_opac::opacity_sct, OpacityAdd1Element(), OpacityAdd1SubshellInduc(), OpacityZero(), t_opac::OpacStack, t_opac::OpacStatic, open_data(), POW3, PrintE93(), prtPunOpacSummary(), t_save::punarg, rfield, save, StatesElemNEW, and t_dense::xIonDense.
Referenced by SaveDo().
void SaveDo | ( | const char * | chTime | ) |
SaveDo produce save output during calculation
chTime | chTime is null terminated 4 char string, either "MIDL" or "LAST" |
Definition at line 244 of file save_do.cpp.
References abund, Wind::AccelCont, Wind::AccelGravity, Wind::AccelLine, Wind::AccelTotalOutward, t_timesc::AgeCOMoleDest, AGN_He1_CS(), AGN_Hemis(), t_opac::albedo, t_rfield::anu, t_rfield::anu2, t_rfield::AnuOrg, AnuUnit(), ASSERT, t_cpu::big_endian(), GrainVar::bin, BOLTZMANN, t_colden::C1Pops, t_colden::C2Pops, called, cdColm(), cdExecTime(), cdEXIT, cdLine(), t_tag_LineSv::chALab, ChargTranPun(), t_rfield::chContLabel, t_elementnames::chElementSym, t_save::chHashString, t_save::chHeader, t_hmi::chLab, t_species::chLabel, chLabel, t_rfield::chLineLabel, t_save::chLineListLabel, t_save::chNONSENSE, t_save::chSave, t_save::chSaveArgs, t_Heavy::chShell, t_tag_LineSv::chSumTyp, t_optimize::chVarFmt, CO_findrk(), CO_punch_mol(), t_colden::colden, colden, t_iso::ColIoniz, transition::Coll, t_rfield::comdn, COmole, t_rfield::comup, t_rfield::ConEmitLocal, t_rfield::ConEmitOut, t_rfield::ConEmitReflec, t_rfield::ConInterOut, t_rfield::ConRefIncid, t_rfield::ConSourceFcnLocal, continuum, conv, t_radius::Conv2PrtInten, t_dynamics::Cool(), t_collision::cool, CoolSave(), t_geometry::covgeo, cpu, t_secondaries::csupra, t_thermal::ctot, dBaseStates, t_thermal::dCooldT, DEBUG_ENTRY, dense, t_radius::depth, t_radius::depth_mid_zone, t_rfield::DiffuseLineEmission, DoppVel, t_radius::drad, t_radius::drad_x_fillfac, GrainVar::dstab, GrainVar::dstsc, Wind::dvdr, dynamics, DynaPunchTimeDep(), DynaSave(), t_dense::eden, t_dense::EdenHCorr, t_dense::EdenTrue, t_rfield::egamry, t_yield::elec_eject_frac(), elementnames, transition::Emis, t_save::emisfreq, t_rfield::emm, EN1RYD, t_phycon::EnergyBinding, t_phycon::EnergyExcitation, t_phycon::EnergyIonization, t_magnetic::EnthalpyDensity, t_phycon::EnthalpyDensity, EVRYD, t_rfield::extin_mag_V_extended, t_rfield::extin_mag_V_point, FeII_Cont, FeIIPunchColden(), FeIIPunchLevels(), FeIIPunchOpticalDepth(), FeIIPunDepart(), FeIIPunPop(), FeIISaveLines(), t_geometry::FillFac, findspecies(), FindStrongestLineLabels(), t_rfield::fine_anu, t_rfield::fine_opac_zone, t_rfield::fine_opt_depth, t_rfield::flux, t_rfield::flux_total_incident, Wind::fmul, fp_equal(), GammaPrt(), t_iso::gamnc, t_dense::gas_phase, GrainVar::GasCoolColl, geometry, GrainVar::GrainEmission, GrainVar::GraphiteEmission, grid, GridGatherInCloudy(), gv, t_colden::H0_21cm_lower, t_colden::H0_21cm_upper, t_colden::H0_ov_Tspin, h2, H2_PunchDo(), t_hmi::H2_Solomon_dissoc_rate_used_H2g, t_hmi::H2_total, hcmap, t_dynamics::Heat(), t_hmi::HeatH2Dexc_used, t_hmi::HeatH2Dish_used, t_thermal::heating, Heavy, molecule::hevmol, HFLines, transition::Hi, t_conv::hist_pres_correct, t_conv::hist_pres_current, t_conv::hist_pres_density, t_conv::hist_temp_cool, t_conv::hist_temp_heat, t_conv::hist_temp_temp, hmi, t_hmi::Hmolec, t_thermal::htot, HydroRecCool(), hyperfine, INPUT_LINE_LENGTH, Singleton< T >::Inst(), Singleton< t_yield >::Inst(), t_pressure::IntegRhoGravity, t_grid::interpParameters, ion_recombAGN(), ionbal, ioQQQ, ipALUMINIUM, ipCARBON, ipCOL_elec, ipCOL_H0, ipCOL_H2g, ipCOL_H2s, ipCOL_H3p, ipCOL_Hp, ipCOL_HTOT, t_save::ipConPun, t_opac::ipElement, t_save::ipEmisFreq, ipFineCont(), ipH1s, ipH2p, ipH2s, ipH_LIKE, ipHe1s1S, ipHe2p1P, ipHe2p3P0, ipHe2p3P1, ipHe2p3P2, ipHe2s3S, ipHE_LIKE, ipHELIUM, ipHYDROGEN, ipIRON, t_iso::ipIsoLevNIonCon, ipMAGNESIUM, t_rfield::ipMaxBolt, ipMH2g, ipMH2p, ipMH2s, ipMH3p, ipMHm, ipoint(), t_iso::ipOpac, ipOXYGEN, t_save::ipPnunit, ipRecEsc, ipRecNetEsc, ipRecRad, ipSILICON, ipSODIUM, ipSULPHUR, ipT1032, ipT146, ipT157, ipT370, ipT610, ipT63, t_rfield::ipV_filter, is_odd(), iso, iteration, iterations, molecule::label, t_save::lg_separate_iterations, lgAbort, lgCheckMonitors(), t_conv::lgConvPres, t_conv::lgConvTemp, t_dense::lgElmtOn, t_save::lgEmergent, lgFirst, t_save::lgFITS, t_save::lgFLUSH, t_grid::lgGrid, t_h2::lgH2ON, t_save::lgHashEndIter, t_iterations::lgLastIt, t_save::lgLineListRatio, t_save::lgLinEvery, t_hcmap::lgMapBeingDone, t_hcmap::lgMapDone, t_cpu::lgMPI_talk(), lgMustPrintHeader, t_grid::lgOutputTypeOn, t_save::lgPunHeader, t_save::lgPunLstIter, t_save::lgRealSave, t_save::lgSaveEveryZone, t_geometry::lgSphere, t_called::lgTalk, t_dynamics::lgTimeDependentStatic, t_DoppVel::lgTurb_pressure, t_warnings::lgWarngs, LIMELM, t_rfield::line_count, LineSave, LineSv, t_save::LinEvery, transition::Lo, magnetic, map_do(), t_hcmap::MapZone, MAX2, mean, t_continuum::mesh_md5sum, MIN2, mole, N_H_MOLEC, t_save::ncSaveSkip, t_yield::nelec_eject(), nFeIIConBins, t_rfield::nfine, t_rfield::nflux, t_grid::nintparm, t_save::nLineList, nMatch(), t_optimize::nOptimiz, t_conv::nPres2Ioniz, t_save::nsave, t_save::nSaveEveryZone, nSpecies, t_Heavy::nsShells, t_LineSave::nsum, t_mole::num_comole_calc, NUM_OUTPUT_TYPES, t_species::numLevels_local, t_iso::numLevels_local, t_species::numLevels_max, t_rfield::nupper, nzone, t_colden::O1Pops, OccupationNumberLine(), opac, t_opac::opacity_abs, t_opac::opacity_sct, optimize, t_save::optname, t_rfield::otscon, t_rfield::otslin, t_rfield::outlin, t_rfield::outlin_noplot, t_dense::pden, t_ionbal::PhotoRate_Shell, phycon, t_pressure::pinzon, t_pressure::pinzon_PresIntegElecThin, plankf(), t_quantumState::Pop, t_emission::PopOpc, pow(), POW2, t_pressure::pres_radiation_lines_curr, t_pressure::PresGasCurr, t_pressure::PresInteg, t_pressure::PresIntegElecThin, t_pressure::PresRamCurr, t_magnetic::pressure, pressure, t_pressure::PresTotlCorrect, t_pressure::PresTotlCurr, t_pressure::PresTotlInit, t_pressure::PresTurbCurr, PrettyTranmission(), prt_LineLabels(), prt_wl(), PrtColumns(), PrtLinePres(), PrtMeanIon(), t_save::punarg, t_radius::r1r0sq, t_radius::Radius, radius, t_radius::Radius_mid_zone, t_iso::RadRec_caseB, t_iso::RadRecomb, t_dynamics::Rate, GrainVar::rate_h2_form_grains_used_total, t_ionbal::RateIonizTot(), t_ionbal::RateRecomTot, t_rfield::reflin, t_save::Resolution, t_continuum::ResolutionScaleFactor, rfield, Energy::Ryd(), RYDLAM, safe_div(), save, save_average(), save_colden(), save_line(), Save_Line_RT(), save_opacity(), SaveFeII_cont(), saveFITSfile(), SaveGaunts(), SaveHeat(), SaveLineData(), SaveLineIntensity(), SaveLineStuff(), SaveNewContinuum(), SaveResults(), SaveSpecial(), SDIV(), secondaries, sexp(), ShowMe(), GrainVar::SilicateEmission, SMALLFLOAT, t_timesc::sound_speed_adiabatic, t_dynamics::Source, Species, StatesElemNEW, struc, t_opac::TauAbsFace, t_opac::TauAbsGeo, t_emission::TauCon, t_emission::TauIn, TauLines, t_opac::TauScatFace, t_phycon::te, t_phycon::te03, t_phycon::te10, t_phycon::te70, t_phycon::TeInit, t_phycon::telogn, TempChange(), t_phycon::TeProp, t_struc::testr, TexcLine(), thermal, t_dynamics::time_elapsed, t_timesc::time_H2_Dest_here, timesc, TorF(), GrainVar::TotalEden, TotalInsanity(), t_rfield::TotDiff2Pht, t_rfield::trans_coef_total, Transitions, t_hyperfine::Tspin21cm, t_DoppVel::TurbVel, t_hmi::UV_Cont_rel2_Draine_DB96_depth, t_hmi::UV_Cont_rel2_Habing_TH85_depth, VERSION_TRNCON, warnings, t_tag_LineSv::wavelength, wavelength, t_rfield::widflx, wind, Wind::windv, t_save::wlLineList, t_secondaries::x12tot, t_dense::xIonDense, t_mean::xIonMean, and t_dense::xMassDensity.
Referenced by BadStart(), and cloudy().
void saveFITSfile | ( | FILE * | io, | |
int | option | |||
) |
Punch spectra to a FITS compatible file.
io | ||
option |
Definition at line 85 of file save_fits.cpp.
References ASSERT, cdEXIT, DEBUG_ENTRY, t_grid::Energies, grid, t_grid::interpParameters, ioFITS_OUTPUT, ioQQQ, t_grid::ipLoEnergy, t_grid::lgGridDone, MAX2, maxParamValues, t_grid::naddparm, t_rfield::nflux, t_grid::nintparm, NUM_OUTPUT_TYPES, t_grid::numEnergies, t_grid::numParamValues, t_grid::paramData, t_grid::paramMethods, t_grid::paramNames, t_grid::paramRange, punchFITS_EnergyData(), punchFITS_EnergyHeader(), punchFITS_GenericData(), punchFITS_GenericHeader(), punchFITS_ParamData(), punchFITS_ParamHeader(), punchFITS_PrimaryHeader(), punchFITS_SpectraData(), punchFITS_SpectraHeader(), rfield, t_grid::Spectra, and t_grid::totNumModels.
Referenced by process_output(), and SaveDo().
void SaveHeat | ( | FILE * | io | ) |
SaveHeat save contributors to local heating, with save heat command, called by punch_do
io |
Definition at line 22 of file heat_save.cpp.
References ASSERT, CALLOC, cdEXIT, t_thermal::chClntLab, t_elementnames::chElementSym, t_elementnames::chIonStage, chLabel, chLineLbl(), t_collision::col_str, transition::Coll, t_thermal::collam, conv, t_dynamics::Cool(), t_thermal::ctot, dBaseLines, DEBUG_ENTRY, dense, t_radius::depth_mid_zone, dynamics, elementnames, transition::Emis, FndLineHt(), t_collision::heat, t_dynamics::Heat(), t_thermal::heating, t_thermal::heatnt, HFLines, t_thermal::htot, ioQQQ, IPRINT, t_conv::lgConvEden, t_conv::lgConvIoniz, t_conv::lgConvPres, t_conv::lgConvTemp, LIMELM, MIN2, t_thermal::ncltot, t_emission::Pesc, phycon, t_emission::pump, radius, save, SDIV(), SMALLFLOAT, spsort(), t_emission::TauIn, TauLine2, TauLines, t_phycon::te, thermal, t_emission::tran, t_save::WeakHeatCool, and t_dense::xIonDense.
Referenced by SaveDo().
NORETURN void SaveLineData | ( | FILE * | io | ) |
SaveLineData punches selected line data for all lines transferred in code
io |
Definition at line 24 of file save_linedata.cpp.
References cdEXIT, t_elementnames::chElementName, t_elementnames::chElementSym, t_thermal::ConstTemp, CoolEvaluate(), dBaseLines, DEBUG_ENTRY, dense, t_dense::eden, t_dense::EdenHCorr, elementnames, FeIIPunData(), t_dense::gas_phase, H2_LevelPops(), H2_Punch_line_data(), HFLines, transition::Hi, hmi, t_hmi::Hmolec, Singleton< T >::Inst(), ioQQQ, ipH1s, ipH_LIKE, ipHe1s1S, ipHE_LIKE, ipHYDROGEN, ipMH2g, ipMH2s, iso, iso_collide(), t_dense::lgElmtOn, t_thermal::lgTemperatureConstant, LIMELM, linesAdded2, LineSave, transition::Lo, MIN2, t_quantumState::nelem, nHFLines, NISO, nLevel1, t_iso::numLevels_max, nUTA, nWindLine, phycon, t_quantumState::Pop, t_LineSave::RecCoefCNO, SatelliteLines, Save1LineData(), SDIV(), TauLine2, TauLines, t_phycon::te, TempChange(), thermal, Transitions, UTALines, and t_dense::xIonDense.
Referenced by SaveDo().
void SaveSpecial | ( | FILE * | io, | |
const char * | chTime | |||
) |
SaveSpecial generate output for the save special command
io | ||
chTime |
Definition at line 14 of file save_special.cpp.
References Wind::AccelCont, t_rfield::anu, t_rfield::anu2, t_iso::As2nu, ASSERT, DEBUG_ENTRY, dense, t_radius::depth, t_radius::drad, t_dense::eden, EN1RYD, Wind::fmul, fnzone, t_dense::gas_phase, h2, H2Lines, ipH1s, ipH2p, ipH2s, ipH_LIKE, ipHYDROGEN, iso, iteration, t_h2::lgH2ON, opac, t_opac::opacity_sct, pow(), PunFeII(), t_radius::Radius, radius, rfield, RYDLAM, StatesElemNEW, Transitions, t_rfield::widflx, wind, and t_dense::xMassDensity.
Referenced by SaveDo().
const long LIMPUN = 100L [static] |
Definition at line 8 of file save.h.
Referenced by InitDefaultsPreparse(), ParseSave(), and SaveFilesInit().
const long MAX_HEADER_SIZE = 20000L [static] |
Definition at line 9 of file save.h.
Referenced by ParseSave().
Referenced by AnuUnit(), atmdat_3body(), atmdat_DielSupres(), cdMain(), ChkUnits(), CloseSaveFiles(), ConvBase(), ConvIterCheck(), CoolEvaluate(), CoolSave(), FeIICreate(), GrainIonColl(), H2_ParseSave(), H2_PunchDo(), HeatSum(), InitDefaultsPreparse(), ion_recomb(), IonCarbo(), iso_radiative_recomb(), lines_helium(), main(), OpacityCreate1Element(), parse_save_average(), ParseSave(), ParseSet(), PrettyTranmission(), process_output(), PrtComment(), radius_first(), radius_next(), RT_tau_inc(), Save1Line(), save_average(), save_opacity(), SaveDo(), SaveFilesInit(), SaveHeat(), SaveLineIntensity(), SaveLineStuff(), SaveResults1Line(), and vary_input().
const long VERSION_TRNCON = 20100901L [static] |
magic version number for the transmitted continuum output file
Definition at line 12 of file save.h.
Referenced by ReadTable(), and SaveDo().