Skip to content

Commit 8496811

Browse files
authored
Fix sensitivity based connectivity calculation (#1341)
Signed-off-by: Geoffroy Jamgotchian <geoffroy.jamgotchian@rte-france.com>
1 parent 5b1d0d3 commit 8496811

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/main/java/com/powsybl/openloadflow/dc/fastdc/ConnectivityBreakAnalysis.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ private static boolean isGroupOfElementsBreakingConnectivity(LfNetwork lfNetwork
180180
for (ComputedElement element2 : computedElements) {
181181
LfBranch branch = lfNetwork.getBranchById(element2.getLfBranch().getId());
182182
ClosedBranchSide1DcFlowEquationTerm p = equationSystem.getEquationTerm(ElementType.BRANCH, branch.getNum(), ClosedBranchSide1DcFlowEquationTerm.class);
183-
DenseMatrix elementMatrix = element2 instanceof ComputedContingencyElement ? contingenciesStates : actionStates;
183+
DenseMatrix elementMatrix = element instanceof ComputedContingencyElement ? contingenciesStates : actionStates;
184184
double value = Math.abs(p.calculateSensi(elementMatrix, element.getComputedElementIndex()));
185185
sum += value;
186186
}

0 commit comments

Comments
 (0)