Go Back   FlexSim Community Forum > FlexSim Software > Tips and Tricks
FAQ Downloads Calendar Search Mark Forums Read vBExperience Register

Tips and Tricks Share helpful modeling ideas

Reply
 
Thread Tools Display Modes
  #1  
Old 04-20-2012
Phil BoBo's Avatar
Phil BoBo Phil BoBo is offline
Flexsim Development
 
Join Date: Jan 2008
Posts: 649
Downloads: 103
Uploads: 18
Thanks: 342
Thanked 1,093 Times in 435 Posts
Rep Power: 871
Phil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond reputePhil BoBo has a reputation beyond repute
Default Virtual Queue Content

You can use flowitem recycling to speed up a model. Flowitem recycling uses more memory in order to store flowitem objects instead of destroying and recreating them. This helps increase the speed of a model run.

Conversely, a model may have too many flowitems and run out of memory. For this case, you could do the opposite of flowitem recycling: destroy flowitems when they are in queue and recreate them when they need to move downstream. This could be helpful if you have queues with so many flowitems that you run out of memory on your system.

Attached is an example model that has "virtual" content on a queue. OnEntry of the queue, it sends a delayed message in 0 time to check if the item is still in the queue. If it is, then it destroys that item and increments a label. When the downstream object (a processor in this model) becomes available, it sends a message to the queue to turn a virtual item back into a real item.

The itemtype and labels on the items are not preserved in this sample. If you want to preserve that data, you would need to store it somewhere else. This isn't a silver bullet for all memory problems, but it might give you an idea on how to minimize memory usage if you have queues with high content.

For fun, this model also custom draw code to draw a stack of boxes in the queue for its virtual content. Also, text visual tools are shown to display the actual number of flowitems in the model and the virtual queue content.
Attached Thumbnails
Click image for larger version

Name:	virtual_queue_content.jpg
Views:	174
Size:	11.5 KB
ID:	1759  
Attached Files
File Type: fsm virtual_queue_content.fsm (32.1 KB, 173 views)
Reply With Quote
The Following User Says Thank You to Phil BoBo For This Useful Post:
LINWEIXU (04-22-2012)
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Running Flexsim on a Virtual machine Kenny Macleod Pre-sales Questions 5 08-29-2013 07:24 PM
Constant content of queue (or CONWIP) Stefan Trabut Q&A 4 05-04-2011 12:16 AM
Merge Sort Virtual Length John Behrends Q&A 1 12-12-2010 07:30 PM
Starting content in the Queue Bartosz Misiurek Q&A 4 10-04-2009 08:25 AM
How to get interval average,max,etc of a queue content ? qin tian Q&A 5 02-14-2008 03:11 PM


All times are GMT -6. The time now is 08:12 PM.


Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2014, vBulletin Solutions, Inc.
Copyright 1993-2014 FlexSim Software Products, Inc.

Please Wait

loading

Create a password for your FlexSim account.






Tell us about your organization.

Healthcare Commercial Government Educational Other

Please provide additional information to complete your commercial account.

Please provide additional information to complete your account.

Please provide additional information to complete your account.

Please provide additional information to complete your government account.

Please provide additional information to complete your student account.

Please provide additional information to complete your educator account.








graduation date



Are you a student or educator?

Student Educator

Download FlexSim Express

Download

Would you like to tell us more about yourself?






Download FlexSim Express

Download

Do you have a FlexSim community forum account?

Yes, I have a forum login
No, I'm not on the forum

Please provide your community forum credentials to link your forum account with your FlexSim Account.Forgot your username or password?

Are you interested in posting to the FlexSim community forum?




Powered by NuWiki v1.3 RC1 Copyright ©2006-2007, NuHit, LLC