We are still at the early stage of the implementation. There will be more functionalities and flexible I/Os coming in the future. Please watch us progress to have the latest update.
The main purpose of this repository is to provide an efficient I/O for generating the optimization problem in power system operation and host a basic set of basic power system operation formulations for the future research and teaching purpose.
This repo contains some basic power system operations written in Python and formulated by cvxpy
, such as:
- Network Constrained Unit Commitment (with/out integer variables) (finished)
- Economic Dispatch (finished)
- Stochastic Unit Commitment (ongoing)
cvxpy: is an open source Python-embedded modeling language for convex optimization problems. It lets you express your problem in a natural way that follows the math, rather than in the restrictive standard form required by solvers.
PyPower: is a power flow and Optimal Power Flow (OPF) solver. It is a port of MATPOWER to the Python programming language.
However, you may also need to have Gurobi, Mosek or other optimization software to efficiently solve the optimization problems, especially if integers are included. Please refer here for details.
Other packages inlcudes
openpyxl, XlsxWriter
The implementation of this repo follows the online cource here and the textbook Power System Operations here, both by Prof. Antonio Conejo. We also write a series of blog posts to explain the formulation used in the code, including:
The optimization formulation replies on reading system configuration from a .xlsx
file. There are several ways to construct the configuration file, either from scratch or build it from existing configurations via the PyPower
package. An example file can be found here.
We recommend to construct the .xlsx
file from the basic PyPower
file to avoid errors. The PyPower
contains several grid topology and parameters that can be directly read by the package. However, you must include several necessary extra configs (that are not covered by the PyPower
) to support the full functionality of power system operation. An example can be found here. The detailed description on how to construct the extra config file can be found here.