I'm trying to implement a recursive algorithm that I came up with that first solves the knapsack for a given objective and then cuts off the solution and then finds the next best solution. However, I have some dependencies among the items in the knapsack which basically group certain items into one big item. I can either choose all or them, or none of them. Is there a way to model this without using additional variables apart from the n indicator ones representing the ones in the knapsack?