aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2019-02-21 20:52:14 +0800
committerAaron LI <aly@aaronly.me>2019-02-21 20:52:14 +0800
commit157028160de3a7baa640cbe87bf5f1a3c1b90ad7 (patch)
treec1670d63eb35e7016ea8cd663de4537507ebf14e /fg21sim
parent78be1f0735829491c7fb322c02feab46ce917d32 (diff)
downloadfg21sim-157028160de3a7baa640cbe87bf5f1a3c1b90ad7.tar.bz2
clusters/halo: Several minor improvements
Diffstat (limited to 'fg21sim')
-rw-r--r--fg21sim/extragalactic/clusters/halo.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/fg21sim/extragalactic/clusters/halo.py b/fg21sim/extragalactic/clusters/halo.py
index bcda7bb..eb873ec 100644
--- a/fg21sim/extragalactic/clusters/halo.py
+++ b/fg21sim/extragalactic/clusters/halo.py
@@ -210,11 +210,10 @@ class RadioHalo1M:
@lru_cache()
def t_merger_end(self):
"""
- The time when the merger/turbulence ends.
+ The time when the merger (i.e., turbulence) ends.
Unit: [Gyr]
"""
- tau_turb = self.duration_turb(self.t_merger)
- return self.t_merger + tau_turb
+ return self.t_merger + self.duration_turb(self.t_merger)
@property
def radius(self):
@@ -847,7 +846,7 @@ class RadioHaloAM(RadioHalo1M):
Return the most recent merger event happend before the given time,
i.e., the merger event that the given time locates in.
"""
- idx = (self.t_merger > t).sum()
+ idx = (self.t_merger > t).sum() # 't_merger' in decreasing order
return {
"idx": idx,
"M_main": self.M_main[idx],
@@ -908,6 +907,8 @@ class RadioHaloAM(RadioHalo1M):
(i.e., smallest ``tau_acc``) is chosen and its beginning time is
returned. Otherwise, the most recent merger event happened before
the given time is chosen.
+
+ Unit: [Gyr]
"""
mergers = [(tm, tm+self.duration_turb(tm), self.tau_acceleration(tm))
for tm in self.t_merger]