Multi-sack 0/1 knapsack

Правка en1, от mrinmoy_2003, 2024-11-17 08:50:34

I want to start off by saying that I don't know the solution to this. I wanted to start a discussion from others about what ideas they have to solve it. Also I couldn't find about this anywhere else on the internet so thats why I'm asking this here. Please don't be mad at me if its a bad question.

So there's the 0/1 knapsack problem where you maximize the profit. Thats cool but theres only one sack. What if theres more than one sack? Everything else is the same. A bunch of objects with some weight and profit, bags with some weight limit (all bags have same weight limit), and you can only, either take an object or leave it. You can't break it up into different bags or only take fractions of it or anything like that. Any ideas are welcome.

The only approach I can think of is just try out all the permitations of the object list and insert them ony by one into the bags till they fill up then move on to the next bag.

If this problem is too difficult you can also assume that profit from all objects is the same ,i.e., one. (I added this constraint because I came across a problem somewhere and that perfectly fit into this type of problem where profit from all objects was same. That's how i started wondering about this topic).

Теги dp, knapsack, discussion

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский mrinmoy_2003 2024-11-17 08:56:19 5
en1 Английский mrinmoy_2003 2024-11-17 08:50:34 1273 Initial revision (published)