i had made a model and used track routing for various destination based on integer attributes.
The simulation is running exactly according to the routes i have defined in the code, but after some 16hours it doesnt follow the destination it is defined and goes on wrong track(had been running properly for last 16hours of Simulation) .
here is the code i have been using
if @.empty and @.name="fzwe" then
elseif @.empty and @.name="fzint" and übergabeA5.NumMu>0 then
elseif übergabeA5.NumMu=0 then
elseif @.occupied then
Error happens sometimes at 21 hours or 16 hours or 18 hours(keeps changing every time) and it occurs only for case 21 everytime(though before it followed the code and travelled to destination for around 290 times.Destination is a track followed by a store with capacity(300*200*10).
i tried to create a demo model and upload it , but the problem doesnt occue in a test .
Can anyone give there insights on what could be the possible reasons for this that a code suddenly stops working.
Without the model to
monitor this behaviour
it will turn in to guessing.
Therefore - in your case - you should provide
the model with the described behaviour.
Error happens sometimes at 21 hours or 16 hours or 18 hours(keeps changing every time)
Also this indicates that you have done something wrong in your model, because it should normally reproduce the same results/errors every time (unless you intentionally changed some randomseeds).
thank you for the replies
the different times in error was due to minor changes in the length of tracks.
what could be the issue with the model otherwise , which will lead to this type of error.
Sorry i cant post the model as it is quite big and confidential, i tried to make a sample model,but error doesnt occur on the sample.
so now the error happens every time you run the model at the same time for the same MU?
yes , the error happens at same time now . It is like the exit control code for a track works fine for some 12 hours and then it misses it and the transporter is directed in a wrong direction.
Maybe it would help us to take a look at your demo/example model, even if the error does not occur there. Just so we can see what methods you used etc.
And for your "real" model in the meantime: Since you know for which MU (with ID/Number X) it fails, set a debug at your case 21
if @.GetNo = X then debug; end
just so you can slowly debug through your code, and see where it goes wrong exactly (the destination is set correctly, but what happens next? At what point does the transporter take a wrong route? Are you using route weight attributes, e.g.?)