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 07-03-2008
Markus Bans Markus Bans is offline
Flexsim User
 
Join Date: Aug 2007
Location: D-41199 Moenchengladbach, Germany
Posts: 8
Downloads: 28
Uploads: 1
Thanks: 2
Thanked 15 Times in 4 Posts
Rep Power: 0
Markus Bans will become famous soon enough
Default State files and global variables

Hello community forum!

I have a question about state files and global variables. I ran the attached .fsm (version 4.32) until time=100 time units and then created a state file (see attachment). In the OnExit trigger of the source, I increase a global variable, so that it has the value 11 at time=100 time units.

As far as I understand state files, I first have to load the .fsm file, and then, I have to load the .fst file. When I do so, and print out the value of the global variable into the output console, it shows 0 instead of 11.

Therefore, I think, a model of me doesn't run properly after using an .fst file.

Doesn't an .fst file save all information of a model?

The background of my question is, that I need the possibility to save a model at a specific time, and then later, I must be able to let it run further beginning at the time of saving, because my model runs for 1 year real time, and that takes about 2.5 hours.

With kind regards

Markus Bans, Germany
Attached Files
File Type: zip MB_Statefile_Test_V_4.32.zip (46.6 KB, 331 views)
  #2  
Old 07-03-2008
Lars-Olof Leven Lars-Olof Leven is offline
Flexsim Distributor
 
Join Date: Aug 2007
Location: Sweden, Borlnge
Posts: 312
Downloads: 278
Uploads: 2
Thanks: 300
Thanked 256 Times in 139 Posts
Rep Power: 330
Lars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to beholdLars-Olof Leven is a splendid one to behold
Default

Hi,

Yes, it looks like the state file do not include all information. Missing the Global Variables.

One solution is to use labels instead. The values of the labels is stored in the state file.

Lars-Olof
  #3  
Old 07-03-2008
Jason Lightfoot Jason Lightfoot is offline
Flexsim Consultant
 
Join Date: Aug 2007
Location: Somerset, UK
Posts: 719
Downloads: 20
Uploads: 0
Thanks: 123
Thanked 953 Times in 446 Posts
Rep Power: 773
Jason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond reputeJason Lightfoot has a reputation beyond repute
Default

Markus, I tested this too in a tiny model and found the values are not saved.

You'll also find that the random number stream states are not saved at the moment so if you're hoping to repeat what would have happened without the state save, at the moment it's a bit tricky.

If you really need this, you could alter the session and save it as a a special statesaving session. I've already done this for the streams and it seem to work ok. If I get a chance I'll have a look at doing it for the global variables too and post it here if it works.

In the meantime I'll add it to the dev list.
  #4  
Old 07-08-2008
Markus Bans Markus Bans is offline
Flexsim User
 
Join Date: Aug 2007
Location: D-41199 Moenchengladbach, Germany
Posts: 8
Downloads: 28
Uploads: 1
Thanks: 2
Thanked 15 Times in 4 Posts
Rep Power: 0
Markus Bans will become famous soon enough
Default Randomness, messages etc.

Hi there,

tks. for your replies.

It would be very important for me to know , what isn't saved in an .fst file.

Global variables and randomness were mentioned, but what about e.g. messages etc. etc.

If I knew, what isn't saved, then maybe I could create a working .fst file, what is very helpful when looking for errors in long running models, but also of worth for the customers.

But if it isn't possible, then Flexsim should be able in a prospective version!


Kind regards,

Markus Bans, Germany


Thread Thread Starter Forum Replies Last Post
Limit in the completion hints? Global Tables, Global Variables, etc.? Tom David Gripes and Goodies 6 09-09-2008 04:05 PM
Opening of FlexSim State Files Fadhlullah Bin Rahmat Q&A 0 02-18-2008 04:57 AM
GUI & linked variables Iulian Marin Ion Q&A 2 11-27-2007 10:23 PM
Creating fsm-Files Ralfi Q&A 4 10-16-2007 06:07 PM


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.