Batch transfer and individual processing

Batch transfer and individual processing

unmesh_t
Not applicable
48 Views
12 Replies
Message 1 of 13

Batch transfer and individual processing

unmesh_t
Not applicable

[ FlexSim 18.1.1 ]

I am trying to simulate the following system.

Source -> Queue1 -> Queue2 -> Processor -> Queue3, there is also an operator in this system.

The source creates a flowitem every 5 seconds which is released to Queue1. The operator is supposed to transfer a batch 20 flowitems from Queue1 to Queue2. After the batch is unloaded at Queue2, the operator is supposed to process 1 item at a time on the Processor. The process time is 5 seconds avg. with a std. dev. of 0.5 seconds. Once the operator finishes working on the 20th flowitem, he is supposed to check if Queue1 has 20 items. If yes, the process continues, if no, he waits untill there are 20 items in Queue1.

What is the best way to accomplish this? I have tried a few things but I dont seem to get the priorities right.

Thanks in advance.

0 Likes
Accepted solutions (1)
49 Views
12 Replies
Replies (12)
Message 2 of 13

tanner_p
Not applicable

All of this can be modeled in Process Flow. If you'd like, I can make a demonstration model for you. Have you tried using Process Flow before?

Message 3 of 13

unmesh_t
Not applicable

Hey Tanner,

Thanks for your response. I have used process flows for basic tasks. I am having trouble translating my requirements into the process flow logic/terminology, but if I see a process flow, i'll be able to understand it.

Thanks

0 Likes
Message 4 of 13

joerg_vogel_HsH
Mentor
Mentor
  • Queue releases 20 items in a batch of 20.
  • The operator loads 20 items.
  • The operator travels to the Queue2.
  • The operator unloads 20 items into the Queue2.
  • The Queue closes its input until the 20th item is processed.
  • The operator loads one item. It can be the last or first in the Queue2.
  • The operator travels to the Processor.
  • The operator unloads the item into the Processor.
  • The operator stays at the Processor while processing time lasts by a delay task or an utilize task.
  • The operator transport the next item and so on.
  • The processor finish processing the last item, the Queue2 is empty.
  • The input of the Queue2 opens.
  • The sequence starts again

This sequence is also possible in 3D only.

Edit: Hint: set the capacity of the Queue2 to 20. If you want to control strictly the Queue2, you can open and close the output of the Queue2 until the queue is full.

Message 5 of 13

tanner_p
Not applicable
Accepted solution

Here is an example of how to do it in Process Flow. We recommend becoming familiar with Process Flow as this is the direction the software is heading in the future. This logic actually ended up challenging me a bit, so I understand your confusion.

Here's a few notes on what is going on in the logic:

1) The "Acquire Resource" is used to claim the Operator so that he cannot be acquired by another resource until after the entire process for the batch is finished. This simulates his availability.

2) As items arrive in the queues, they are pushed to a list. The token then pulls them from the list to be loaded and then unloaded to the next destination.

3) The "Assign Label" activity basically marks the token every time it goes through the load/unload process. This is like keeping a tally.

4) Finally, the "Decide" activity reads the label of the token to see if the batch (or tally) of 20 has been completed.

Hopefully it works. I've attached the model to this comment. Let me know if you have additional questions and I'd be happy to try and answer them.

batch-transfer-process.fsm

Message 6 of 13

emily_hardySTLSK
Autodesk
Autodesk

Hi, @Unmesh T, did either of these answers help you?

Message 7 of 13

unmesh_t
Not applicable

Hi, @Emily Hardy, these answers were indeed very helpful. Thank You.

Message 8 of 13

unmesh_t
Not applicable

Hey @Tanner Poulton,

Thanks for this answer. I tried to learn more about the process flows and how they can be used to control the simulation. The model you attached in your response makes the operator transfer 1 item at a time until 20 items are transferred, and then the operator processes one item at a time until the batch is finished. My requirement is that I need the operator to transfer 20 (or any preset absolute value) objects at a time and then process them one at a time. During this time, if there are more than 20 objects collected at the upstream queue (from which the operator picks up his batch of 20), I need the operator to transfer 20 objects only. Please see the attached model. I have used some of the concepts you used in your models and some other I found online / in the manual. I this that my solution is a workaround at best. for following reasons.

1) If i increase the capacity of 'queue1' to more than 40, the logic fails in the decide stage in the process loop

2) I need the operator to be able to transfer the batch to 'queue 2', and start picking up items from the same queue. I had to use 'queue 3' so that I could push the items to 'list2', and subsequently use the process loop as intended.

Is there way to correct this model and to potentially optimize it? and I may be asking for a lot here, but if you change/optimize/modify certain parts of the model, batch-transfer-trial-2.fsm ,can you also explain why you chose to make those specific changes.

Thanks,

Unmesh

0 Likes
Message 9 of 13

tanner_p
Not applicable

@Unmesh T Is your attached model working as you want it to as long as there are less than 40 items in Queue1? I don't want to mess too much up if possible.

0 Likes
Message 10 of 13

unmesh_t
Not applicable

@Tanner Poulton, Yes. If the queue1 capacity is set at 40, the model works exactly as I want it to.

0 Likes
Message 11 of 13

raja_sekaran
Not applicable

@Unmesh T

In the attached model, I have updated the logic in decide activity to send the token based on the current content in "Queue3", also added zone activity in transfer loop to control the task assignment. I hope this is what you are looking for. unmesh-support.fsm

Message 12 of 13

unmesh_t
Not applicable

@Raja Sekaran Yes this is certainly a more refined version of what I was trying to accomplish. Is there a list of definitions of the various properties, e.g. the length of subnodes. I'd really appreciate it. Thanks

0 Likes
Message 13 of 13

raja_sekaran
Not applicable

@Unmesh T Yes, you will get the definitions of the properties in the user manual under the following section. In version 18.1.2

Reference >> Coding in Flexsim >> Flexcript Class Reference

0 Likes