Here's perhaps a better way to think of the shadow price. (I don't like the word "relax" here; I think it's confusing.)
For maximization problems like this one the constraints can often be thought of as restrictions on the amount of resources available, and the objective can be thought of as profit. Then the shadow price associated with a particular constraint tells you how much the optimal value of the objective would increase per unit increase in the amount of resources available. In other words, the shadow price associated with a resource tells you how much more profit you would get by increasing the amount of that resource by one unit. (So "How much you would be willing to pay for an additional resource" is a good way of thinking about the shadow price.)
In the example you give, there are 16 units available of the first resource and 35 units available of the second resource. The fact that the shadow price of
c1
is 0.727273 means that if you could increase the first resource from 16 units to 17 units, you would get an additional profit of about$0.73. Similarly, if you could increase the second resource from 35 units to 36 units then you would get an additional profit of about $0.02.
So if you could increase just one resource by one unit, and the cost of increasing the first resource is the same as that of increasing the second resource (this assumption is not part of the model), then, yes, you should definitely increase the first resource by one unit.
求解优化问题,利用拉格朗日松弛法时,拉格朗日乘子就相当于shadow price 的意思,当增加约束一个单位,objective will get more profit,so it can be used to change some variable to make the problem converge