question

Ahmed H2 avatar image
0 Likes"
Ahmed H2 asked Jeff Nordgren commented

Enter schedule for separator to pull from by quantity

Hello,

How i make the six separators in my model to pull from the queues by certain quantity in each day like (day 1 : separator 1 pull 100, separator 2 pull 70 .....-day 2 : separator 1 pull 70, separator 2 pull 60,....and so on) as i have schedule for the separators in excel i want to import it and make the separators read from it how much each one will pull in each day.

trial3.fsm

FlexSim 18.2.2
pull from listpull strategyschedule
trial3.fsm (31.2 KiB)
· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

Jeff Nordgren avatar image
0 Likes"
Jeff Nordgren answered Jeff Nordgren commented

@Ahmed H2,

Attached is your model with the changes that I've made. You didn't attach your Excel file so I don't know what that looks like. So, I created my own Excel file to use with this model, also attached. The Excel file is a simple one with 31 days and the 6 Separators with the production amounts. I only filled out day 1 just to make sure that it worked.

I added code in the OnModelReset trigger to set the day of the month to retrieve the production numbers. If the production number is zero for any Separator, it will not process anything. If you wanted to run all 31 days, you would probably do that in the Experimenter and increment the Global Variable "CurrDay" by one at the end of each replication. Otherwise, you would just need to change the value in the OnModelReset trigger for the day that you want to run processing for.

I also added an Excel import that is used to retrieve the amounts in your Excel spreadsheet and put them into a Global Table called "DailyProduction". The Separators will then look at the Global Table to determine how many flowitems to process.

I hope that all of this makes some sense. Look at the model and see if something like this would work for your situation. If it doesn't, please describe in a little more detail what needs to happen and be sure to include your Excel spreadsheet so that we can see how that should be imported. Just put the attached spreadsheet in the same folder as your model. It makes it a lot easier.

Thanks.

trial3-jn1.fsm

dailyproduction.xlsx


trial3-jn1.fsm (57.8 KiB)
· 9
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.