2 ms·
Solving the knapsack problem for practical instances is actually really easy. (That's a general pattern with NP hard problem: most of them are easy in practice
by eru 9y ago
Solving the knapsack problem for practical instances is actually really easy. (That's a general pattern with NP hard problem: most of them are easy in practice.)
But the problem described is closer to two- or three-dimensional bin packing (or scheduling in general) than to the knapsack problem. See eg http://www.research.ibm.com/people/n/nikhil/papers/Bansal-packing.pdf http://www.research.ibm.com/people/n/nikhil/papers/Bansal-pa...
Another thing to look at is the "Cutting stock" problem (https://en.wikipedia.org/wiki/Cutting_stock_problem https://en.wikipedia.org/wiki/Cutting_stock_problem).