Cloudy
Spectral Synthesis Code for Astrophysics
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
t_save Struct Reference

#include <save.h>

Collaboration diagram for t_save:

Public Member Functions

 t_save ()
 
 ~t_save ()
 
void SaveLineListFree (long i)
 
void SaveAverageFree (long i)
 
string chGridDelimeter (long n)
 
void SetSaveHeaderNeeded (bool lgVal)
 
bool lgSaveTitle (int ipPun) const
 
void SaveTitleDone (int ipPun)
 
bool lgSaveHeader (int ipPun) const
 
void SaveHeaderDone (int ipPun)
 

Public Attributes

long nLineList [LIMPUN]
 
vector< LineIDLineList [LIMPUN]
 
bool lgLineListRatio [LIMPUN]
 
long nAverageList [LIMPUN]
 
vector< string > chAverageType [LIMPUN]
 
vector< int > nAverageIonList [LIMPUN]
 
vector< int > nAverage2ndPar [LIMPUN]
 
SaveParams params [LIMPUN]
 
vector< string > chFileName
 
long ipSaveGrid
 
bool lgNoClobber [LIMPUN]
 
bool lgPrtOldStyleLogs [LIMPUN]
 
bool lgPunConv_noclobber
 
bool lgDROn_noclobber
 
bool lgDTOn_noclobber
 
bool lgPunPoint_noclobber
 
bool lgioRecom_noclobber
 
bool lgQHSaveFile_noclobber
 
bool lgTraceConvergeBase_noclobber
 
bool lgSaveGrid_noclobber
 
bool lgRealSave [LIMPUN]
 
bool lgEmergent [LIMPUN]
 
bool lgCumulative [LIMPUN]
 
bool lgSubtrCont
 
bool lgPrtIsotropicCont [LIMPUN]
 
long int nsave
 
char chSave [LIMPUN][5]
 
diatomicswhichDiatomToPrint [LIMPUN]
 
char chOpcTyp [LIMPUN][5]
 
bool lgSaveToSeparateFiles [LIMPUN]
 
bool lg_separate_iterations [LIMPUN]
 
bool lgPunContinuum
 
realnum punarg [LIMPUN][3]
 
string optname [LIMPUN]
 
bool lgSaveEveryZone [LIMPUN]
 
long int nSaveEveryZone [LIMPUN]
 
char chSaveArgs [LIMPUN][5]
 
vector< string > chSaveSpecies [LIMPUN]
 
bool lgPunLstIter [LIMPUN]
 
bool lgFITS [LIMPUN]
 
bool lgXSPEC [LIMPUN]
 
int FITStype [LIMPUN]
 
bool lgPunchFits
 
const char * chConSavEnr [LIMPUN]
 
long int ipConPun
 
bool lgHashEndIter [LIMPUN]
 
string chHashString
 
bool lgFLUSH
 
bool lgLuminosityOld
 
string chGridPrefix
 
string chFilenamePrefix
 
string chRedirectPrefix
 
string chOutputFile
 
char chPunRltType [7]
 
FILE * ipPoint
 
bool lgPunPoint
 
bool lgPunConv
 
FILE * ipPunConv
 
bool lgSDSOn
 
FILE * ipSDSFile
 
FILE * ipDRout
 
bool lgDROn
 
bool lgDRPLst
 
bool lgDRHash
 
FILE * ipDTout
 
bool lgDTOn
 
bool lgDTPLst
 
bool lgDTHash
 
bool lgTraceConvergeBase
 
bool lgTraceConvergeBaseHash
 
FILE * ipTraceConvergeBase
 
FILE * ioRecom
 
bool lgioRecom
 
long int LinEvery
 
bool lgLinEvery
 
long int ncSaveSkip
 
realnum WeakHeatCool
 
realnum Resolution
 
realnum ResolutionAbs
 
string chSpeciesDominantRates [LIMPUN]
 
Energy emisfreq [LIMPUN]
 
long ipEmisFreq [LIMPUN]
 
bool lgSaveDataWn
 
bool lgSaveDataGf
 
bool lgSaveDataRates
 
vector< string > contSaveSpeciesLabel
 
vector< adjPseudoContsetPseudoCont
 
string SpeciesBandFile [LIMPUN]
 
save_img_matrix img_matrix
 

Private Attributes

bool p_lgSaveTitleDone [LIMPUN]
 
bool p_lgSaveHeaderDone [LIMPUN]
 
bool p_lgSaveHeaderNeeded
 

Constructor & Destructor Documentation

t_save::~t_save ( )
inline

References LIMPUN, SaveAverageFree(), and SaveLineListFree().

Here is the call graph for this function:

Member Function Documentation

string t_save::chGridDelimeter ( long  n)
inline

References chHashString.

Referenced by fix_grid_file(), and SaveDo().

bool t_save::lgSaveHeader ( int  ipPun) const
inline
bool t_save::lgSaveTitle ( int  ipPun) const
inline

is it OK to save title now?

References ipPun, p_lgSaveHeaderNeeded, and p_lgSaveTitleDone.

void t_save::SaveAverageFree ( long  i)
inline
void t_save::SaveHeaderDone ( int  ipPun)
inline
void t_save::SaveLineListFree ( long  i)
inline

References LineList.

Referenced by ~t_save().

void t_save::SaveTitleDone ( int  ipPun)
inline

References ipPun, and p_lgSaveTitleDone.

void t_save::SetSaveHeaderNeeded ( bool  lgVal)
inline

References p_lgSaveHeaderNeeded.

Referenced by main().

Member Data Documentation

vector<string> t_save::chAverageType[LIMPUN]

chAverageType is label for type of average

Referenced by parse_save_average(), save_average(), and SaveAverageFree().

const char* t_save::chConSavEnr[LIMPUN]

chConPunEnr - units of continuum in save output

Referenced by AnuUnit(), ParseSave(), Save1Line(), and Save1LineData().

vector<string> t_save::chFileName

the filename is needed during the file gathering phase in grid runs

Referenced by ParseSave(), process_output(), and SaveGrid().

string t_save::chFilenamePrefix

this is a prefix that will be set at the start of all save file names normally an empty string, set with PUNCH PREFIX command or -p flag

Referenced by cdMain(), ParseSave(), ParseSet(), and process_output().

string t_save::chGridPrefix

this is a prefix that will be used at the start of all file names when doing an MPI grid run, normally an empty string, set with -g flag

Referenced by cdMain(), and ParseSave().

string t_save::chHashString

this is the hash string, normally a set of hash marks, can be reset with set save hash command

Referenced by check_grid_file(), chGridDelimeter(), ConvBase(), InitDefaultsPreparse(), ParseSet(), radius_first(), save_DT(), SaveDo(), and SaveLineStuff().

char t_save::chOpcTyp[LIMPUN][5]

which opacity to save out

Referenced by ParseSave(), and save_opacity().

string t_save::chOutputFile

this is the name of the main output file we are writing to it is set by calling cdOutput()

Referenced by cdOutput(), cdRead(), and ParseDont().

char t_save::chPunRltType[7]

set with save line intensities and save results commands, says whether results arrays produced by routine PunResults1Line should be column or array

string t_save::chRedirectPrefix

this is the prefix that will be set at the start of the input and output file normally an empty string, set with -p or -r flag

Referenced by cdMain(), main(), process_output(), and vary_input().

char t_save::chSave[LIMPUN][5]

chSave - what is it we want to save? set in GetPunch, used in DoPunch

Referenced by diatomics::H2_ParseSave(), ParseSave(), SaveDo(), and saveXSPEC().

char t_save::chSaveArgs[LIMPUN][5]

set of optional arguments for save command, but as a string

Referenced by ParseSave(), SaveDo(), SaveSpecies(), and SaveSpeciesPseudoCont().

vector<string> t_save::chSaveSpecies[LIMPUN]
string t_save::chSpeciesDominantRates[LIMPUN]

Referenced by InitDefaultsPreparse(), and SaveDo().

vector<string> t_save::contSaveSpeciesLabel

Parameters for saving the pseudocontinuum

Referenced by PseudoContCreate(), and SpeciesPseudoContCreate().

Energy t_save::emisfreq[LIMPUN]

Referenced by InitDefaultsPreparse(), and SaveDo().

int t_save::FITStype[LIMPUN]

which FITS type is in this file

Referenced by process_output(), saveXSPEC(), and t_save().

FILE* t_save::ioRecom

option to save recombination coefficients to external file

Referenced by atmdat_3body(), CloseSaveFiles(), ion_recomb(), iso_radiative_recomb(), and SaveFilesInit().

long int t_save::ipConPun

this global variable is index of save command loop in dopunch

Referenced by AnuUnit(), Save1Line(), Save1LineData(), and SaveDo().

FILE* t_save::ipDRout

these control saving choice of dr - this is not really a save command ipDRout is io unit, lgDROn says saving dr logic has been set, and lgDRPLst says to save the last iteration

Referenced by CloseSaveFiles(), radius_first(), radius_next(), and SaveFilesInit().

FILE* t_save::ipDTout

Likewise for saving choice of dt

Referenced by CloseSaveFiles(), save_DT(), and SaveFilesInit().

long t_save::ipEmisFreq[LIMPUN]

Referenced by InitDefaultsPreparse(), and SaveDo().

FILE* t_save::ipPoint

option to save out pointers with save pointers command ipPoint is save file handle, lgPunPoint says whether we will do it

Referenced by CloseSaveFiles(), OpacityCreate1Element(), and SaveFilesInit().

FILE* t_save::ipPunConv
long t_save::ipSaveGrid

pointer into chFileName for the name of the SAVE GRID file

Referenced by cdPrepareExit(), SaveGrid(), and t_save().

FILE* t_save::ipSDSFile
FILE* t_save::ipTraceConvergeBase
bool t_save::lg_separate_iterations[LIMPUN]

option to not insert end-of-iteration separator - used for save files that create one line per iteration

Referenced by check_grid_file(), InitDefaultsPreparse(), and SaveDo().

bool t_save::lgCumulative[LIMPUN]

cumulative line intensities for time dependent sim

Referenced by SaveDo().

bool t_save::lgDRHash
bool t_save::lgDROn
bool t_save::lgDROn_noclobber

Referenced by CloseSaveFiles(), and SaveFilesInit().

bool t_save::lgDRPLst
bool t_save::lgDTHash

Referenced by InitDefaultsPreparse(), and save_DT().

bool t_save::lgDTOn
bool t_save::lgDTOn_noclobber

Referenced by CloseSaveFiles(), and SaveFilesInit().

bool t_save::lgDTPLst

Referenced by InitDefaultsPreparse(), and save_DT().

bool t_save::lgEmergent[LIMPUN]

emergent or intrinsic line intensities

Referenced by SaveDo(), and SaveLineIntensity().

bool t_save::lgFITS[LIMPUN]

flag saying that this save file is in FITS format

Referenced by check_grid_file(), CloseSaveFiles(), SaveDo(), and t_save().

bool t_save::lgFLUSH

flush file after every iteration

Referenced by InitDefaultsPreparse(), ParseSet(), and SaveDo().

bool t_save::lgHashEndIter[LIMPUN]

should hash marks be printed after every iteration? default is yes, set no with no hash option on save command

Referenced by check_grid_file(), InitDefaultsPreparse(), ParseSave(), and SaveDo().

bool t_save::lgioRecom_noclobber

Referenced by CloseSaveFiles(), and SaveFilesInit().

bool t_save::lgLineListRatio[LIMPUN]

flag saying whether to take ratio (true) of pairs

Referenced by SaveDo().

bool t_save::lgLinEvery

Referenced by SaveDo().

bool t_save::lgLuminosityOld

in save continuum output, in the luminosity case, use old style of luminosity per inner cloud area rather than true luminosity

Referenced by InitDefaultsPreparse(), ParseSet(), and ZoneStart().

bool t_save::lgNoClobber[LIMPUN]

option to append instead of overwrite

Referenced by CloseSaveFiles(), ParseSave(), and SaveFilesInit().

bool t_save::lgPrtIsotropicCont[LIMPUN]

option to remove isotropic continua from the output of 'save continuum'

Referenced by SaveDo().

bool t_save::lgPrtOldStyleLogs[LIMPUN]

print old style logs

Referenced by ParseSave(), and PrtLogLin().

bool t_save::lgPunchFits

option to say whether any FITS output should be punched, initialized to false, but turned to true after last grid exec.

bool t_save::lgPunContinuum

flag saying whether any save continuum commands were entered set true in parsecontinuum when save continuum entered, used in PrtComment to warn if continuum punched with no iterations

Referenced by InitDefaultsPreparse(), and PrtComment().

bool t_save::lgPunConv

unit number, and flag, for saving reason for continued iterations

Referenced by CloseSaveFiles(), ConvIterCheck(), and SaveFilesInit().

bool t_save::lgPunConv_noclobber

these are for some special cases, same purpose as previous no clobber

Referenced by CloseSaveFiles(), and SaveFilesInit().

bool t_save::lgPunLstIter[LIMPUN]

lg flag lgPunLstIter for this save option, do we only want to save on last iteration?

Referenced by ParseSave(), and SaveDo().

bool t_save::lgPunPoint
bool t_save::lgPunPoint_noclobber

Referenced by CloseSaveFiles(), and SaveFilesInit().

bool t_save::lgQHSaveFile_noclobber

Referenced by CloseSaveFiles(), and SaveFilesInit().

bool t_save::lgRealSave[LIMPUN]

is this a real save command, or one of the similar options like save dr, which is not done in save files

Referenced by SaveDo(), and SaveFilesInit().

bool t_save::lgSaveDataGf
bool t_save::lgSaveDataRates
bool t_save::lgSaveDataWn
bool t_save::lgSaveEveryZone[LIMPUN]

implement save every option - lgSaveEveryZone true if want to save every zone, nSaveEveryZone is number of zones to save

Referenced by InitDefaultsPreparse(), ParseSave(), and SaveDo().

bool t_save::lgSaveGrid_noclobber

Referenced by CloseSaveFiles(), and SaveFilesInit().

bool t_save::lgSaveToSeparateFiles[LIMPUN]

this flag tells us whether to save results of a grid to separate files for each grid point or all to the same file. Different for different save commands

Referenced by ParseSave(), and process_output().

bool t_save::lgSDSOn

Identify whether Save Data Sources is on

Referenced by database_readin(), ion_recom_calculate(), and read_UTA_lines().

bool t_save::lgSubtrCont

user-defined option to subtract continuum in reported line flux

Referenced by InitDefaultsPreparse(), ParseDont(), and set_xIntensity().

bool t_save::lgTraceConvergeBase
bool t_save::lgTraceConvergeBase_noclobber

Referenced by CloseSaveFiles(), and SaveFilesInit().

bool t_save::lgTraceConvergeBaseHash

Referenced by ConvBase(), and InitDefaultsPreparse().

bool t_save::lgXSPEC[LIMPUN]

flag saying that this save file is in XSPEC format

Referenced by CloseSaveFiles(), process_output(), and t_save().

vector<LineID> t_save::LineList[LIMPUN]

LineID's for line list

Referenced by SaveDo(), and SaveLineListFree().

long int t_save::LinEvery

option to save line intensities every for every zone logical variable says whether LinEvery was set

Referenced by SaveDo().

vector<int> t_save::nAverage2ndPar[LIMPUN]

nAverage2ndPar is set of second parameters for averages

Referenced by parse_save_average(), save_average(), and SaveAverageFree().

vector<int> t_save::nAverageIonList[LIMPUN]

nAverageIonList is set of ions for averages

Referenced by parse_save_average(), save_average(), and SaveAverageFree().

long t_save::nAverageList[LIMPUN]

following are for save averages option nAverageList is number of averages, -1 if not defined

Referenced by parse_save_average(), save_average(), SaveAverageFree(), and t_save().

long int t_save::ncSaveSkip

set skip sets this variable, which says how many cells to skip in save

Referenced by InitDefaultsPreparse(), ParseSet(), and SaveDo().

long t_save::nLineList[LIMPUN]

following are for save LineList option nLineList is number of em lines, -1 if not defined

Referenced by SaveDo(), and t_save().

long int t_save::nsave
long int t_save::nSaveEveryZone[LIMPUN]
string t_save::optname[LIMPUN]

punarg is set of optional arguments for the save command

Referenced by SaveDo().

bool t_save::p_lgSaveHeaderDone[LIMPUN]
private

flag saying whether the header has been saved already. Used in grid runs so that the header only gets saved once.

Referenced by lgSaveHeader(), SaveHeaderDone(), and t_save().

bool t_save::p_lgSaveHeaderNeeded
private

flag saying whether a header is needed at all Used in grid runs so that the header only gets saved once.

Referenced by lgSaveHeader(), lgSaveTitle(), SetSaveHeaderNeeded(), and t_save().

bool t_save::p_lgSaveTitleDone[LIMPUN]
private

flag saying whether the title has been saved already. Used in grid runs so that the title only gets saved once.

Referenced by lgSaveTitle(), SaveTitleDone(), and t_save().

SaveParams t_save::params[LIMPUN]

this is the file where we will direct the output

Referenced by CloseSaveFiles(), save_average(), SaveDo(), SaveFilesInit(), SaveSpeciesBands(), SaveSpeciesOptDep(), and SaveSpeciesPseudoCont().

realnum t_save::punarg[LIMPUN][3]
realnum t_save::Resolution

contrast factor for lines to continuum in save output default is 1 (gives correct line intensities) and changed with set width command (enters width in km/sec)

Referenced by flxCell(), InitDefaultsPreparse(), ParseSet(), and SaveDo().

realnum t_save::ResolutionAbs
vector<adjPseudoCont> t_save::setPseudoCont
string t_save::SpeciesBandFile[LIMPUN]

Parameters for species bands

Referenced by SaveDo().

realnum t_save::WeakHeatCool

threshold for faintest cooling or heating to be punched default is set to 0.05 in scalar, can be reset with 'set weakheatcool'

Referenced by CoolSave(), InitDefaultsPreparse(), ParseSet(), and SaveHeat().

diatomics* t_save::whichDiatomToPrint[LIMPUN]

Referenced by diatomics::H2_ParseSave(), and SaveDo().


The documentation for this struct was generated from the following file: