aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim/extragalactic/clusters/halo.py
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2017-07-26 15:58:51 +0800
committerAaron LI <aly@aaronly.me>2017-07-26 15:58:51 +0800
commit2e089e03fdeb0fc5bde86cd5fd93e16a42983a79 (patch)
tree8691b7ee79705e7151862670d0e0df09ab9be168 /fg21sim/extragalactic/clusters/halo.py
parente6b727785fab339103a103194317ffdc6ba37684 (diff)
downloadfg21sim-2e089e03fdeb0fc5bde86cd5fd93e16a42983a79.tar.bz2
clusters/halo.py: Add property "magnetic_field"
Signed-off-by: Aaron LI <aly@aaronly.me>
Diffstat (limited to 'fg21sim/extragalactic/clusters/halo.py')
-rw-r--r--fg21sim/extragalactic/clusters/halo.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/fg21sim/extragalactic/clusters/halo.py b/fg21sim/extragalactic/clusters/halo.py
index 7c52f97..44d1e1a 100644
--- a/fg21sim/extragalactic/clusters/halo.py
+++ b/fg21sim/extragalactic/clusters/halo.py
@@ -162,6 +162,17 @@ class RadioHalo:
r_halo = helper.radius_halo(mass, self.z_merger) # [kpc]
return r_halo
+ @property
+ def magnetic_field(self):
+ """
+ The magnetic field strength at the simulated observation
+ time (i.e., cluster mass of ``self.M_obs``), will be used
+ to calculate the synchrotron emissions.
+
+ Unit: [uG]
+ """
+ return helper.magnetic_field(self.M_obs)
+
def calc_electron_spectrum(self, zbegin=None, zend=None, n0_e=None):
"""
Calculate the relativistic electron spectrum by solving the