Пример #1
0
# Locate datasets
base_dir = '../externals/atomneb/'
data_dir = os.path.join('atomic-data', 'chianti70')
data_rc_dir = os.path.join('atomic-data-rc')
atom_elj_file = os.path.join(base_dir, data_dir, 'AtomElj.fits')
atom_omij_file = os.path.join(base_dir, data_dir, 'AtomOmij.fits')
atom_aij_file = os.path.join(base_dir, data_dir, 'AtomAij.fits')
atom_rc_sh95_file = os.path.join(base_dir, data_rc_dir, 'rc_SH95.fits')

atom = 'h'
ion = 'ii'  # H I Rec
hi_rc_data = atomneb.read_aeff_sh95(atom_rc_sh95_file, atom, ion)

atom = 'o'
ion = 'iii'  # [O III]
o_iii_elj = atomneb.read_elj(atom_elj_file, atom, ion,
                             level_num=5)  # read Energy Levels (Ej)
o_iii_omij = atomneb.read_omij(atom_omij_file, atom,
                               ion)  # read Collision Strengths (Omegaij)
o_iii_aij = atomneb.read_aij(atom_aij_file, atom,
                             ion)  # read Transition Probabilities (Aij)

levels5007 = '3,4/'
temperature = np.float64(10000.0, )
density = np.float64(5000.0)
iobs5007 = np.float64(1200.0)
abb5007 = np.float64(0.0)

emis = pyequib.calc_emissivity(temperature=temperature,
                               density=density,
                               atomic_levels=levels5007,
                               elj_data=o_iii_elj,
# read Collision Strengths (Omegaij) list
omij_data_list = atomneb.read_omij_list(atom_omij_file)
# read Transition Probabilities (Aij) list
aij_data_list = atomneb.read_aij_list(atom_aij_file)

# read Energy Levels (Ej) references
elj_data_reference = atomneb.read_elj_references(atom_elj_file)
# read Collision Strengths (Omegaij) references
omij_data_reference = atomneb.read_omij_references(atom_omij_file)
# read Transition Probabilities (Aij) references
aij_data_reference = atomneb.read_aij_references(atom_aij_file)

atom = 'o'
ion = 'iii'
# read Energy Levels (Ej) of O III upto level number 6
oiii_elj_data = atomneb.read_elj(atom_elj_file, atom, ion, level_num=6)
# print Levels of O III
print(oiii_elj_data['j_v'])
# print Energy Levels (cm-1) of O III
print(oiii_elj_data['ej'])

# get citations for Energy Levels (Ej) Reference L7288
citation = atomneb.get_elj_reference_citation(atom_elj_file, 'L7288')
# print citations for Energy Levels (Ej) Reference L7288
print(citation)

atom = 'o'
ion = 'iii'
reference = 'SSB14'
# read Collision Strengths (Omegaij) of O III from Reference SSB14
oiii_omij_data = atomneb.read_omij(atom_omij_file,