Hello All,
I am trying to maximize my objective function which is equation E4. When i place the lower bound on h, GAMS returns : ** Unbounded solution. A variable has reached 'Infinity'. Largest legal value (Rtmaxv) is 1.00E+10
In this program, I am trying to find the value of x which will maximize the value of Q. In the code i have below, i have placed bounds on Q, x and h. The issue I am having is that GAMS simply uses the upper bound I have given the problem as the maximum value. In this case, Q. Now this makes sense because before when the problem was unbounded a variable could go to 1.00E+10, but I don't understand why my system of equations is doing that in the first place. Does this make sense?? I have spent alot of time on this and cannot figure out what the issue is. ANY input would be most appreciated.
Thank You!!!
Also, one more thing, values of x do not change with changes in values of Q, which is the heart of the model. That is what I am trying to solve for. That is, x =416.66 regardless of the value of Q. Q=200, 300, 800, x will always equal 416.66. I dont understand what the issue is. If anyone could please help me understand anything further about this issue I would be most grateful!!
scalars
d mean ocean SWE /14/
s saltfreshwater ratio /1.025/
xw well distance from coast line /1000/
y distance between wells /0/
phi_1 freshwater potential /2.5/;
parameters
C1 coefficient /0.006/
C2 coefficient /0.00079577/;
positive variable
h Freshwater head
Q Optimal pumping rate
x saltwater toe length ;
free variable Z objective variable;
equations
E1 constraint on well pumping equation
E2 Equation for the Freshwater potential
E3 toe constraint
E4 objective fcn for max pumpage;
E1.. phi_1=e=0.5*(h**2-s*d**2);
E2.. C1*x+(Q*C2*log((Power((x-xw),2))+(y**2))/((Power((x+xw),2))+(y**2)))=e=phi_1;
E3.. x=l=xw;
E4.. Z=e=Q;
E5.. h=g=1;
Q.up=600;
Q.lo=200;
x.lo=1.0e-3;
h.lo=1;
model saltwater /all/;
solve saltwater using NLP maximize Z;
* I dont know what execerror does
execerror=0;
display Q.l, x.l, Z.l, h.l;