aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim
diff options
context:
space:
mode:
authorAaron LI <aly@aaronly.me>2018-01-05 20:58:59 +0800
committerAaron LI <aly@aaronly.me>2018-01-05 20:58:59 +0800
commit900dc8a09932dc3d101e66c8da3c7449a34bc983 (patch)
treeb8d066fb130c5cd6520bd5ab74afe6ca55a3499c /fg21sim
parent6f28b7d037dbbe3aba0a0e2cf0c3ffcd51643987 (diff)
downloadfg21sim-900dc8a09932dc3d101e66c8da3c7449a34bc983.tar.bz2
clusters/halo: fix self.time_step error
Diffstat (limited to 'fg21sim')
-rw-r--r--fg21sim/extragalactic/clusters/halo.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/fg21sim/extragalactic/clusters/halo.py b/fg21sim/extragalactic/clusters/halo.py
index ace50d1..c9bb56b 100644
--- a/fg21sim/extragalactic/clusters/halo.py
+++ b/fg21sim/extragalactic/clusters/halo.py
@@ -891,7 +891,7 @@ class RadioHaloAM(RadioHalo):
Unit: [Gyr]
"""
- dt = self.tstep
+ dt = self.time_step
xt = np.arange(self.age_begin, self.age_obs+dt/2, step=dt)
t_turb = np.array([self.time_turbulence(t) for t in xt])
avg = np.sum(t_turb * dt) / (len(xt) * dt)
@@ -903,7 +903,7 @@ class RadioHaloAM(RadioHalo):
Calculate the time-averaged turbulence Mach number within the
period from ``age_begin`` to ``age_obs``.
"""
- dt = self.tstep
+ dt = self.time_step
xt = np.arange(self.age_begin, self.age_obs+dt/2, step=dt)
mach = np.array([self.mach_turbulence(t) for t in xt])
avg = np.sum(mach * dt) / (len(xt) * dt)
@@ -918,7 +918,7 @@ class RadioHaloAM(RadioHalo):
Unit: [Gyr]
"""
- dt = self.tstep
+ dt = self.time_step
xt = np.arange(self.age_begin, self.age_obs+dt/2, step=dt)
tau = np.array([self.tau_acceleration(t) for t in xt])
avg = np.sum(tau * dt) / (len(xt) * dt)
@@ -931,7 +931,7 @@ class RadioHaloAM(RadioHalo):
``age_begin`` to ``age_obs`` that the turbulence acceleration
is active.
"""
- dt = self.tstep
+ dt = self.time_step
xt = np.arange(self.age_begin, self.age_obs+dt/2, step=dt)
active = np.array([self._is_turb_active(t) for t in xt], dtype=int)
fraction = active.mean()