cloudy trunk
Loading...
Searching...
No Matches
t_conv Struct Reference

#include <conv.h>

Collaboration diagram for t_conv:

Public Member Functions

void resetConvIoniz ()
void setConvIonizFail (const char *reason, double oldval, double newval)
bool lgConvIoniz () const
const char * chConvIoniz () const
double convIonizOldVal () const
double convIonizNewVal () const
void incrementCounter (const counter_type type)
void resetCounters ()
void resetCountersZone ()
long getCounter (const long type)
long getCounterZone (const long type)

Data Fields

char chConvEden [INPUT_LINE_LENGTH]
char chNotConverged [INPUT_LINE_LENGTH]
bool lgConvPops
long int nPres2Ioniz
bool lgFirstSweepThisZone
bool lgLastSweepThisZone
long int limPres2Ioniz
long int nTotalIoniz
long int nTotalIoniz_start
bool lgSearch
realnum AverEdenError
realnum BigHeatCoolError
realnum AverHeatCoolError
realnum BigPressError
realnum AverPressError
bool lgIonStageTrimed
bool lgOscilOTS
bool lgConvTemp
bool lgConvPres
bool lgConvEden
long int nTotalFailures
long int nTeFail
realnum failmx
long int nPreFail
long int nNeFail
realnum BigEdenError
long int nIonFail
long int nPopFail
long int nGrainFail
long int nChemFail
long int LimFail
bool lgMap
long int ifailz [12]
char chSolverEden [20]
char chSolverTemp [20]
bool lgBadStop
bool lgAutoIt
bool lgUpdateCouplings
realnum autocv
double EdenErrorAllowed
realnum PressureErrorAllowed
double MaxFractionalDensityStepPerIteration
realnum HeatCoolRelErrorAllowed
realnum IonizErrorAllowed
realnum GasPhaseAbundErrorAllowed
double dCmHdT
double sigma_dCmHdT
vector< double > hist_pres_density
vector< double > hist_pres_current
vector< double > hist_pres_error
long int hist_pres_nzone
vector< double > hist_temp_temp
vector< double > hist_temp_heat
vector< double > hist_temp_cool
long int hist_temp_nzone

Private Attributes

char m_chConvIoniz [INPUT_LINE_LENGTH]
bool m_lgConvIoniz
double m_BadConvIoniz [2]
long m_counters [NTYPES]
long m_counters_zone [NTYPES]

Detailed Description

the variables that deal with the convergence of the model

Definition at line 89 of file conv.h.

Member Function Documentation

◆ chConvIoniz()

const char * t_conv::chConvIoniz ( ) const
inline

Definition at line 119 of file conv.h.

References m_chConvIoniz.

◆ convIonizNewVal()

double t_conv::convIonizNewVal ( ) const
inline

Definition at line 127 of file conv.h.

References m_BadConvIoniz.

◆ convIonizOldVal()

double t_conv::convIonizOldVal ( ) const
inline

Definition at line 123 of file conv.h.

References m_BadConvIoniz.

◆ getCounter()

long t_conv::getCounter ( const long type)
inline

Definition at line 323 of file conv.h.

References m_counters.

◆ getCounterZone()

long t_conv::getCounterZone ( const long type)
inline

Definition at line 327 of file conv.h.

References m_counters_zone.

◆ incrementCounter()

void t_conv::incrementCounter ( const counter_type type)
inline

Definition at line 308 of file conv.h.

References m_counters, and m_counters_zone.

◆ lgConvIoniz()

bool t_conv::lgConvIoniz ( ) const
inline

Definition at line 115 of file conv.h.

References m_lgConvIoniz.

◆ resetConvIoniz()

void t_conv::resetConvIoniz ( )
inline

Definition at line 100 of file conv.h.

References INPUT_LINE_LENGTH, m_BadConvIoniz, m_chConvIoniz, and m_lgConvIoniz.

◆ resetCounters()

void t_conv::resetCounters ( )
inline

Definition at line 313 of file conv.h.

References m_counters, and NTYPES.

◆ resetCountersZone()

void t_conv::resetCountersZone ( )
inline

Definition at line 318 of file conv.h.

References m_counters_zone, and NTYPES.

◆ setConvIonizFail()

void t_conv::setConvIonizFail ( const char * reason,
double oldval,
double newval )
inline

Definition at line 107 of file conv.h.

References INPUT_LINE_LENGTH, m_BadConvIoniz, m_chConvIoniz, and m_lgConvIoniz.

Field Documentation

◆ autocv

realnum t_conv::autocv

a convergence criteria

Definition at line 262 of file conv.h.

◆ AverEdenError

realnum t_conv::AverEdenError

remember the average electron density error

Definition at line 178 of file conv.h.

◆ AverHeatCoolError

realnum t_conv::AverHeatCoolError

Definition at line 182 of file conv.h.

◆ AverPressError

realnum t_conv::AverPressError

Definition at line 186 of file conv.h.

◆ BigEdenError

realnum t_conv::BigEdenError

remember the biggest electron density error as test of convergence quality

Definition at line 220 of file conv.h.

◆ BigHeatCoolError

realnum t_conv::BigHeatCoolError

remember the biggest and average heating-cooling error

Definition at line 181 of file conv.h.

◆ BigPressError

realnum t_conv::BigPressError

remember the biggest and average pressure error

Definition at line 185 of file conv.h.

◆ chConvEden

char t_conv::chConvEden[INPUT_LINE_LENGTH]

this says why the electron density did not converge,

Definition at line 92 of file conv.h.

◆ chNotConverged

char t_conv::chNotConverged[INPUT_LINE_LENGTH]

this gives the reason the model was declared not converged when 'iter to convergence' command is given

Definition at line 135 of file conv.h.

◆ chSolverEden

char t_conv::chSolverEden[20]

which electron density solver to use? set with set eden solver command, simple and new

Definition at line 245 of file conv.h.

◆ chSolverTemp

char t_conv::chSolverTemp[20]

which temperature density solver to use? set with set eden solver command, default and brent

Definition at line 249 of file conv.h.

◆ dCmHdT

double t_conv::dCmHdT

numerical estimate of d(cooling-heating)/dT

Definition at line 288 of file conv.h.

◆ EdenErrorAllowed

double t_conv::EdenErrorAllowed

this is relative error in the electron density we want set in zero to 0.01 reset with set eden error command

Definition at line 267 of file conv.h.

◆ failmx

realnum t_conv::failmx

failmx is largest relative error in heating cooling match

Definition at line 211 of file conv.h.

◆ GasPhaseAbundErrorAllowed

realnum t_conv::GasPhaseAbundErrorAllowed

allowed error in total gas-phase density of each element, including molecules change with "SET DENSITY TOLERANCE" command default set in zero

Definition at line 285 of file conv.h.

◆ HeatCoolRelErrorAllowed

realnum t_conv::HeatCoolRelErrorAllowed

allowed error in heating - cooling balance, set with TOLERANCE command default set in zerologic

Definition at line 278 of file conv.h.

◆ hist_pres_current

vector<double> t_conv::hist_pres_current

Definition at line 295 of file conv.h.

◆ hist_pres_density

vector<double> t_conv::hist_pres_density

these are used to retain the density pressure history in current zone, can be output with save pressure history

Definition at line 295 of file conv.h.

◆ hist_pres_error

vector<double> t_conv::hist_pres_error

Definition at line 295 of file conv.h.

◆ hist_pres_nzone

long int t_conv::hist_pres_nzone

Definition at line 296 of file conv.h.

◆ hist_temp_cool

vector<double> t_conv::hist_temp_cool

Definition at line 300 of file conv.h.

◆ hist_temp_heat

vector<double> t_conv::hist_temp_heat

Definition at line 300 of file conv.h.

◆ hist_temp_nzone

long int t_conv::hist_temp_nzone

Definition at line 301 of file conv.h.

◆ hist_temp_temp

vector<double> t_conv::hist_temp_temp

these are used to retain the temp/heat/cooling history in current zone, can be output with save temperature history

Definition at line 300 of file conv.h.

◆ ifailz

long int t_conv::ifailz[12]

zones where converge problems occurred

Definition at line 241 of file conv.h.

◆ IonizErrorAllowed

realnum t_conv::IonizErrorAllowed

Definition at line 280 of file conv.h.

◆ lgAutoIt

bool t_conv::lgAutoIt

says "interate to convergence" command given

Definition at line 256 of file conv.h.

◆ lgBadStop

bool t_conv::lgBadStop

flag saying that calculation stopped for bad reason mostly set in lgEndfun

Definition at line 253 of file conv.h.

◆ lgConvEden

bool t_conv::lgConvEden

true when the electron density has converged

Definition at line 202 of file conv.h.

◆ lgConvPops

bool t_conv::lgConvPops

this flag is used in ConvPresTempEdenIoniz to check that populations have converged

Definition at line 143 of file conv.h.

◆ lgConvPres

bool t_conv::lgConvPres

true if pressure is converged, false if not

Definition at line 199 of file conv.h.

◆ lgConvTemp

bool t_conv::lgConvTemp

true if temperature is converged, false if not

Definition at line 196 of file conv.h.

◆ lgFirstSweepThisZone

bool t_conv::lgFirstSweepThisZone

first sweep through solvers in this zone. also true is search phase

Definition at line 155 of file conv.h.

◆ lgIonStageTrimed

bool t_conv::lgIonStageTrimed

flag set in ConvBase, saying whether ionization stage is trimmed down

Definition at line 189 of file conv.h.

◆ lgLastSweepThisZone

bool t_conv::lgLastSweepThisZone

last sweep through solvers in this zone, so update fine opacities

Definition at line 157 of file conv.h.

◆ lgMap

bool t_conv::lgMap

lgMap is option to map failures

Definition at line 238 of file conv.h.

◆ lgOscilOTS

bool t_conv::lgOscilOTS

this is true if ots rates are oscillating, and this is why ionization is not converged

Definition at line 193 of file conv.h.

◆ lgSearch

bool t_conv::lgSearch

conv.lgSearch is true during initial temp-ion search phase, false after first zone established

Definition at line 175 of file conv.h.

◆ lgUpdateCouplings

bool t_conv::lgUpdateCouplings

says update inter-couplings after every ion solution

Definition at line 259 of file conv.h.

◆ LimFail

long int t_conv::LimFail

LimFail is limit to number of te failures, set with "failures" cmnd

Definition at line 235 of file conv.h.

◆ limPres2Ioniz

long int t_conv::limPres2Ioniz

a limit to the above, in case where one zone takes forever to not converge, usually very large, set with SET PRESIONIZ command

Definition at line 161 of file conv.h.

◆ m_BadConvIoniz

double t_conv::m_BadConvIoniz[2]
private

when the lgConvIoniz flag is set false, the old and new numbers, the reason for the lack of convergence, should be set to following

Definition at line 148 of file conv.h.

Referenced by convIonizNewVal(), convIonizOldVal(), resetConvIoniz(), and setConvIonizFail().

◆ m_chConvIoniz

char t_conv::m_chConvIoniz[INPUT_LINE_LENGTH]
private

this says why the ionization did not converge, reasons can be a large change in the level of ionization, or in the heating

Definition at line 97 of file conv.h.

Referenced by chConvIoniz(), resetConvIoniz(), and setConvIonizFail().

◆ m_counters

long t_conv::m_counters[NTYPES]
private

Definition at line 305 of file conv.h.

Referenced by getCounter(), incrementCounter(), and resetCounters().

◆ m_counters_zone

long t_conv::m_counters_zone[NTYPES]
private

Definition at line 306 of file conv.h.

Referenced by getCounterZone(), incrementCounter(), and resetCountersZone().

◆ m_lgConvIoniz

bool t_conv::m_lgConvIoniz
private

this flag is used in ConvPresTempEdenIoniz to check that ionization has converged

Definition at line 139 of file conv.h.

Referenced by lgConvIoniz(), resetConvIoniz(), and setConvIonizFail().

◆ MaxFractionalDensityStepPerIteration

double t_conv::MaxFractionalDensityStepPerIteration

Definition at line 274 of file conv.h.

◆ nChemFail

long int t_conv::nChemFail

number of chemistry solution failures

Definition at line 232 of file conv.h.

◆ nGrainFail

long int t_conv::nGrainFail

number of grain ionization balance failures

Definition at line 229 of file conv.h.

◆ nIonFail

long int t_conv::nIonFail

nIonFail is number of ionization failures

Definition at line 223 of file conv.h.

◆ nNeFail

long int t_conv::nNeFail

nNeFail is number of electron density failures

Definition at line 217 of file conv.h.

◆ nPopFail

long int t_conv::nPopFail

nIonFail is number of level population failures

Definition at line 226 of file conv.h.

◆ nPreFail

long int t_conv::nPreFail

nPreFail is number of pressure failures

Definition at line 214 of file conv.h.

◆ nPres2Ioniz

long int t_conv::nPres2Ioniz

this will count the number of ionizations in one call from ConvPresTempEdenIoniz

Definition at line 152 of file conv.h.

◆ nTeFail

long int t_conv::nTeFail

nTeFail number of temperature failures

Definition at line 208 of file conv.h.

◆ nTotalFailures

long int t_conv::nTotalFailures

total number of all falures, used to trigger abort

Definition at line 205 of file conv.h.

◆ nTotalIoniz

long int t_conv::nTotalIoniz

counts the number of calls to conv base after iteration starts can be used to determine very first pass through an iteration reset to zero at start of each iteration in a simulation

Definition at line 166 of file conv.h.

◆ nTotalIoniz_start

long int t_conv::nTotalIoniz_start

the same counter but set to zero after the initial solution is converged, so this is a measure of the number of calls within true zones

Definition at line 171 of file conv.h.

◆ PressureErrorAllowed

realnum t_conv::PressureErrorAllowed

this is relative error in the pressure, initialized to 0.02 in reset with set pressure error command

Definition at line 272 of file conv.h.

◆ sigma_dCmHdT

double t_conv::sigma_dCmHdT

1-sigma uncertainty in numerical estimate of d(cooling-heating)/dT

Definition at line 291 of file conv.h.


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