Modeling
- class gtep.gtep_model.ExpansionPlanningModel(stages=1, formulation=None, data=None, num_reps=3, len_reps=24, num_commit=24, num_dispatch=4)
A generalized generation and transmission expansion planning model.
- create_model()
Create concrete Pyomo model object associated with the ExpansionPlanningModel
- report_large_coefficients(outfile, magnitude_cutoff=100000.0)
Dump very large magnitude (>= 1e5) coefficients to a json file.
- Outfile:
should accept filename or open file and write there; see how we do this in pyomo elsewhere
- Magnitude_cutoff:
magnitude above which to report coefficients
- report_model(outfile='pretty_model_output.txt')
Pretty prints Pyomo model to outfile.
- Outfile:
(str, optional) _description_. Defaults to “pretty_model_output.txt”.
- gtep.gtep_model.add_commitment_constraints(b, comm_per)
Add commitment-associated disjunctions and constraints to representative period block.
- gtep.gtep_model.add_commitment_variables(b, commitment_period)
Add variables and disjuncts to commitment period block.
- gtep.gtep_model.add_dispatch_constraints(b, disp_per)
Add dispatch-associated inequalities to representative period block.
- gtep.gtep_model.add_dispatch_variables(b, dispatch_period)
Add dispatch-associated variables to representative period block.
- gtep.gtep_model.add_investment_constraints(b, investment_stage)
Add standard inequalities (i.e., those not involving disjunctions) to investment stage block.
- gtep.gtep_model.add_investment_variables(b, investment_stage)
Add variables to investment stage block.
- Parameters:
b – Investment block
investment_stage – Investment stage index or name
- Returns:
None
- gtep.gtep_model.commitment_period_rule(b, commitment_period)
Create commitment period block.
- Parameters:
b – commitment period block
commitment_period – corresponding commitment period label
- gtep.gtep_model.create_objective_function(m)
Creates objective function. Total cost is operating cost plus expansion cost plus penalty cost (penalties include generation deficits, renewable quota deficits, and curtailment) :param m: Pyomo GTEP model.
- gtep.gtep_model.investment_stage_rule(b, investment_stage)
Creates investment stage block.
- B:
Investment block
- Investment_stage:
ID for current investment stage
- gtep.gtep_model.model_create_investment_stages(m, stages)
Creates investment blocks and linking constraints for GTEP model. Largely manages retirements and links operational units in a given investment stage to operational + installed - retired in the previous investment stage.
- M:
Pyomo model object
- Stages:
Number of investment stages in planning horizon
- gtep.gtep_model.model_data_references(m)
Creates and labels data for GTEP model; ties input data to model directly. :param m: Pyomo model object
- gtep.gtep_model.model_set_declaration(m, stages, rep_per=['a', 'b'], com_per=2, dis_per=2)
Creates Pyomo Sets necessary (convenient) for solving the GTEP model.
- M:
Pyomo model object
- Stages:
Number of stages in investment horizon
- gtep.gtep_model.representative_period_rule(b, representative_period)
Create representative period block.
- B:
Representative period block
- Representative_period:
corresponding representative period label