ASk HN: How do I solve 2d bin packing problem if I can change the bin size?
The inputs are:
-A list of unique small rectangles. The list includes the dimensions of the small rectangles, a number that represents the rectangle’s frequency of usage relative to the other small rectangles, and the orientation (whether or not it can be rotated 90 degrees)
-The maximum number of large rectangle dimensions. And the minimum and maximum dimensions of the large rectangles.
The output is an optimized list of large rectangle dimensions.
One way to prove the validity of the result is by creating a nest of the small rectangles within the large rectangles. Here is a paper and an open source project that provides a solution to the 2d bin packing problem that we are currently using to nest. We are using the Maximal Rectangle algorithm and we vary the heuristics (typically bottom left or contact point heuristics).
http://clb.demon.fi/files/RectangleBinPack.pdf
https://github.com/juj/RectangleBinPack
How do I solve this problem?
1 comment
[ 3.3 ms ] story [ 9.6 ms ] threadIn most papers it is assumed that you have a finite set of bins with different, but fixed dimensions to select from (as opposed to your problem, where both dimensions seem to be free). A notable exception is [3] (maybe there are more, but it's the only one I have come across).
There is also quite a lot of literature on the strip packing/cutting problem, which deals with the case of one fixed and one "infinite" dimension.
[1] http://www.sciencedirect.com/science/article/pii/S1572528605...
[2] http://www.sciencedirect.com/science/article/pii/S0305054808...
[3] http://www.tandfonline.com/doi/abs/10.1080/00207540903317523