Cloudy
Spectral Synthesis Code for Astrophysics
Loading...
Searching...
No Matches
prt.h
Go to the documentation of this file.
1/* This file is part of Cloudy and is copyright (C)1978-2025 by Gary J. Ferland and
2 * others. For conditions of distribution and use see copyright notice in license.txt */
3
4#ifndef PRT_H_
5#define PRT_H_
6
7#include "module.h"
8#include "container_classes.h"
9#include "lines.h"
10
11class TransitionProxy;
12
13//* Maximum number of columns in output print
14const long NCOLMAX=132;
15
17void PrtZone(void);
18
20void PrtComment(void);
21
23void PrtFinal(void);
24
25
27void SetPrintLineCol ();
28
33void prt_line_err( FILE *ioOUT, const LineID& lineid );
34
35/* prt_line_inlist print line suitable for output list, label not enclosed in quotation marks
36\param *ioOUT output file handle
37\param *label line label
38\param twav line wavelength
39 */
40void prt_line_inlist ( FILE *ioOUT, const char *label, t_wavl twav );
41
44void PrtHeader(void);
45
54 FILE * io,
55 bool lgPrintAll,
56 bool lgPrintIndex
57 );
58
60void prtmet(void);
61
68void PrtMeanIon( char chType ,
69 bool lgDensity,
70 FILE *);
71
75double PrtLineSum(void);
76
79void PrtLinePres(FILE *ioPRESSURE);
80
85void PrtColumns(
86 FILE *ioMEAN );
87
90
93
96void PrtAllTau(void);
97
98class t_prt_matrix : public module {
99public:
102 string species;
104 vector<long> speciesLevelList;
105 bool lgLevelsResolved = false;
106
107 void zero();
109
110 const char *chName() const
111 {
112 return "prt_matrix";
113 }
114
115 void setSpecies( const string &sspec );
116 void resolveLevels();
117 void prtRates( const long numLevels,
118 const multi_arr<double,2,C_TYPE> &matrix,
119 valarray<double> &b );
120};
121
123struct t_blend {
124 string chLabel;
128 vector<LineID> component;
129 t_blend() : chLabel("Blnd"), lgQuiet(false), lgIgnore(false) {}
130};
131
132struct t_prt {
133
136
140
144
148
152
156
160
163
167
170
174
177
181
185
188
197
201
202 /* flag set with print continuum index command, to identify all lines
203 * that lie within a continuum cell */
205 /* these are lower and upper limits to the energy range in Rydbergs.
206 * they are the first and second number on the command line, lower and
207 * upper bounds of the code are used if not specified */
210
216
219
222
225
230
233
235 long int nstart;
236
239
242
244
251
255
261 long int nPrnLineCell;
262
266
270
274
280
281 /* Generate output in HTML format */
283
293 long int ipeak;
295
296 long int nzdump;
297
300
302 vector<t_blend> blend;
303
306
308 {
309 // make sure this has the correct value before main() starts
310 // this is needed by check_data() and possibly others
311 lgPrintTime = true;
312 // this needs to be set before the code starts reading the input script
313 lgIncludeBlends = true;
314 }
315};
316extern t_prt prt;
317
318
319
320struct t_line_col : public module
321{
322 const char* chName() const
323 {
324 return "prt_linecol";
325 }
326 void zero();
328
331
334
338
342
345
347 string col_gap;
348};
349extern struct t_line_col prt_linecol;
350
351#endif /* PRT_H_ */
const int LIMELM
Definition cddefines.h:318
float realnum
Definition cddefines.h:127
Definition lines.h:15
Definition transition.h:24
t_wavl twav() const
Definition transition.h:455
module()
Definition module.h:29
Definition container_classes.h:916
Definition prt.h:98
const char * chName() const
Definition prt.h:110
void zero()
Definition prt.cpp:120
void comment(t_warnings &)
Definition prt.h:108
void setSpecies(const string &sspec)
Definition prt.cpp:128
void resolveLevels()
Definition prt.cpp:150
bool lgLevelsResolved
Definition prt.h:105
string speciesLevels
Definition prt.h:103
vector< long > speciesLevelList
Definition prt.h:104
string species
Definition prt.h:102
void prtRates(const long numLevels, const multi_arr< double, 2, C_TYPE > &matrix, valarray< double > &b)
Definition prt.cpp:161
Definition warnings.h:11
Definition cddefines.h:1299
t_line_col prt_linecol
Definition prt.cpp:15
t_prt prt
Definition prt.cpp:14
void PrtFinal(void)
Definition prt_final.cpp:550
void PrtZone(void)
Definition prt_zone.cpp:35
void PrtColumns(FILE *ioMEAN)
Definition prt_columns.cpp:14
void SetPrintLineCol()
Definition prt.cpp:28
void PrtMeanIon(char chType, bool lgDensity, FILE *)
Definition prt_meanion.cpp:11
void PrtHeader(void)
Definition prt_header.cpp:17
void prtmet(void)
Definition prt_met.cpp:19
void CloudyPrintReference()
Definition service.cpp:1807
void prt_line_inlist(FILE *ioOUT, const char *label, t_wavl twav)
Definition prt.cpp:112
void DatabasePrintReference()
Definition service.cpp:1824
double PrtLineSum(void)
Definition prt_linesum.cpp:50
void PrtLinePres(FILE *ioPRESSURE)
Definition prt_linepres.cpp:16
void prt_line_err(FILE *ioOUT, const LineID &lineid)
Definition prt.cpp:103
void PrtAllTau(void)
Definition prt_alltau.cpp:15
void PrtComment(void)
Definition prt_comment.cpp:66
const long NCOLMAX
Definition prt.h:14
void prt_LineLabels(FILE *io, bool lgPrintAll, bool lgPrintIndex)
Definition prt.cpp:42
vector< LineID > component
Definition prt.h:128
t_blend()
Definition prt.h:129
bool lgQuiet
Definition prt.h:126
string chLabel
Definition prt.h:124
t_wavl wave
Definition prt.h:125
bool lgIgnore
Definition prt.h:127
Definition prt.h:321
int absint_len
Definition prt.h:330
string relint_outrange
Definition prt.h:344
int column_len
Definition prt.h:337
void comment(t_warnings &)
Definition prt.h:327
string col_gap
Definition prt.h:347
int relint_len
Definition prt.h:333
int col_gap_len
Definition prt.h:341
void zero()
Definition prt.cpp:17
const char * chName() const
Definition prt.h:322
Definition prt.h:132
bool lgPrtLineLog
Definition prt.h:269
bool lgPrintBlock
Definition prt.h:135
bool lgSourceTransmitted
Definition prt.h:213
bool lgPrnInwd
Definition prt.h:196
realnum PrtTauFnt
Definition prt.h:187
realnum fx1ryd
Definition prt.h:292
long int nzdump
Definition prt.h:296
realnum powion
Definition prt.h:286
bool lgPrtBN
Definition prt.h:218
bool lgDiffuseOutward
Definition prt.h:215
bool lgPrintBlockIntrinsic
Definition prt.h:139
bool lgSurfaceBrightness
Definition prt.h:184
bool lgPrnIsoCollapsed
Definition prt.h:200
bool lgPrintBlockEmergent
Definition prt.h:143
realnum pradio
Definition prt.h:291
t_prt()
Definition prt.h:307
bool lgFntSet
Definition prt.h:254
t_wavl wlSort2
Definition prt.h:155
bool lgPrtShort
Definition prt.h:224
bool lgPrintLineCumulative
Definition prt.h:273
bool lgPrtTau
Definition prt.h:176
bool lgPrintLineAirWavelengths
Definition prt.h:279
realnum xpow
Definition prt.h:287
bool lgSortLineIntensity
Definition prt.h:151
bool lgPrtArry[LIMELM]
Definition prt.h:241
bool lgPrtLastIt
Definition prt.h:221
bool lgPrnColl
Definition prt.h:195
t_wavl wlSort1
Definition prt.h:155
bool lgDiffuseInward
Definition prt.h:214
bool lgOnlyZone
Definition prt.h:227
bool lgPrnPump
Definition prt.h:193
realnum lgPrtContIndices_lo_E
Definition prt.h:208
bool lgPrintHTML
Definition prt.h:282
bool lgOnlyHead
Definition prt.h:229
realnum GammaLumin
Definition prt.h:294
realnum lgPrtContIndices_hi_E
Definition prt.h:209
t_prt_matrix matrix
Definition prt.h:243
bool lgPrintColumns
Definition prt.h:162
bool lgPrtStart
Definition prt.h:232
bool lgPrintFluxEarth
Definition prt.h:180
realnum qx
Definition prt.h:285
bool lgSortLineWavelength
Definition prt.h:151
realnum TooFaint
Definition prt.h:249
realnum pbal
Definition prt.h:288
bool lgPrnHeat
Definition prt.h:194
bool lgPrtCitations
Definition prt.h:299
bool lgPrintTime
Definition prt.h:166
bool lgPrintHeating
Definition prt.h:238
vector< t_blend > blend
Definition prt.h:302
bool lgIncludeBlends
Definition prt.h:305
bool lgSourceReflected
Definition prt.h:212
bool lgPrnAges
Definition prt.h:169
realnum qgam
Definition prt.h:290
realnum q
Definition prt.h:289
long int nPrnLineCell
Definition prt.h:261
bool lgPrtContIndices
Definition prt.h:204
long int nstart
Definition prt.h:235
bool lgPrtMaser
Definition prt.h:173
bool lgSortLines
Definition prt.h:147
bool lgPrnLineCell
Definition prt.h:258
bool lgSurfaceBrightness_SR
Definition prt.h:184
long int ipeak
Definition prt.h:293
bool lgPrtLineArray
Definition prt.h:265
bool lgFaintOn
Definition prt.h:250