question

Ousmane avatar image
0 Likes"
Ousmane asked Jason Lightfoot commented

How to load randomly by batch of article ?

In my model, I get the Orders as a table. and in the table I have the day the order number, the class, the article and the quantities. My model currently allows to make the preparation by order and by pallet in a random way. That is to say, if I have an order with several articles of different classes or not, my operator searches randomly for each box to put on the pallet. What I want to do now is have my "search item" find the item in the same location or close to the previous item if it is the same item and otherwise it will randomly search the box elsewhere.


Someone can help me with this please ?


attached my model for more details


Mini modele preparation.fsm

FlexSim 23.0.1
pickingrandomorderpicking
· 3
5 |100000

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

Kavika F avatar image Kavika F ♦ commented ·
Hey @Ousmane, what criteria classify two items as "the same"? If they have the same class and type? Also, what does "Article" mean in this context? I think I could help if I knew more details about your table setup and what they mean. Thank you.
0 Likes 0 ·
Ousmane avatar image Ousmane Kavika F ♦ commented ·

Hey Kavika, thank you for your help.


1679654448928.png

in my table :


Day : mean the days of the simulation

Order : is the id of the order in each day

Classe : I classifiy my items in 3 classes (1 mean F (frequent), 2 mean M(moyen) and 3 mean R (Rare)) (My rack are also classify as Classe but with different name "Type" (1 for F, 2 for M and 3 for R)

Type : there are two types 1 for food and 2 for non-food (but in the model i send i don't realy use this column

Article : is the id of the item


Pallet : is the nimber of pallet in the order

Boxes : is the number of boxes i have to load separatly

So i consider two items are the same if they have the same Article id


In my model I have my operator loaded in batches of 35 boxes. my operator will therefore have to load 12 boxes of article 1 + 14 boxes of article 2 + 9 boxes of article 3 on the same pallet.


what I really want is for my operator to load all 12 boxes of Article 1 into the same slot by matching the Item Classe and the Type of the slot (and if there are not enough boxes to load in the slot, he must look in the nearest one with the same Classe) if he has finished, to load Article 2 he must randomly search for another slot (matching the Classe of the Article 2 with the slot type) not close to where he loaded Article 1


if you don't understand the problem, please let me know.

0 Likes 0 ·
1679654448928.png (29.2 KiB)
Jason Lightfoot avatar image Jason Lightfoot ♦ commented ·

Hi @Ousmane, was one of Ousmane's or Clair A's answers helpful? If so, please click the "Accept" button at the bottom of the one that best answers your question. Or if you still have questions, add a comment and we'll continue the conversation.

If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always unaccept and comment back to reopen your question.

0 Likes 0 ·
Ousmane avatar image
0 Likes"
Ousmane answered Ousmane commented

I developed a model that does approximately what I want.


during my picking, I use a "Decide", where I compare the value of the previous article with the article that I am about to pick. once it's the same label, I pick near to where I picked the previous article, otherwise I pick randomly.


attached my model


Mini modele preparation.fsm


· 5
5 |100000

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

Ousmane avatar image Ousmane commented ·
it works for one operator, but i have a problem when it is more than one operator. because each operator modify the global vairaible i set.


can i have a variable for each operator ? or is there another way to do what i want to do?

0 Likes 0 ·
Felix Möhlmann avatar image Felix Möhlmann Ousmane commented ·
You could use a label on each operator instead of a global variable.
1 Like 1 ·
Ousmane avatar image Ousmane Felix Möhlmann commented ·
How can i do that ? can i have a example please ?
0 Likes 0 ·
Show more comments
Clair A avatar image
0 Likes"
Clair A answered Clair A commented

Hello @Ousmane ,

Here is a sample model that could help you: 2023-03-24 Picking logic.fsm.

gif1.gif


When the operator starts a picking order, he looks for a non-empty pallet with the matching order type, and the closest from his current location, using this query in the Pull from List activity:

WHERE Type = puller.OrderType AND boxes <> 0 ORDER BY distanceFromPickingOperator ASC

After loading a box, if the order quantity is not met, he will load the next box from the same pallet. If the pallet is empty, he will look again for a non-empty pallet with the matching order type, and the closest from his current location.

I hope that some parts of logic in this model will inspire you for your own model.


gif1.gif (815.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.

Ousmane avatar image Ousmane commented ·
I am thinking about a method, but to do it , i will need to store the Article Id of the the previous box and use a "Decide" to compare the Article id of the two boxes. Do you have a idea how to do that?


Thank you

0 Likes 0 ·
Clair A avatar image Clair A Ousmane commented ·

Before you unload a new box on the pallet, the previous box is the last box on the pallet. You can get a reference to the last box using the last property:

https://docs.flexsim.com/en/23.0/Reference/CodingInFlexSim/FlexScriptAPIReference/Tree/treenode.html#Property-last

For example in the picking logic of the model that I posted earlier, this statement:

token.palletToFill.last.Type

would return the type of the last box stored on the pallet to fill.

0 Likes 0 ·