28 fprintf(
ioQQQ,
"The COMPILE OPACITIES command is currently not supported\n" );
52 "Success!! Created file opacity.opc\nMake sure this is on the path.\n" );
109 if(
strstr_s(chRead.c_str(),
".rfi") != NULL ||
strstr_s(chRead.c_str(),
".mix") != NULL )
111 strcpy(chRFI,chRead.c_str());
113 else if(
strstr_s(chRead.c_str(),
".szd") != NULL )
115 strcpy(chSZD,chRead.c_str());
119 fprintf(
ioQQQ,
" filename %s has unknown extension, sorry\n" , chRead.c_str() );
130 if(
strstr_s(chRead.c_str(),
".rfi") != NULL ||
strstr_s(chRead.c_str(),
".mix") != NULL )
132 strcpy(chRFI,chRead.c_str());
134 else if(
strstr_s(chRead.c_str(),
".szd") != NULL )
136 strcpy(chSZD,chRead.c_str());
140 fprintf(
ioQQQ,
" filename %s has unknown extension, sorry\n" , chRead.c_str() );
146 if( chRFI[0] ==
'\0' )
152 strcpy(chRFI ,
"ac1-amcarb.rfi" );
158 strcpy(chRFI ,
"be1-amcarb.rfi" );
161 else if( p.
nMatch(
"GRAP") )
164 strcpy(chRFI ,
"graphite.rfi" );
166 else if( p.
nMatch(
"SILI" ) )
169 strcpy(chRFI ,
"silicate.rfi" );
171 else if( p.
nMatch(
" SIC" ) )
174 strcpy(chRFI ,
"sic.rfi" );
176 else if( p.
nMatch(
" PAH" ) )
179 strcpy(chRFI ,
"pah1.rfi" );
183 strcpy(chRFI ,
"grey.rfi" );
188 if( chSZD[0] ==
'\0' )
193 strcpy(chSZD ,
"0m010.szd" );
197 strcpy(chSZD ,
"0m100.szd" );
201 strcpy(chSZD ,
"1m000.szd" );
203 else if( p.
nMatch(
"ORIO" ) )
205 strcpy(chSZD ,
"orion.szd" );
207 else if( p.
nMatch(
" ISM" ) )
209 strcpy(chSZD ,
"ism.szd" );
214 strcpy(chSZD ,
"ab08.szd" );
219 strcpy(chSZD ,
"c15.szd" );
224 strcpy(chSZD ,
"c120.szd" );
230 if( chRFI[0] ==
'\0' && chSZD[0] !=
'\0' )
232 fprintf(
ioQQQ,
"Sorry, but I did not recognize a refractive index file.\n");
233 fprintf(
ioQQQ,
"Supply a file name between quotes or one of the following ");
234 fprintf(
ioQQQ,
"keywords: ac1-amcarb, be1-amcarb, graphite, silicate, grey, pah\n");
238 if( chSZD[0] ==
'\0' && chRFI[0] !=
'\0' )
240 fprintf(
ioQQQ,
"Sorry, but I did not recognize a size distribution file.\n");
241 fprintf(
ioQQQ,
"Supply a file name between quotes or one of the following ");
242 fprintf(
ioQQQ,
"keywords: 0m010, 0m100, 1m000, ism, orion, c15, c120, ab08\n");
247 if( chRFI[0] ==
'\0' && chSZD[0] ==
'\0' )
320 fprintf(
ioQQQ,
"Number of bins must be positive. Sorry.\n");
328 "Success!! Created grain opacity file(s).\nMake sure this directory is on the path.\n" );
340 else if( p.
nMatch(
"HE-L") )
344 fprintf(
ioQQQ,
"Sorry, but I did not recognize an iso sequence.\n");
345 fprintf(
ioQQQ,
"The available options are H-like and He-like.\nSorry.\n");
354 for( nelem = ipISO; nelem <
LIMELM; nelem++)
371 else if( p.
nMatch(
"STAR") )
373 bool lgProblems =
false;
390 if( ( ptr =
strstr_s( chRead.c_str(),
"." ) ) != NULL )
392 if( strncmp( ptr,
".asc", 4 ) == 0 )
396 else if( strncmp( ptr,
".stb", 4 ) == 0 )
403 else if( p.
nMatch(
"NEBU" ) )
408 string chASC(chRead.c_str(), ptr);
412 lgProblems = lgProblems ||
GridCompile( chASC.c_str() );
416 fprintf(
ioQQQ,
" I did not recognize this file extension: %s\n", ptr );
422 fprintf(
ioQQQ,
" I did not find any file extension: %s\n", chRead.c_str() );
460 fprintf(
ioQQQ,
"\n PROBLEM - No ascii files were found!\n" );
461 fprintf(
ioQQQ,
" Did you change directory to where the stellar atmosphere files are?\n" );
462 fprintf(
ioQQQ,
" This command will only work on files in the local directory. Sorry.\n" );
476 fprintf(
ioQQQ,
", %d file(s) skipped after failure", nSkip );
483 fprintf(
ioQQQ,
"\n Problems occurred during the compilation - check output.\n" );
487 fprintf(
ioQQQ,
"\n The compilation was successful!\n" );
495 fprintf(
ioQQQ,
" One of the keywords, GRAINS, RECO COEF, or STARS, must appear.\n" );
bool nMatch(const char *chKey) const
int WernerCompile(process_counter &pc)
bool GridCompile(const char *InName)
const int FILENAME_PATH_LENGTH_2
void OpacityCreateAll(void)
bool lgCompileRecomb[NISO]
int TlustyCompile(process_counter &pc)
int GetQuote(string &chLabel)
const char * strstr_s(const char *haystack, const char *needle)
bool nMatchErase(const char *chKey)
NORETURN void StringError() const
int RauchCompile(process_counter &pc)
t_iso_sp iso_sp[NISO][LIMELM]
void ParseCompile(Parser &p)
void Badnell_rec_init(void)
void iso_update_num_levels(long ipISO, long nelem)
long int n_HighestResolved_max
void ContCreatePointers(void)
int AtlasCompile(process_counter &pc)
int Kurucz79Compile(process_counter &pc)
bool StarburstCompile(process_counter &pc)
void mie_write_opc(const char *, const char *, long int)
int CoStarCompile(process_counter &pc)
#define LIKE_RREC_MAXN(A_)
int MihalasCompile(process_counter &pc)
#define DEBUG_ENTRY(funcname)
int fprintf(const Output &stream, const char *format,...)
int WMBASICCompile(process_counter &pc)
bool StarburstInitialize(const char chInName[], const char chOutName[], sb_mode mode)