A fast and accurate method to compute the mass return from multiple stellar populations