How to auto record runspeed of FlexSim model

How to auto record runspeed of FlexSim model

leungch
Not applicable
182 Views
4 Replies
Message 1 of 5

How to auto record runspeed of FlexSim model

leungch
Not applicable

[ FlexSim 18.2.3 ]

I need to run simulation study with a model connected to SQL server for data exchange with another software. Currently, all of the required data can be recorded by Statistic Collector or in Global table except the runspeed. I expect the runspeed of FlexSim would affect the result, but I are not sure how much it will be. It would be appreciated if someone can tell me how to auto record runspeed just like other data. Thanks!

0 Likes
Accepted solutions (1)
183 Views
4 Replies
Replies (4)
Message 2 of 5

Ben_WilsonADSK
Community Manager
Community Manager

@leungch, do you mean the runspeed slider that a user can adjust to affect the amount of simulation time per real time? Or some other runspeed?

Please give some more description of what data you are trying to capture. I can't think of a reason you would store info about how the user moves the runspeed slider. Ideally you will have built your model such that the runspeed does not effect the logic of your model, and therefore the results.

Perhaps you mean something else. Please elaborate and we'll be happy to answer your questions.

0 Likes
Message 3 of 5

leungch
Not applicable

@ben.wilson, I agree simulation model should be built that runspeed has no effect on result.

My model is an virtual production environment with production equipments and AGVs. The AGVs are responsible for material transfer, loading and unloading amongst the equipments production line. It is used to evaluate our production control software which would control the AGV according to the material status at equipments.

The problem we are facing is our simulation studies have to run for a few 10 hours. On the other hands, processing time of our production control software and the communication between FlexSim model and it (through SQL server) would not be accelerated. If we only set a higher runspeed (by the slider you mentioned), simulation result would definitely be affected.

I don't think we can resolve that problem. If we need to get absolute data which reflect the actual case, we have to run model in normal speed. However, I think we can still make comparison (no need of absolute results) between results of simulation studies with different parameters in higher runspeed. So I wonder if the runspeed could be auto. recorded.

0 Likes
Message 4 of 5

benjamin_w2
Not applicable
Accepted solution

@leungch,

You can reference the runspeed with the following command:

maintree().find("project/exec/step").value


In the attached model, I created a statistics collector to collect the runspeed every 10 model seconds.

First, create a timer event, then add an Event Data Label like so:

32312-1599081593514.png

Then, add a column that references the runspeed:

32313-1599081628176.png

RunSpeed.fsm


Message 5 of 5

leungch
Not applicable

@benjamin.w2 Although your model couldn't be run in my copy of FlexSim (v18.2.3), I tested your command and it works as what I need. Thanks!

0 Likes