Repast Simphony simulation ticks incrementing inconsistenly

73 Views Asked by At

I am running a simulation that moves agents along shape file "roads" in repast simphony. My code is derived from the RepastCity3 example. I have made some edits to simplify the code and when I run it, the Tick Count occasionally (not always) takes quick jumps making the GUI display show my agents jerking along the road instead of traveling at a consistent pace.

Is this likely caused by a threading error? I have tried to make sure all code pertaining to movement is under the synchronized keyword.

1

There are 1 best solutions below

0
Nick Collier On

This can happen when the displays have lots of rendering to do and get behind the current tick, then the GUI will jump ahead and skip some display updates. That situation can occur if the model runs quickly but each iteration of the model produces some time consuming rendering updates.

I'm not sure if this will help at all, but you could try increasing the schedule tick delay in the Run Options panel and see if that helps.