-
Notifications
You must be signed in to change notification settings - Fork 164
Description
Hi,
I am working with a larger power grid test case (~2000 buses) that contains some buses with multiple generators and I've been using PowerModels.jl mostly to solve the DC power flow equations using run_dc_pf.
During my simulations, I sometimes noticed a strange behavior: While the solver reported convergence to an optimal solution in most cases, I noticed that generator dispatches sometimes unexpectedly changed or the solver did not manage to converge at all (e.g. it exited with "Iterates divering; problem might be unbounded.").
The cause for this inconsistent behavior was most probably that I used to always define a reference bus in every connected component by running correct_reference_buses!. I know that DC power flow does not require a reference bus to compensate losses, since there are none. However, I did not expect to run into problems, since I always made sure that the total active power generation matched the total demand in every connected component prior to running run_dc_pf. In the majority of cases all went well.
Only recently I noticed that the inconsistencies arise, if there are multiple generators connected to a reference bus. In fact, the JuMP model that PowerModels.jl builds in the background seems to become underdetermined in these cases. This makes sense, since the number of variables stays the same while a constraint for pg is dropped for every additional generator connected to the reference bus. I am not sure, whether this could also lead to problems in AC power flow calculations, but in the case of DC calculations this leads to avoidable convergence issues.
The inconsistencies seem to disappear, if only one generator is connected to the reference bus (e.g. by aggregating all connected generators to a single generator) or no reference bus is defined at all. Hence, I think that PowerModels.jl should at least print a warning message, if a reference bus with more than one generator is defined while trying to run run_dc_pf. This can also be easily overlooked, if one uses a data set that comes with predefined reference buses. What are your thoughts on this?
Alternatively, it could also help to have another type of reference bus for DC calculations - one that only comes with a voltage angle constraint without lifting the pg-constraints of connected generators. For example, I preferred to have reference buses defined to easily identify connected components in plotting functions that I wrote.
Thanks for the great package and I am looking forward to any thoughts on this!
PS: I could also provide a minimal script to reproduce my observations, if necessary.