6 from class_files.reaclib_class
import reaclib
7 import matplotlib.pyplot
as plt
19 reaclib_file_path =
" INSERT REACLIB FILE PATH "
20 reaclib_file_update_path =
" INSERT MORE RECENT REACLIB FILE PATH "
24 r_testclass.read_reaclib()
37 r_testclass.test_reaclib()
39 r_testclass.get_rate_error_html(
'reaclib_errors.html')
41 r_testclass.drop_errors()
48 reactants = [
'he4',
'c12']
52 figure = r_testclass.plot_rate(reactants,products)
65 print(
'Overview of contained reactions:')
66 print((r_testclass.get_statistics()))
79 r_testclass.update(reaclib_file_update_path,ignore_label=
False)
80 print((r_testclass.get_statistics()))
82 r_testclass.save_reaclib(
'updated_reaclib.dat')
85 n_gamma = r_testclass.get_dataframe(reaction_type=
'n-gamma')
89 n_gamma[
'a0'] = n_gamma[
'a0'].apply(
lambda x: x*10.)
91 r_testclass.update(dataframe=n_gamma)
97 crit_low_temp_dataframe = r_testclass.get_critical_low_temperature_rates(min_temperature=1e-3,amount_points=20,max_rate=1.e100)
99 print((
'Amount critical low temperature rates : ' + str(crit_low_temp_dataframe.count()[0])))
100 r_testclass.save_reaclib(
'crit_lowtemp.dat',dataframe = crit_low_temp_dataframe)