I am curious if it is possible to modify (or use) a DP algorithm of the Unbounded Knapsack Problem to minimize the total value of items in the knapsack while making the total weight at least some minimum constraint C.
A bottom-up DP algorithm for the maximization version of UKP:
let w = set of weights (0-indexed)
and v = set of values (0-indexed)
DP[i][j] = max{ DP[i-1][j], DP[i][j - w[i-1]] + v[i-1] }
for i = 0,...,N and j = 0,...,C
given DP[0][j] = 0 and DP[i][0] = 0
where N = amount of items
and C = maximum weight
DP[N][C] = the maximum value of items for a knapsack capacity of C
Can we make a minimization UKP ? If not, can anyone offer another solution or technique to solve a problem like this?
Thanks, Dan
DP[i-1][j - w[i-1]], notDP[i][j - w[i-1]]in the algorithm above. I tried making the edit but it didn't go through the review. - bernie