A real-time bus dispatching policy to minimize headway variance