aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim/extragalactic/clusters
diff options
context:
space:
mode:
authorAaron LI <aaronly.me@outlook.com>2017-01-08 18:46:50 +0800
committerAaron LI <aly@aaronly.me>2017-06-01 16:33:39 +0800
commitb888ec8a1abf602a4cc9237ff78babb131a2d008 (patch)
tree52369a6238e3da41dd1cc315019dbd979551d1e4 /fg21sim/extragalactic/clusters
parentbd036531712dd4f7403e6f50205a836bac76c37f (diff)
downloadfg21sim-b888ec8a1abf602a4cc9237ff78babb131a2d008.tar.bz2
halo.py: Update to match MergerTree structures
Diffstat (limited to 'fg21sim/extragalactic/clusters')
-rw-r--r--fg21sim/extragalactic/clusters/halo.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/fg21sim/extragalactic/clusters/halo.py b/fg21sim/extragalactic/clusters/halo.py
index 6adfba5..8fd49c5 100644
--- a/fg21sim/extragalactic/clusters/halo.py
+++ b/fg21sim/extragalactic/clusters/halo.py
@@ -430,16 +430,16 @@ class HaloSingle:
events = []
tree = self.mtree
while tree:
- if (tree.major and tree.minor and
- tree.minor.node.mass >= self.merger_mass_th and
- tree.major.node.z <= self.zmax):
+ if (tree.main and tree.sub and
+ tree.sub.data["mass"] >= self.merger_mass_th and
+ tree.main.data["z"] <= self.zmax):
events.append({
- "M_main": tree.major.node.mass,
- "M_sub": tree.minor.node.mass,
- "z": tree.major.node.z,
- "age": tree.major.node.age
+ "z": tree.main.data["z"],
+ "age": tree.main.data["age"],
+ "M_main": tree.main.data["mass"],
+ "M_sub": tree.sub.data["mass"],
})
- tree = tree.major
+ tree = tree.main
return events
def _coef_acceleration(self, z):