aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2017-09-01 15:31:24 +0800
committerAaron LI <aly@aaronly.me>2017-09-01 15:31:24 +0800
commitfb559ff794b79246fe64c3f0a11ddc7c55d9a9a8 (patch)
treecc7b97ced86f74e2ec8c88a84a698b0bc46afb1f
parente35fc3ce66a7dfe0099a17fdab83952460f52f62 (diff)
downloadfg21sim-fb559ff794b79246fe64c3f0a11ddc7c55d9a9a8.tar.bz2
Update "Fnu_to_Tb_fast()" to "Fnu_to_Tb()"
-rw-r--r--fg21sim/extragalactic/clusters/helper.py4
-rw-r--r--fg21sim/extragalactic/pointsources/fr1.py4
-rw-r--r--fg21sim/extragalactic/pointsources/fr2.py4
-rw-r--r--fg21sim/extragalactic/pointsources/radioquiet.py2
-rw-r--r--fg21sim/extragalactic/pointsources/starbursting.py2
-rw-r--r--fg21sim/extragalactic/pointsources/starforming.py2
-rw-r--r--fg21sim/galactic/snr.py4
7 files changed, 11 insertions, 11 deletions
diff --git a/fg21sim/extragalactic/clusters/helper.py b/fg21sim/extragalactic/clusters/helper.py
index 26146cc..b54340c 100644
--- a/fg21sim/extragalactic/clusters/helper.py
+++ b/fg21sim/extragalactic/clusters/helper.py
@@ -40,7 +40,7 @@ from ...share import CONFIGS, COSMO
from ...utils.units import (Units as AU,
Constants as AC,
UnitConversions as AUC)
-from ...utils.convert import Fnu_to_Tb_fast
+from ...utils.convert import Fnu_to_Tb
from ...utils.draw import circle
from ...utils.transform import circle2ellipse
@@ -398,7 +398,7 @@ def calc_brightness_mean(flux, frequency, omega, pixelsize=None):
omega = pixelsize ** 2 # [arcsec^2]
logger.warning("Object sky coverage < 1 pixel; force to be 1 pixel")
- Tb = [Fnu_to_Tb_fast(Fnu, omega, freq)
+ Tb = [Fnu_to_Tb(Fnu, omega, freq)
for Fnu, freq in zip(np.array(flux, ndmin=1),
np.array(frequency, ndmin=1))]
if len(Tb) == 1:
diff --git a/fg21sim/extragalactic/pointsources/fr1.py b/fg21sim/extragalactic/pointsources/fr1.py
index 49969e0..4d337eb 100644
--- a/fg21sim/extragalactic/pointsources/fr1.py
+++ b/fg21sim/extragalactic/pointsources/fr1.py
@@ -321,11 +321,11 @@ class FRI(BasePointSource):
npix = hp.nside2npix(self.nside)
sr_to_arcsec2 = (np.rad2deg(1) * 3600) ** 2 # [sr] -> [arcsec^2]
core_area = 4 * np.pi / npix * sr_to_arcsec2 # [arcsec^2]
- Tb_core = convert.Fnu_to_Tb_fast(flux_core, core_area, freq) # [K]
+ Tb_core = convert.Fnu_to_Tb(flux_core, core_area, freq) # [K]
# lobe
lumo_lobe = lumo_151 * (1 - ratio_obs) / (1 + ratio_obs) # [Jy]
flux_lobe = (freq / freq_ref)**(-0.75) * lumo_lobe
- Tb_lobe = convert.Fnu_to_Tb_fast(flux_lobe, area, freq) # [K]
+ Tb_lobe = convert.Fnu_to_Tb(flux_lobe, area, freq) # [K]
Tb = [Tb_core, Tb_lobe]
return Tb
diff --git a/fg21sim/extragalactic/pointsources/fr2.py b/fg21sim/extragalactic/pointsources/fr2.py
index 2fd1f3e..ec565d1 100644
--- a/fg21sim/extragalactic/pointsources/fr2.py
+++ b/fg21sim/extragalactic/pointsources/fr2.py
@@ -340,11 +340,11 @@ class FRII(BasePointSource):
npix = hp.nside2npix(self.nside)
sr_to_arcsec2 = (np.rad2deg(1) * 3600) ** 2 # [sr] -> [arcsec^2]
core_area = 4 * np.pi / npix * sr_to_arcsec2 # [arcsec^2]
- Tb_core = convert.Fnu_to_Tb_fast(flux_core, core_area, freq) # [K]
+ Tb_core = convert.Fnu_to_Tb(flux_core, core_area, freq) # [K]
# lobe
lumo_lobe = lumo_151 * (1 - ratio_obs) / (1 + ratio_obs) # [Jy]
flux_lobe = (freq / freq_ref)**(-0.75) * lumo_lobe
- Tb_lobe = convert.Fnu_to_Tb_fast(flux_lobe, area, freq) # [K]
+ Tb_lobe = convert.Fnu_to_Tb(flux_lobe, area, freq) # [K]
# hotspots
# Willman Eq. (3)
diff --git a/fg21sim/extragalactic/pointsources/radioquiet.py b/fg21sim/extragalactic/pointsources/radioquiet.py
index f07f8dc..0fbb6b2 100644
--- a/fg21sim/extragalactic/pointsources/radioquiet.py
+++ b/fg21sim/extragalactic/pointsources/radioquiet.py
@@ -159,7 +159,7 @@ class RadioQuiet(BasePointSource):
# Calc flux
flux = (freq / freq_ref)**(-0.7) * lumo_1400
# Calc brightness temperature
- Tb = convert.Fnu_to_Tb_fast(flux, area, freq)
+ Tb = convert.Fnu_to_Tb(flux, area, freq)
return Tb
diff --git a/fg21sim/extragalactic/pointsources/starbursting.py b/fg21sim/extragalactic/pointsources/starbursting.py
index 57fd5a0..897d53f 100644
--- a/fg21sim/extragalactic/pointsources/starbursting.py
+++ b/fg21sim/extragalactic/pointsources/starbursting.py
@@ -208,7 +208,7 @@ class StarBursting(BasePointSource):
# Calc flux
flux = (freq / freq_ref)**(-0.7) * lumo_1400
# Calc brightness temperature
- Tb = convert.Fnu_to_Tb_fast(flux, area, freq)
+ Tb = convert.Fnu_to_Tb(flux, area, freq)
return Tb
diff --git a/fg21sim/extragalactic/pointsources/starforming.py b/fg21sim/extragalactic/pointsources/starforming.py
index a16d58d..d4664bb 100644
--- a/fg21sim/extragalactic/pointsources/starforming.py
+++ b/fg21sim/extragalactic/pointsources/starforming.py
@@ -227,7 +227,7 @@ class StarForming(BasePointSource):
# Calc flux
flux = (freq / freq_ref)**(-0.7) * lumo_1400
# Calc brightness temperature
- Tb = convert.Fnu_to_Tb_fast(flux, area, freq)
+ Tb = convert.Fnu_to_Tb(flux, area, freq)
return Tb
diff --git a/fg21sim/galactic/snr.py b/fg21sim/galactic/snr.py
index 74b9525..2e6d21c 100644
--- a/fg21sim/galactic/snr.py
+++ b/fg21sim/galactic/snr.py
@@ -32,7 +32,7 @@ from astropy.coordinates import SkyCoord
from ..sky import get_sky
from ..utils.wcs import make_wcs
-from ..utils.convert import Fnu_to_Tb_fast
+from ..utils.convert import Fnu_to_Tb
from ..utils.grid import make_ellipse
from ..utils.units import UnitConversions as AUC
@@ -251,7 +251,7 @@ class SuperNovaRemnants:
if omega < pixelarea:
# The object is smaller than a pixel, so round up to a pixel area
omega = pixelarea
- Tb = Fnu_to_Tb_fast(Fnu, omega, frequency)
+ Tb = Fnu_to_Tb(Fnu, omega, frequency)
return Tb
def _simulate_templates(self):