powsybl-open-loadflow icon indicating copy to clipboard operation
powsybl-open-loadflow copied to clipboard

Refactor DC Sensitivity Analysis with Woodbury engine

Open p-arvy opened this issue 1 year ago • 2 comments

Please check if the PR fulfills these requirements

  • [ ] The commit message follows our guidelines
  • [ ] Tests for the changes have been added (for bug fixes / features)
  • [ ] Docs have been added / updated (for bug fixes / features)

Does this PR already have an issue describing the problem?

What kind of change does this PR introduce?

What is the current behavior?

What is the new behavior (if this is a feature change)?

Does this PR introduce a breaking change or deprecate an API?

  • [ ] Yes
  • [ ] No

If yes, please check if the following requirements are fulfilled

  • [ ] The Breaking Change or Deprecated label has been added
  • [ ] The migration steps are described in the following section

What changes might users need to make in their application due to this PR? (migration steps)

Other information:

p-arvy avatar Mar 22 '24 09:03 p-arvy

After refactoring, we propose to implement the DC sensitivity analysis as follows:

  1. Calculation of potential/actual connecrtivity losses of the contingencies (for now, in the WoodburyEngine).
  2. Calculation of rhs (for flows/injections), with modifications applied to the rhs in cases of broken connectivity, glsk with loss of elements... This is done in the DcSensitivityAnalysis class, and modified rhs are stored in the class WoodburyEngineRhsModifications.
  3. Calculation of pre/post contingency states using the WoodburyEngine. Note that only states are calculated here.
  4. Calculation of sensitivities in the DcSensitivityAnalysis class from the previously calculated states, and filling writers/results returned by the DC sensitivity analysis.

Feel free to comment @annetill @geofjamg !

p-arvy avatar Apr 05 '24 09:04 p-arvy