Bin Allocation from a Lot based on set of rules

Bala216

New Member
Joined
Jun 12, 2020
Messages
8
Office Version
  1. 2019
  2. 2016
Platform
  1. Windows
Hi There,

Here is the screen shot of my problem scenario and output required....

Forum experts help is highly appreciated to solve this problem...

Thank you...

Box Number Generator Problem Description.xlsx
ABCDEFGHIJKLMNOPQRSTUVW
1Box Number Generator
2
3Technical Terms used:
41. Lot Number
52. Size
63. Pairs
74.Box Number
8
9Scenario:
101. A lot number is a 5 digit unique identity number given for a group of pairs from different sizes.
112. A lot will have minimum 18 Pairs and maximum of 144 pairs in different sizes and multiples of 18 pairs (eg. 18,36,54,72,90,108,126,144)
123. Each size will have minimum zero pairs and maximum of 144 pairs and will be always multiple of 3. (eg. 0, 3, 6,9,12,15………max of 144)
134. Minimum size is 2.5 and increases with an increment of 0.5 and maximum would be 12.
14
15Picotral Representation of a typical scenario:
16Sizes / Pairs
17Lot Number:2.533.544.555.566.577.588.599.51010.51111.512Total Pairs
181234536912152436363144
196789015339121531272
20789013333333333636
21
22
23Objective:
24
251.When a size run is filled up for a lot number, then these sizes has to be split/ grouped into sum of 12 pairs.
262. Each group of pairs (called Box ) will be assigned a box number starting from 1 to maximum of 12.
273. A full box will have maximum of 12 pairs and minmum of 3 pairs and always be either 3 or 6 or 9 or 12.
284. Sizes more than 12 pairs are split into multiples of 12 and assigned box number
295. Sizes less than 12 are grouped with other sizes to make up 12 pairs if possible to form a box.
306. 3 can join only with 9, if this option is not available then the second option is to join with 6 & 3 . Simillarly 6 can join only with 6 or 3 & 3. 9 can join with 3
317. A box can have minimum one size and maximum of 4 sizes
32
33A typical grouping of size / pairs into Box numbers for the above 3 lot numbers is as follows:
34
35Lot No.12345
36Box Number123456789101112
37Size2.53.54.55.56.56.57777.57.57.5
38Pairs(1-3)(1-6)(1-12)(1-12)(1-12)(13-24)(1-12)(13-24)(25-36)(1-12)(13-24)(25-36)
39
40Size45.5
41Pairs(1-9)(13-15)
42
43Size10.5
44Pairs(1-3)*
45
46Size
47Pairs
48
49Lot No.67890
50Box Number123456789101112
51Size333.555.58.5
52Pairs(1-12)(13-15)(1-3)(1-12)(1-12)(1-12)
53
54Size4.54
55Pairs(1-9)(1-3)
56
57Size5.5
58Pairs(13-15)
59
60Size7
61Pairs(1-3)
62
63Lot No.78901
64Box Number123456789101112
65Size3.55.57.5
66Pairs(1-3)(1-3)(1-3)
67
68Size468
69Pairs(1-3)(1-3)(1-3)
70
71Size4.56.58.5
72Pairs(1-3)(1-3)(1-6)
73
74Size57
75Pairs(1-3)(1-3)
76
Problem Description
Cell Formulas
RangeFormula
V18:V20V18=SUM(B18:U18)
 
It is a common issue with this type of problem that the requirements are unclear.
For example, using your test4 data, it is possible to have 23 non-zero parts in 14 boxes. It is also possible to have 22 non-zero parts in 15 boxes. I'm not sure if it is possible to have 22 non-zero parts in 14 boxes.
Which solution is preferred, and why? That would be a question for the OP to clarify.
 
Upvote 0

Excel Facts

Waterfall charts in Excel?
Office 365 customers have access to Waterfall charts since late 2016. They were added to Excel 2019.
Good point. About the "parts" term, does that mean any subset of shoes of one size added to a bin? For example, if I subdivide 9 pairs of size 10 into 3-3-3 to use toward filling three bins, then each of those would constitute a "part"...so in that case, three parts?

Just to add to the mix (or confusion?), I had a look at the test4 data (9, 6, 21, 9, 21, 9, 9, 9, 9, 9, 3, 6, 3, 3, 9, 9, 6, 3, 3, 3 ) with the three-table formula-based approach I posted. I get 14 boxes (13 complete and 1 incomplete), and those are formed from a total of 25 parts (using the definition I suggested above), while subdividing 2 sets of partials (size 10 was split 3-3-3, and size 10.5 was split 3-3).
 
Upvote 0
Yes, that's what I mean by "Parts".
The solution of 23 non-zero parts in 14 boxes comes from a slightly modified model, where I solve for the minimum number of boxes and then constrain the number of bins at that level and minimise the number of parts.
 
Upvote 0
Thanks for the clarification. I'm curious if the OP weighs in about which factors matter and their relative weights: number of bins, number of parts, and number of sets of partials that are subdivided.
 
Upvote 0
H
Thanks for the link. I haven't had much luck with OpenSolver on other integer optimization problems, but this might be interesting to investigate further. I had a look at your Formulation/Notes and think your assessment of the number of sizes per bin (<=4) is correct: the number of partials is either 0, 3, 6, or 9--and since 0 is moot, one cannot have more than 4 sizes in a bin. So your point about not needing enforcement of that constraint is spot on.

I have to apologize for messing up the description of the rules...unfortunately, I forgot to mention a critical point: after the first partial is added to a bin and the search begins for the next partial, priority is given to using a 9 over a 6 or 3, and to using a 6 over a 3. Other than this detail, the rest of my description is consistent with earlier posts offered by @Bala216.

I'll recap the Phase 1 and Phase 2 rules because they illustrate something important:

Phase 1:
  1. Allocate to individual bins all sets of 12 pairs (homogeneous sizes) that are readily apparent in the original list.
Phase 2:
  1. Searches always begin at the left and proceed to the right (small-to-large size)---this applies to the first partial added to a bin and any subsequent partials.
  2. The first partial added is always the smallest size available, and any other partials are added in the order they are encountered while first honoring the priority to use larger partials before smaller partials if the situation allows. This means that if we have a new bin and the smallest shoe size partial is a quantity of 3 (so it is added first), then the partials are searched left-to-right for a 9, and if none, then for a 6, and if none, then for another 3. If multiple 9's are encountered in this example, the first one would be added. Similarly, if multiple 6's are encountered and no 9's are available, then the first 6 would be added, and so on if 3's were present and no 9's or 6's were available...the first encountered would be added.
  3. Partials are not to be subdivided.
  4. For any given bin that is being filled, after searching for suitable partials and finding none, the bin is set aside and treated as an incomplete bin, and a new bin is begun.
The important take-away from the Phase 1 and Phase 2 rules is that they are completely deterministic. This part of the problem does not lend itself to optimization.

Once the partials remaining in incomplete bins are reinstated and the stringent rules for forming sets of 12 are lifted, as is done in Phase 3, that would lend itself to an optimization strategy. In that case, there is considerable latitude in combining the remaining partials and subdividing them if necessary. I believe the primary objective in that case would be to minimize the number of bins, and if there are multiple solutions, then preference would be given to those that minimize the number of sets of partials that need to be subdivided. Even then, more clarity would be needed to choose a preferred solution since there may be multiple solutions with those characteristics. With that said, it's not clear to me either where the threshold is for an acceptable solution...I think this comes close, but some details are still lacking.


HI i_nth... Welcome to the thread and thanks for your inputs..

Hi Kirk...Thanks for your in depth understanding of the problem and detailed description of it to i_nth.... I doubt whether I could have been able to do that..

Coming back to the discussion, I hope now there is no confusion up to phase-II. Coming to phase-III, as Kirk has mentioned, the objective would be to have less number of bins to combine the partials and also the final spill over partials quantity is to be minimum. In that way i think we can narrow down and eliminate possible multiple options. Here with I have attached the illustration of partial combination rule set for your further understanding and I hope that will help to understand better and arrive at an optimal solution. In the illustration the order of priority runs from top to bottom... Hope we will have interesting outcome...

And thank you guys for your valuable time and input to refine the solution to this problem....
 

Attachments

  • Partials combination rule set (397x640).jpg
    Partials combination rule set (397x640).jpg
    101.3 KB · Views: 9
Upvote 0

Forum statistics

Threads
1,215,059
Messages
6,122,917
Members
449,093
Latest member
dbomb1414

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top