pynbody.analysis.halo.hybrid_center#
- pynbody.analysis.halo.hybrid_center(sim, r='3 kpc', **kwargs)[source]#
Determine the center of the halo by finding the shrink-sphere-center near the potential minimum
Most users will want to use the general
center()
function, which actually performs the centering operation. This function is a lower-level interface that calculates the center but does not move the particles.- Parameters:
sim (SimSnap) – The simulation snapshot of which to find the center
r (float | str, optional) – Radius from the potential minimum to search for the center. Default is 3 kpc.
:param Remaining parameters are passed onto
shrink_sphere_center()
.:- Returns:
com (SimArray) – The center of mass of the final sphere
vel (SimArray) – The center of mass velocity of the final sphere. Only returned if particles_for_velocity > min_particles.