Some important changes to the FOF algorithm.
We create two kinds of particles: linkable
and attachable
:
The two categories are specified at runtime in the parameter file.
The use case is to run FOF on the DM only and then attach the gas/stars/BHs to the nearest DM particle they find. With some minor caveats this is what other FOF codes do.
The strategy I used is as follows:
fof_union
fof_union
is similar to the basic one but, crucially, does not make the smallest group_index the root. It maintains the linkable
(or its own root) as the root irrespective of group_index
. This way the attachable
is never a root and always "dangling" at the end of a tree and can thus be updated easily if we find an even nearer linkable
later.Still to do: