aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim/extragalactic
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2018-01-21 16:42:07 +0800
committerAaron LI <aly@aaronly.me>2018-01-21 16:42:07 +0800
commitff9504cfc37362e67d1f6f88b35f6b5e4bdae24c (patch)
treedcdfc35d319eae081900369f2b9faf772a6fa2a0 /fg21sim/extragalactic
parent5181899842fc69230eb815fc319639e84892be1b (diff)
downloadfg21sim-ff9504cfc37362e67d1f6f88b35f6b5e4bdae24c.tar.bz2
clusters/halo: most consistent turbulent acceleration and time calculations
Diffstat (limited to 'fg21sim/extragalactic')
-rw-r--r--fg21sim/extragalactic/clusters/halo.py4
-rw-r--r--fg21sim/extragalactic/clusters/helper.py2
2 files changed, 3 insertions, 3 deletions
diff --git a/fg21sim/extragalactic/clusters/halo.py b/fg21sim/extragalactic/clusters/halo.py
index 2e04189..4a1811e 100644
--- a/fg21sim/extragalactic/clusters/halo.py
+++ b/fg21sim/extragalactic/clusters/halo.py
@@ -347,8 +347,8 @@ class RadioHalo:
t_merger = self._merger_time(t)
z_merger = COSMO.redshift(t_merger)
- mass_main = self.mass_main(t_merger)
- R_vir = helper.radius_virial(mass=mass_main, z=z_merger)
+ mass_merged = self.mass_merged(t_merger)
+ R_vir = helper.radius_virial(mass=mass_merged, z=z_merger)
L = self.f_lturb * R_vir # [kpc]
cs = helper.speed_sound(self.kT(t_merger)) # [km/s]
v_turb = self._velocity_turb(t_merger) # [km/s]
diff --git a/fg21sim/extragalactic/clusters/helper.py b/fg21sim/extragalactic/clusters/helper.py
index 8d6db09..5fd25a9 100644
--- a/fg21sim/extragalactic/clusters/helper.py
+++ b/fg21sim/extragalactic/clusters/helper.py
@@ -389,7 +389,7 @@ def time_turbulence(M_main, M_sub, z=0.0, configs=CONFIGS):
# Turbulence injection scale factor
key = "extragalactic/halos/f_lturb"
f_lturb = configs.getn(key)
- R_vir = radius_virial(M_main, z) # [kpc]
+ R_vir = radius_virial(M_main+M_sub, z) # [kpc]
distance = 2*R_vir * f_lturb
vi = velocity_impact(M_main, M_sub, z) # [km/s]
uconv = AUC.kpc2km * AUC.s2Gyr # [s kpc/km] => [Gyr]