This project uses Pyomo to solve an Optimal Power Flow (OPF) problem for a three-bus power system. The model minimizes generation costs while adhering to system constraints such as power flow limits, generator capacities, and load demands.
- Abstract model using Pyomo.
- Cost function and constraint-based optimization.
- Supports nonlinear solvers like IPOPT.
- Reads system data from an Excel file (
opfthreebus.xlsx
).
- Python 3.x
- Libraries:
pyomo
,pandas
,openpyxl
- Solver: IPOPT
opfthreebus.xlsx
:
bus_num
: Bus numbers.a
: Cost coefficients.Pmax
: Maximum generation.Pmin
: Minimum generation.Pd
: Load demand.imp
: Impedance matrix.
- Optimal power generation for each bus.
- Voltage angles (theta) for each bus.
- Results written to the console and formatted output via Pyomo.
Open source, MIT License.