I'm working on a problem that involves constraints containing certain kind of expressions, which are to be solved using LPsolve
. I can't seem to figure out how to formulate the constraints though.
e.g:- I'd like to reformulate the following constraint:
+0.35 C1 +0.15 C2 +0.15 C3 +0.2 C4 +0.15 C5 +0.15 C6 +0.15 C7 +0.15 C8 +0.15 C9 +0.15 C10 <= 3750;
as
+(0.35)*(1+C1) +0.15*(1+C2) +0.15*(1+C3)....+0.15*(1+C10)<= 3750;
I've tried using set.constr.value()
but that only takes a fixed row as an input.
and then solve for the optimal solution.