Repository navigation
Experimental OPF Implementation - #594
Conversation
|
A few comments:
|
|
@pelesh I changed it so it uses the PowerFlow parser with very few changes. I do believe its valuable to have that as the input format only because it makes validation easier and there is practically unlimited data in I believed I addressed your other issues too. I am able to use the example app to change the objective/model, solve for new operating point, and start simulation in steady state at that new point! |
95913b8 to
5c4fb92
Compare
5c4fb92 to
49ad14b
Compare
pelesh
left a comment
There was a problem hiding this comment.
This is very nice work. I suggest limiting the scope of this PR to providing ACOPF module only. Imho, the integration with dynamic simulations modules should be done after ACOPF is tested and input file format specified.
979e671 to
a6e3ae1
Compare
superwhiskers
left a comment
There was a problem hiding this comment.
tests pass on my end. i think it works quite well, but there are a few implementation questions we should sort out before this moves forward.
additionally, if we are to continue with matpower, are we intending to handle capability curves for generators or the convention of a dispatchable load as a generator with negative real-power injection? if they are outside the intended scope, could we reject them and document that limitation?
i think these conventions, particularly the latter, strengthen the argument for going with our own format, as using an existing format such as matpower requires us to adhere to its conventions, which may not be desirable.
nkoukpaizan
left a comment
There was a problem hiding this comment.
Overall nice work! The component implementations are clear and I like the consolidated ComponentModelImpl.hpp.
A few comments:
- For Enzyme, can we re-use some of the existing boilerplate for
LowerSparseStorageand use buffers instead ofCooEntrieswrappingstd::vector)? Feel free to amend the wrappers. - Can we bind
GridKit::LinearAlgebra::Vectorat the component level instead ofstd::vector? This could be a follow-up PR. - Several methods, e.g., in
OptimizationEvaluator*andSteadyState*don't have a Doxygen documentation.
pelesh
left a comment
There was a problem hiding this comment.
This looks very good and has clean component model structure. Main issues that I would raise are:
- Separating equality and inequality constraint evaluation methods.
- Selection of coordinates polar vs. Cartesian.
- Inheritance patterns should mirror
PhasorDynamicsmodule. If we want to change it, then the change should made be across the GridKit modules.
38dc4b5 to
5bc7404
Compare
|
Thank you all for detailed review, I believe I have addressed all except a distinct few. I will go response by response soon, but the overall design is overall more consistent with PhasorDynamics except for the inheritance structure. I am considering removing the larger ACTIVSg2000 case until after this is merged, please let me know what you think. |
superwhiskers
left a comment
There was a problem hiding this comment.
some further changes since i looked a little closer at the ipopt interface code
|
I have adjusted so that OPF now follows same inheritance of PhasorDynamics. Once again, thank you for the invaluable feedback. I have taken great care to touch existing files very little! Nearly ready. |
86a079b to
0b5b3a4
Compare
|
Addressed! |
nkoukpaizan
left a comment
There was a problem hiding this comment.
Looks good! I'll wait for a rebase before merging to make sure there's no interference from #632.
fe0303a to
dafe4e8
Compare
|
Rebased! thanks so much |
|
Is it in play to get this merged today? |
Description
AC optimal power flow module (
OptimalPowerFlow) solved with Ipopt using exact sparse derivatives from Enzyme. It follows the PhasorDynamics structure (OptimizationEvaluator->Component->SystemModel) and uses the same JSON case format. Scope is ACOPF only, coupling with PhasorDynamics will be a separate PR.Bus,Branch,Generator,Load(Cartesian voltages)SteadyState::IpoptInterfaceEconomicDispatch, tested against PYPOWER costs for IEEE39, Hawaii, and ACTIVSg2000Checklist
-Wall -Wpedantic -Wconversion -Wextra.Further comments
I can remove the large new OPF formatted cases if needed.