Hello Gurus,
Hello Gurus, am having difficulty in clearing this error code in my model.
Would be very grateful if your could help.
Regards,
Dele
Incompatible operands for addition error 133.
-
- User
- Posts: 12
- Joined: 5 years ago
Incompatible operands for addition error 133.
- Attachments
-
- 19.gms
- (590.29 KiB) Downloaded 314 times
Re: Incompatible operands for addition error 133.
The code is unclear what z is. Your declare z as a set: Set z Zone the feedstock is located (within 15 30 45 and 60 miles) from the plant /z1*z4/ but then you use it as a variable in equation
and more obvious in your loop:
I changed the variable z to a zz but then there are plenty of other compilation errors.
-Michael
Code: Select all
con_obj(om1).. 1$z(om1) - dir(om1)*sl(om1) =e= rhs(om1);
Code: Select all
repeat
solve mod_payoff using MINLP maximizing obj;
payoff(op,oo) = z.l(oo);
z.fx(oo) = z.l(oo); // freeze the value of the last objective optimized
-Michael
-
- User
- Posts: 12
- Joined: 5 years ago
Re: Incompatible operands for addition error 133.
Tnx Mr, Micheal,
I was able to reduce the compilation errors to the barest minimum. the 'z' was changed to 'b'.
am still having some errors if you could help me with. (in the attached file below).
Tnx sir in anticipation.
I was able to reduce the compilation errors to the barest minimum. the 'z' was changed to 'b'.
am still having some errors if you could help me with. (in the attached file below).
Tnx sir in anticipation.
- Attachments
-
- 20.gms
- (593.84 KiB) Downloaded 268 times
Re: Incompatible operands for addition error 133.
I see no compilations error, but the default MINLP solver (DICOPT) has trouble finding a feasible solution. That's not an error. Optimal, unbounded, and infeasible are all valid and good outcomes of an optimization model. In case of a non-convex model you also have to deal with local optima and local infeasibility when using a local solver. Your model is to big to be solved with a global MINLP solver to determine if it locally or truly infeasible. You need to work this out differently. Bruce McCarl has a nice writeup how to address infeasible models, see Misbehaving Model - Infeasible, https://www.gams.com/fileadmin/communit ... news40.pdf.
-Michael
-Michael
-
- User
- Posts: 12
- Joined: 5 years ago
Re: Incompatible operands for addition error 133.
Tnx. Mr Mike...
I appreciate..
I appreciate..