This is really complex !

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Well I have a problem that I can't figure out.
I have Orders that contain from 1 to many items of diferent lenghts, we need
to put these items on boxes (preferebly on boxes of 100" or less,we can cut
the box at any size, they can go on a box >100" if nesesary but it is more
expensive, so we try to fit the pieces on <100" boxes)
ex. piece 1 is 35" piece 2 is 50" both=85" (that will cover one side of the
box, each box has 2 sides that give us a max of 200" all together) so we can
put piece 3 of 50" and piece 4 of 30" both=80
These four pieces will fit on box 1. The size of the box will be 95" that is
because the longer side is 85" plus 5" on each side for end caps.
THIS REPRESENTS ONLY 4 BOXES BUT WE HAVE ORDERS WITH 1 (NO PROBLEM WITH THIS
ONE) OR 10 OR 5 OR 400.
The system needs to sort and accomodate the pieces to create each box.
SOLUTION EXAMPLE: Box 1 = piece 5, piece 3 and piece 7 (ALL= 78")
Box 2 = piece 1, piece 2, piece 4 and piece
6 (ALL= 89")

If anyone could help me I really Thank you.

IT1957
 
This issue is more complex than can be solved in a newsgroup posting. You
are talking about writing some fuzzy logic code here that calculates the
most cost effective solution from a very large number of possibilities.

To take a simple example, if Length was the only criteria (ignoring weight
and volume for now) OpenRecordset on the pieces in this order, ordered by
Length DESC. Loop through the records, packaging the longest ones together
until the first box is full. Then start a new box, and continue the loop
until a Box has been assigned to all pieces in the order.

Obviously we can't write the code for you, but hopefully that gives you a
useful direction to persue.
 
This is really, really complex. Search on "Optimimum packing and depletion"
to get some of the heavy maths behind this problem. "Genetic algorithms"
might be another search term that will lead to some code..
 
Back
Top