Commit bf41b73e authored by Guang's avatar Guang Committed by Guang
Browse files

xray.py optimization

parent a3ec3f26
......@@ -105,7 +105,7 @@ class Xray(SedModule):
"""
# Stellar info.
# star formation rate, units: M_sun/yr
sfr = sed.info['sfh.sfr100Myrs']
sfr = sed.info['sfh.sfr']
# stellar mass, units: 1e10 M_sun
mstar = sed.info['stellar.m_star']/1e10
# log stellar age, units: Gyr
......@@ -153,9 +153,10 @@ class Xray(SedModule):
sed.add_info("xray.agn_Lx_2to10keV", l_agn_xray_2to10keV, True)
sed.add_info("xray.agn_Lnu_2keV", Lnu_2keV, True)
# Add the SED components
sed.add_contribution('xray.hot_gas', self.wave, self.lumin_hotgas * l_hotgas_xray_0p5to2keV)
sed.add_contribution('xray.high_mass_binary', self.wave, self.lumin_xrb * l_hmxb_xray_2to10keV)
sed.add_contribution('xray.low_mass_binary', self.wave, self.lumin_xrb * l_lmxb_xray_2to10keV)
sed.add_contribution('xray.galaxy', self.wave,
self.lumin_hotgas*l_hotgas_xray_0p5to2keV + \
self.lumin_xrb*l_hmxb_xray_2to10keV + \
self.lumin_xrb*l_lmxb_xray_2to10keV)
sed.add_contribution('xray.agn_corona', self.wave, self.lumin_corona * L_lam_2keV)
# SedModule to be returned by get_module
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment