Search found 373 matches
- 4 years ago
- Forum: Solvers
- Topic: the solver found integer solution
- Replies: 11
- Views: 9692
Re: the solver found integer solution
No, unfortunately I can't. That's not how things work. I assume that your model is a description of an actual problem. As mentioned before, it is not unusual that it can take a long time to solve a MIP (especially when outdated software is used). You cannot just add some arbitrary constraints to get...
- 4 years ago
- Forum: Syntax
- Topic: Speeding up constraint creation during compilation
- Replies: 2
- Views: 2222
Re: Speeding up constraint creation during compilation
James, The crux is that you are making a lot of comparisons (in the range of card(h) x card(h)) in the equation body. Also, you are doing that for every z where the condition is completely independent from z. It is faster to precompute a mapping set outside the equation body. Basically you want for ...
- 4 years ago
- Forum: Modeling
- Topic: Change Equation over time
- Replies: 4
- Views: 3143
Re: Change Equation over time
You can just move the dollar condition into the equation body.
I hope this helps!
Fred
Code: Select all
eq(t).. I(t) =E= S(t) * (Y(t)$(ord(t)<=5) + AY(t)$(ord(t)>=6)) ;
Fred
- 4 years ago
- Forum: Solvers
- Topic: the solver found integer solution
- Replies: 11
- Views: 9692
Re: the solver found integer solution
Hi,
As Michael already suspected, the log states
Fred
As Michael already suspected, the log states
Code: Select all
CPLEX Error 1001: Out of memory.
- 4 years ago
- Forum: Solvers
- Topic: the solver found integer solution
- Replies: 11
- Views: 9692
Re: the solver found integer solution
Hi, You are using a 13(!) year old version of GAMS and Cplex. I highly recommend to update to a more recent version (https://www.gams.com/download/). With the latest GAMS 27.2.0, Cplex reaches a smaller gap after seconds than what you get after hours. Still, the model seems to be challenging and you...
- 4 years ago
- Forum: Modeling
- Topic: Change Equation over time
- Replies: 4
- Views: 3143
Re: Change Equation over time
Hi, You can have two different equations, one for t<=5 and one for t>=6. Assuming that t is an ordered set (https://www.gams.com/latest/docs/UG_OrderedSets.html), this can be done as follows: equation eq1(t), eq2(t); [...] eq1(t)$(ord(t)<=5).. I(t) =E= S(t) * Y(t); eq2(t)$(ord(t)>=6).. I(t) =E= S(t)...
- 4 years ago
- Forum: Solvers
- Topic: the solver found integer solution
- Replies: 11
- Views: 9692
Re: the solver found integer solution
Hi, You wrote that you get MODEL STATUS 8 integer solution . Applying IIS makes no sense because it computes an irreducible infeasible set but your model is feasible. SOLVER STATUS 3 resource interrupt means that a time limit was reached before any other termination criterion was satisfied. This is ...
- 4 years ago
- Forum: Solvers
- Topic: the solver found integer solution
- Replies: 11
- Views: 9692
Re: the solver found integer solution
Hi, Sometimes it can take a long time to solve a difficult MIP. If you need the optimal solution you can set the relative optimality criterion optcr to zero and at the same time you should in crease the time limit reslim to give CPLEX more time to solve to optimality: https://www.gams.com/latest/doc...
- 4 years ago
- Forum: Modeling
- Topic: Problem with loop in MINLP model.
- Replies: 0
- Views: 1648
Re: Problem with loop in MINLP model.
Hi, Since you don't share with us how you set the starting point when you are not using a loop, there is no chance to tell you where the difference comes from. What you do in the loop looks strange. You set many variable levels and then you clear most of the variables before you do anything with the...
- 4 years ago
- Forum: Modeling
- Topic: stochastic programming
- Replies: 7
- Views: 7441
Re: stochastic programming
Where exactly are struggling? PV is a variable that is currently indexed with bus. If you want to index it over time as well, add a t to the index PV(bus,t) and make sure to adjust your code at all places where the variable occurs accordingly.
Regards,
Fred
Regards,
Fred