Files and scripts for MC reaction rate uncertainty simulations
-
Start by copying the files and folders from here to the ppn run directory.
Prepare a list (the text file "reaction_factors.txt") of isotopes whose (n,g), (a,n), or (n,p) reaction rates are to be varied with their maximum variation factors in the last columns in the following format:
C 13 1.190476190 (a,n)
N 14 1.067216981 (n,p)
PROT 1.078740157 (n,g)
H 2 1.066666667 (n,g)
C 12 1.064935065 (n,g)(n,g) reactions can easily be replaced with other reactions, e.g. (p,g), etc. Use the reaction list order found in the networksetup file.
-
The python program "prep_mc_network.py" located in MC_setup uses this list to generate a large number (say, "nmc=10000") of "networksetup_imc.txt" files, where "imc=1,nmc", with randomly selected multiplication factors for the listed reaction rates from a "networksetup.txt" file that is used in the benchmark model.
Don't forget to copy networksetup.txt to networksetup_0.txt AFTERWARDS!
This program also generates text file "reaction_factors_multi.txt" that contains arrays of the applied variation factors for each of the MC runs.
-
Run the shell script onezone_MC_sims.sh that cycles over "imc=1,nmc" to copy the generated "networksetup_imc.txt" files one after another to your ppn run directory and starts the runs.
The file ppn_physics.input must have ININET=3, so that ppn.exe uses the current file networksetup.txt.
Check the content of onezone_MC_sims.sh to see if the names of the run and result directories are correct.
-
Then use a jupyter notebook to read the MC simulation data and analyze them.