ATTENTION

This FlexSim Community Forum is read-only. Please post any new questions, ideas, or discussions to our new community (we call it Answers) at https://answers.flexsim.com/. Our new Question & Answer site brings a modern, mobile-friendly interface and more focus on getting answers quickly. There are a few differences between how our new Q&A community works vs. a classic, threaded-conversation-style forum like the one below, so be sure to read our Answers Best Practices.


flexsim.com

Go Back   FlexSim Community Forum > FlexSim Software > Q&A
Downloads

Q&A Using Flexsim and building models

  #1  
Old 11-28-2007
Nico Zahn's Avatar
Nico Zahn Nico Zahn is offline
Flexsim User
 
Join Date: Sep 2007
Location: Bingen am Rhein, Germany
Posts: 179
Downloads: 19
Uploads: 4
Thanks: 66
Thanked 60 Times in 32 Posts
Rep Power: 201
Nico Zahn has a spectacular aura aboutNico Zahn has a spectacular aura about
Default Automated runs / Exporting mdb file..

Hi there,
I have to do a couple of runs with a model.
So I load an Excel-Parameterfile at the start of each Scenario.
Now I need to export the results to a mdb File so I can analyse the results with the Flexsim Charts. I found a undocumented command exportfullhistory() which is working but I don´t know how to automate the saving process. Each time I call exportfullhistory, I have to give a filename. How can I pass the filename automaticly?

Another question is how to compare the results of two or more runs. I can have serveral instances of the Flexchart, but if I want to put a result graph of run1 and run2 in one diagram, I have to export the graphs to excel and link them there. Is there a more easy solution for this?
__________________
kind regards Nico.

Last edited by Nico Zahn; 11-28-2007 at 04:35 AM.
  #2  
Old 11-28-2007
Jeff Nordgren's Avatar
Jeff Nordgren Jeff Nordgren is offline
Technical Support Manager
 
Join Date: Jul 2007
Location: Orem, UT
Posts: 65
Downloads: 79
Uploads: 0
Thanks: 40
Thanked 21 Times in 17 Posts
Rep Power: 233
Jeff Nordgren is just really niceJeff Nordgren is just really niceJeff Nordgren is just really niceJeff Nordgren is just really nice
Default

Nico,

You're trying to record the results of each of his scenarios to a database for Flexsim Chart to read. Right now there's no way to automate that the way you want. That functionality should exist in the next release.
__________________
Jeff
Flexsim Support
  #3  
Old 11-29-2007
Nico Zahn's Avatar
Nico Zahn Nico Zahn is offline
Flexsim User
 
Join Date: Sep 2007
Location: Bingen am Rhein, Germany
Posts: 179
Downloads: 19
Uploads: 4
Thanks: 66
Thanked 60 Times in 32 Posts
Rep Power: 201
Nico Zahn has a spectacular aura aboutNico Zahn has a spectacular aura about
Default

Hi Jeff,
so I have to save the states in the end of each scenario. Maybe write some custom code to export some of the results to excel....

Is there any way to comapre two runs with the flexsimchart tool?
__________________
kind regards Nico.
  #4  
Old 11-29-2007
Nico Zahn's Avatar
Nico Zahn Nico Zahn is offline
Flexsim User
 
Join Date: Sep 2007
Location: Bingen am Rhein, Germany
Posts: 179
Downloads: 19
Uploads: 4
Thanks: 66
Thanked 60 Times in 32 Posts
Rep Power: 201
Nico Zahn has a spectacular aura aboutNico Zahn has a spectacular aura about
Default Saving states at the end of scenario

So if you wan´t to save the states in the end of a scenarie there has to be a 'expiriment' folder in the program directory. Otherwise the states don´t get saved. This should be added to the documentation, or the folder should be automaticly created when Flexsim installs.
__________________
kind regards Nico.
  #5  
Old 11-29-2007
Nico Zahn's Avatar
Nico Zahn Nico Zahn is offline
Flexsim User
 
Join Date: Sep 2007
Location: Bingen am Rhein, Germany
Posts: 179
Downloads: 19
Uploads: 4
Thanks: 66
Thanked 60 Times in 32 Posts
Rep Power: 201
Nico Zahn has a spectacular aura aboutNico Zahn has a spectacular aura about
Default The event database is not saved with the state

So I just recognized that I can not let Flexsim save the state at the end of each scenary, open the states and look at the Chart in the Flexsim Chart Tool. I guess the event times are not saved with the states.
__________________
kind regards Nico.
  #6  
Old 11-29-2007
Anthony Johnson's Avatar
Anthony Johnson Anthony Johnson is offline
Manager of Product Development
 
Join Date: Jul 2007
Posts: 440
Downloads: 86
Uploads: 4
Thanks: 171
Thanked 899 Times in 288 Posts
Rep Power: 735
Anthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond repute
Default

Quote:
Originally Posted by Nico Zahn View Post
So if you wan´t to save the states in the end of a scenarie there has to be a 'expiriment' folder in the program directory. Otherwise the states don´t get saved. This should be added to the documentation, or the folder should be automaticly created when Flexsim installs.
In the next version the experimenter has been changed so that states will instead be saved in the same folder as the model.

Quote:
So I just recognized that I can not let Flexsim save the state at the end of each scenary, open the states and look at the Chart in the Flexsim Chart Tool. I guess the event times are not saved with the states.
Yes, unfortunately the full history is not saved with the save state feature. We still need to better integrate the experimenter with Flexsim Chart. However, I think there is a command (or at least there will be a command in the next version) that will write the full history to an .mdb file that you specify. As mentioned above, you can call exportfullhistory() at the end of a model run, although it will open a save dialog and then open Flexsim Chart, which wouldn't be helpful when you're running an experiment. All that stuff is managed by AJ, so he would be the best one to ask on this. I'll ask him and get back to you.

Last edited by Anthony Johnson; 11-29-2007 at 10:58 AM.
The Following User Says Thank You to Anthony Johnson For This Useful Post:
Brandon Peterson (10-08-2009)
  #7  
Old 11-29-2007
Anthony Johnson's Avatar
Anthony Johnson Anthony Johnson is offline
Manager of Product Development
 
Join Date: Jul 2007
Posts: 440
Downloads: 86
Uploads: 4
Thanks: 171
Thanked 899 Times in 288 Posts
Rep Power: 735
Anthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond repute
Default

Just talked to AJ, and he says that in the next version the exportfullhistory command will have an optional parameter where you can pass in the path to the mdb file that you want to save.
  #8  
Old 11-29-2007
Anthony Johnson's Avatar
Anthony Johnson Anthony Johnson is offline
Manager of Product Development
 
Join Date: Jul 2007
Posts: 440
Downloads: 86
Uploads: 4
Thanks: 171
Thanked 899 Times in 288 Posts
Rep Power: 735
Anthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond repute
Default

Quote:
Originally Posted by Nico Zahn View Post
Another question is how to compare the results of two or more runs. I can have serveral instances of the Flexchart, but if I want to put a result graph of run1 and run2 in one diagram, I have to export the graphs to excel and link them there. Is there a more easy solution for this?
In the next version the experimenter results have been revamped so that the graphs are easier to read and you can glean more information from them. You will also be able to create "Group" performance measures, which allow you to compare a performance measure across multiple objects, get the group average, etc.

Last edited by Anthony Johnson; 11-29-2007 at 11:09 AM.
  #9  
Old 11-29-2007
AlanZhang's Avatar
AlanZhang AlanZhang is offline
Flexsim Super Moderator
 
Join Date: Aug 2007
Location: CA
Posts: 289
Downloads: 64
Uploads: 0
Thanks: 88
Thanked 91 Times in 47 Posts
Rep Power: 225
AlanZhang is a jewel in the roughAlanZhang is a jewel in the roughAlanZhang is a jewel in the rough
Default

I am glad that Nico brings up this issue. I have noticed the problem for a while. Since I am using the experimenter a lot, being able to output full history of a simulation after each replications for a post analysis would benefit me and others a lot. Is this going to happen in the Flexsim v4.1?

Alan
__________________
Best,
Alan
  #10  
Old 11-30-2007
Nico Zahn's Avatar
Nico Zahn Nico Zahn is offline
Flexsim User
 
Join Date: Sep 2007
Location: Bingen am Rhein, Germany
Posts: 179
Downloads: 19
Uploads: 4
Thanks: 66
Thanked 60 Times in 32 Posts
Rep Power: 201
Nico Zahn has a spectacular aura aboutNico Zahn has a spectacular aura about
Default

So the only way I could set up a lot of runs automated was for me to have a input-excelfile and a output one.
The output-file is predefined with diagramms so I can save a lot work in the analysing.
When you want to read a excelfile at the start of each scenario and write one in the end you have to call a 'excellaunch' on the 'Start of experiment' trigger and a 'excel quit' on the 'end of experiment' trigger, otherwise you get some OLE - errors. Excel stays open during the runs.
In this way I have correlating input and output files. Also setting up the export code and input files is some work, I can use the cpu the whole night without hanging around...
__________________
kind regards Nico.
  #11  
Old 12-13-2007
Nico Zahn's Avatar
Nico Zahn Nico Zahn is offline
Flexsim User
 
Join Date: Sep 2007
Location: Bingen am Rhein, Germany
Posts: 179
Downloads: 19
Uploads: 4
Thanks: 66
Thanked 60 Times in 32 Posts
Rep Power: 201
Nico Zahn has a spectacular aura aboutNico Zahn has a spectacular aura about
Default

I spend quite a while trying it but the OLE interface is not stable enough for importing a parameter list and exporting a result file with Excel. I could manage some 20 scenarios each with one import at the start an one export at the end of a scenario run. On scenario 21 I found myself in the land of the happy Megabugs. All the nice things like 'Invalid node remove command' , 'Byte Block allocation failed' and OLE errors appeard. The Excelfile seemed to be mixed up with the importfile and the result file. So I guess it is the interface which is not working properly. I varied the parameter now in the experimenter inside Flexsim and only exported the result file and this worked, but if you have a big list of parameters you want to change through the scenarios this is not the appropriate method to do this. So please think in the next release about how a user could automate a lot of runs automated...At least try to get the OLE interface more stable...
__________________
kind regards Nico.
  #12  
Old 12-13-2007
AJ Bobo's Avatar
AJ Bobo AJ Bobo is offline
Flexsim Senior Developer
 
Join Date: Jul 2007
Posts: 108
Downloads: 8
Uploads: 0
Thanks: 23
Thanked 89 Times in 41 Posts
Rep Power: 221
AJ Bobo is a jewel in the roughAJ Bobo is a jewel in the roughAJ Bobo is a jewel in the roughAJ Bobo is a jewel in the rough
Default OLE instability

Nico,

Can you provide a small model that demonstrates the OLE instability that you're describing? The OLE interface can be fairly picky about how and when certain commands are called. I would be happy to look over your code and see if there's a way to make it more stable and usable.
  #13  
Old 12-15-2007
Nico Zahn's Avatar
Nico Zahn Nico Zahn is offline
Flexsim User
 
Join Date: Sep 2007
Location: Bingen am Rhein, Germany
Posts: 179
Downloads: 19
Uploads: 4
Thanks: 66
Thanked 60 Times in 32 Posts
Rep Power: 201
Nico Zahn has a spectacular aura aboutNico Zahn has a spectacular aura about
Default

Hi AJ,
I am sorry, I tried to build a small modell and had some 90 runs and it worked. I am not shure by now what caused this errors, but in the big model it doesn´t work. So I need some more time to let the trial modell use the im- and export more excessivly (when I find time).
As I hearded you take care of the Chart Tool. So did you regognize that the warm up time is not taken out of the percentage values in the charts?
__________________
kind regards Nico.
  #14  
Old 12-17-2007
Anthony Johnson's Avatar
Anthony Johnson Anthony Johnson is offline
Manager of Product Development
 
Join Date: Jul 2007
Posts: 440
Downloads: 86
Uploads: 4
Thanks: 171
Thanked 899 Times in 288 Posts
Rep Power: 735
Anthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond reputeAnthony Johnson has a reputation beyond repute
Default

Nico,
AJ can post his own reply, but I have a feeling that he will concur with my opinion that, since you have the ability to specify a time range for generating a state chart, there is no need to leave the warm-up time out of it by default. Perhaps we could provide an automatic selection for "time after warm-up", but I don't think there is anything "incorrect" in the way it's done right now. The state report takes the warm-up time out, and you have the ability to do that in the state charts by specifying a time range, so I don't see it as an "error", just an "ease-of-use" feature that could be added in the future.
  #15  
Old 12-17-2007
AJ Bobo's Avatar
AJ Bobo AJ Bobo is offline
Flexsim Senior Developer
 
Join Date: Jul 2007
Posts: 108
Downloads: 8
Uploads: 0
Thanks: 23
Thanked 89 Times in 41 Posts
Rep Power: 221
AJ Bobo is a jewel in the roughAJ Bobo is a jewel in the roughAJ Bobo is a jewel in the roughAJ Bobo is a jewel in the rough
Default

Anthony's right. Automatically removing warm-up time is something we can add to Flexsim Chart in the future, but for now use the time range feature in Flexsim Chart to limit the amount of time that the report covers.



All times are GMT -6.
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Copyright 1993-2018 FlexSim Software Products, Inc.