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 06-23-2008
Simon Farsah Simon Farsah is offline
Flexsim User
 
Join Date: Jan 2008
Posts: 23
Downloads: 4
Uploads: 0
Thanks: 23
Thanked 0 Times in 0 Posts
Rep Power: 151
Simon Farsah is on a distinguished road
Default Cost function as a PFM in a Experimenter

Hi Guys,
I want to create a cost function and use it as a Performance Measure (PFM) in an Experimenter with several scenarios (variable = batch size). My model contains several processors, so I want to create a lable “cost” for each one: cost = (Processtime + Setuptime)*cost rate.
Which command let me get the process and setup time (in numerical form) of the processor ?
If I use “getstatenum” command, how can I specify the state? I tried to use it in the “OnSetupFinish” and “OnProcessFinish” triggers, but it gives me all the simulation run time and not the setup/process run time.

Thanks for ur help

Simon
  #2  
Old 06-23-2008
Brandon Peterson's Avatar
Brandon Peterson Brandon Peterson is offline
The Flexsim Consultant
 
Join Date: Jul 2007
Location: Salt Lake City, Utah
Posts: 382
Downloads: 29
Uploads: 6
Thanks: 192
Thanked 516 Times in 235 Posts
Rep Power: 490
Brandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant futureBrandon Peterson has a brilliant future
Default

Simon,

The states you are looking for are STATE_PROCESSING and STATE_SETUP. The following line of code will get you the time an object spent processing as of it's last state update:

getnodenum(rank(state_profile(myobject), STATE_PROCESSING))

States are updated on an object everytime the object changes states, the stop button is pressed, updatestates() is called, or updatestate(myobject) is called.

If you are using a visual tool to display the data then you will want to be aware of the states being or not being updated. However, if you are calling this at the end of the model run then you probably don't need to worry about it.

Good Luck,
Brandon
__________________
thats not normal.
The Following User Says Thank You to Brandon Peterson For This Useful Post:
Simon Farsah (06-23-2008)
  #3  
Old 06-23-2008
Simon Farsah Simon Farsah is offline
Flexsim User
 
Join Date: Jan 2008
Posts: 23
Downloads: 4
Uploads: 0
Thanks: 23
Thanked 0 Times in 0 Posts
Rep Power: 151
Simon Farsah is on a distinguished road
Default

Thanks Brandon it works...

Simon


Thread Thread Starter Forum Replies Last Post
[Suggesiton] UNDO function KelvinHo Gripes and Goodies 10 05-23-2008 01:58 AM
Print function David Chan Gripes and Goodies 0 05-21-2008 09:38 PM
Cost analysis? mallik Q&A 5 04-07-2008 10:54 AM
max() is a deprecated function; use maxof() instead! Lolke Koopmans Gripes and Goodies 0 02-25-2008 02:45 AM
How to report setup cost? jbruxelle Q&A 1 09-05-2007 12: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.