-
Notifications
You must be signed in to change notification settings - Fork 17
Support disconnection of DC elements in the load flow #1471
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
bperr
wants to merge
24
commits into
dc-component-validator
Choose a base branch
from
dc-disconnection
base: dc-component-validator
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 17 commits
Commits
Show all changes
24 commits
Select commit
Hold shift + click to select a range
6845ec3
Add tests for DC Ground and DC line disconnection
bperr a595b5b
Implement VSC disconnection
bperr 487ed75
Add safeguard check to throw error on invalid DC configuration
bperr 9b6f8cd
Small refactor and add author tag
bperr 97c772e
Update docs to specify behavior on disconnection
bperr 89aacde
Merge branch 'main' into dc-disconnection
bperr d34f682
Improve code coverage
bperr 4e73ea9
Refactor tests
bperr ce3844a
Refactor DcNetworkValidationHelpers in DcComponentValidator
bperr c5651ac
Handle properly reset of previous load flow result
bperr 4a5f41d
Fix checkstyle
bperr b817df2
Remove failing import
bperr 2efc11a
Implement automatic switching to V_DC mode
bperr 1bd02e3
Add docs and tests
bperr de4a25c
Update tests
bperr 7277e6c
lint
bperr b2818e0
Update comments in test
bperr 425fb8f
Update comments in test
bperr e04d3e9
Update comments in test
bperr 75e70f8
Merge branch 'main' into dc-disconnection
bperr eddbba5
Fix code coverage issue
bperr bfbd774
Refactor DcIsland naming in DcComponentValidator
bperr 2d5e03e
Merge branch 'main' into dc-disconnection
bperr e852caf
Merge branch 'dc-component-validator' into dc-disconnection
bperr File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
50 changes: 50 additions & 0 deletions
50
src/main/java/com/powsybl/openloadflow/ac/equations/dcnetwork/OpenDcLineEquationTerm.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,50 @@ | ||
| /** | ||
| * Copyright (c) 2026, SuperGrid Institute (http://www.supergrid-institute.com) | ||
| * This Source Code Form is subject to the terms of the Mozilla Public | ||
| * License, v. 2.0. If a copy of the MPL was not distributed with this | ||
| * file, You can obtain one at http://mozilla.org/MPL/2.0/. | ||
| * SPDX-License-Identifier: MPL-2.0 | ||
| */ | ||
| package com.powsybl.openloadflow.ac.equations.dcnetwork; | ||
|
|
||
| import com.powsybl.openloadflow.ac.equations.AcEquationType; | ||
| import com.powsybl.openloadflow.ac.equations.AcVariableType; | ||
| import com.powsybl.openloadflow.equations.AbstractElementEquationTerm; | ||
| import com.powsybl.openloadflow.equations.Variable; | ||
| import com.powsybl.openloadflow.network.LfDcLine; | ||
|
|
||
| import java.util.List; | ||
| import java.util.Objects; | ||
|
|
||
| /** | ||
| * Equation term returning 0 for the current in an open DC line. | ||
| * | ||
| * @author Baptiste Perreyon {@literal <baptiste.perreyon at supergrid-institute.com>} | ||
| */ | ||
| public class OpenDcLineEquationTerm extends AbstractElementEquationTerm<LfDcLine, AcVariableType, AcEquationType> { | ||
|
|
||
| public OpenDcLineEquationTerm(LfDcLine dcLine) { | ||
| super(dcLine); | ||
| } | ||
|
|
||
| @Override | ||
| public double eval() { | ||
| return 0.0; | ||
| } | ||
|
|
||
| @Override | ||
| public double der(Variable<AcVariableType> variable) { | ||
| Objects.requireNonNull(variable); | ||
| throw new IllegalStateException("Unknown variable: " + variable); | ||
| } | ||
|
|
||
| @Override | ||
| public String getName() { | ||
| return "dc_open_line"; | ||
| } | ||
|
|
||
| @Override | ||
| public List<Variable<AcVariableType>> getVariables() { | ||
| return List.of(); | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.