Modeling to Generate Alternatives

GenX.mga!Method
mga!(EP::Model, inputs::Dict, setup::Dict)

This function reads the input data, collect the resources with MGA flag on and creates a set of unique technology types. The function then adds a constraint to the model to compute total capacity in each zone from a given Technology Type.

If the user set MGAAnnualGeneration = 0 in the genx_settings.yml file, the constraint has the following form:

\[P_{z,r} = \sum_{y \in \mathcal{G}}C_{y,z,r}\]

where, the aggregated capacity $P_{z,r}$ represents total capacity from technology type $r$ in a zone $z$.

If the user set MGAAnnualGeneration = 1 in the genx_settings.yml file, the constraint has the following form:

\[P_{z,r} = \sum_{y \in \mathcal{G}}\sum_{t \in \mathcal{T}} \omega_{t} \Theta_{y,t,z,r} \]

where $\Theta_{y,t,z,r}$ is a generation of technology $y$ in zone $z$ in time period $t$ that belongs to a resource type $r$. $\Theta_{y,t,z,r}$ is aggregated into a new variable $P_{z,r}$ that represents total generation from technology type $r$ in a zone $z$.

Arguments

  • EP::Model: GenX model object
  • inputs::Dict: Dictionary containing input data

Returns

  • This function updates the model object EP with the MGA variables and constraints in-place.
source
GenX.mgaMethod
mga(EP::Model, path::AbstractString, setup::Dict, inputs::Dict)

We have implemented an updated Modeling to Generate Alternatives (MGA) Algorithm proposed by Berntsen and Trutnevyte (2017) to generate a set of feasible, near cost-optimal technology portfolios. This algorithm was developed by Brill Jr, E. D., 1979 and introduced to energy system planning by DeCarolia, J. F., 2011.

To create the MGA formulation, we replace the cost-minimizing objective function of GenX with a new objective function that creates multiple generation portfolios by zone. We further add a new budget constraint based on the optimal objective function value $f^*$ of the least-cost model and the user-specified value of slack $\delta$. After adding the slack constraint, the resulting MGA formulation is given as (MGAAnnualGeneration = 0 in the genx_settings.yml file, or not set):

\[\begin{aligned} \text{max/min} \quad &\sum_{z \in \mathcal{Z}}\sum_{r \in \mathcal{R}} \beta_{z,r}^{k}P_{z,r}\\ \text{s.t.} \quad &P_{z,r} = \sum_{y \in \mathcal{G}}C_{y,z,r} \\ & f \leq f^* + \delta \\ &Ax = b \end{aligned}\]

where, $\beta_{z,r}$ is a random objective function coefficient betwen $[0,1]$ for MGA iteration $k$. We aggregate capacity into a new variable $P_{z,r}$ that represents total capacity from technology type $r$ in a zone $z$.

If the users set MGAAnnualGeneration = 1 in the genx_settings.yml file, the MGA formulation is given as:

\[\begin{aligned} \text{max/min} \quad &\sum_{z \in \mathcal{Z}}\sum_{r \in \mathcal{R}} \beta_{z,r}^{k}P_{z,r}\\ \text{s.t.} \quad &P_{z,r} = \sum_{y \in \mathcal{G}}\sum_{t \in \mathcal{T}} \omega_{t} \Theta_{y,t,z,r} \\ & f \leq f^* + \delta \\ &Ax = b \end{aligned}\]

where, $\beta_{z,r}$ is a random objective function coefficient betwen $[0,1]$ for MGA iteration $k$. $\Theta_{y,t,z,r}$ is a generation of technology $y$ in zone $z$ in time period $t$ that belongs to a resource type $r$. We aggregate $\Theta_{y,t,z,r}$ into a new variable $P_{z,r}$ that represents total generation from technology type $r$ in a zone $z$.

In the second constraint in both the above formulations, $\delta$ denote the increase in budget from the least-cost solution and $f$ represents the expression for the total system cost. The constraint $Ax = b$ represents all other constraints in the power system model. We then solve the formulation with minimization and maximization objective function to explore near optimal solution space.

source