Tracking nonperiodic trajectories with the overtaking criterion