Model 2: Suppose that we select the items from the piles one by one so
that each time an item is selected the question is: from which pile should the
next item be selected? Let f(s) = z
∗
(s), namely let f(s) denote the optimal
value of the objective function in (20) when W = s. Then it is not difficult to
show that