Subhalo Merger Tree Atlas

Locate a snapshot 080 subhalo in the distributed LHaloTree files.

In postprocessing/atlas/atlas_080.hdf5, the row number is the global SUBFIND subhalo number at snapshot 080 (z = 5.51). The three integer arrays form an address in a merger tree. Earlier progenitors can then be followed using the links in that tree.

Fields

FieldMeaning
FileChunk number in trees_sf1_080.FILE.hdf5.
TreeNumber in the group name TreeN inside that chunk.
IndexNode index within that tree. Check SnapNum and SubhaloNumber at this index.

Find subhalo 42 in its tree

Paths in this example are relative to Thesan-1/postprocessing/.

import h5py

subhalo = 42
with h5py.File("atlas/atlas_080.hdf5") as atlas:
    chunk, tree, row = (int(atlas[key][subhalo]) for key in ("File", "Tree", "Index"))
with h5py.File(f"trees/trees_sf1_080.{chunk}.hdf5") as f:
    node = f[f"Tree{tree}"]
    print(chunk, tree, row, node["SnapNum"][row], node["SubhaloNumber"][row])
    assert (node["SnapNum"][row], node["SubhaloNumber"][row]) == (80, subhalo)
Output from THESAN-1
0 0 94691 80 42