1 Introduction

The physical and technical properties of gas transport in networks have been studied for many decades already. They have gotten increasing attention in the last years since countries worldwide attempt a turnaround in their national energy policies towards carbon dioxide neutral means of energy production. Reasons for this are the potential usage of gas networks as flexible energy storage for balancing the highly volatile generation of renewable energy sources (Federal Ministry for Economic Affairs and Energy 2021) or the prospect of shifting to hydrogen transport in the future (European Commission 2020). In both cases, controlling the network is expected to become more dynamic and complex, either due to the increasing variability of supply and demand or the gas properties of hydrogen compared to natural gas (Hoppmann-Baum et al. 2020). To make the task of operating gas networks manageable, the decision-making is split into multiples levels. It ranges from the complete view on the network featuring only abstract representations of the technical elements to detailed but local control decisions, for example, the degree of openness of a single pressure regulator or the rotational speed of a gas compressor (Stelter 1988). The decisions on the different levels are usually connected via the concept of set-point values or target values. These represent a control requirement determined in the full network view, which then serves as an objective for the local operation of the actual machinery.

Controlling an element with set-points is a well-known concept in the community of automated control systems. The difference between the measured (actual) and the desired (target) value of an observed process variable is the basis for error-controlled regulation with negative feedback (closed-loop) in automatic control (Porter and Khaki-Sedigh 1988). Proportional-Integral-Derivative (PID) control is the most common feedback control algorithm in engineering systems. In process industries, most of the control loops ( \(\approx 95\%\)) are of PID type (Åström and Murray 2008). The advanced control methods including model based control techniques (model predictive control (Camacho and Alba 2007; Darby and Nikolaou 2012; Haber et al. 2014) or multivariable control (Skogestad and Postlethwaite 2005)), intelligent control techniques (fuzzy control (Nguyen et al. 2019) or neural network based control (Meireles et al. 2003)), and adaptive control (Åström and Kumar 2014), are often used as a high level control procedures for designing high performance controllers that can be applied to high-order and multivariable processes, typically nonlinear and subject to constraints.

When looking at work regarding the simulation or optimization of mid-to-high pressure gas transport networks, the usage of set-points to control active elements has a long history as well. In (Mallinson et al. 1993), the authors present the optimization problem of finding a stationary control for the British gas network. The control of the compressors is defined as the corresponding set-point for the gas pressure after compression, also called the outlet or outgoing pressure of the element. The same holds for (Rachford and Carter 2000), who examine a transient optimization problem on a gunbarrel network, given a desired final state of the network. In a second paper, the same authors extended the model to prepare for not one but multiple possible future scenarios in a robust way (Carter and Rachford 2003). In recent years, more set-point or target value models have been used. In their description of a stationary gas network control optimization problem, (Pfetsch et al. 2015; Schmidt et al. 2015; Koch et al. 2015) introduced a model for a regulator without remote access having a fixed set-point for the outgoing pressure. However, depending on whether the actual state value exceeds the set-point, matches it, or falls below it, the regulator is closed, active, or fully open. In the last case, it acts as a bypass. Finally, there are also models including a multitude of different set-point or target values. In (Pambour et al. 2016), a model used for gas network simulation was introduced, in which regulators and compressors are given a set-point either for the inlet pressure, the outlet pressure, the flow, or the ratio of both the in- and outlet pressure. Alternatively, they can be chosen to be closed or in bypass mode. The simulation model of (Benner et al. 2019) features two different modes for each compressor and regulator. These either try to keep the inlet or the outlet pressure at a given target value.

In this article, we introduce a more elaborate description of the desired control of active elements. It features up to six different target value restrictions that are simultaneously active and compete with each other, which surpasses the current state-of-the-art in the literature, where only one set-point value is considered at a time. An element in our model can react to changing conditions in the surrounding network without the need to change the target value objective manually. In the example of a regulator, it is able to autonomously switch between holding the inlet pressure, holding the flow, or even closing the element. This model captures the behavior of complex elements used in real-world networks and industry-standard simulators to precisely express the desired control given dynamically changing conditions in the corresponding part of the network.

The description can, in general, be applied to regulators and compressors. However, we focus on regulators here, i.e., the elements reducing the pressure in flow direction by reducing the element’s throughput. In literature, there exist several models for regulators. For example, (Huck 2018) models an idealized regulator by demanding that the pressure difference between its outlet and inlet pressure must be positive and inside a given interval. In (Benner et al. 2019), the regulator is described as a resistor with variable diameter. Hence, it is given a degree of openness ranging between 0 and 1. This allows them to include the edge case of a fully closed regulator, in which the two pressures are decoupled and the flow is zero. The model presented in (Pfetsch et al. 2015; Schmidt et al. 2015; Koch et al. 2015) distinguishes two types of regulators: Those with and without remote access. The ones without remote access are controlled as already described above using the outlet pressure target value. When having remote access, the regulators can either be closed or again keep their pressure difference inside a given interval. Another and precursor to one of our models presented here is presented in (Hennings et al. 2021). Within there, the authors consider three different modes for a regulator: The regulator is either closed, active, or open. A closed regulator is defined as for the other models, an open one does assume the inlet and outlet pressures to be equal, while an active regulator allows for arbitrary pressure reduction. In addition, the regulator features a check valve or flap trap, which prevents flow against the regulator’s orientation.

We present two models for regulators using the target value control: one model suitable for dynamic simulation and one for discrete optimization problems. While for the simulation model a set of target values over time is given, the optimization model determines target values that induce the desired element behavior while changing as little as possible. Both models go beyond a one-at-a-time-target-point-value paradigm by introducing up to 6 competing target values at any given point in time. Subsequently, we provide a regulator instance that pushes the envelope for any target value incorporating regulator model, on which we base 2 different numerical experiments. Within these experiments, we first compare each of the proposed models with simulations from the industrial simulator SIMONE (LIWACOM Informationstechnik GmbH 2022), and we then second demonstrate a framework pipeline, in which we connect both models to predict-then-verify a set of intervention-minimizing set-point values on top of the first experiment. The premise of our work is that SIMONE is an established and certified simulator from and for the industry. We therefore assume it to be sufficiently accurate to real-world gas transport operations. Even more, complete data sets of pressures and flows of entire gas networks, such as national grids, can only exist as a result of so-called reconstructions from sporadic measurements within the network (Graham et al. 1996). Such a reconstruction mode is provided, e.g., by SIMONE. Hence, we compare our results versus SIMONE not in the role of another simulator but as a representative of reality. As a consequence, the simulations done by SIMONE are not our competition but instead our reference benchmarks.

Even though this paper deals with the control of active elements in gas networks, the presented models can easily be applied to other engineering applications featuring automated control systems in which errors of multiple process variables affect the same actuator. For these cases, it provides templates for modeling the corresponding behavior in a simulation or an optimization context.

The rest of the paper is structured as follows: In Sect. 2, we introduce the fundamental gas flow dynamic in pipes and our representation of a gas network as a directed graph. Based on this, we describe our new regulator model based on the 6 different target values in Sect. 3. In the following two sections, we first introduce a corresponding model suitable for the transient simulation of regulators given the target value settings for a future time horizon. Afterwards, we describe a discrete optimization model that can determine the control of a regulator in terms of the target values in a transient context. In Sect. 6, we present two experiments on a minimal gas network and compare the performance of the two models against each other as well as a commercial simulation software. We conclude with the outlook in Sect. 7.

2 Models for gas flow in pipe networks

Mathematical models of various so-called active elements, such as regulators, compressors, or valves, manipulate the passing gas flow by blocking, resisting, or enhancing it. However, the response to their actions is determined in the surrounding pipes that provide the volume for the gas to be. Hence, we need to model the behavior of the gas in pipes in terms of pressures p, mass-flows q, and their interaction. We use a version of the isothermal Euler equations, which we introduce and describe in the following subsection.

2.1 Isothermal Euler equations

A simplified or friction dominated version of the one-dimensional set of isothermal Euler equations for the description of the behavior of fluids within perfectly cylindrical pipes of length \(L \in \mathbb {R}_{>0}\) in \(\hbox {m}\) and diameter \(D \in \mathbb {R}_{>0}\) in \(\hbox {m}\) is given by

$$\begin{aligned} \dot{p}&= -\left[ \frac{z^2(p)}{z(p) - p\cdot \partial _p z(p)}\right] \kappa \cdot \partial _x q, \end{aligned}$$
(1a)
$$\begin{aligned} \chi \cdot \dot{q}&= A\partial _x p + \frac{\lambda }{2 D}\kappa z(p) \frac{q|q|}{p} + \delta \!h \frac{g}{\kappa } \frac{p}{z(p)}, \end{aligned}$$
(1b)

with \(\chi \in \{0, 1\}\) being a time constant model switch. These particular versions are referred to as ISO2 if \(\chi = 1\), or as ISO3 if \(\chi = 0\) according to (Domschke et al. 2021) and can be derived by a time scaling approach presented by (Brouwer et al. 2011). According to empirical observations in (Hennings 2021), we use the ISO3 case exclusively here, where \(\chi = 0\).

The intrinsic quantities of the equations are \(p \equiv p(x, t)\) for the pressure, \(q \equiv q(x, t)\) for the mass flow, \(\rho (x, t)\) for the density, and v(xt) for the velocity and are parameterized along the longitudinal axis by \(x \in \varOmega = [0, L]\) as well as being averaged across the cross-sectional area \(A = \frac{1}{4} \pi D^2\) as enclosed by the pipe. Furthermore and throughout, let \( \dot{p}(x, t) \equiv \partial _t p(x, t) \) and likewise for \(\dot{q}(x, t)\) be the time derivatives. Also, let \(R_s\) be the specific gas constant, T be the time-constant temperature, \(\kappa = R_sT/A\) as shorthand, \(g \approx 9.81\hbox {m}/\hbox {s}^{2}\) the gravity constant, and \(\delta \! h = (h_r - h_\ell )/L\) as secant slope defined by the heights \(h_\ell \) on the left and \(h_r\) right end of the pipe. Furthermore, let \(z(p) = z_0 + z_1 p + \dots + z_np^n\) be a polynomial model or truncated Virial expansion for the gas factor for real gases (Onnes 1902), and \(\lambda \) be the friction coefficient of the Darcy-Weisbach equation (Brown 2003). The latter is an empirical model of pressure loss due to friction with the pipe wall.

For the determination of coefficients of the polynomial real gas factor model z(p), we make use of the linear AGA formula (SIMONE Research Group and LIWACOM Informationstechnik GmbH 2021; Domschke et al. 2021) of the American Gas Association, being accurate up to pressures \(p \le 70\,\hbox {bar}\), the quadratic formula of Pápay (Pápay 1968; Saleh 2002) for pressures \(p \le 150\,\hbox {bar}\), or the constant model \(z_0 = c^2/(R_s T)\) as suggested by (Domschke et al. 2021), where c is the speed of sound within the given gas mixture.

To approximate the friction factor \(\lambda \), we use the Nikuradse formula (Nikuradse 1950), which is given by

$$\begin{aligned} \lambda = \left[ -2\log _{10}\big ( r/(3.71D) \big ) \right] ^{-2}. \end{aligned}$$
(2)

It is an explicit simplification of the otherwise implicit Colebrook-White (Colebrook and White 1937; Brown 2003) formula. Here r is the roughness of the pipe wall surface and is usually provided in millimeters \(\hbox {mm}\).

Two important identities that have already been utilized for the ultimate derivation of (1) are

$$\begin{aligned} p = R_s\cdot T\cdot \rho \cdot z(p) \quad \text {and}\quad q = A\cdot \rho \cdot v, \end{aligned}$$
(3)

where the first one is referred to as the state equation for real gases (Menon 2005). We call (1) the pipe equations. More in-depth details on Euler equations in the context of fluid transport can be found, e.g., in (Osiadacz 1996; Domschke et al. 2021; Benner et al. 2019).

Alternatively, in (Hennings 2018), a linearization of the pipe Eq. (1) has been proposed, which has the benefit of avoiding divisions by small pressure values. There it was observed that the Eq. (3) yield the identity \(|v| = z(p)\cdot \kappa \cdot |q|/p\), which can be fixed on predetermined or forecast velocities \(|{{\bar{v}}}|\), such that

figure a

Provided we use a constant model for the real gas factor, then Eqs. (1a) and (1b”) together yield a linearized model of the pipe equations.

2.2 Gas networks as graph structures from a macroscopic perspective

We have just established the system of pipe Eq. (1), but we are interested in gas networks as a whole and in solving online tasks. In this context, online means to utilize simulation or optimization to formulate control and operation recommendations as a guiding as well as continuous process live at operation time. Thus, the overall problem results in potentially large systems that must be solved repeatedly in a very limited time frame. For this reason, we have to take a macroscopic viewpoint regarding modeling the network and its building blocks. Hence, we consider gas networks as directed graphs \({\mathcal {G}} = ({\mathcal {N}}, {\mathcal {A}})\) over some time horizon \([t_0, T] \subseteq \mathbb {R}\) of interest. The set of nodes \({\mathcal {N}}\) is finite \(|{\mathcal {N}}| < \infty \), and the set of arcs \({\mathcal {A}} \subseteq {\mathcal {N}}\times {\mathcal {N}}\) is a collection of ordered tuples of nodes.

Nodes represent the intersection points of all the arcs. Each node \(n \in {\mathcal {N}}\) serves as a boundary to all of its adjacent arcs and hence intertwines and connects them by the so-called flow balance equation, which is a Kirchhoff typed law

$$\begin{aligned} q^{(n)}(t) + \sum _{a \in {\mathcal {A}}_r[n]} q_a(L, t) = \sum _{a \in {\mathcal {A}}_\ell [n]} q_a(0, t). \end{aligned}$$
(4)

Here \({\mathcal {A}}_\ell [n]\) is the set of all arcs (i.e., ordered tuples) \(a \in {\mathcal {A}}\) whose first node is n and \({\mathcal {A}}_r[n]\) likewise is the set of all arcs \(a \in \mathcal A\) whose second node is n, i.e.

$$\begin{aligned} a \in {\mathcal {A}}_\ell [n]&\iff \exists m \in {\mathcal {N}}: a = (n, m) \in {\mathcal {A}}, \\ a \in {\mathcal {A}}_r[n]&\iff \exists m \in {\mathcal {N}}: a = (m, n) \in {\mathcal {A}}. \end{aligned}$$

Furthermore, \(q^{(n)}\) is the gas inflow or outflow to the network, and therefore \(q^{(n)} = 0\) for most nodes. However, if n is an entry or exit, a time-dependent piecewise constant or piecewise linear flow-profile \(q^{(n)}:\, [t_0, T]\subseteq \mathbb {R}\rightarrow \mathbb {R}\) is assumed to be provided. A second kind of Kirchhoff law hosted at nodes mediates boundary pressures from adjacent arcs in the following sense

$$\begin{aligned} \forall a \in {\mathcal {A}}_\ell [n]:\, p_a(0, t)&= p^{(n)}(t),&\forall a \in {\mathcal {A}}_r[n]:\, p_a(L, t)&= p^{(n)}(t), \end{aligned}$$
(5)

where \(p^{(n)}(t)\) is the so-called node pressure. Hence, this Kirchhoff law forces adjacent boundary pressures to coalesce at all times and associates the mutual value to be the pressure of the node.

Arcs represent mostly pipes but may also stand for other network elements such as active elements, like valves, regulators, and compressors. For each arc \(a = (n_\ell , n_r) \in {\mathcal {A}}\), the flow \(q(x, t) \equiv q_a(x, t)\) and pressure \(p(x, t) \equiv p_a(x, t)\) on both its ends are of particular interest and, therefore, are abbreviated by \(q_\ell (t) \equiv q(0, t)\), \(q_r(t) \equiv q(L, t)\), \(p_\ell (t) \equiv p(0, t)\), and \(p_r(t) \equiv p(L, t)\). Correspondingly, the same holds true for the time derivatives, such that \(\dot{p}_\ell (t) = \dot{p}(0, t)\), \(\dot{p}_r(t) = \dot{p}(L, t)\), \(\dot{q}_\ell (t) = \dot{q}(0, t)\), and \(\dot{q}_r(t) = \dot{q}(L, t)\). On top and for the sake of readability we often omit the argument t from our notions \(p_\ell = p_\ell (t)\), \(p_r = p_r(t)\), \(q_\ell = q_\ell (t)\), \(q_r = q_r(t)\), \(\dot{p}_\ell = \dot{p}_\ell (t)\), \(\dot{p}_r = \dot{p}_r(t)\), \(\dot{q}_\ell = \dot{q}_\ell (t)\), \(\dot{q}_r = \dot{q}_r(t)\) within larger formulas.

2.3 On spatial discretizations of the pipe equations

The literature offers quite a variety of potential spatial discretizations for the pipe Eq. (1). We pick two schemes for our presentation and numerical experiments following in Sect. 6 below. The first discretization in our listing originates as discretization for pipes in water networks (Huck et al. 2014) and also has been studied in-depth in (Huck 2018) for gas networks in advance. We refer to it as left-right-discretization

$$\begin{aligned} \dot{p}_r&= -\left[ \frac{z^2(p_r)}{z(p_r) - p_r\cdot \partial _p z(p_r)}\right] \kappa \frac{q_r - q_\ell }{L}, \end{aligned}$$
(6a)
$$\begin{aligned} 0&= A\frac{p_r - p_\ell }{L} + \frac{\lambda }{2D}\kappa z(p_\ell ) \frac{q_\ell |q_\ell |}{p_\ell } + \delta \!h \frac{g}{\kappa } \frac{p_\ell }{z(p_\ell )}. \end{aligned}$$
(6b)

The second scheme, or implicit-box-scheme, has been analyzed within (Kolb et al. 2010). It is a combined spatial and time discretization scheme. In (Streubel 2022) it was observed that it can be derived in two stages by discretizing in space first and applying the time discretization subsequently. Executing the first stage only leads to the following system of differential equations

$$\begin{aligned} \dot{p}_r + \dot{p}_\ell&= -\left[ \frac{z^2(p_\ell )}{z(p_\ell ) - p_\ell \cdot \partial _p z(p_\ell )} + \frac{z^2(p_r)}{z(p_r) - p_r\cdot \partial _p z(p_r)}\right] \kappa \frac{q_r - q_\ell }{L}, \end{aligned}$$
(7a)
$$\begin{aligned} 0&= A\frac{p_r - p_\ell }{L} + \frac{\lambda }{2 D}\kappa \left[ z(p_\ell )\frac{q_\ell |q_\ell |}{p_\ell } + z(p_r)\frac{q_r|q_r|}{p_r}\right] \nonumber \\&\quad + \delta \!h \frac{g}{\kappa } \left[ \frac{p_\ell }{z(p_\ell )} + \frac{p_r}{z(p_r)}\right] , \end{aligned}$$
(7b)

relying on the trapezoidal quadrature method along the spatial dimension. Hence, we refer to (7) as the trapezoidal-discretized pipe equation.

3 Towards the regulator: a target value model

Regulators can down-regulate or halt the passing gas flow, and thereby indirectly exercise control of their surrounding neighborhood, and ultimately down the network. They can also mediate and exchange gas between areas operated at different pressure levels. Their operation is controlled by target values. In this section, we provide a detailed explanation of the underlying target value logic and establish notions as well as terminology. The logic is based on the interactions between pipes and regulators, which we can express in the following diagram of expected principal reactions of the left pressure \(p_\ell \) and right pressure \(p_r\) when facing changes of the regulator’s flow q:

$$\begin{aligned} q \nearrow \qquad&\rightsquigarrow \qquad p_\ell \searrow p_r \nearrow \ ,\end{aligned}$$
(8a)
$$\begin{aligned} q \searrow \qquad&\rightsquigarrow \qquad p_\ell \nearrow p_r \searrow \ . \end{aligned}$$
(8b)

In other words a sudden rise in flow either causes a drop of the left pressure or a rise of the right pressure or both. Likewise a drop of flow either causes a rise of the left pressure or a drop of the right pressure or both. This relationship is deduced from the pipe equations in Sect. A.1 of the “Appendix”.

3.1 Regulators controlling the gas flow

Fig. 1
figure 1

Visualization of a regulator controlling the right pressure; picture created by (Kuphaldt 2019), published under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/)

The task of regulators in gas networks is to reduce the pressure along their orientation along their orientation, which they achieve by using the connection to the neighboring pipes established by (8) and decreasing the passing gas flow. This flow decrease is accomplished by reducing the regulator’s opening degree \(o\in [0,1]\), which can be interpreted as changing the diameter of the regulator, assuming its cross-sectional area is cylindrical, see (Fügenschuh et al. 2015). If a regulator is fully opened at \(o=1\), it does not reduce the flow and \(p_\ell =p_r\) holds. At \(o=0\), a regulator is fully closed, which disconnects the network. Hence, \(q=0\) and the pressures are decoupled. Values in between induce artificial resistance to reduce the flow and therefore create a pressure decreases in flow direction as derived in Section A.1, i.e., \(p_\ell \ge p_r\). A schematic visualization of the principle operation of a regulator is depicted in Fig. 1. It originates from (Kuphaldt 2019), where more insights on various technical details and further information on other gas network elements are provided, too.

3.2 Target value control

For gas network operators, i.e., dispatchers, adjusting the opening degree of single elements by hand is far too involved and would require continuous observation. Instead, regulators have automated systems fed by desired ranges for the 3 local intrinsic quantities \(p_\ell , p_r, q_m\). The 6 defining bounds for these ranges , , , , , are called target values (and sometimes also referred to as set-point values). An overview of the 6 types of target values and their consequential influence is listed in Table 1.

Table 1 Overview of all types of target values sorted by priority from high at the top to low at the bottom

If a target value imposed bound is violated by the state values (we then also refer to the target value as being violated), the element adjusts according to Table 1 to prevent or reduce the violation as much as possible, using the relation of the opening degree to the three quantities. To resolve conflicts of multiple violated target values demanding opposing changes, the target value types are prioritized by \(\varphi (\tau )\) for the target values \(\tau \) from top to bottom. In general, pressure target values and those reducing the opening degree and thereby the flow have higher priorities. Some target values may share their priority value, but only if they influence the element’s control in the same way.

Note that it is possible to force the regulator to be fully opened or fully closed by using certain target value combinations, for example, by setting

The Regulator’s Check Valve A regulator contains a built-in element that prevents flow against its orientation, i.e., \(q\ge 0\). This element is called a check valve or flap trap and automatically closes the regulator in case the right pressure rises above the left one, i.e. \(p_\ell < p_r\). This action has a higher priority than all the target values and therefore happens independently of these. If the regulator is not closed by the check valve, \(p_\ell \ge p_r\) holds.

Infinite Minimal Flow Target Value For most elements, the lowest priority target value is fixed to \(\infty \), which effectively is the same as choosing , in which case we may also denote . Regulators were actually are called “flow band regulators” or simply “band regulators”. They keep their current degree of openness and do not react to changes in the flow as long q stays within and provided that all other target values are satisfied. This behavior would increase the overall complexity of the models used for the simulation and optimization of target values tremendously and is out of this paper’s scope.

Target Value Existence Not all target values are always in use. This has to be taken into account by the models described below, for example by prohibiting their violation by setting maximal target values to \(\infty \) and minimal target values to 0.

However, we assume that the fixed target value always exists and, in addition, at least one of the closing target values. Furthermore, we expect the existence of in case either or exists. As a consequence, for each existing not-fixed target value, there also exists a target value of opposing direction as well as lower priority.

3.3 Target values for compressors

In addition to regulators, also active compressors are controlled by target values. While compressors increase the pressure in flow direction, they influence their flow throughput to achieve these local pressure changes similar to regulators. For the two most common types of compressors, the flow changes are realized by controlling the compressor’s rotational speed, see (Fügenschuh et al. 2015; Schmidt et al. 2017) for a more detailed explanation. Due to the similarities, the target value description for compressors is very close to the one of regulators. However, it is out of this paper’s scope.

4 Modeling regulators for dynamic simulations

We follow (Streubel 2022) for the derivation of regulator models for the dynamical simulation. Consider the following ordinary differential equation

$$\begin{aligned} \dot{x}(t) = \alpha [c(t) - x(t)],\quad \text {where}\quad x(t_0) = x_0. \end{aligned}$$
(9)

Assuming that \(c(t) = 0\) is the constant zero function, the corresponding solution would be \(x(t) = \exp (t_0 - t)^\alpha \cdot x_0\) and be convergent to \(c(t) = 0\) for \(t \rightarrow \infty \). On the other hand if c(t) is some continuous but not necessarily smooth function, we still can find an explicit expression by adding a correction term to the solution formula

$$\begin{aligned} x(t) = \exp (t_0 - t)^\alpha \cdot x_0 + \alpha \int _{t_0}^t \exp (s - t)^\alpha \cdot c(s)\, {\textrm{d}}s. \end{aligned}$$

This more general solution is a leaky or lazy smoothing of c(t), because in the limit \(\dot{x}/\alpha \xrightarrow {\alpha \rightarrow \infty } 0\), we find \(x(t) = c(t)\). Hence, the behaviour of x(t) is best described as chasing or constantly steering towards c(t). This means we can utilize (9) as a starting point for modeling regulators in the following way: Assume \(x(t) = q(t)\) within (9) to be the flow through a regulator, then the function c(t) can be interpreted as a controller. That means by raising or lowering the values of c(t) over time we can guide the flow and hence regulate it up or down.

Let us again substitute \(x(t) = q(t)\) but also with the target value for the flow and so (9) turns into

(10)

Here and for the remainder of this section we will assume .

Most regulators do not allow reversed flow and are of course non-compressing. Check valves can be modeled via \(\dot{q} = \alpha \max (0, -q)\), where \(\dot{q} = 0\) whenever \(q \searrow 0\). The non-compressing behavior can be expressed via \(\dot{q} = \alpha \min (p_\ell - p_r, 0)\) such that \(\dot{q} = 0\) once \(p_\ell \searrow p_r\) to avoid further contribution into the right pressure according to the behavioral tendencies introduced in (8). Both features combined with (10) provide

(11)

which is a nesting of max-min-comparisons that represent logical and/or conjunctions. This nesting is necessary and represents the prioritization of the already integrated features. In a similar manner to the non-reversed flow and the non-compressing behaviour, we find independent modelings for each of the remaining target values

Finally, we combine all single-aspect models within the nesting of (11) and end up with the full regulator model

(12)

Two possible modifications of (12) are

figure l

or the limit system \(\dot{q}/\alpha \xrightarrow {\alpha \rightarrow \infty } 0\)

figure m

5 Modeling regulators for discrete optimization

To be able to optimize over the regulator’s target values in the context of time-discretized transient gas network operation, we aim for a model suitable for discrete optimization solvers. Our objective is to minimize the number of changes in the target values such that the control decisions induced by them are feasible to fulfill the demands of the network, which are usually given at the entries and exits. A low number of target values leads to a more stable control of the network, which is preferable for the network operators and reduces strain on the technical elements (Hennings et al. 2021).

For improved readability, we use indicator constraints of the form

$$\begin{aligned} y = b \quad \rightarrow \quad a^T x \le a_0 \qquad y,b\in \{0,1\}, x,a\in \mathbb {R} ^i, a_0\in \mathbb {R} \end{aligned}$$

stating that the constraint \(a^T x \le a_0\) for a set of variables \(x = \{x_1, \dots , x_i\}\) is active if the binary variable y attains the value b. If x is bounded, these can be reformulated using linear constraints, see for example (Bonami et al. 2015).

5.1 A basic regulator model

We use the following model describing the general behavior of a regulator \(a=(\ell ,r)\) from the literature, see for example (Koch et al. 2015; Hennings et al. 2021):

figure n

The model features the mode variables \(m _{a}^\textrm{op}\) for an open regulator, \(m _{a}^\textrm{cl}\) for a closed regulator, and \(m _{a}^\textrm{ac}\) for an active regulator with opening degree in (0, 1), which has also been used in (Hennings et al. 2021). We add the mode \(m _{a}^\textrm{cvcl} \) for a regulator closed by the internal check valve in case of \(p _{\ell } \le p _{r} \). In this case, the target values do not influence the regulator according to Sect. 3.2. Note that the open mode is often replaced by a “bypass” mode in the literature, representing a bypassing network path that also allows flow in the backwards direction, which is not included in our regulator model.

5.2 Stable-pushing target value combinations

In preparation for the model construction, we determine for each target value the cases in which its implied bound has to be obeyed. While in reality, the adjustments of active elements caused by violated target values happen with a certain delay, we make the following assumption for our target value model:

Assumption 1

The control of each active element, i.e., the opening degree adjustment for regulators, reacts to changing target values or operation point conditions immediately and with perfect precision according to the given list of target value priorities \(\varphi \). Hence, we can assume the control is always fully adjusted to the given network situation and target values.

This assumption is fundamental for the following classification and is mainly motivated by the fact that the larger size of time steps used in discrete optimization problems in comparison to simulation approaches prohibits an appropriate modeling of delayed element reactions. Note that this is equivalent to the simulation model (12.ii) assuming \(\alpha \rightarrow \infty \). Moreover, we observe the following:

Observation 1

Since always exists and is violated, there always is at least one violated target value. From these target values, we call the one with the highest priority \(\varphi \) the pushing target value.

Note that there might be multiple violated target values of highest priority. However, these always have the same direction, i.e., either opening or closing altogether, see Table 1.

Having these two building blocks, the following theorem can be deduced, which is the fundamental building block for enumerating all the possible compositions of target value states of a regulator.

Theorem 1

[Stable and pushing target values] If \(p _{\ell } \ge p _{r} \) for a regulator a, i.e., it is not closed due to its check valve, one of the following statements holds:

  1. (1)

    There is at least one target value \(\tau \), called the stable target value, with higher priority than the pushing target value as well as opposing direction in terms of change in case of violation, such that \(\tau \) is equal to its corresponding operation point quantity.

  2. (2)

    The regulator a is fully open, i.e., in open mode, and the pushing target value is an opening target value.

  3. (3)

    The regulator a is fully closed, i.e., in closed mode, and the pushing target value is a closing target value.

Proof

Observation 1 states the existence of the pushing target value as a violated target value of highest priority at any given point in time. According to the description given in Sect. 3.2, the regulator tries to adjust the opening degree to reduce the corresponding violation. However, according to Assumption 1, the opening degree is already perfectly adjusted and therefore does not change. The two possible reasons are:

  1. (a)

    The regulator cannot adjust the opening degree in the desired direction since it is already fully opened or closed.

  2. (b)

    There is some higher priority target value that would be violated if the opening degree would be changed by any amount in the desired direction due to the induced operation point changes.

For case (a), either statement (2) or (3) holds, depending on the direction of the pushing target value’s opening degree change. For case (b), the higher priority target value has to have the opposite opening degree change direction compared to the pushing target value. Furthermore, the current target value must be equal to the corresponding operation point quantity since any change in the opening degree, no matter how small, would cause a violation. Hence, statement (1) is true. \(\square \)

Note that while the situations of (2) and (3) are coupled to a specific regulator mode, this is not the case for (1), where the two opposing target values may fix the opening degree at a position that just happens to be fully open or fully closed.

Table 2 The table shows all possible stable-pushing target value combinations, one for each line

Using Theorem 1, we are able to compile a complete list of possible configurations in terms of combinations of stable and pushing target values, which cover all possible states of a fully adjusted regulator according to Assumption 1. This list of stable-pushing target value combinations is displayed in Table 2. Each row represents either a possible stable-pushing target value combination with opposite directions or a single pushing target value without a stable target value counterpart. Since the pushing target value is, by definition, the highest priority target value that is violated, all bounds implied by target values having a higher priority have to be satisfied. On the other side, all constraints of target values with priority lower than or equal to the pushing target value are irrelevant for that stable-pushing combination. Note that in the case of non-existing target value types, the corresponding rows with non-existing stable or pushing target values, as well as the columns of the missing target value types, would be removed.

To prepare for the formulation of our mixed-integer programming model, we make one adjustment to the contents of Table 2: We only allow the usage of the active mode for all target value combinations featuring a stable target value. This is possible since the feasible region of both the open and the closed mode is contained in the one of the active mode according to the above-presented regulator model (13). As a result, we can assume that the regulator is in active mode if and only if it has a stable target value. All the open and closed mode cases with stable target value are covered by a corresponding operation point from the active mode showing the exact same behavior.

5.3 A mixed-integer linear formulation

Based on the characterization derived in the previous section, we now present our mixed-integer linear programming (MILP) target value model for single regulator \(a=(\ell ,r)\) at time t. As the model extends the basic regulator model (13), we only state the additional variables and constraints. First, we introduce some sets:

figure q

Now, we can specify the new variables as

The \(\tau \) variables represent the target values chosen by the model. They can be set inside the variable bounds \(\underline{\tau }_{x,a}\) and \(\bar{\tau } _{x,a}\) for each target value x. These are given for each individual regulator a and can considerably restrict the feasible operating range of the regulator. If, for example, the minimal left pressure target value has a lower bound value of \(40\,\hbox {bar}\), then the regulator has to operate at a left pressure value of at least \(40\,\hbox {bar}\) in active mode and open mode, since according to Table 2, the target value can only be violated for the closed mode or if the regulator is closed due to the check valve. The variables \(\theta \) represents the stable-pushing target value combination chosen for each regulator a. Finally, the \(\delta \) variables indicate a change in the target value variables \(\tau \) between the values of the previous and the current time point.

For the following set of constraints, we introduce the function o mapping from a given type of target value to the corresponding point of operation:

In addition, we use \(\varphi \) as a function from target value types to the priorities given in Table 1 above. Also, we introduce the parameter \(\varepsilon \), which represents a relative tolerance used in the equality constraint of the stable target value. As explained at the beginning of Sect. 5.2, the adjustment of the regulator’s control to changing target values or operating point conditions happens with a certain delay in reality. Hence, there usually is an offset between the used target values and the current operation point. To better reflect this behavior and prevent too many target value changes caused by minor adjustments of the stable target value, we introduced the relative \(\varepsilon \) value.

The constraints for our target value model are then given as

$$\begin{aligned} m _{a,t}^\textrm{x}&= \sum _{y\in \varTheta ^\textrm{x}_{a}} \theta _{y,a,t} \quad \forall \textrm{x}\in \{\textrm{ac}, \textrm{by}, \textrm{cl}\} \end{aligned}$$
(14a)
(14b)
(14c)
(14d)
$$\begin{aligned} \delta _{x,a,t} = 0 \quad \rightarrow \quad&\tau _{x,a,t} = \tau _{x,a,t-1} \quad \forall x \in \varGamma _{a} \end{aligned}$$
(14e)

Equation (14a) ensures the choice of exactly one stable-pushing target value combination fitting to the current mode. Note that for the check-valve-closed mode, no combination is chosen. Constraints (14b), (14c), and (14d) establish the consequences of the choice of a stable-pushing target value combination and are based on the illustration of Table 2. Structure-wise these constraints collect for a given target value type \(\tau \) all stable-pushing target value combinations in which this type of target value is the stable one for (14b), is violated for (14c), or is satisfied for (14d). If one of these combinations is chosen, the corresponding relations between the target value and the corresponding operation point are enforced. Finally, constraint (14e) defines the target value change variables, forcing the actual target value variable \(\tau _{x,a,t} \) to keep their value if the change variable does not indicate a change, i.e., is zero.

As objective function, we minimize the number of target value changes:

$$\begin{aligned} \min \sum _{a,t} \sum _{x \in \varGamma _{a}} \delta _{x,a,t}. \end{aligned}$$

Note that (Pfetsch et al. 2015; Schmidt et al. 2015; Koch et al. 2015) introduced a model for regulators without remote access that have a set-point control for the maximum right pressure with value \(p ^\textrm{set}\). Depending on whether the right pressure is larger than, equal to, or less than \(p ^\textrm{set}\), the mode is closed, active, or open, respectively. In addition, these regulators also feature a check valve behavior, which in their case allows flow against the regulator’s orientation (bypass instead of open mode). Except for the reverse flow possibility, the described behavior can as well be achieved with our formulation, for example, by setting , , and . The target value is always satisfied and is always violated. Hence, the regulator is either in active mode and has a stable , with \(p _{r} \) equal to the set-point value, or is violated, leading to a closed regulator, or \(p _{r} \) is below and satisfied, leading to the open mode. This shows that our optimization model covers regulators with and without remote access, as introduced in the mentioned literature.

6 Numerical evaluation

To show and verify the accuracy of our models, we present in this section two experiments using the target value control on a single regulator. It is embedded in a simple path network between two pipes, each with \(L={10}\,\hbox {km}, D={0.9}\,\hbox {m}, r={0.012}\,\hbox {mm}\), see Fig. 2.

Fig. 2
figure 2

Benchmark network, consisting of one regulator arc and two pipes surrounding the regulator

For both scenarios, we determine the solution using the dynamic simulation model presented in Sect. 4 as well as the optimization model presented in Sect. 5. Both solutions need to be validated in comparison with a reference solution embodying or substituting the real-world network. Such a reference solution is determined using the SIMONE simulator, which has established itself as a de facto standard due to its wide use in industry. We therefore refer to solutions computed with SIMONE as industry simulations. In other words we attempt to get close to SIMONE results.

The initial steady state of the scenarios features a flow of \(10\,\hbox {kg/s}\) on all arcs as well as inflow at the entry and outflow at the exit. The pressure ranges from \({50}\,\hbox {bar}\) at \(n_\textrm{in}\) to \({49.992}\,\hbox {bar}\) at \(n_{\textrm{out}}\), the regulator is fully open, the constant gas temperature is set to \({283.15}\,\hbox {K}\), and the gas is, for the sake of simplicity, assumed to be pure methane.

The simulation has been programmed in python using the numpy (Harris et al. 2020) and scipy (Virtanen et al. 2020) libraries, i.e., all models, their derivatives but also the necessary solver for differential algebraic equations, for which we have implemented the well-known implicit Euler method. As pipe model, we use the left-right-discretization (6) of the ISO 3 model, equipped with the linear AGA formula for the real gas factor. Note that we chose \(\alpha =1000\) for the simulation model.

For the optimization, we take the linearized pipe model (1b”) discretized with the implicit box scheme. Furthermore, we use a constant real gas factor z, which is determined for each node by using the formula of Pápay and computed from the initial state. The linearized model is not reliable in the case of volatile flow conditions but works fine for the following scenarios featuring similar flows for most of the time. As a benefit, the resulting overall model is linear, which enables us to use a MILP solver for the optimization, in our case Gurobi in version 9.1.1 (Gurobi Optimization 2020), which was accessed via Pyomo (Hart et al. 2011, 2017). Furthermore, we picked \(\varepsilon =0\) for the optimization model.

All computations have been executed on a desktop computer using an Intel Core i5-10310U processor and 16 GB of RAM.

6.1 First scenario

The first scenario’s goal is to verify that both our models are able to accurately produce a realistic target value behavior. As test instance, we use a set of target values obtained from our project partner, the gas network operator Open Grid Europe GmbH (OGE). These target values should lead to different opening degree and throughput changes of the regulator while assuming a steady inflow and outflow at the boundaries of \({10}\,\hbox {kg/s}\) over the whole time horizon of \({12}\,\hbox {h}\). This scenario is a stress test, which represents an example of the gas flow within large transport pipelines in the mid-to-high pressure range of \({30}\,\hbox {bar}\) to \({100}\,\hbox {bar}\). It has been designed to provoke relevant interferences from the regulator involving almost each available target value. An overview of the different switching actions of the target values is provided in Table 3.

Table 3 The target values specified by Open Grid Europe GmbH (OGE) in our benchmark scenario

For the optimization, the simulation, as well as the reference industry simulation, we use a rather typical time discretization of \({3}\,\hbox {min}\). By typical we mean that we have come across this particular time resolution frequently in data and various discussions with representatives from the transporting industry. So we go along with it and treat it as a mandatory time resolution within our experiments. Note that while for the optimization its time discretization is fully determined by this initial choice, the simulators do take it as a baseline and may dynamically vary the time steps’ length internally to add time points in between the mandatory ones. Also note that the target values are fixed for the optimization here, which effectively transforms the problem into a plain feasibility problem, where any feasible solution of the problem has the same nodal pressure and arc flow values. Both simulation runs as well as the optimization run finished in less than 10 s.

Fig. 3
figure 3

Comparison of the simulated solution (SIM), the optimized solution (OPT), and the solution of the industry simulator (IND) for the first scenario with predefined target values based on Table 3. The figures show the difference between two of these solutions, where the second solution acts as a reference solution: On the top is the difference between SIM and IND, then the difference between OPT and IND, and finally, the difference between OPT and SIM. The differences are displayed for each of the three quantities integrated over time and normalized by the quantity integral of the reference solution. Figures created with (Plotly Technologies Inc. 2015)

The differences between the three solutions are shown in Fig. 3, where we compare the simulated solution (SIM) with the one computed by the industry simulator (IND) in Fig. 3a, the optimized solution (OPT) with the one computed by the industry simulator (IND) in Fig. 3b, and the optimized solution (OPT) with the simulated solution (SIM) in Fig. 3c. The displayed relative accumulated errors are defined as the integrated difference over time divided by the time-integrated reference solution, i.e., let \({\textrm{SOL}}, {\textrm{REF}} \in \{{\textrm{SIM}}, {\textrm{OPT}}, {\textrm{IND}}\} \), \(\textrm{SOL} \ne {\textrm{REF}}\) and \(y \in \{p_\ell , p_r, q\}\), then

$$\begin{aligned} \text {relative accumulated error}[y](t) \equiv \frac{\int _{t_0}^t {\textrm{SOL}}[y](s) - {\textrm{REF}}[y](s) {\textrm{d}}s}{\int _{t_0}^t {\textrm{REF}}[y](s) {\textrm{d}}s}. \end{aligned}$$

The development of the left and right pressure values and target values of the regulator, as well as the development of the flow values and target values, are given in the appendix in Figs. 6, 7, and 8. There, we also give a detailed description of the interaction of the different target values with the three quantities and explain the resulting changes of the regulator’s opening degree.

All three solutions are very similar to each other in terms of the development of the regulator’s operation point over time. Hence both derived models, the simulation model and the optimization model, catch the regulator’s behavior compared to the industrial simulation. From Figs. 3, we are able to obtain the following maximal relative error values and relative error values at the end of the time horizon for the pressure, where we always choose the bigger of the two errors given for the left and right pressure, as well as the flow.

figure aq

We observe that the differences in the pressures are, in general, smaller than those in the flows. This is due to the fact that each of the three methods has a different internal implementation of the reaction of the regulator’s opening degree to changing target values conditions. Hence, even though the time discretization is the same for all approaches, the flow values are different in the unstable periods shortly after a target value change leading to a new violation. However, these differences only occur for brief periods of time. We also note that the differences between the two simulation procedures are, in general, smaller than those between the optimization and one of the simulation runs. This is no surprise, as we assume an idealized target value behavior for the optimization model, see Assumption 1. However, we are glad to see how close the solution of the idealized model is to both simulations.

6.2 Second scenario

In the second scenario, we tested both models in a different setup. Here, we determine the regulator’s target values using the optimization model and verify them using the simulation model. Since this task is quite demanding in a volatile environment, even for only a single regulator, we discretized the time horizon for the optimization model into steps of 15 min, leading to 48 time steps in total, whereas both the simulations continue to solve with the baseline resolution of \(3\,\hbox {min}\) as established in the first scenario.

To ensure and provoke the necessity of target value adjustments, we prescribed not only the inflow at the entry and outflow at the exit but also the pressure values over time at both nodes. These pressure values were obtained by solving the optimization model of the first scenario using a time step resolution of \({15}\,\hbox {min}\). This enables us to compare the number of target value changes between the OPT solutions of scenarios 1 and 2 and provide an estimate of the optimization potential.

There is a fundamental difference in the interpretation of value updates of target values between the optimization and the simulation model. A simulation starts with the control adjustment at some point in time, let it be t, and proceeds to adjust thereafter. In contrast to this and due to Assumption 1, the optimization model assumes the adjustment to be finished at t. Hence, it basically assumes that the target values have been changed at some point within the 15 min time step preceding time t. To better synchronize the behaviour in both models, we offset each time point t where the optimization model has determined a change of target values to \(t - \varDelta _t/2\) before passing to the simulation processes. Here \(\varDelta _t\) corresponds to the time resolution of the optimization model, i.e., \(\varDelta _t={15}\,\hbox {min}\). This reduces the maximum possible error between the used and the actual change time. Note that we further round \({7.5}\,\hbox {min}\) up to the next integer value of \({8}\,\hbox {min}\), because our data interface can only process full minutes. While all the simulation runs finishes after couples of seconds, the optimization process requires up to 11 h to finish, i.e., to confirm optimality. The corresponding optimal solution is found in under 6 s.

Table 4 The target values determined by the optimization model. Each row represents a target value change of the given type of target value to the given value at the given time
Fig. 4
figure 4

Comparison of the simulated solution (SIM), the optimized solution (OPT), and the solution of the industry simulator (IND) for the second scenario with optimized target values based on Table 3. The figures show the difference between two of these solutions, where the second solution acts as a reference solution: On the top is the difference between SIM and IND, then the difference between OPT and IND, and finally, the difference between OPT and SIM. The differences are displayed for each of the three quantities integrated over time and normalized by the quantity integral of the reference solution. Figures created with (Plotly Technologies Inc. 2015)

The target values determined by the optimization are listed in Table 4. The differences between the three solutions are shown in Fig. 4, where we again compare two out of the three solutions using the above-defined relative accumulated error measure in each of the visualizations.

When comparing the listed target value changes in Tables 3 and 4, we observe that only 8 target value changes were needed to achieve the regulator control instead of the previous 11 changes. In the optimized solution, the redundant changes of at 04:30 and of at 06:30 are removed, as they do not affect the regulator’s control but increase the objective function value. In addition, the control change at 07:30, which was a consequence of changing at 05:30 and at 07:30, could be realized by a single change of at 07:30. Similar to this last case, some of the other control changes are now triggered by different target value changes. One example would be the change at 05:00, which was previously caused by setting to \({55}\,\hbox {bar}\) and is now triggered by setting to \({45}\,\hbox {bar}\). We again refer to the appendix for a visualization of the development of the left and right pressure values and target values, as well as the development of the flow values and target values in Figs. 9, 10, and 11.

When looking at the solutions over time, the development is again quite similar, which can also be observed from the table below. It shows the maximal relative error and the relative error at the end of the time horizon for the pressure values, where we always choose the bigger of the two errors given for the left and right pressure, as well as the flow values.

figure bl

The error values of the comparison between our simulation and the one of the industry software are consistent with those of the first scenario. This is not surprising, as only the simulated instance changes while the general setup for both stays the same. When comparing one of the two and the optimized solution, we clearly see the difference to the values of the first scenario. Especially the maximum flow error, but also the maximal and overall errors in the pressure have increased significantly. This is an expected change, as the optimization now uses a more coarse discretization. Nevertheless, the pressure differences are still very small in general and not too far away from the values of either simulation. Regarding the errors in the flow, the main difference occurs in the very first minutes of the scenario. Since the initial target values are violated, the control adjusts immediately, which happens during the first time step for all of the three approaches. Due to the different time discretizations, the adjustment is 5 times faster for the simulations than for the optimization. However, the final error regarding the flow values is surprisingly small and consistent to the values of the first scenario. We summarize that both simulations yield very similar results, while the solution of the target value optimization may produce different values during the times of adjusting the control to new target values, but gives very similar results regarding the stabilized control situations.

7 Outlook

In this article, we introduced models for regulators in gas networks and embedded target values for their control. The target values form a system of 6 simultaneously active and hence competing set-points, which enables the regulating element to react to changing conditions in the surrounding network without the need of continuous human observation or manual interactions. Our description lives up to expectations and needs compared to features found in industry-standard simulators.

To capture the behavior of target value controlled regulators, we introduced two different models. The first one is a model suitable for dynamic or transient simulation. Here, the target values are assumed to be piecewise linear functions, and their competing logic is encoded in terms of nested \(\max -\min \)-comparisons. A second model was designed to be used in discrete optimization problems and determines an optimized set of target values changing as little as possible while enabling the demanded network control. It is based on a characterization of the target value behavior as a set of specific element states, the stable-pushing target value combinations. These assume a regulator reacting to changes in its environment or of its target values immediately and perfectly precise. Depending on the chosen combination, different constraints are active that relate the target values to the values of the element’s point of operation.

Both models have been evaluated in comparison to a commercial simulator, actively used in industry. We showed that the behavior of our simulation model matches the expectations in that the simulated solutions stick close in terms of the resulting pressure and flow values. The relatively higher differences in the flow values are short-lived and their integral equaling the total amount of transported gas is negligible. These differences in the flow values represent slightly different timings and adjustment speeds of regulator actions. Possible strategies to address this could be the introduction of delay or slope limiter. However, this is more a question of technical specification rather than mathematical consideration. For the optimization model, we could show that it works very well when using the same time discretization as for the simulation together with already fixed target values. Here, the differences to both simulated results are just slightly larger than both simulations among each other, even though we used a model based on more simplifying assumptions. In a more realistic scenario, in which the target values are subject to optimization, we need to use fewer and larger time steps. As a result, the relative differences to the simulated results have increased. However, they still stay very close and bounded, especially the components representing the pressures. This indicates that the optimization model is able to reproduce the target value behavior reasonably well.

There are multiple paths to pursue for future research. Firstly, we could replace or add other kinds of target values, e.g., bounding values for the ratio or difference of in- and outlet pressures. Secondly, the regulator model for simulation could be converted into a model for band regulator if by replacing (10) with

just before adding the remaining target value mechanisms. Thirdly, we may apply our techniques to embed target-value-based controls into compressor unit, group, and station modeling. In that regard, we have already discussed it briefly in Sect. 3.3, but it would need to be elaborated and established further in full detail. Furthermore, the optimization model can probably be improved to enhance the performance when combined with state-of-the-art optimization frameworks. While the model captures the target value behavior very well already, it is quite challenging to solve for one single element. The overall goal is to make it usable in a transient gas network operation model using multiple regulators and hundreds of other network elements. Finally, the concept of a target-value-based element control can be applied to active elements in other flow networks. As an example, we mention pumps in water networks, which from a macroscopic viewpoint similarly control their network as compressors do for gas networks.