I am solving a multi-year MINLP problem. I would like to solve the problem from year to year. That is, I would like to solve the problem for one year at a time in a way that GAMS should use previous year’s solution to solve the next year problem. For example, once the program solves for year 1, then it should use the solution of year 1 to solve the problem for year 2 and so on. How can I do it in a single run?
Hi
You could use a loop over all years (You might have to rewrite the model equations, so that the time is not part of the model anymore)
set t /2018*2050/
* Define the model parameters for each year
table myyearlyvalues(t,*);
capa ...
2018 10
2019 11
;
loop(t,
mymodelparameter = myyearlyvalues(t, "capa");
...
solve mymodel
* Adjust the start values (if necessary for the next year)
mymodelstart = X.L;
);
Gams will, in most cases, use the solution of the previous solve as a starting point for the next solve.