Airton,
Attached to this posted are five files that show how to execute replications using a batch file:
- "Example 2 - Server and Queue.cfg" - the example model. The attached copy is identical to the one on the Downloads webpage.
- run1,cfg, run2,cfg, and run3.cfg - the configuration file for each of the three simulation runs to be batched.
- BatchRuns1-3.bat - the batch file that will execute the three runs one after another. You can double-click on this file to launch the batched runs. Note - the file was renamed as "BatchRuns1-3.bat.txt" to allow it to be attached to the post. If you have any difficulty downloading this file, you can create it yourself by copying the text given later in this post.
The first run files contain the following lines (the other two are similar):
Include 'Example 2 - Server and Queue.cfg'
Simulation RealTime { FALSE }
ExponentialDistribution-1 GlobalSubstreamSeed { 1 }
The include statement in the first line loads all the inputs from the file 'Example 2 - Server and Queue.cfg' to the present run. The second line turns off RealTime mode so that the run executes as fast as possible. The third line selects the first global sub-stream -- this input automatically changes the effective seed for ALL the random distributions.
The batch file contains the following lines:
jaamsim2014-50.exe run1.cfg -b
jaamsim2014-50.exe run2.cfg -b
jaamsim2014-50.exe run3.cfg -b
This is just a standard DOS batch file that executes three runs in succession. All the files need to be in the same directory for this batch file to execute correctly.
Normally, each run would produce a separate report file, however, the model used for this example, "Example 2 - Server and Queue.cfg", does not generate a report, so nothing is generated by each run. Add the ReportGenerator object to your model to create an output report for each run.
This should be enough to get you started. Let me know if you have any difficulty.
Harry