↑ Return to Network calculations

Getting started

Update reaction and nuclide data

Recent version of REACLIB can be downloaded from https://groups.nscl.msu.edu/jina/reaclib/db
/library.php
already in XML format. However the nuclide and reaction data
are provided in two separate files that have to be merged into one file. This can be done by running:

./merge_net nuclide_data.xml reaction_data.xml output.xml

in nucnet-tools/vendor/libnucnet/0.15/examples directory.

Preparing input file

To convert a text file (initial_mass_fractions.txt) containing Z, A and X for all the seed nuclides into an input XML file (pp_init_abund.xml) for the calculations go to example/misc folder and run:

./create_zone_xml_from_text ../../data_pub/my_net.xml initial_mass_fractions.txt init_abund.xml "mass fractions"

To add properties to the pp_init_abund.xml file and create a proper input file pp_input.xml for the code run:

./add_properties_to_zone_xml ../../data_pub/my_net.xml pp_init_abund.xml 0 0 0 properties.txt input.xml

Where properties.txt has a series of

property name
property value

Running the code – examples

CNO burning

Edit input.xml so that tau = 0., t9 = T=109 K = 0.04, rho = 10., steps = 5, and tend = 1.e15. Also change the initial species to “h1” with z = 1, a = 1, and x = 0.98 and “c12” with z = 6, a = 12, and x = 0.02. Now run the calculation:

./run_single_zone ../../data_pub/my_net.xml ../../data_pub/zone.xml out_cno.xml

This leaves an XML output file called out_cno.xml. You can choose to add a zone XPATH “[z <=
15]" to speed the calculation up:

./run_single_zone ../../data_pub/my_net.xml ../../data_pub/zone.xml out_cno.xml "[z <= 15]"

Get a table with t, t9, and rho in the time steps by typing:

./print_properties ../network/out_cno.xml time t9 rho

Now get the hydrogen, helium-4, carbon-12, and nitrogen-14 mass fractions in the timesteps:

./print_mass_fractions_in_zones c12 n14 ../network/out_cno.xml h1 he4

He burning

Edit input.xml so that tau = 0., t9 = 0.3, rho = 103 g/cc, and tend = 1.e12. Choose initial mass fractions such that X(4He) = 0.98, X(14N) = 0.018, and X(56Fe) = 0.002. Run the calculation as above but replace the out_cno.xml with out_he.xml. You can choose to add a zone xpath “[z <= 40]" to speed the calculation up.