September 2020 Online http://co-at-work.zib.de
CO@Work 2020
Gas Networks Introduction
Topics are:
- 1. European Regulations
- 2. Gas Network Basics
- 3. Network Design
- 4. Gas Network Capacity
- 5. Gas Network Control
CO@Work 2020 Gas Networks Introduction Topics are: 1. European - - PowerPoint PPT Presentation
CO@Work 2020 Gas Networks Introduction Topics are: 1. European Regulations 2. Gas Network Basics 3. Network Design 4. Gas Network Capacity 5. Gas Network Control September 2020 Online http://co-at-work.zib.de The Energy Team (ZIB, TU
September 2020 Online http://co-at-work.zib.de
Topics are:
The Energy Team (ZIB, TU Berlin, MODAL GasLab)
Thorsten Koch 2
Tom Christine Jan Milena Janina Charlie Inci Nils Mark Carsten Lovis Felix Kai Jaap Thai Ying
β¦ and me
A pipeline
β
π½ π π = π!"#
$
β π%&
$
π½ depending on dimension and inclination of the pipeline, the friction in the
pipeline, gas temperature, gas composition, outside temperature, and more.
Thorsten Koch 20
50 bar 20 bar pipeline
The network
Thorsten Koch 21
Given a graph π» = (π, π΅) with pressure π!, and flow π", for π£ β π, π β π΅ and π! = π!
#.
Exists π, π subject to 1
"β%!(!)
π" ( 1
"β%"(!)
π" = π! for all π£ β π π½" β£ π" β£ π" = π! β πΎ"π) for all π = π£, π€ β π΅ π! β€ π! β€ π! for all π£ β π π" β€ π" β€ π" for all π β π΅
Line Theorem with bounded variables
Theorem (Maugis, 1977, Collins at al, 1978, Humpola, K., et al, 2013) Let π β β* be a balanced demand and Ξ¦" strictly increasing function. Then the solution space of exists π, π subject to is either empty or fulfills the conditions: 1. The flow is unique 2. The squared pressure component π has the form πβ + π, π β€ π β€ Μ π } for some πβ, π, Μ π .
Thorsten Koch 22
1
"β%!(!)
π" ( 1
"β%"(!)
π" = π! for all π£ β π Ξ¦"(π") = π! β π) for all π = π£, π€ β π΅ π! β€ π! β€ π! for all π£ β π π" β€ π" β€ π" for all π β π΅
Line Theorem: The Line
β· Flow is unique and Ξ¦'is strictly increasing. β· π" β π( are uniquely determined for all arcs. β· Shifting all values by a constant is feasible. β· Constant shift is the only possible source of difference.
Consider two feasible squared pressure vectors: π) und π)). Both are shifted in such a way that they coincide in the value at π£. The difference is constant which implies π"
) β π( ) = π' π' = π" )) β π( )).
Since π"
) = π" )), we also have π( ) = π( )) .
Thorsten Koch 23
Convex Slack Reformulation
The solution space of the problem
min 1
!β*
Ξ- + 1
"β.
Ξ" subject to
is non-empty and is convex.
Thorsten Koch 24
1
"β%!(!)
π" ( 1
"β%"(!)
π" = π! for all π£ β π Ξ¦"(π") = π! β π) for all π = π£, π€ β π΅ π! β Ξ- β€ π! for all π£ β π π! + Ξ! β₯ π! for all π£ β π Ξ! β₯ 0 for all π£ β π π" β Ξ" β€ π" for all π β π΅ π" + Ξ" β₯ π" for all π β π΅ Ξ" β₯ 0 for all π β π΅
Element Function Symbol
Valve Switch
Regulator Decrease pressure Compressor Increase pressure Active elements in gas networks
Thorsten Koch 25
Controllable Networks
This is an example of just a compressor station
Thorsten Koch 26
Compressor machines
Thorsten Koch 27
Compressor performance depends on input pressure, output pressure, flow, temperature, composition, compressor power.
Compressor stations
Thorsten Koch 28
How precise can we model a compressor? Let us assume we assume the gas temperature 10Β°C too low. This gives about 3% more power to the compressor station. This might be enough to get another 1500 MW gas through.
3 Questions
βΆ Design a new network
(or extend an existing one)
βΆ Determine the capacity
βΆ Control a network to achieve
Thorsten Koch 29
CO@Work Online, September 2020
Network Construction Steiner Tree
The Steiner tree problem in graphs (STP) Given an undirected connected graph π» = (π, πΉ), costs π: πΉ β β! and a set π β π of terminals, find a minimum weight tree π β π» which spans π. The STP is one of the classical 21 NP-hard problems.
Thorsten Koch 31
Direct Cut Integer Programming Formulation for SAP
min π πΌπ subject to π§ π"
#
β₯ 1, for all π β π, π β π, π \ π β© π β β π§ π$
% 2
= 0, if π€ = π ; = 1, if π€ β π \ π ; β€ 1, if π€ β π for all π€ β π π§ π$
% β€ π§ π$ # ,
for all π€ β π; π§ π$
% β₯ π§&,
for all π β π$
#, π€ β π;
0 β€ π§& β€ 1, for all π β π΅; π§& β 0,1 , for all π β π΅, where π = π β π, π'
# β { π£, π€ β π΅|π£ β π, π€ β π β X}, π' % β π(β' #
for π β V.
Thorsten Koch 32
See, e.g., Koch, Martin, Solving Steiner tree problems in graphs to optimality, Networks (1998) Polzin, Algorithms for the Steiner problem in networks, Uni Saarland, 2004, Rehfeldt, Koch, Combining NP-Hard Reduction Techniques and Strong Heuristics in an Exact Algorithm for the Maximum-Weight Connected Subgraph Problem, SIAMOPT (2019), Shinano, Rehfeldt, Koch, Building Optimal Steiner Trees on Supercomputers by Using up to 43,000 Cores, CPAIOR 2019, LNCS 11494, and the references there in.
SCIP-Jack is a solver for Steiner Tree Problems in Graphs
It is part of the SCIP Optimization Suite and can solve:
β· Steiner Tree Problem in Graphs (STP) β· Steiner Arborescence Problems in Graphs (SAP) β· Rectilinear Steiner Minimum Tree (RSMTP) β· Node-weighted Steiner Tree (NWSTP) β· Prize-collecting Steiner Tree (PCSTP) β· Rooted Prize-collecting Steiner Tree (RPCSTP) β· Maximum-weight Connected Subgraph (MWCSP) β· Degree-constrained Steiner Tree (DCSTP) β· Group Steiner Tree (GSTP) β· Hop-constrained directed Steiner Tree (HCDSTP)
http://scipopt.org
Thorsten Koch 33
Thorsten Koch 34
CO@Work Online, September 2020
What does βCapacity of the Networkβ mean?
The Technical Capacity is defined as the maximum flow bounds at the entry- and exit-nodes, such that any possible balanced demand scenario within these bounds can be fulfilled by the network.
Thorsten Koch 36
1000 1000 1000 1000 1000 1000
What does βCapacity of the Networkβ mean?
The Technical Capacity is defined as the maximum flow bounds at the entry- and exit-nodes, such that any possible balanced demand scenario within these bounds can be fulfilled by the network. Now adding a connectionβ¦
Thorsten Koch 37
1000 1000 1000 1000 1000 1000 500 1000 1000
What does βCapacity of the Networkβ mean?
The Technical Capacity is defined as the maximum flow bounds at the entry- and exit-nodes, such that any possible balanced demand scenario within these bounds can be fulfilled by the network. Now adding a connection β¦ does not necessarily increase it.
Thorsten Koch 38
1000 1000 1000 1000 1000 1000 500 1000 1000 500 500 500 500
What does βCapacity of the Networkβ mean?
The new connection also adds restrictions due to pressure coupling. Not all splits of the inflow between the two entries are easily possible anymore. See also Braessβs paradox.
Thorsten Koch 39
80 bar 60 bar 50 bar 34 bar 70 bar 42 bar
Transient Models
Transient models describe the network state over time. Advantages
β· This is quite realistic (depending on the time step size)
Disadvantages
β· Can only be computed over a finite time horizon β· Requires a forecast of the in- and outflow over time β· Requires a start state, which is not known for planning β· Deviations between the predicted and the physical network
state grow over time If we want to decide the feasibility of a future demand scenario should we test against:
β· A worst case start state? Far too pessimistic β· All possible start states? Infinitely many β· A suitable start state? Likely overly optimistic
Thorsten Koch 40
Stationary Models
Stationary models describe a (timeless) equilibrium network state. Advantages
β· Stable situation (by definition)
modelling an βaverage networkβ state
β· No start state needed, no time horizon to consider β· Ensures that the situation is sustainable
(we cannot paint ourselves easily into a corner)
β· Much less data requirements, simpler physics
Disadvantages
β· Using pipes as gas storage (linepack) cannot be modelled β· Transition between states cannot be modelled β· Too pessimistic, especially regarding short-term peak situations
Often better suited for medium and long-term planning.
Thorsten Koch 41
Demand Scenarios
Thorsten Koch 42
Demand Scenario
π specifies for each π£ β π the amount of flow that enters π! β₯ 0 or leaves π! β€ 0 the network at π£. The scenario π is balanced, i.e., we have 1
!β*
π! = 0. The task is to decide, whether or not the scenario d can be realized in the network by controlling the active elements. Given a directed graph π» = (π, π΅) that models a gas network. The arcs represent the elements of the network. We distinguish between passive network elements (pipes and resistors), whose behavior cannot be influenced, and active network elements (valves, control valves, and compressors), which allow to control the network. The active and passive elements are collected in the arc sets π΅"/01)2 and π΅3"441)2, respectively.
Are all contractually legitimate scenarios technically feasible?
Thorsten Koch 43
Contractually legitimate Contractually illegitimate
A possible approach:
that are on the border of feasibility.
checked using stationary models.
concluded that also all
feasible.
Assumptions on the Set of all feasible Scenarios
Thorsten Koch 44
Non-smooth Non-convex Non-compact
Assumptions on the Scenarios
Thorsten Koch 45
β· Span the set β· Convexity β· Sweep the border β· Monotonicity
Decisions regarding the Momentum-Equation
Thorsten Koch 46
Momentum-Equation Analytically Discretisation Approximation Friction model HP-PC Colebrook Hofer Nikuradse Smooth Approximation
For medium temperature For medium pressure
Assumptions on the Border
Thorsten Koch 47
The border is not unique
β· different Models/Methods β· different Parameters β· different Implementations
The border is the frontier between technical feasible and technical infeasible.
Assumptions on the Border
Thorsten Koch 48
Vertraglich zulΓ€ssig und realistisch Contractual legitimate and reasonable What we want is not the contractual legitimate area, but the contractual legitimate and reasonable area. This area is not well defined.
Shit!
Thorsten Koch 49
Scenario Generation
Thorsten Koch 50
We are able to generate scenarios and test their technical feasibility (with some limitations). Generation of scenarios:
β· Manual generation of expert scenarios
+ high quality
β· Automatic generation of extreme value scenarios
+ high number
β· Automatic generation of stochastic scenarios
+ reasonable, + high number, + probable distribution
Manual Expert Scenarios
Advantages:
βΆ High Quality βΆ Very well understood
Problems:
βΆ Risk of being too much tuned towards a particular model,
parameter setting, or implementation βlet us see how far we can drive thisβ Disadvantages:
βΆ Small number βΆ Complete coverage of the feasible set is hard to ensure βΆ Only extreme value scenarios, i.e., the probability for the
scenarios to happen in reality is nearly zero
Thorsten Koch 51
Automatic Extreme Value Scenarios
Advantages:
βΆ High number βΆ Can be generated with different methods
Problems:
βΆ Hard to detect contractual legitimate but unreasonable
Disadvantages:
βΆ Only the border of the feasible set is covered βΆ Only extreme value scenarios, i.e. the probability for the
scenarios to happen in reality is nearly zero
Thorsten Koch 52
Stochastic Scenarios
Advantages:
βΆ High number βΆ Can be generated with different methods βΆ Realistic βΆ Coverage of the inner part of the feasible set βΆ Can be attributed with probabilities
Problems:
βΆ Methods for generation are involved and need much data βΆ Refer to the past
Disadvantages:
βΆ Extreme values occur seldom since they are not probable
to happen
Thorsten Koch 53
Combination
βΆ If all three methods are combined, there are nearly no
disadvantages left.
βΆ This may lead to a huge number of scenarios of which
many are possibly similar.
βΆ This can be countered by methods for scenario reduction. βΆ Testing the technical feasibility of the scenarios has
necessarily to happen automatically.
βΆ This can be troublesome regarding extremal value
scenarios.
βΆ Now it is possible to automatically validate scenarios. βΆ This can be extended to compute capacities. βΆ It is possible to extend these concepts to answer more
sophisticated questions, e.g. looking at probabilities for buy back happening when overbooking.
Thorsten Koch 54
Using Optimization rather than Simulation
Thorsten Koch 55
Simulation:
βΆ allows very accurate gas
physics models
βΆ Relies on human
experience to decide feasibility
βΆ Therefore cannot
determine infeasibility Optimization:
βΆ Works on simplified models
βΆ Automatically finds settings
for active elements
βΆ Eventually can prove
infeasibility of a scenario Beware: different solution spaces due to different modeling
Forschungskooperation Netzoptimierung
Thorsten Koch 56
Nova: Nomination Validation
Goal of the project: Build an automatic system that given a network and a set of supplies and demands at the border points computes settings for the active elements
scenario is feasible.
57
Thorsten Koch 57
S t a r t
p r
e c t 09/2008
58
07/2016 Thorsten Koch 58
xxxxxxxxxxxxxxxxxxxxxxxxxSimplified Subnetwork
Thorsten Koch
09/2008 02/10
Element Count Pipes 136 Compressor groups 3 Resistors 8 Control valves 7 Valves 1 Entries 26 Exits 14
59
Start of project First running code and data: 30 min
Simplified Subnetwork
Thorsten Koch
09/2008 02/10 05/10
60
Start of project First running code and data: 30 min nonlinear preprocess: 15 sec
Element Count Pipes 136 Compressor groups 3 Resistors 8 Control valves 7 Valves 1 Entries 26 Exits 14
H-Gas Network (north)
Thorsten Koch
09/2008 02/10
Element Count Pipes 470 Compressor groups 6 Resistors 8 Control valves 23 Valves 34 Entries 26 Exits 87
05/10 10/10
61
Start of project First running code and data: 30 min nonlinear preprocess: 15 sec novel MIP relaxation: 3 min
H-Gas Network (north)
Thorsten Koch
09/2008 02/10 05/10 10/10 01/11
62
Start of project First running code and data: 30 min nonlinear preprocess: 15 sec novel MIP relaxation: 3 min subnet operation modes: 1 min
Element Count Pipes 470 Compressor groups 6 Resistors 8 Control valves 23 Valves 34 Entries 26 Exits 87
Entire L-Gas Network
Thorsten Koch
09/2008 02/10
Element Count Pipes 3,638 Compressor groups 12 Resistors 26 Control valves 121 Valves 308 Entries 9 Exits 860
05/10 10/10 01/11 03/12
63
Start of project First running code and data: 30 min nonlinear preprocess: 15 sec novel MIP relaxation: 3 min subnet operation modes: 1 min first results L-gas network: 2 h
Entire L-Gas Network
Thorsten Koch
09/2008 02/10 05/10 10/10 01/11 03/12 02/13
64
Start of project First running code and data: 30 min nonlinear preprocess: 15 sec novel MIP relaxation: 3 min subnet operation modes: 1 min first results L-gas network: 2 h novel PADM algorithm: 20 min
Element Count Pipes 3,638 Compressor groups 12 Resistors 26 Control valves 121 Valves 308 Entries 9 Exits 860
H-Gas Network (south)
Thorsten Koch
09/2008 02/10
Element Count Pipes 1,218 Compressor groups 34 Resistors 47 Control valves 115 Valves 473 Entries 17 Exits 286
05/10 10/10 01/11 03/12 02/13 06/13
65
Start of project First running code and data: 30 min nonlinear preprocess: 15 sec novel MIP relaxation: 3 min subnet operation modes: 1 min first results L-gas network: 2 h novel PADM algorithm: 20 min first results for south H-gas: 9 h
Entire H-Gas Network
Thorsten Koch
Start of project 09/2008 First running code and data: 30 min 02/10
Element Count Pipes 1,747 Compressor groups 41 Resistors 85 Control valves 145 Valves 545 Entries 45 Exits 429
Nonlinear preprocess: 15 sec 05/10 novel MIP relaxation: 3 min 10/10 subnet operation modes: 1 min 01/11 first results L-gas network: 2 h 03/12 novel PADM algorithm: 20 min 02/13 first results for south H-gas: 9 h 12/14 tailored heuristics: 57 min 06/13
66
The Research Cooperation Network Optimization ForNe ran for 6 years and involved more than 30 people from around 10 universities and institutes along with more than 10 employees from Germanyβs largest gas network system
Γ§ Here are the results.
Thorsten Koch 67
Computational outcome
Thorsten Koch 68
Number of infeasible scenarios Number of scenarios reaching iteration limit Feasible scenarios
Time spend
Thorsten Koch 69
Running time in h Number of computed scenarios
Feasible Infeasible Iteration limit
Additional difficulties
βΆ Technology is changing all the time,
new systems mix with existing ones
βΆ Often hard to determine actual system limits
(many assumptions are necessary for optimization)
βΆ Optimization drives errors to cluster in one direction βΆ For larger models/scenarios hard to check against reality
(also very hard to find data errors/inconsistencies)
βΆ Marketization makes it difficult to predict behavior of
participants, since the objectives of the individual players are unknown, and the outcome is result of a game (negotiation).
Thorsten Koch 70
Some insights
Thorsten Koch 71
Relevant real-world questions can be tackled efficiently with mathematical optimization and algorithmic intelligence.
βΆ a substantial effort is needed to succeed, βΆ the setup cost is high compared to pure research, βΆ close cooperation with practitioners is indispensable, βΆ different disciplines need to collaborate, βΆ access to and curation of data is essential.
Thorsten Koch 72
Thorsten Koch 73
Thorsten Koch 74