question

Ben Walker avatar image
1 Like"
Ben Walker asked Ben Wilson edited

How to destroy excess objects once batched.

I would like to either stack 3 objects once they are batched and have them travel as 1 or send 1 object through and destroy the remaining two.

In my current model I have the batch collect 3 and release 1. One object goes to the next queue but the remaining two objects stay on the current queue.

FlexSim 16.1.0
process flowseparatorbatchdestroyobject
flexsimforum.png (170.6 KiB)
5 |100000

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

Ben Wilson avatar image
2 Likes"
Ben Wilson answered Ben Wilson edited

Please see attached model.

This is a solution modifying your existing process flow.

Rather than the batch activity releasing just a single token, it will release all 3 batched tokens. That way you can still reference each individual item in the 3D.

The tokens flow from the batch activity to a decide. The decide just does round robin to route 1 token toward the rest of your logic, and the other two tokens toward the destroy object activity, where the related items are destroyed.


animation.gif (195.3 KiB)
samplemodel.fsm (19.4 KiB)
5 |100000

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

Jeff Nordgren avatar image
0 Likes"
Jeff Nordgren answered Ben Wilson edited

Without seeing what you're doing in your model, the first thing that comes to mind to me is to use the Combiner object rather than a Queue to do the batching. You can either Pack (still 3 objects but put together as one so they could be separated later) or Join.

If Joined, they become one item, as you describe that you need.

If that doesn't work for you maybe you could explain more details or send your model or a sample model of what you are trying to accomplish.

5 |100000

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