Westeros scenario does not solve with --foresight=1
- Dominant language
- Jupyter Notebook
- Stars
- 150
- Forks
- 178
- Avg merge
- 17h 32m
- Merged PRs (30d)
- 2
Description
Hi, I'm making power sector model using MESSAGEix.
And I was wondering what is difference between perfect-foresight and recursive-dynamic.
So, I just try westores examples at first.
below is what i did.
1) open the 'westeros_baseline.ipynb'
2) chage a code 'scenario.solve()' to 'scenario.solve(gams_args =["--foresight=1"])'
※python version: 3.9.7 and I use latest version of all package(message-ix, ixmp, ...)
And then, the moel said 'GAMS errored with return code 3: There was an execution error'.
So I found MESSAGE_run.lst, and I can find some error like that.
※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※
**** Exec Error at line 2780: Equation infeasible due to rhs value
**** INFEASIBLE EQUATIONS ...
---- CAPACITY_CONSTRAINT =L= capacity constraint for technology (by sub-annual time slice)
CAPACITY_CONSTRAINT(Westeros,coal_ppl,690,700,year).. 0 =L= -18.2648401826484 ; (LHS = 0, INFES = 18.2648401826484 ****)
CAPACITY_CONSTRAINT(Westeros,wind_ppl,690,700,year).. 0 =L= -12.1765601217656 ; (LHS = 0, INFES = 12.1765601217656 ****)
REMAINING 5 ENTRIES SKIPPED
**** Exec Error at line 2806: Equation infeasible due to rhs value
**** INFEASIBLE EQUATIONS ...
---- CAPACITY_MAINTENANCE_HIST =E= constraint for capacity maintenance historical installation (built before start of model horizon)
CAPACITY_MAINTENANCE_HIST(Westeros,coal_ppl,690,700).. 0 =E= 18.2648401826484 ; (LHS = 0, INFES = 18.2648401826484 ****)
CAPACITY_MAINTENANCE_HIST(Westeros,wind_ppl,690,700).. 0 =E= 33.8237781160156 ; (LHS = 0, INFES = 33.8237781160156 ****)
**** Exec Error at line 2830: Equation infeasible due to rhs value
**** INFEASIBLE EQUATIONS ...
---- CAPACITY_MAINTENANCE_NEW =E= constraint for capacity maintenance of new capacity built in the current period (vintage == year)
CAPACITY_MAINTENANCE_NEW(Westeros,coal_ppl,700,700).. 0 =E= 3.5527136788005E-15 ; (LHS = 0, INFES = 3.5527136788005E-15 ****)
※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※※
I know the above code's meanings, but...
Why did I get these results?
How can I solve it?
I guess "scenario.solve(gams_args =["--foresight=1"])" is right, because if i adjust ["--foresight=0"], it operate well( 0 means perfect-foresight, you know)
Please.. help me!
Thanks! :)
Contributor guide
Research direction
Reproduce the failure in westeros_baseline.ipynb by comparing scenario.solve(gams_args=["--foresight=1"]) with --foresight=0, then inspect MESSAGE_run.lst and the reported CAPACITY_CONSTRAINT and CAPACITY_MAINTENANCE equations. Done means identifying why the foresight setting makes the Westeros scenario infeasible and documenting or correcting the supported way to run it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- jupyter-notebook, python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100