lanl-ansi / PowerModels.jl

A Julia/JuMP Package for Power Network Optimization
https://lanl-ansi.github.io/PowerModels.jl/stable/
Other
387 stars 145 forks source link

Something wrong with switch #924

Closed lry77ist closed 1 month ago

lry77ist commented 1 month ago

When I add switch component into MATPOWER file and then do optimal power flow computation, it threw an error: [error | PowerModels]: active power decision variables appear to be missing for switch components What can I do with that?

ccoffrin commented 1 month ago

You should call one of these OPF variants to consider the switch data, https://github.com/lanl-ansi/PowerModels.jl/blob/master/src/prob/test.jl#L49-L221