32 char chNumbers[31][3] = {
"0",
"1",
"2",
"3",
"4",
"5",
"6",
"7",
"8",
"9",
33 "10",
"11",
"12",
"13",
"14",
"15",
"16",
"17",
"18",
"19",
34 "20",
"21",
"22",
"23",
"24",
"25",
"26",
"27",
"28",
"29",
"30"};
59 fprintf( ioPUN,
"%12.4e\t%10.2e\t%10.2e\t%10.2e\t%10.2e\t%4.4s\n",
76 fprintf( ioPUN,
"%.5e\t%.3e\t%.3e\n",
103 long int k, nu_hi , nskip;
125 nskip =
MAX2( 1, nskip );
127 for( i=j; i<nu_hi; i+=nskip )
130 for( k=0; k<nskip; ++k )
149 ener3 = 1e24*
POW3(ener);
151 "%12.4e%12.4e%12.4e%12.4e%12.4e\n",
161 ener3 = 1e24*
POW3(ener);
163 "%12.4e%12.4e%12.4e%12.4e%12.4e\n",
181 for( ion=0; ion<=nelem; ++ion )
184 long nelec = nelem+1 - ion;
189 for(
long nshell=0; nshell <
Heavy.
nsShells[nelem][ion]; nshell++ )
229 strcat( chFileName , chNumbers[1] );
232 strcat( chFileName ,
".opc" );
235 ioFILENAME =
open_data( chFileName,
"w" );
246 fclose( ioFILENAME );
264 strcat( chFileName , chNumbers[1] );
267 strcat( chFileName ,
".opc" );
270 ioFILENAME =
open_data( chFileName,
"w" );
280 fclose( ioFILENAME );
291 strcat( chFileName , chNumbers[2] );
294 strcat( chFileName ,
".opc" );
297 ioFILENAME =
open_data( chFileName,
"w" );
309 fclose( ioFILENAME );
347 for( ion=0; ion <= nelem; ion++ )
349 for( j=0; j < (nelem + 2); j++ )
366 strcat( chFileName , chNumbers[ion+1] );
369 strcat( chFileName ,
".opc" );
372 ioFILENAME =
open_data( chFileName,
"w" );
387 fclose( ioFILENAME );
400 fprintf(
ioQQQ,
"\n\nThe opacity files have been successfully created.\n");
401 fprintf(
ioQQQ,
"The files have names that start with the first 4 characters of the element name.\n");
402 fprintf(
ioQQQ,
"There is one file per ion and the number after the element name indicates the ion.\n");
403 fprintf(
ioQQQ,
"The energies are in eV and the cross sections in megabarns.\n");
405 fprintf(
ioQQQ,
"The data only extend to the highest energy in this continuum source.\n");
void OpacityAdd1Element(long int ipZ)
realnum punarg[LIMPUN][3]
FILE * open_data(const char *fname, const char *mode, access_scheme scheme)
long int ipElement[LIMELM][LIMELM][7][3]
STATIC void prtPunOpacSummary(void)
void PrintE93(FILE *, double)
const int FILENAME_PATH_LENGTH_2
vector< string > chContLabel
long ipFineCont(double energy_ryd)
double * eeFreeFreeOpacity
double anu(size_t i) const
t_elementnames elementnames
t_iso_sp iso_sp[NISO][LIMELM]
long int nflux_with_check
double xIonDense[LIMELM][LIMELM+1]
void save_opacity(FILE *io, long int np)
long nelec_eject(long n, long i, long ns) const
long int nsShells[LIMELM][LIMELM]
char chElementNameShort[LIMELM][CHARS_ELEMENT_NAME_SHORT]
double AnuUnit(realnum energy)
realnum gas_phase[LIMELM]
string makeChemical(long nelem, long ion)
#define DEBUG_ENTRY(funcname)
int fprintf(const Output &stream, const char *format,...)
void OpacityAdd1SubshellInduc(long int ipOpac, long int low, long int ihi, double a, double b, char chStat)
long int ipHeavy[LIMELM][LIMELM]