diff options
-rwxr-xr-x | calc_coolfunc.py | 24 | ||||
-rw-r--r-- | coolfunc.conf | 28 |
2 files changed, 14 insertions, 38 deletions
diff --git a/calc_coolfunc.py b/calc_coolfunc.py index 6d57319..1ed0063 100755 --- a/calc_coolfunc.py +++ b/calc_coolfunc.py @@ -4,22 +4,26 @@ # # Aaron LI # Created: 2016-06-19 -# Updated: 2016-06-19 +# Updated: 2016-06-27 +# +# Change logs: +# 2016-06-27: +# * Minor style fixes +# * Change 'tprofile' to 't_profile' # """ -Calculate the 'cooling function' profile with respect to the -given 'temperature profile' and the average abundance, redshift, +Calculate the *cooling function* profile with respect to the +given *temperature profile* and the average abundance, redshift, and column density nH, using the XSPEC model 'wabs*apec'. -Sample config file: +Sample configuration file: ------------------------------------------------------------ -# Configuration file for `calc_coolfunc.py` -# Aaron LI -# 2016-06-19 +## Configuration file for `calc_coolfunc.py` +## 2016-06-27 # temperature profile fitted & extrapolated by model: [r, T] -tprofile = tprofile.txt +t_profile = t_profile.txt # average abundance (unit: solar) abundance = 0.5 @@ -85,7 +89,7 @@ dummyrsp 0.01 100.0 4096 linear model wabs*apec & %(nh)s & 1.0 & %(abundance)s & %(redshift)s & %(apec_norm)s & /* # input and output files -set tpro_fn "%(tprofile)s" +set tpro_fn "%(t_profile)s" set cf_fn "%(coolfunc)s" if { [ file exists $cf_fn ] } { exec rm -fv $cf_fn @@ -158,7 +162,7 @@ def main(): "prog_name": os.path.basename(sys.argv[0]), "cur_date": datetime.now().isoformat(), # - "tprofile": config["tprofile"], + "t_profile": config["t_profile"], "abundance": config.as_float("abundance"), "abund_table": config.get("abund_table", "grsa"), "redshift": redshift, diff --git a/coolfunc.conf b/coolfunc.conf deleted file mode 100644 index d20c96e..0000000 --- a/coolfunc.conf +++ /dev/null @@ -1,28 +0,0 @@ -# Configuration file for `calc_coolfunc.py` -# Aaron LI -# 2016-06-19 - -# temperature profile fitted & extrapolated by model: [r, T] -tprofile = tprofile.txt - -# average abundance (unit: solar) -abundance = 0.5 - -# abundance table (default: grsa) -abund_table = grsa - -# redshift of the object -redshift = 0.0137 - -# H column density (unit: 10^22 cm^-2) -nh = 0.03 - -# energy range within which to calculate the cooling function (unit: keV) -energy_low = 0.7 -energy_high = 7.0 - -# output file of the XSPEC script for cooling function calculation -xspec_script = coolfunc.xcm - -# output file of the cooling function profile: [r, CF] -coolfunc = coolfunc_profile.txt |