  Motivated by the recent proposal of the splashback radius as a physical
boundary of dark matter halos, we present a parallel computer code for Subhalo
and PARticle Trajectory Analysis (SPARTA). The code analyzes the orbits of all
simulation particles in all host halos, billions of orbits in the case of
typical cosmological N-body simulations. Within this general framework, we
develop an algorithm that accurately extracts the location of the first
apocenter of particles after infall into a halo, or splashback. We define the
splashback radius of a halo as the smoothed average of the apocenter radii of
individual particles. This definition allows us to reliably measure the
splashback radii of 95% of host halos above a resolution limit of 1000
particles. We show that, on average, the splashback radius and mass are
converged to better than 5% accuracy with respect to mass resolution, snapshot
spacing, and all free parameters of the method.
