question

Amy M3 avatar image
0 Likes"
Amy M3 asked Felix Möhlmann commented

How to get stats on rack slots?

How can i get stats on my warehouse drive in racks? Looking for max slots used at any time and avg to help size the amount of storage we need. I see the normal content stats but with having to segregate my sku, there are holes you can't use so I don't want to just use max contents.

FlexSim 22.2.1
racksstats
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

Felix Möhlmann avatar image
0 Likes"
Felix Möhlmann answered Felix Möhlmann commented

You will have to build a Statistics Collector or other logic to collect that data.

You can use querySlots() to get the number of used slots. Though in order to measure the average number of used slots you will have to do this every time an item enters or exits a slot. Depending on the number of slots, this can become quite expensive in terms of computing resources, so I would suggest to instead store the value of currently used slots somewhere (a label or as part of the Statistics Collector table) and simply increment/decrement it whenever the first item enters a slot or the last item leaves a slot.

For the average, you can add up the time for which slots had at least one item in them, summed up over all slots inside a rack. So you essentially get a "SlotSeconds" value (X slots were active for Y seconds -> XY SlotSeconds. By dividing this by the total model time, you get the average number of occupied slots. Again, this can be done by storing the previous value and adding to it whenever the number of currently used slots updates. Or by using a kinetic tracked variable (for example as a label), whose rate is always equal to the current number of active slots.

Both approaches (StatisticsCollector and Labels on Rack1) are demonstrated in the attached model. The collector listens to slot entries/exits in the "Racks" group. The labels of Rack1 are updated in its triggers.

SlotStats.fsm


slotstats.fsm (637.5 KiB)
· 10
5 |100000

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