I am making an lp solution but am stuck at defining constraints.
Suppose I have 9 decision variables, {x1,x2...n}
Suppose also I have a constraint that involves a subset of all decision variables:
x1 / (x1+x2+x3) = 40/100
Then how can I write this for lpsolve to use this?
I have tried:
add.constraint(model, c(1,0,0,0,0,0,0,0,0), "=", c(.4,.4,.4,0,0,0,0,0,0))
and
add.constraint(model, c(0.4,0,0,0,0,0,0,0,0), "=", c(1,1,1,0,0,0,0,0,0))
Thanks in advance.