Skip to content

faq 79527949

Billy Charlton edited this page Sep 5, 2018 · 2 revisions

End dvrp/taxi simulation

by Yousef Hindy on 2016-08-19 01:07:22


How does a dvrp/taxi simulation end? I understand that it should end when all of the requests have been performed, but when I ran my taxi simulation it kept running indefinitely. Is there a way to ensure that the simulation will end at the conclusion of the last request?

Source: MATSim

Comments: 1


Re: End dvrp/taxi simulation

by Michal Maciejewski on 2016-08-19 08:47:16

Hi Yousef, If you know that all requests have been performed and all vehicles are idle now, you can set the end time of the last task (==current task) for each vehicle to 'now'. The simulation will end within 1 time step. Something like this:

Schedules.getLastTask(taxiSchedule).setEndTime(now);

Hope that helps,
Michal 

Clone this wiki locally