// genesis include doi_example.g /* Main Body of the Simulation */ function run_psearch(number, reactionkf, reactionkb, Acolor, Bcolor) int number float reactionkf float reactionkb str Acolor str Bcolor str Aplotname = {"/graphs/conc1/xoverlay/A.Co#0." @ {number}} str Bplotname = {"/graphs/conc1/xoverlay/B.Co#0." @ {number}} setfield /kinetics/reaction kf {reactionkf} setfield /kinetics/reaction kb {reactionkb} /* Display Some Message before Running */ echo "Running Simulation with kf = " {reactionkf} "and kb =" {reactionkb} step {MAXTIME} -time /* Change the Colors of the Graphs */ setfield {Aplotname} fg {Acolor} setfield {Bplotname} fg {Bcolor} /* Save the Time Course of A and B with Varying kf and kb */ do_save_named_plot {Aplotname} {"Atimecourse_kf" @ {reactionkf} @ "_kb" @ {reactionkb} @ ".plot"} do_save_named_plot {Bplotname} {"Btimecourse_kf" @ {reactionkf} @ "_kb" @ {reactionkb} @ ".plot"} reset end /* Parameter List */ function select_plist(select_num) int select_num if (select_num == 0) run_psearch {select_num} 0.2 0.1 "#FF4444" "#4444FF" elif (select_num == 1) run_psearch {select_num} 0.5 0.1 "#FF8888" "#8888FF" elif (select_num == 2) run_psearch {select_num} 1.0 0.1 "#FFCCCC" "#CCCCFF" elif (select_num == 3) run_psearch {select_num} 0.05 0.1 "#CC0000" "#0000CC" elif (select_num == 4) run_psearch {select_num} 0.02 0.1 "#880000" "#000088" elif (select_num == 5) run_psearch {select_num} 0.01 0.1 "#440000" "#000044" end end /* running simulation with default parameter values */ step {MAXTIME} -time do_save_named_plot /graphs/conc1/A.Co "Atimecourse.plot" do_save_named_plot /graphs/conc1/B.Co "Btimecourse.plot" reset select_plist 0 select_plist 1 select_plist 2 select_plist 3 select_plist 4 select_plist 5 echo "Simulation has done!"