Skip to content
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

Display switch on feeder in Bus/Breaker view #538

Open
So-Fras opened this issue Jul 24, 2023 · 7 comments
Open

Display switch on feeder in Bus/Breaker view #538

So-Fras opened this issue Jul 24, 2023 · 7 comments

Comments

@So-Fras
Copy link
Collaborator

So-Fras commented Jul 24, 2023

Describe the current behavior

When we create a simple voltage level in Bus/Breaker view, with the code below:

        Network network2 = Network.create("test", "test");
        Substation substation = createSubstation(network2, "S1", "S1", Country.FR);

        VoltageLevel vl1 = createVoltageLevel(substation, "VL1", "VL1", TopologyKind.BUS_BREAKER, 400);

        vl1.getBusBreakerView().newBus()
                .setId("B11")
                .add();
        vl1.newLoad()
                .setId("LD1")
                .setConnectableBus("B11")
                .setBus("B11")
                .setP0(1.0)
                .setQ0(1.0)
                .add();

        vl1.getBusBreakerView().newBus()
                .setId("B12")
                .add();
        vl1.getBusBreakerView().newSwitch()
                .setId("BR1")
                .setBus1("B12")
                .setBus2("B11")
                .setOpen(false)
                .add();
        vl1.getBusBreakerView().newBus()
                .setId("B13")
                .add();
        vl1.getBusBreakerView().newSwitch()
                .setId("BR2")
                .setBus1("B12")
                .setBus2("B13")
                .setOpen(false)
                .add();
        vl1.newGenerator()
                .setId("G1")
                .setConnectableBus("B13")
                .setBus("B13")
                .setMaxP(100.0)
                .setMinP(50.0)
                .setTargetP(100.0)
                .setTargetV(400.0)
                .setVoltageRegulatorOn(true)
                .add();

We get the following svg output:

image

Describe the expected behavior

Instead, one may want to get the following output (looking more like a Node/Breaker view):

image

The switches would be displayed on feeders instead of being displayed as bridges between bus bars.

Describe the motivation

This would enhances the diagram readability.

@geofjamg
Copy link
Member

I disagree with this issue, it does not make any sense to try to display a bus/breaker model as a node/breaker model. If one needs this kind of display it has to use a node/breaker model. In a bus/breaker model, switches are bus coupler only, nothing related to feeder switch, there is a terminal status for that.

@jonenst
Copy link
Contributor

jonenst commented Jul 26, 2023

Should the sld svg generator be updated to always display equipments with bus="null" but connectableBus="XXX" with an open breaker to the XXX bar ? Or we do we want explicit data in the network (extension ?) to model this ?

The following network (written by hand by me, may have mistakes) (load1 and gen1 are connected, but load2 and gen2 are disconnected)

<?xml version="1.0" encoding="UTF-8"?>
<iidm:network xmlns:iidm="http://www.powsybl.org/schema/iidm/1_9" xmlns:slt="http://www.powsybl.org/schema/iidm/ext/slack_terminal/1_5" id="ieee9cdf" caseDate="2009-04-26T00:00:00.000Z" forecastDistance="0" sourceFormat="IEEE-CDF" minimumValidationLevel="STEADY_STATE_HYPOTHESIS">
    <iidm:substation id="S">
        <iidm:voltageLevel id="VL1" nominalV="100.0" topologyKind="BUS_BREAKER">
            <iidm:busBreakerTopology>
                <iidm:bus id="B1" name="B1"/>
            </iidm:busBreakerTopology>
            <iidm:load id="L1" p0="100.0" q0="35.0" connectableBus="B1" bus="B1"/>
            <iidm:generator id="G1" energySource="OTHER" minP="10.0" maxP="110.0" targetP="100.0" targetV="100.0" targetQ="35.0" voltageRegulatorOn="true" connectableBus="B1" bus="B1"/>
        </iidm:voltageLevel>
        <iidm:voltageLevel id="VL2" nominalV="100.0" topologyKind="BUS_BREAKER">
            <iidm:busBreakerTopology>
                <iidm:bus id="B2" name="B2"/>
            </iidm:busBreakerTopology>
            <iidm:load id="L2" p0="100.0" q0="35.0" connectableBus="B2"/>
            <iidm:generator id="G2" energySource="OTHER" minP="10.0" maxP="110.0" targetP="100.0" targetV="100.0" targetQ="35.0" voltageRegulatorOn="true" connectableBus="B2"/>
        </iidm:voltageLevel>
        <iidm:twoWindingsTransformer id="T" r="0.0" x="5.76" g="0.0" b="0.0" ratedU1="100.0" ratedU2="100.0" bus1="B1" connectableBus1="B1" voltageLevelId1="VL1" bus2="B2" connectableBus2="B2" voltageLevelId2="VL2">
            <iidm:ratioTapChanger lowTapPosition="0" tapPosition="0" loadTapChangingCapabilities="true" regulating="false">
                <iidm:step r="0.0" x="0.0" g="0.0" b="0.0" rho="1.0"/>
            </iidm:ratioTapChanger>
        </iidm:twoWindingsTransformer>
    </iidm:substation>
</iidm:network>

produces (after running openloadflow)
Capture d’écran de 2023-07-26 10-34-25
Is this expected ? the only way to see that the equipement is not connect to the bus is that the active and reactive power is "-" ?
Not sure maybe I did something wrong ?

@jonenst
Copy link
Contributor

jonenst commented Jul 26, 2023

Or is the bus/breaker topology not supposed to be used for this usecase ?

@So-Fras
Copy link
Collaborator Author

So-Fras commented Jul 26, 2023

In powsybl-diagram latest version (v5.3.2), a fix was introduced to display disconnected components. A disconnected load or a disconnected line terminal now appear with a dashed line:
image

@jonenst
Copy link
Contributor

jonenst commented Jul 26, 2023

Capture d’écran de 2023-07-26 13-39-55

ok I see it with 4.0.0-SNAPSHOT with the "highlight" checkbox in the dev tools viewer. Is it enough ?

@So-Fras
Copy link
Collaborator Author

So-Fras commented Jul 26, 2023

Yes and now you can visualize that G2 and L2 are both disconnected.

@jonenst
Copy link
Contributor

jonenst commented Jul 26, 2023

At least we need to add documentation on the expected semantics of buses and switches in the busbreaker definition.

And what if your objective is to display a diagram that looks like the busbreaker one in this image https://www.powsybl.org/pages/documentation/grid/model/img/index/voltage-level.svg (from our docs https://www.powsybl.org/pages/documentation/grid/model/#voltage-level ). that's what I meant with "is it enough?"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants