Say I have n
linear equations of the form:
ax1 + bx2 + cx3 = y1
-ax1 + bx2 + cx3 = y2
-ax1 -bx2 + cx3 = y3
Here is n=3
and a,b,c
are known and fixed.
I'm looking for the optimal values for x1,x2,x3
such that their ranges are within [-r,r]
for some positive r
and the sum sum(y1,y2,y3)
is maximized.
Is there a package for R which can handle such optimization problems?