Improved speed by cacheing all DB queries
Got the simulation working sans rerouting