Connection Questions - statnett/Talk2PowerSystem GitHub Wiki
Task: https://github.com/statnett/Talk2PowerSystem_PM/issues/33
Demo1 raises some questions about connectivity. Q1.3 Substation Connectivity asked about "OSLO":
PREFIX cimr: <https://cim.ucaiug.io/rules#>
PREFIX cim: <http://iec.ch/TC57/2013/CIM-schema-cim16#>
PREFIX sesame: <http://www.openrdf.org/schema/sesame#>
select ?sub1Name ?lineName ?sub2Name {
values ?sub1Name {"OSLO"}
?sub1 a cim:Substation; cim:IdentifiedObject.name ?sub1Name;
cimr:connectedThroughPart ?line.
?line a cim:Line; cim:IdentifiedObject.name ?lineName.
?sub2 a cim:Substation; cim:IdentifiedObject.name ?sub2Name;
cimr:connectedThroughPart ?line.
filter(?sub1 != ?sub2)
}
It returns 15 results.
In particular, the query claims that OSLO is connected through Line
"LC 420SYLLING-HAGAFOSS"
to all these substations: SYLLING, STAVANGER, KVILLDAL, HAGAFOS.
But I thought the Line
with such name connects only SYLLING to HAGAFOSS??
Substations Connected Directly
This made me doubt whether Inference is correct, and maybe cimr:connectedThroughPart
made too many connections.
After much digging, this query finds substation parts connected directly (not through a Line
).
Please note that cimr:hasPartTransitive, cimr:isPartTransitive
are used only to find such parts,
but the connection is checked with explicit (non-inferred) props,
and the part names clearly indicate to which substation they belong
(saved query part-conns
):
PREFIX cim: <http://iec.ch/TC57/2013/CIM-schema-cim16#>
PREFIX cimr: <https://cim.ucaiug.io/rules#>
PREFIX sesame: <http://www.openrdf.org/schema/sesame#>
select ?name1 ?type1 ?part1 ?part1type ?connNode ?part2 ?part2type ?name2 ?type2 {
values (?name1 ?name2) {("OSLO" "SYLLING")}
?x1 cim:IdentifiedObject.name ?name1; sesame:directType ?type1.
?x2 cim:IdentifiedObject.name ?name2; sesame:directType ?type2.
?p1 cim:IdentifiedObject.name ?part1; sesame:directType ?part1type.
?p2 cim:IdentifiedObject.name ?part2; sesame:directType ?part2type.
?cn cim:IdentifiedObject.name ?connNode.
?x1 cimr:hasPartTransitive ?p1.
?p2 cimr:isPartTransitive ?x2.
?p1 cim:ConductingEquipment.Terminals/cim:Terminal.ConnectivityNode ?cn.
?cn cim:ConnectivityNode.Terminals/cim:Terminal.ConductingEquipment ?p2.
}
A BusbarSection
and a LinearShuntCompensator
at SYLLING are connected directly to a PowerTransformer
at OSLO.
Sylling to Oslo is at least 15km (46km by road), so shouldn't there be a Line
connecting them?
I thought ConnectivityPoint
is a point feature, can it be a long piece of Conductor?
Another problem is that ConnectivityNode
names are non-canonical strings (have trailing spaces).
Lines Connected Directly
Similarly, I thought that Lines
are connected through Substations
.
This query finds 86 Line-Line
connected pairs and 50 Line-Substation
connected pairs that are in different regions (saved query line-conns
);
(there are 201 Line-Line
pairs and 564 Line-Substation
pairs in total):
PREFIX cim: <http://iec.ch/TC57/2013/CIM-schema-cim16#>
PREFIX sesame: <http://www.openrdf.org/schema/sesame#>
PREFIX cimr: <https://cim.ucaiug.io/rules#>
select ?lineName ?regName ?otherName ?type ?otherRegName where {
?line a cim:Line; cim:IdentifiedObject.name ?lineName; cimr:connectedThroughPart ?other.
?line (cim:Line.Region|cim:Substation.Region) ?reg.
?reg cim:IdentifiedObject.name ?regName.
?other sesame:directType ?type; cim:IdentifiedObject.name ?otherName
filter(if(?type=cim:Line, ?lineName<?otherName, ?line != ?other))
?other (cim:Line.Region|cim:Substation.Region) ?otherReg.
?otherReg cim:IdentifiedObject.name ?otherRegName
filter(?reg != ?otherReg)
}
For the first Line-Line
pair ("LC 420HJALTA-RINGHALS 1" and "LC 420RINGHALS-HALDEN 1")
we can use the previous query to find exactly which parts are connected:
it's the ACLineSegments "420HJALTA-RINGHALS 1" and "420RINGHALS-HALDEN 1",
at ConnectivityNode
"RINGHALS ".
I thought there needs to be some equipment between the lines?
Correct Modeling
This diagram shows how things should be: an ACLineSegment of KRISTIAN-ARENDAL is connected to a disconnector at KRISTIAN. Substations are connected only through Lines, and Lines are not connected directly to each other:
Resolution
Substations should in principle not be connected to each other without an AC or DC line bewtween. In a real system the modelling error should not appear because the modelling team executes the modelling in line with strict guidelines. Even if it did appear, it should be detected by the automatic consistency tests that are run as part of the model merging process. The best solution is therefore to fix the model so that is does not contain the error, i.e. by adding AC-lines and any other lacking components.