0

I hope you're doing good

I'm having a bit of trouble finding maximum value for a multiple constrained 0/1 knapsack problem.

I am given the data above and below

Name Weight Volume Value
F     2       1     3
G     1       3     2
H     2       2     4
I     3       2     5


W = 5
V = 4

I have been trying to draw tables for each item and trying to plot the volume and weight values using a recurrence relation.

I can easily apply a recurrence relation for 2 values (IE OPT(k,w)) but I'm looking for more advanced OPT(k,w,v) recurrence relation and there's limited information on the web for this.

Primarily I have 2 questions.

  1. which recurrence relation would I use in order to generate the tables of data for each item?

and

  1. which set of items would I need to pick in order to obtain the maximum value?
George
  • 101
  • 9
  • 1
    Does this answer your question? [Knapsack algorithm with 2 properties. How to implement that in a 3d array?](https://stackoverflow.com/questions/13445402/knapsack-algorithm-with-2-properties-how-to-implement-that-in-a-3d-array) – Abhinav Mathur Jan 21 '21 at 05:19
  • Cheers I’ll have a look at this – George Jan 21 '21 at 08:46

0 Answers0