Closed WilsonGV closed 5 months ago
Thanks for pointing this out @WilsonGV. I knew it wasn't completely consistent with the legacy output, but I hadn't gotten around to splitting the line losses into the series and shunt parts yet.
I must say I'm gratified to know that someone was able to understand the new code well enough to make such detailed suggestions. Thank you!
I believe I've addressed the issues you raise in #235, along with a few more. Let me know what you think.
(And give my greetings to Carlos.) 👋
Thanks for your rapid response @rdzman.
A much clearer solution using the C matrix for branches over the node voltages at the network model solution rather than using dme_bus.tab.uid.
Note: I hadn't noticed the existence of tab.g_fr
in the main data table of branches. Since that column has zero values, do you see a potential application for the shunt conductance in a flexible branch modeling?
I put it in there as a step toward a more general branch model. In fact, it is possible to update those values in the data model after loading it (and rebuilding the branch data model element) and the computations will all be handled correctly. It's just not handled in the current version of the MATPOWER case format.
I found differences in the pretty-printed results of the branch summary between legacy and flexible Matpower's frameworks. In particular, the total reactive power brach losses printed while using the flexible Matpower framework is not consistent with the result of the Matpower's function
get_losses
(used in the legacy Matpower framework)This happens because in the method
pp_data_sum
of subclassdme_branch
the total losses are calculated from the port injections which also includes reactive power of shunt admitances of the pi-model. I implemmented the following code to show the issue:The suggested computation for the total branch series reactive losses employs two new columns,
qsh_fr
andqsh_to
, added to the table of branches which hold the reactive power related to shunts admitances at from and to sides.Notice that the computation of
obj.tab.qsh_fr
andobj.tab.qsh_to
could be included in the methoddata_model_update_on
of subclassmme_branch_pf_ac
such that they could be used in line 200 of subclassdme_brach