Welcome to the GenX documentation!
What is GenX?
GenX is a highly-configurable, open source electricity resource capacity expansion model that incorporates several state-of-the-art practices in electricity system planning to offer improved decision support for a changing electricity landscape.
The model was originally developed by Jesse D. Jenkins and Nestor A. Sepulveda at the Massachusetts Institute of Technology and is now jointly maintained by a team of contributors at the Princeton University ZERO Lab (led by Jenkins), MIT (led by Ruaridh MacDonald), and NYU (led by Dharik Mallapragada).
GenX is a constrained linear or mixed integer linear optimization model that determines the portfolio of electricity generation, storage, transmission, and demand-side resource investments and operational decisions to meet electricity demand in one or more future planning years at lowest cost, while subject to a variety of power system operational constraints, resource availability limits, and other imposed environmental, market design, and policy constraints.
GenX features a modular and transparent code structure developed in Julia + JuMP. The model is designed to be highly flexible and configurable for use in a variety of applications from academic research and technology evaluation to public policy and regulatory analysis and resource planning. See the User Guide for more information on how to use GenX and the Developer Guide for more information on how to contribute to GenX.
Uses
From a centralized planning perspective, the GenX model can help to determine the investments needed to supply future electricity demand at minimum cost, as is common in least-cost utility planning or integrated resource planning processes. In the context of liberalized markets, the model can be used by regulators and policy makers for indicative energy planning or policy analysis in order to establish a long-term vision of efficient market and policy outcomes. The model can also be used for techno-economic assessment of emerging electricity generation, storage, and demand-side resources and to enumerate the effect of parametric uncertainty (e.g., technology costs, fuel costs, demand, policy decisions) on the system-wide value or role of different resources.
Roadmap of the Documentation: A Guide for the Users and Developers
This section provides a quick guidance as to how to navigate through the different parts of the documentation pages; what the different sections contain, and how to relate it to the different parts of the GenX code-base.
This page serves as a gentle introduction to what GenX is meant for and what it does.
The next subsection, Installation Guide goes over how to download and install GenX and also how to download and install the Julia programming language (in which GenX is written) and the different open-source non-commercial freely available solvers, as well as the commercial solvers and the respective JuMP interfaces. This subsection also goes over installing the environment dependencies and instantiating a virtual environment.
We also mention the shortcomings of GenX and some third party extentions in the next couple subsections
The next section is Getting Started goes over Running GenX and has two subsections. The first subsection, Example cases, gives a walkthrough through some predefined example systems and how to run GenX for those and interpret the results. It also tells how to run GenX for a user-defined case. The subsection Using commercial solvers: Gurobi or CPLEX talks specifically about how to run GenX with commercial solvers like Gurobi and CPLEX that are absolutely indispensable for solving large cases.
The third section, Tutorial starts with GenX Tutorials and gives a comprehensive tour of the different steps that are involved when a GenX capacity expansion simulation is run. It consists of 6 tutorial sections, each of which highlights the different important aspects of model construction and run of GenX. The different sections are configuring the GenX settings, visualizing the network, time domain reduction, generating the model, solving the model, and adjusting the different solver settings.
The User Guide, which the fourth section (User Guide) goes into the depths and details of the different steps and the settings and input parameters from the previous Tutorial section. The sections starts off with an overview of the workflow in GenX, briefing about the different steps (some of which we encountered in the Tutorials) of running GenX model. It then explains the different parameters of settings, policy, time-domain reduction, model structure, and output. Following this, the next subsection explains the different solver settings parameters of the different solvers. The next subsection goes over the different input CSV files and the different fields that are used there. The following two subsections are devoted to Time Domain Reduction (TDR). The first one walks through and explains the different settings parameters for TDR and the second one explains the couple different ways to run TDR for GenX and what exactly happens when we run TDR. The next four subsections, respectively, explains the different parameters, inputs, and outputs, and what happens when Modeling to Generate Alternatives (MGA), Multi-stage model, slack variables for policies (when we want to satisfy policy constraints in a soft manner by adding penalty of violation in the objective function), and Method of Morris. Finally, the last two sections are about the different steps involved while solving the model and the explanation of different output fields for both the default settings and user-specific settings.
The Model Concept and Overview section first introduces the GenX model in GenX Model Introduction and talks about its scope. It also introduces the notations, the objective function, and the power balance constraints. This is the first section which delves into the theoretical and mathematical details of the model, which is the most important one for model developers.
The Model Reference, which is the sixth section delves deep into the GenX model and introduces the mathematical formulation, while discussing the physical interpretations of all the different parts of the GenX model. This section starts off with discussing the Core of the model, which models the Discharge, Non-Served Energy, Operational Reserves, Transmission, Unit Commitment, CO2, and Fuel. The different parts of the model consists of the different tyoe of generating resources (thermal, hydro, VRE, storage etc.), transmission network (modeling of flows as well as losses), demand modeling, operating reserves, unit commitment, different policies (such as CO2 constraint, capacity reserve margin, energy share requirement, min and max cap requirement etc.). This section also mentions about the different Julia functions (or methods) used for loading the input files, building the model, solving it, and generating the output files. Also, this is the section that explains the internal details of the Julia functions used for TDR, MGA, Method of Morris, Multi-stage modeling, and the several utility functions used throughout the GenX code-base.
The seventh section, Public API Reference Public Documentation is for describing the functions that are directly accessible to an external program from GenX (like loading inputs, generating output, running TDR script etc.) and how an external "client" code can access the GenX features, if the user desires to run his/her own code instead of the Run.jl provided by us.
The eighth section, Third Party Extension Additional Third Party Extensions to GenX mentions about Pygenx, a Python interface for GenX, that was built by Daniel Olsen and GenX case runner for automated batch running, built by Jacob Schwartz.
Finally, the ninth and last section, Developer Docs How to contribute to GenX talks about the resource organization in GenX, how to add a new user-defined resource, and also several JuMP functions that are used as utility throughout the GenX code-base.
How to cite GenX
We recommend users of GenX to cite it in their academic publications and patent filings. Here's the text to put up as the citation for GenX: MIT Energy Initiative and Princeton University ZERO lab. [GenX](https://github.com/GenXProject/GenX): a configurable power system capacity expansion model for studying low-carbon energy futures n.d. https://github.com/GenXProject/GenX
.
Acknowledgement
The GenX team expresses deep gratitude to Maya Mutic for developing the tutorials along with Filippo Pecci and Luca Bonaldo. The Julia-themed GenX logo was designed by Laura Zwanziger and Jacob Schwartz.
License
GenX is released under the General Public License, GPL-2.0
Index
GenX.co2!
GenX.dcopf_transmission!
GenX.discharge!
GenX.fuel!
GenX.investment_discharge!
GenX.investment_transmission!
GenX.load_operational_reserves!
GenX.non_served_energy!
GenX.operational_reserves!
GenX.operational_reserves_contingency!
GenX.operational_reserves_core!
GenX.transmission!
GenX.ucommit!
GenX.write_co2
GenX.write_multi_stage_capacities_discharge
GenX.write_virtual_discharge
GenX.curtailable_variable_renewable!
GenX.curtailable_variable_renewable_operational_reserves!
GenX.flexible_demand!
GenX.hydro_res!
GenX.hydro_res_operational_reserves!
GenX.hydro_inter_period_linkage!
GenX.must_run!
GenX.storage!
GenX.investment_charge!
GenX.investment_energy!
GenX.long_duration_storage!
GenX.storage_all!
GenX.storage_asymmetric!
GenX.storage_asymmetric_operational_reserves!
GenX.storage_symmetric!
GenX.storage_symmetric_operational_reserves!
GenX.elec_vre_stor!
GenX.inverter_vre_stor!
GenX.investment_charge_vre_stor!
GenX.lds_vre_stor!
GenX.solar_vre_stor!
GenX.stor_vre_stor!
GenX.vre_stor!
GenX.vre_stor_capres!
GenX.vre_stor_operational_reserves!
GenX.wind_vre_stor!
GenX.write_vre_stor
GenX.write_vre_stor_capacity
GenX.write_vre_stor_charge
GenX.write_vre_stor_discharge
GenX.thermal!
GenX.thermal_plant_effective_capacity
GenX.maintenance_formulation_thermal_commit!
GenX.thermal_commit!
GenX.thermal_commit_operational_reserves!
GenX.thermal_maintenance_capacity_reserve_margin_adjustment!
GenX.thermal_no_commit!
GenX.thermal_no_commit_operational_reserves!
GenX.electrolyzer!
GenX.controlling_maintenance_start_hours
GenX.ensure_maintenance_variable_records!
GenX.has_maintenance
GenX.maintenance_down_name
GenX.maintenance_down_variables
GenX.maintenance_formulation!
GenX.maintenance_shut_name
GenX.resources_with_maintenance
GenX.cap_reserve_margin!
GenX.co2_cap!
GenX.energy_share_requirement!
GenX.hourly_matching!
GenX.hydrogen_demand!
GenX.load_energy_share_requirement!
GenX.load_maximum_capacity_requirement!
GenX.maximum_capacity_requirement!
GenX.minimum_capacity_requirement!
GenX._get_policyfile_info
GenX._get_resource_info
GenX._get_summary_map
GenX.add_attributes_to_resource!
GenX.add_df_to_resources!
GenX.add_id_to_resource_df!
GenX.add_module_to_resources!
GenX.add_modules_to_resources!
GenX.add_policies_to_resources!
GenX.add_policy_to_resources!
GenX.add_resources_to_input_data!
GenX.check_mustrun_reserve_contribution
GenX.check_resource
GenX.compute_resource_indices
GenX.create_resource_array
GenX.create_resource_array
GenX.create_resources_sametype
GenX.dataframerow_to_dict
GenX.extract_matrix_from_dataframe
GenX.file_exists
GenX.get_systemfiles_path
GenX.load_cap_reserve_margin!
GenX.load_cap_reserve_margin_trans!
GenX.load_co2_cap!
GenX.load_dataframe
GenX.load_dataframe
GenX.load_demand_data!
GenX.load_energy_share_requirement!
GenX.load_fuels_data!
GenX.load_generators_variability!
GenX.load_hydrogen_demand!
GenX.load_inputs
GenX.load_minimum_capacity_requirement!
GenX.load_multi_fuels_data!
GenX.load_network_data!
GenX.load_network_map_from_list
GenX.load_network_map_from_matrix
GenX.load_period_map!
GenX.load_process_variability!
GenX.load_resource_df
GenX.load_resources_data!
GenX.load_vre_stor_variability!
GenX.prevent_doubled_timedomainreduction
GenX.process_piecewisefuelusage!
GenX.scale_columns!
GenX.scale_resources_data!
GenX.scale_vre_stor_data!
GenX.split_storage_resources!
GenX.summary
GenX.update_retrofit_id
GenX.validate_df_cols
GenX.validate_policy_dataframe!
GenX.validate_policy_files
GenX.RemoveConstCols
GenX.check_condition
GenX.cluster
GenX.cluster_inputs
GenX.full_time_series_reconstruction
GenX.get_absolute_extreme
GenX.get_demand_multipliers
GenX.get_extreme_period
GenX.get_integral_extreme
GenX.get_worst_period_idx
GenX.parse_data
GenX.parse_multi_stage_data
GenX.rmse_score
GenX.run_timedomainreduction!
GenX.scale_weights
GenX.compute_overnight_capital_cost
GenX.configure_multi_stage_inputs
GenX.validate_can_retire_multistage
GenX.add_cut
GenX.configure_ddp_dicts
GenX.fix_capacity_tracking
GenX.fix_initial_investments
GenX.generate_cut_component_inv
GenX.generate_cut_component_track
GenX.initialize_cost_to_go
GenX.run_ddp