Weird behavior in cost writing when objective is changed
ml6802 opened this issue · comments
When running MGA, cost files are not reliable for several reasons, some seem to be intentional and should be upgraded, while others seem buggy.
-
cTotal is based on the value of the objective function, not a separate expression. Making it reliably a separate expression will allow for accurate total cost quantification when running MOO or MGA methods.
-
When MGA is run, other cost numbers look funky too for unclear reasons: examples are:
-
Sometimes the variable costs come out negative - unclear why
-
the sum of zonal costs for non cost-optimal runs are occasionally less than those for the cost optimal run. This might be due to system costs not caught in the sum of zonal costs.
Two fixes here.
-
We need a total cost expression that is used to write cost results, rather than the model objective function. Otherwise, when we change the objective function as we do in MGA or other alternative objective formulations, the costs written will be incorrect. @lbonaldo please fix this as it is straightforward and try to get a bugfix PR into main & develop when complete.
-
We need to identify source of errors for the variable costs etc. @ml6802 can you please try to replicate this and provide example for debugging?
This is now fixed on develop