This is a CNO for AC-OPF. Data, optimization problem formulation is obtained from pandapower, tested on coincidence.
Look up for notebooks/acopf_PSO_pyomo_KKT.ipynb
. You can change here test case and its parameters.
Last two cells display optimal points, costs. Unit Commitment (UC) binary variables are displayed for CNO.