scieee AI-readable full text Open interactive document viewer

Global optimization for the multilevel European gas market system with nonlinear flow models on trees

Schewe, Lars,Schmidt, Martin,Thürauf, Johannes

Abstract

EconStor is a publication server for scholarly economic literature, provided as a non-commercial public service by the ZBW.

Full text

Schewe, Lars; Schmidt, Martin; Thürauf, Johannes Article — Published Version Global optimization for the multilevel European gas market system with nonlinear flow models on trees Journal of Global Optimization Provided in Cooperation with: Springer Nature Suggested Citation: Schewe, Lars; Schmidt, Martin; Thürauf, Johannes (2022) : Global optimization for the multilevel European gas market system with nonlinear flow models on trees, Journal of Global Optimization, ISSN 1573-2916, Springer US, New York, NY, Vol. 82, Iss. 3, pp. 627-653, https://doi.org/10.1007/s10898-021-01099-8 This Version is available at: https://hdl.handle.net/10419/307492 Standard-Nutzungsbedingungen: Die Dokumente auf EconStor dürfen zu eigenen wissenschaftlichen Zwecken und zum Privatgebrauch gespeichert und kopiert werden. Sie dürfen die Dokumente nicht für öffentliche oder kommerzielle Zwecke vervielfältigen, öffentlich ausstellen, öffentlich zugänglich machen, vertreiben oder anderweitig nutzen. Sofern die Verfasser die Dokumente unter Open-Content-Lizenzen (insbesondere CC-Lizenzen) zur Verfügung gestellt haben sollten, gelten abweichend von diesen Nutzungsbedingungen die in der dort genannten Lizenz gewährten Nutzungsrechte. Terms of use: Documents in EconStor may be saved and copied for your personal and scholarly purposes. You are not to copy documents for public or commercial purposes, to exhibit the documents publicly, to make them publicly available on the internet, or to distribute or otherwise use the documents in public. If the documents have been made available under an Open Content Licence (especially Creative Commons Licences), you may exercise further usage rights as specified in the indicated licence. https://creativecommons.org/licenses/by/4.0/ Journal of Global Optimization (2022) 82:627–653 https://doi.org/10.1007/s10898-021-01099-8 Global optimization for the multilevel European gas market system with nonlinear flow models on trees Lars Schewe1·Martin Schmidt2·Johannes Thürauf2,3 Received: 20 August 2020 / Accepted: 21 September 2021 / Published online: 3 January 2022 © The Author(s) 2021 Abstract The European gas market is implemented as an entry-exit system, which aims to decouple transport and trading of gas. It has been modeled in the literature as a multilevel problem, which contains a nonlinear flow model of gas physics. Besides the multilevel structure and the nonlinear flow model, the computation of so-called technical capacities is another major challenge. These lead to nonlinear adjustable robust constraints that are computationally intractable in general. We provide techniques to equivalently reformulate these nonlinear adjustable constraints as finitely many convex constraints including integer variables in the case that the underlying network is tree-shaped. We further derive additional combinatorial constraints that significantly speed up the solution process. Using our results, we can recast the multilevel model as a single-level nonconvex mixed-integer nonlinear problem, which we then solve on a real-world network, namely the Greek gas network, to global optimality. Overall, this is the first time that the considered multilevel entry-exit system can be solved for a real-world sized network and a nonlinear flow model. Keywords European entry-exit gas market ·Multilevel optimization ·Robust optimization · Mixed-integer nonlinear optimization ·Nonlinear flows Mathematics Subject Classification 90B10 ·90C26 ·90C35 ·90C90 BMartin Schmidt [email protected] Lars Schewe lars.sche[email protected] Johannes Thürauf [email protected] 1School of Mathematics, University of Edinburgh, James Clerk Maxwell Building, Peter Guthrie Tait Road, Edinburgh EH9 3FD, UK 2Department of Mathematics, Trier University, Universitätsring 15, 54296 Trier, Germany 3Energie Campus Nürnberg, Fürther Str. 250, 90429 Nürnberg, Germany 123 628 Journal of Global Optimization (2022) 82:627–653 1 Introduction The European gas market is organized as a so-called entry-exit system. This market structure was introduced as a result of the European gas market liberalization [7,8] with the main goal to decouple transport and trading of natural gas. To this end, the market system is split into multiple levels, in which the transmission system operator (TSO) and gas traders interact with each other. The traders book capacities at nodes in the network, typically for a longer time period, e.g., months. They then nominate every day the amount of gas they want to trade at this node. To determine the capacity that can be booked at a point, the TSO allocates technical capacities in advance. These technical capacities are the main tool to decouple the transport and trading of gas. To achieve this goal, the TSO has to guarantee that every nomination below these technical capacities—i.e., infinitely many balanced load flows—can be transported through the network. As a consequence, gas trading within these technical capacities is no longer explicitly restricted by the actual transport of gas. The advantage of this setup is that the traders can completely ignore the physical network and that they only have to know the technical capacities that have been announced by the TSO. The main goal that the entry-exit-system is meant to achieve is the “effective separation of supply and production activities from network operations” [7]. On the other hand, the entryexit-system has some obvious drawbacks. By decoupling the different steps it is expected that economic inefficiencies arise. It is, however, very difficult to quantify the welfare losses of this system, which is the goal of the multilevel model studied in this paper. From a mathematical point of view, the allocation of technical capacities leads to a highly challenging nonlinear adjustable robust problem, which is one of the major computational challenges of the entry-exit market organization. For a general overview about adjustable robust optimization, we refer to [1,36] and the references therein. We will show how one can overcome these mathematical difficulties to analyze an entry-exit-system for a tree-shaped network with a nonlinear gas flow model. A multilevel mathematical model of an entry-exit-system has been proposed in [14], where it is also shown that it can be reformulated as an equivalent bilevel model under suitable assumptions. In a stylized way, the considered entry-exit system can be described along four subsequent and interconnected levels. First, the TSO has to allocate technical capacities to all nodes of the network. Afterward, the TSO and the gas traders sign mid- to long-term booking contracts in which the traders buy node-specific capacity-rights for the maximal injection or withdrawal of gas. The sum of these bookings at every node of the network is bounded from above by the previously allocated technical capacities. On the day-ahead market, the traders then nominate the amount of gas that they feed in or withdraw under the condition that these amounts are below their booked quantities. Lastly, the TSO operates the network such that the requested amount of gas is transported through the network. The model in [14] does not prescribe the physical model underlying the gas flow. For simplified linear flow models, this model can be solved on stylized small and passive (but cyclic) networks, i.e., networks without active elements such as compressor stations or (control) valves; see [2]. Unfortunately, the techniques exploited in [2] cannot be applied to nonlinear flow models. In this paper, we focus on solving the multilevel problem for a nonlinear flow model. Since switching from a linear to a nonlinear flow model makes the computation of technical capacities much more challenging, we need to restrict ourselves to only considering tree-shaped networks. Our results allow for the first time to solve a multilevel entry-exit gas market model in a real-world sized network, namely a passive version of the Greek gas network. 123 Journal of Global Optimization (2022) 82:627–653 629 Since even linear multilevel problems are highly challenging in general, see [17,20], and since we additionally consider nonlinear flow models on top of the multilevel structure, we need to make the following assumptions. First, the considered multilevel market model in [14] is based on the assumption of perfect competition among gas traders. Including strategic interaction is out of scope of this paper since strategic interaction alone leads to computationally challenging models in this context; see, e.g., [13]. Second, many different approaches exist for modeling gas physics. For a comprehensive overview see, e.g., the book [26] and the survey article [28] as well as the many references therein. We assume that our gas flow model represents a stationary potential-based flow and that the network does not contain active elements such as compressor stations or control valves. These assumptions allow us to consider the classic Weymouth equation for gas flows, which we formally introduce in Sect. 2. However, our findings hold for any nonlinear potential-based flow model under mild assumptions. Let us note that the choice of modeling the gas physics directly influences the computational complexity of computing technical capacities, bookings, and nominations. For capacitated linear and linear potential-based flows, deciding the feasibility of a nomination is in P;see[5,19,24]. However, it is NP-hard in case of active elements; see [34]. Deciding the feasibility of a booking can be done in polynomial time for linear potential-based flows as well as in tree-shaped and single-cycle networks in case of nonlinear potential-based flows; see [21,22,29]. On the contrary, it is coNP-complete for capacitated linear flows, see [19], and it is coNP-hard for nonlinear potential-based flows; see [35]. In [32], structural properties such as (non-)convexity regarding the sets of feasible nominations and bookings are proven w.r.t. different models of gas transport. Finally, the computation of maximal technical capacities is NP-hard for capacitated linear and nonlinear potential-based flows even on trees; see [31]. Consequently, solving the considered multilevel entry-exit model including nonlinear flows poses a big challenge. Our contribution is the following. We use the bilevel reformulation of the multilevel entry-exit gas market model presented in [14] and derive, as in [2], an exact single-level reformulation. In contrast to [2], we consider a nonlinear flow model of gas transport. The obtained single-level reformulation is still computationally intractable since it contains infinitely many nonlinear adjustable robust constraints that model technical capacities. We then derive for these constraints an equivalent finite-dimensional reformulation for the case of tree-shaped networks. This reformulation provides nice properties such that it consists of finitely many convex constraints including newly introduced integer variables. We further derive additional combinatorial constraints using the tree-shaped network structure that significantly speed up the solution process. Overall, we obtain a finite-dimensional nonconvex mixedinteger nonlinear single-level reformulation of the multilevel entry-exit gas market system. We then apply our results to solve the entry-exit model for a real-world network, namely the Greek gas network without active elements, to global optimality. Our computational results demonstrate the effectiveness of our techniques since the majority of the instances can be solved within 1h. We further show that the additional combinatorial constraints are of great importance to achieve these short running times. The remainder of this paper is structured as follows. In Sect. 2, we review the multilevel model and its bilevel reformulation as given in [14]. We then present the single-level reformulation in line with [2] and derive further model improvements in Sect. 3. Afterward, we handle the nonlinear adjustable robust constraints regarding the technical capacities in tree-shaped networks; see Sect. 4. In Sect. 5, we derive additional combinatorial constraints for the computation of technical capacities that significantly speed up the solution process. 123 630 Journal of Global Optimization (2022) 82:627–653 Finally, we apply our findings to solve the entry-exit model for the real-world Greek gas network without active elements in Sect. 6. 2 A multilevel model of the entry-exit gas market system Inthissection,webrieflyreviewtheoptimizationmodeloftheEuropeanentry-exitgasmarket developed in [14]. Its structure is given by the European directive [7] and the subsequent regulation [8] as a result of the European market liberalization. As in [14], we informally describe the four decision steps that correspond to the timing of the considered entry-exit market. We then go into more detail for the bilevel model that is the basis for our further investigations. The four steps of the entry-exit gas market system can be briefly outlined as follows: (i) Allocation of technical capacities and specification of booking price floors by the TSO. (ii) Booking of capacity rights by gas traders. (iii) Nomination of gas within the booked capacities by gas traders at the day-ahead market. (iv) Transport of the nominations by the TSO at minimum costs. In Section 3 of [14], it is shown that the gas market model can be formulated as a bilevel model. The upper level (4) represents the first and fourth step, in which the TSO takes action. The lower level (5) corresponds to the second and third step, in which the gas traders interact with each other. We note that for this model, the assumption of perfect competition is essential. Otherwise, combining step 2 and 3 leads to a multi-leader multi-follower game, which can be modeled as an equilibrium problem with equilibrium constraints; see, e.g., the recent paper [13] in which the strategic setting is studied in detail. A visualization of this bilevel reformulation is given in Figure 3 of [14]. In the following, we discuss the notation and motivate the objective functions and constraints of the bilevel model. We first introduce some basic notation regarding the considered gas networks. We model a gas network as a directed and weakly connected graph G=(V,A)with nodes Vand arcs A. The set of nodes is partitioned into the set of entry nodes V+, at which gas is injected, the set of exit nodes V−, at which gas is withdrawn, and the remaining inner nodes V0. We note that the model allows for multiple gas traders iat any single node of the network, i.e., i∈Pu for u∈V+∪V−. Moreover, we consider multiple time periods t∈Tof gas trading and transport with |T|<∞. Due to the general hardness of the multilevel model, we consider stationary gas flow without active, i.e., controllable, elements such as valves or compressors. In the upper level (4), the TSO allocates technical capacities qTC, specifies booking price floors πbook, and is responsible to transport the gas in accordance with the nominations to maximize the total social welfare in the considered market. The decision variables of the first level are the technical capacities qTC, the booking price floors πbook, and the pressure and flow variables (pand q, respectively) to express the state of the network for each time period t∈T. Throughout this paper, we consider the optimistic notion of bilevel optimization. Thus, the leader also optimizes over the optimal solutions of the lower-level problem, which makes the bookings qbook and the nominations qnom variables of the upper-level problem as well. The objective function (4a) represents the total social welfare aggregated over the considered time periods T.Further,cvar iare the variable production costs of a gas seller i∈Pu at node u∈V+. For a gas buyer i∈Puat node u∈V−, elastic demand is modeled by the inverse demand function Pi,t. This function models the marginal price tolerance as a function 123 Journal of Global Optimization (2022) 82:627–653 631 of the demand. Using inverse demand functions is standard in such micro-economic settings; see, e.g., the seminal textbook [23]. There it is also justified that these functions Pi,tare continuous and strictly decreasing, which we assume in the following for all i∈Pu,u∈V−,and t∈T. We discuss the transportation costs after we have introduced the physical modeling of the gas transport. Next, we discuss the core regulatory constraint. Constraint (4d) ensures that all balanced nominations that comply with the technical capacities, i.e., N(qTC):=⎧ ⎨ ⎩ qnom ∈RV+∪V−:0≤qnom ≤qTC, u∈V+ qnom u= u∈V− qnom u⎫ ⎬ ⎭ , can be transported through the considered network. This is formalized by F(ˆqnom),which consists of the feasible transport solutions for ˆqnom. Many different approaches for modeling the set F(qnom)exist. As mentioned earlier, we consider stationary gas flow without active elements such as (control) valves or compressor stations. We further focus on a nonlinear gas transport model that is based on the Weymouth pressure loss equation. Note that our results also hold for the general case of nonlinear potential-based flows, which we further explain in Remark 2.1. For every node u∈Vof the gas network and time period t∈T, we denote the pressure level at node uby pu,twith corresponding bounds 0<p− u≤pu,t≤p+ u<∞.(1) We further denote the flow on arc a∈Aby qa,t. Note that arc flow qa,tcan be negative if it flows in the opposite direction w.r.t. the orientation of the arc. For every time period t∈T, the flows have to satisfy flow conservation at every node of the network, which is modeled by  a∈δout(u) qa,t− a∈δin(u) qa,t= i∈Pu qnom u,t,u∈V+,t∈T,  a∈δout(u) qa,t− a∈δin(u) qa,t=− i∈Pu qnom u,t,u∈V−,t∈T,(2)  a∈δout(u) qa,t− a∈δin(u) qa,t=0,u∈V0,t∈T. Here, δout(u)represents the set of outgoing arcs and δin(u)the set of incoming arcs at node u. We note that we need to impose different signs for the nominations of entries V+and exits V− in (2) to model that gas is injected or withdrawn since a nomination is a nonnegative vector. For an arc a∈Aand a time period t∈T, the corresponding flow qa,tlinks the pressure levels at the incident nodes of arc a. This link is given by the following Weymouth-like pressure loss law p2 u,t−p2 v,t=aqa,tqa,t,a=(u,v)∈A,t∈T,(3) where a>0 is an arc specific constant. We finally turn to the modeling of the transportation costs ctfor t∈T. Here, we model transportation costs as proposed in [2]. As in the latter paper, we consider a passive network withoutactiveelements.However, the majority of transportation costs consist of the operating costs of active elements such as compressors. Usually, these transportation costs are driven by the pressure losses in the network. In order to mimic cost-optimal transport in a passive 123 632 Journal of Global Optimization (2022) 82:627–653 network, the costs are given by the absolute squared pressure losses in the entire network  t∈T ct(p,q;qnom)= t∈T a=(u,v) ctrans tp2 u,t−p2 v,t, where ctrans t>0 holds for t∈T. We note that using Constraints (3), we can equivalently reformulate the transport costs as follows:  t∈T ct(p,q;qnom)= t∈T a=(u,v) ctrans tp2 u,t−p2 v,t= t∈T a=(u,v) ctrans taq2 a,t. The transportation costs also appear in Constraint (4c). This constraint ensures that the booking price floors are chosen such that they recover transportation costs and additional investment costs C. Finally, the coupling between the upper and lower level is expressed in Constraint (4f). In the lower level (5), gas traders buy capacity rights, so-called bookings qbook,that determine the maximum amount of gas that can be nominated. All traders then nominate their individual load of gas that is only bounded above by the chosen booking. The goal of every trader is to maximize its own profit, i.e., the trader books a capacity right that later leads to a surplus maximizing nomination. In doing so, the traders are only restricted by the technical capacities and booking price floors determined by the TSO in the first level. Note that the gas buyers and sellers do not take into account flow balance equations as well as any other physical or technical restrictions of the transport network. This is a defining aspect of the entry-exit system. It is touted as one of its features that buyers and sellers of gas do not have to care about the state of the network when making their trading decisions—except for the bookings that limit the nominations. The interplay of booking and nominating can be modeled as a multi-leader multi-follower game. This game is difficult to analyze (see [13]) and, hence, is not usable in our context. Under a number of assumptions (as discussed in [14]), however, the solution of the game can be expressed as the solution of an optimization problem. We use the strongest assumption consideredin[14],i.e.,weassumeperfectcompetitionbothin thebookingandthenomination process on the day-ahead markets for both buyers and sellers. This allows to rewrite both the model of the booking and the day-ahead markets as mixed nonlinear complementarity problems (MNCP). These MNCPs are equivalent to optimization problems and can then be aggregated into a single optimization problem. The single optimization problem can be interpreted as follows: The objective (5a)maximizes the welfare of all traders, that is, the surplus of the buyers minus the generation costs of the sellers, and minus the booking costs of all traders. The constraints make sure that bookings stay within the technical capacities (5b), nominations stay within the bookings (5c), and that all nominations are balanced (5d). In summary, we obtain the bilevel model max qTC,πbook,p,q, qbook,qnom ϕ(qnom,p)= t∈T⎛ ⎝ u∈V− i∈Puqnom i,t 0 Pi,t(s)ds− u∈V+ i∈Pu cvar iqnom i,t⎞ ⎠(4a) − t∈T a=(u,v)∈A ctrans tp2 u,t−p2 v,t−C s.t. 0 ≤qTC u,0≤πbook u,u∈V+∪V−,(4b) 123 Journal of Global Optimization (2022) 82:627–653 633  u∈V+∪V− i∈Pu πbook uqbook i= t∈T a=(u,v)∈A ctrans tp2 u,t−p2 v,t+C,(4c) ∀ˆqnom ∈N(qTC):F(ˆqnom)=∅,(4d) (p,q)∈F(qnom), i.e., (p,q)satisfies (1)–(3),(4e) (qbook,qnom)∈arg max(5), (4f) where the lower level is given by max qbook,qnom  t∈T⎛ ⎝ u∈V− i∈Puqnom i,t 0 Pi,t(s)ds− u∈V+ i∈Pu cvar iqnom i,t⎞ ⎠(5a) − u∈V+∪V− i∈Pu πbook uqbook i s.t.  i∈Pu qbook i≤qTC u,u∈V+∪V−,(5b) 0≤qnom i,t≤qbook i,i∈Pu,u∈V+∪V−,t∈T,(5c)  u∈V− i∈Pu qnom i,t− u∈V+ i∈Pu qnom i,t=0,t∈T.(5d) In general, bilevel problems are nonconvex. Further, they are strongly NP-hard even in case of linear bilevel problems; see [17,20]. In addition, the upper level of the considered problem is very challenging itself as we briefly outline in the following. First, the upper level contains nonsmooth terms in the objective function, which also appear in (4c). Moreover, Constraint (4c) contains nonconvex bilinear terms πbook uqbook i. Additionally, considering a nonlinear flow model for gas transport leads to nonconvex constraints in (4e). Finally, and most critical, (4d) is a nonlinear adjustable robust constraint, which, in general, is computationally intractable. From the point of view of robust optimization, Constraint (4d)isan adjustable robust constraint with uncertainty set N(qTC). For a detailed explanation regarding the connection of computing technical capacities, respectively deciding the feasibility of a booking, and adjustable robustness, we refer to Remark 2.6 in [22]. For the considered nonlinear flow model, already deciding its feasibility is coNP-hard; see [35]. Due to the inherent difficulty of the problem, we focus on tree-shaped networks. This allows us to obtain a finite-dimensional reformulation of the nonlinear adjustable robust constraint (4d) in Sect. 4. Moreover, this reformulation has some nice properties such that it is a convex mixed-integer model. Remark 2.1 We note that our results, especially the computation of the technical capacities in Sect. 4, are also valid for the general case of potential-based flows. This means that we can generally replace Constraints (1)and(3) by the potential-based flow model 0<π − u≤πu,t≤π+ u<∞,u∈V,t∈T, πu,t−πv,t=φa(qa,t), a=(u,v)∈A,t∈T, where φais a continuous, strictly increasing, and odd (i.e.,φa(−qa,t)=−φa(qa,t)) function. The latter is rather natural in the context of utility networks. We note that the freedom of modeling φais large and it ranges from simple linear models to sophisticated nonlinear ones. On the one hand, this allows to apply our results to many different gas transport models. In particular, this includes the case of non-horizontal pipes; see [26]. On the other hand, we 123 634 Journal of Global Optimization (2022) 82:627–653 can also apply our results to many other different network types such as water, hydrogen, or lossless DC power flow networks, if the physics is appropriately modeled; see [15]. In the next section, we reformulate the presented bilevel as a single-level problem and present further model improvements. 3 Reduction to a single level problem Since the bilevel model (4) with lower level (5) contains nonlinearities in the upper and lower level and since the linking variables qTC and πbook are continuous, we replace the convex lower level by its necessary and sufficient first-order optimality conditions to obtain a single-level problem. This is in line with [2], where the multilevel problem is considered for a linear potential-based flow model. We can adapt the single-level reformulation of [2] since the lower level is independent of the considered gas flow model. To obtain concave-quadratic upper- and lower-level objective functions w.r.t. the upper- or lower-level variables, we make the following assumption. Assumption 1 All inverse market demand functions are linear and strictly decreasing, i.e., Pi,t(qnom i,t)=bi,tqnom i,t+ai,twith ai,t>0andbi,t<0foralli∈Pu,u∈V−,t∈T. This assumption is rather standard in multilevel modeling of energy markets; see, e.g., [2,11,12] and the many references therein. Since the lower-level (5) then is a concavequadratic maximization problem with a linearly constrained feasible region, its KKT conditions are both necessary and sufficient; see, e.g., [3]. We now replace the lower level (5) by its KKT conditions, i.e., the stationarity conditions −πbook u−βu+ t∈T γ+ i,t=0,i∈Pu,u∈V+∪V−,(6a) ai,t+bi,tqnom i,t+γ− i,t−γ+ i,t−δt=0,i∈Pu,u∈V−,t∈T,(6b) −cvar i+γ− i,t−γ+ i,t+δt=0,i∈Pu,u∈V+,t∈T,(6c) primal feasibility (5b)–(5d), nonnegativity βu≥0,u∈V+∪V−,(7a) γ− i,t,γ+ i,t≥0,i∈Pu,u∈V+∪V−,t∈T,(7b) of inequality multipliers, and complementary slackness conditions βu⎛ ⎝qTC u− i∈Pu qbook i⎞ ⎠=0,u∈V+∪V−,(8a) γ− i,tqnom i,t=0,i∈Pu,u∈V+∪V−,t∈T,(8b) γ+ i,tqbook i−qnom i,t=0,i∈Pu,u∈V+∪V−,t∈T.(8c) Then, the bilevel problem (4) can be reformulated as the single-level problem 123 Journal of Global Optimization (2022) 82:627–653 641 We note that the bilinear terms of the following model can be reformulated by using big- Ms, which we describe later. Our convex mixed-integer model of (19) is given as follows: ¯ h+ (u,v) = w∈V+∩V(u,v) u qTC w,(u,v)∈A,(21a) ¯ h− (u,v) = w∈V−∩V(u,v) v qTC w,(u,v)∈A,(21b) ¯ h+ (u,v) −¯ h− (u,v) ≤M+¯x(u,v),(u,v)∈A,(21c) ¯q(u,v) =¯ h+ (u,v)(1−¯x(u,v))+¯ h− (u,v) ¯x(u,v),(u,v)∈A,(21d) h+ (u,v) = w∈V+∩V(u,v) v qTC w,(u,v)∈A,(21e) h− (u,v) = w∈V−∩V(u,v) u qTC w,(u,v)∈A,(21f) h+ (u,v) −h− (u,v) ≤M+x(u,v),(u,v)∈A,(21g) q(u,v) =h+ (u,v)(1−x(u,v))+h− (u,v)x(u,v),(u,v)∈A,(21h) ¯q2 a≤¯ fa,a∈A,(21i) q2 a≤fa,a∈A,(21j)  a∈A→(u,v) a¯ fa+ a∈A←(u,v) afa≤(p+ u)2−(p− v)2,(u,v)∈V2,(21k) xa,¯xa∈{0,1},qTC v≥0,a∈A,v∈V.(21l) Constraints (21a)–(21d)and(21e)–(21h) ensure that ¯qis at least as large as the upper flow bound ξ+ a(qTC)and qis at least the absolute value of the lower flow bound ξ− a(qTC); see Lemma 4.2. The negative sign of the lower flow bound is directly modeled in Constraints (21k). Constraints (21i)and(21j) result from a modeling choice. They allow to model the flow linearly in Constraints (21k), which reduces the number of convex constraints. We now show the correctness of (21). To this end, we first prove that any feasible point of the original bilevel problem (4) satisfying Lemma 3.5 can be extended to a feasible point of (21). Afterward, we prove that every feasible point of (21) is also feasible for the adjustable robust constraint (4d) of the bilevel problem (4). We abbreviate a feasible point of (21)byz, i.e., z=¯ f,f,¯q,q,h− ,¯ h− ,h+ ,¯ h+ ,x,¯x,qTC. Lemma 4.5 Let G =(V,A)be a tree and qTC ∈RV+∪V− ≥0be part of an optimal solution of (4) satisfying Lemma 3.5. Then, qTC can be extended to a feasible point z of (21). Proof Constraints(21a), (21b),(21e),and(21f) areuniquelydeterminedbyqTC.Further,they are feasible because the corresponding variables are not bounded. Due to the construction of M+by (20a)and(20b), we can set for a∈Athe variable ¯xa, respectively xa, to 1 if the lefthand side of (21c), respectively (21g), is positive and otherwise to 0. Due to this assignment, ¯qais uniquely determined and equals the upper flow bound ξ+ a(qTC);see(17). Further, qais unique and equals the absolute value of the lower flow bound ξ− a(qTC);see(17). We now set ¯ fa=¯q2 a, respectively fa=q2 a,fora∈Aand thus, Constraints (21i)and(21j) are satisfied. 123 642 Journal of Global Optimization (2022) 82:627–653 Finally, we have to check the feasibility of Constraints (21k). For doing so, we consider an arbitrary node pair (u,v) ∈V2. From the previous construction it follows that (21k) simplifies to  a∈A→(u,v) a¯ fa+ a∈A←(u,v) afa= a∈A→(u,v) aξ+ a(qTC)2+ a∈A←(u,v) aξ− a(qTC)2 ≤(p+ u)2−(p− v)2. The feasibility of the last inequality follows from Corollary 4.4 and the feasibility of the considered technical capacities qTC for (4d). Consequently, the constructed point is feasible for (21).  We now prove that a feasible point of (21) is also feasible to the adjustable robust constraint (4d). Lemma 4.6 Let G =(V,A)be a tree and let z be a feasible point of (21). Then, qTC satisfies (4d). Proof We contrarily assume that qTC does not satisfy Constraint (4d). Thus, from Corollary 4.4 it follows that there is a node pair (w1,w 2)∈V2violating (19), i.e.,  a∈A→(w1,w2) aξ+ a(qTC)2+ a∈A←(w1,w2) aξ− a(qTC)2>(p+ w1)2−(p− w2)2.(22) Due to Constraints (21a)–(21d), it follows ξ+ a(qTC)2≤¯q2 a≤¯ fa,a∈A→(u,v), ξ− a(qTC)2≤q2 a≤¯ fa,a∈A←(u,v). Consequently, from this and the feasibility of (21k)forz, it follows  a∈A→(w1,w2) aξ+ a(qTC)2+ a∈A←(w1,w2) aξ− a(qTC)2 ≤ a∈A→(w1,w2) a¯ f+ a∈A←(w1,w2) af≤(p+ w1)2−(p− w2)2, which is a contradiction to (22).  Combining the previous results proves that we can model the infinitely many adjustable robust constraints (4d) by the finitely many Constraints (21). Theorem 4.7 Let G =(V,A)be a tree. Then, every optimal solution of the bilevel problem (4), where we replaced (4d)by(21), is an optimal solution of the bilevel problem (4). Moreover, every optimal solution of (4) that additional satisfies the conditions of Lemma 3.5 can be extended to an optimal solution of (4), where we replaced (4d)by(21). Proof The claim follows from Lemmas 3.5,4.5,and4.6 . Remark 4.8 We note that we can easily include lower q− aand upper q+ aarc flow bounds for all arcs a∈Aby q− a≤−qa≤q+ a,q− a≤¯qa≤q+ a. Since in Model (21)thevariableqaequals the absolute value of the lower arc flow bound ξ− a(qTC)and since ¯qaequals the upper arc flow bound ξ+ a(qTC)given by Lemma 4.2, this ensures that the flow stays in the a priori given flow bounds. We abstract from flow bounds in our model, since the consideration of pressure levels allows to bound the flow by Constraints (21k). 123 Journal of Global Optimization (2022) 82:627–653 643 Model (21) contains bilinear terms in Constraints (21d)and(21h). Since these bilinear terms are products of a binary variable and a nonnegative and bounded variable, we can reformulate them using big-Ms. We note that the upper bounds for h+ (u,v) and ¯ h+ (u,v) are givenby(20a)andfor¯ h− (u,v) and h− (u,v) by (20b). The bilinear constraints (21d) can thus be reformulated as ¯q(u,v) =¯y+ (u,v) +¯y− (u,v),(23a) ¯y+ (u,v) ≥0,¯y+ (u,v) ≤M+(1−¯x(u,v)), ¯y+ (u,v) ≥¯ h+ (u,v) −M+¯x(u,v),(23b) ¯y− (u,v) ≥0,¯y− (u,v) ≤M−¯x(u,v),¯y− (u,v) ≥¯ h− (u,v) −M−(1−¯x(u,v)). (23c) In analogy, we can reformulate the bilinear constraints (21h)by q(u,v) =y+ (u,v) +y− (u,v),(24a) y+ (u,v) ≥0,y+ (u,v) ≤M+(1−x(u,v)), y+ (u,v) ≥h+ (u,v) −M+x(u,v),(24b) y− (u,v) ≥0,y− (u,v) ≤M−x(u,v),y− (u,v) ≥h− (u,v) −M−(1−x(u,v)). (24c) For ease of notation in the following lemma, (21*) denotes (21) where we replaced Constraints (21d)and(21h)by(23)and(24). Lemma 4.9 A vector qTC ∈RV+∪V− ≥0is feasible for (21) if and only if it is feasible for (21*). Proof We can extend every feasible solution of (21) to satisfy (23)and(24). To do so, we choose ¯y+,¯y−,y+,and y+as small as possible. Consequently, (23a)and(24a) equal Constraints (21d)and(21h). Thus, the extended solution satisfies (21*). From the construction of (23)and(24) it follows that the flows ¯qand qobtained in (23a) and (24a) are at least as large as the flows obtained in (21d)and(21h). From this and the fact that aqa|qa|is increasing for all a∈A, it follows that every feasible point of (21*), is also feasible for (21).  After reformulating the bilinear terms in (21) by the discussed linearizations, we can model the adjustable robust Constraint (4d) by the finitely many constraints (21a)–(21c), (21e)–(21g), (21i)–(21l), (23), (24).(25) For the considered nonlinear flow model, which is based on the Weymouth pressure loss equation, the presented model of the technical capacities is a convex mixed-integer model. This is surprising since the Weymouth pressure drop model is itself nonconvex. The convex mixed-integer reformulation is obtained by using additional binary variables to model the maximum flow in a pipe and by exploiting that, for the considered gas transport model, the pressure drop aqa|qa|is quadratic for every pipe a∈Aif the direction of the arc flow qais known. The model further consists only of polynomially many (in the number of nodes of the network) constraints and variables. Finally, we note that this model can also be generalized to potential-based flow models as explained in Remark 2.1. To do so, we only have to replace (21k)by  a∈A→(u,v) φa(¯qa)+ a∈A←(u,v) φa(qa)≤π+ u−π− v,(u,v)∈V2, where φis the potential loss function as introduced in Remark 2.1. We further can neglect Constraints (21i)and(21j), which result from a modeling choice to reduce the number of convex constraints. For general potential-based flows, the obtained model is not necessarily 123 644 Journal of Global Optimization (2022) 82:627–653 convex anymore since general potential loss functions may not depend quadratically on the arc flow, e.g., in case of water networks. 5 Additional combinatorial constraints In this section, we present valid combinatorial constraints for (21), respectively (25), that speed up the solution process, which we will analyze later in Sect. 6. We prove the results w.r.t. Model (21), but they can be shown in analogy for Model (25). We note that these additionalconstraintsdonotinfluencethesetof feasible technical capacities modeled by (21). We first provethat forevery feasiblepoint zof(21),afeasible point with the same technical capacities qTC always exists such that the right-hand sides of Constraints (21c)and(21g) are minimal, i.e., a binary variable is zero if the corresponding left-hand side is non-positive. Here, xdenotes rounding up the value x. Lemma 5.1 Let G =(V,A)be a tree and let z be a feasible point of (21) with technical capacities qTC. Then, a feasible point ˜z with the same technical capacities qTC exists such that for arc (u,v)∈A the corresponding binaries are given by ˜ ¯x(u,v) =max 0,1 M+(¯ h+ (u,v) −¯ h− (u,v)),(26a) ˜x(u,v) =max 0,1 M+(h+ (u,v) −h− (u,v)).(26b) Proof Let be z=(¯ f,f,¯q,q,h− ,¯ h− ,h+ ,¯ h+ ,x,¯x,qTC)a feasible point of (21). We assume that an arc (u,v)∈Aexists such that, w.l.o.g., 1=¯x(u,v) >0=max 0,1 M+(¯ h+ (u,v) −¯ h− (u,v)) holds. We now set ¯x(u,v) =0. Consequently, ¯q(u,v) possibly decreases according to Constraint (21d). The remaining point stays feasible since Constraints (21a), (21b), (21e)–(21h), (21j), and (21l) are not affected by this modification. Furthermore, Constraint (21i) is still fulfilled since we only possibly decreased ¯q(u,v) and thus, (21k) is satisfied. We also note that Constraint (21c) is satisfied due to the choice of M+≥0. Repeating the previous procedure for ¯xand xshows the claim.  With the help of the latter result, we now present additional combinatorial constraints regarding the binary variables that explicitly use the network structure. The intuition behind these constraints can be sketched as follows: From Lemma 5.1 it follows that an optimal solution for model (21) exists such that for an arc a=(u,v) ∈A,thevariable¯qarepresents the maximal arc flow of a, i.e., ¯q(u,v) =min ⎧ ⎪ ⎨ ⎪ ⎩ w∈V+∩V(u,v) u qTC w, w∈V−∩V(u,v) v qTC w⎫ ⎪ ⎬ ⎪ ⎭ =min ¯ h+ (u,v),¯ h− (u,v). This means that ¯qaequals the minimum flow that can be sent via (u,v)by entries in V(u,v) u, which is the sub-tree that includes node uandisobtainedbyremovingarc(u,v), and of the flow that can be received by exits in V(u,v) v. If the entries in V(u,v) ucan supply more flow than 123 Journal of Global Optimization (2022) 82:627–653 645 the exits in V(u,v) vcan receive, i.e., ¯q(u,v) =min ⎧ ⎪ ⎨ ⎪ ⎩ w∈V+∩V(u,v) u qTC w, w∈V−∩V(u,v) v qTC w⎫ ⎪ ⎬ ⎪ ⎭ = w∈V−∩V(u,v) v qTC w=¯ h− (u,v), then ¯x(u,v) =1 holds. Considering now for an outgoing arc (v, l)the variable ¯q(v,l)only possibly increases the number of entries that can supply flow via (v, l), i.e., V(u,v) u⊂V(v,l) v, and possibly reduces the number of exits that can receive flow via arc (v, l), i.e., V(v,l) l ⊂V(u,v) v.Consequently,thevalue of ¯q(v,l)isagaindetermined by theexits,i.e., ¯q(v,l)=¯ h− (v,l), and, thus, ¯x(v,l)=1 holds. This shows a correspondence between the binary variables using the given network structure and is the key for the following combinatorial constraints. In analogy to the above, we can derive further constraints for the binaries xcorresponding to the lower flow variables q. Lemma 5.2 Let G =(V,A)be a tree and z a feasible point of (21) that satisfies (26). Then, the inequalities ¯x(u,v) ≤¯x(v,l),(v,l)∈δout(v), (27a) x(v,l)≤x(u,v),(v,l)∈δout(v), (27b) ¯x(u,v) ≤x(l,v),(l,v)∈δin(v), (27c) are satisfied for a =(u,v). Proof Applying Lemma 5.1, a feasible point (¯ f,f,¯q,q,h− ,¯ h− ,h+ ,¯ h+ ,x,¯x,qTC)for (21)exists that satisfies (26). We first consider Inequality (27a). If ¯x(u,v) =0 holds, then (27a) is redundant since ¯x(v,l)∈{0,1}.Wenowassumethat¯x(u,v) =1 holds. Consequently, 1=¯x(u,v) =1 M+(¯ h+ (u,v) −¯ h− (u,v)) holds and thus, ¯ h+ (u,v) >¯ h− (u,v) ≥0 is satisfied. From (v, l)∈δout(v) it follows V(u,v) u⊂V(v,l) v,V(v,l) l⊂V(u,v) v,(28) where V(u,v) u, respectively V(v,l) v, contains the nodes of the connected component that includes u, respectively v, and is created by removing arc (u,v), respectively (v, l).From this as well as Constraints (21a)and(21b), it follows ¯ h+ (v,l)≥¯ h+ (u,v) >¯ h− (u,v) ≥¯ h− (v,l)≥0, and consequently, ¯x(v,l)=1 is satisfied due to (21c). We now consider (27b). If x(v,l)=0 holds, then (27b) is redundant since x(u,v) ∈{0,1}. Thus, we now assume that x(v,l)=1 holds. Due to (26), 1=x(v,l)=1 M+(h+ (v,l)−h− (v,l)) 123 646 Journal of Global Optimization (2022) 82:627–653 holds and, thus, h+ (v,l)>h− (v,l)≥0 is satisfied. From (v, l)∈δout(v) it again follows (28). This, as well as Constraints (21e) and (21f), lead to h+ (u,v) ≥h+ (v,l)>h− (v,l)≥h− (u,v) ≥0, and consequently, x(u,v) =1 is satisfied due to (21g). We finally consider (27c). If ¯x(u,v) =0 holds, then (27c) is redundant since x(l,v) ∈{0,1}. Thus, we now assume that ¯x(u,v) =1 holds. Due to (26), 1=¯x(u,v) =1 M(¯ h+ (u,v) −¯ h− (u,v)) holds and, thus, ¯ h+ (u,v) >¯ h− (u,v) ≥0 is satisfied. From (l,v)∈δin(v), it follows V(u,v) u⊂V(l,v) v,V(l,v) l⊂V(u,v) v and thus, from (21a), (21b), (21e), and (21f) it follows h+ (l,v) ≥¯ h+ (u,v) >¯ h− (u,v) ≥h− (l,v) ≥0. From this and Constraint (21g) it follows x(l,v) =1.  Consequently, the adjustable robust constraint (4d) can be modeled by (21), respectively (25), and the additional Constraints (27a)–(27c). In the following computational study, we demonstrate the impact of the presented combinatorial constraints w.r.t. running times. 6 Computational results We now apply our results to solve the considered multilevel model of the European entry-exit gas market system with a nonlinear flow model in tree-shaped networks. To this end, we solve the model for a passive version of the Greek gas network, i.e., the network corresponds to the Greek gas network excluding its single compressor station and its single control valve. This is the first time that the considered entry-exit gas market model can be solved for a realworld sized network. For our computations, we consider the single-level reformulation (9) with linearized complementarity constraints, the additional constraints (12)and(13), the handling of the technical capacities (25), and the additional combinatorial constraints (27). For the latter, we also analyze their explicit effect on the running times. We further note that we can a priori exclude Constraints (1)and(3) since the flow is uniquely determined by (2) in tree-shaped networks. 6.1 Physical and economic data For our computational analysis, we consider the GasLib 134 (version 2) network; see [33]. The GasLib 134 represents the Greek gas network, with more than 7000km of pipes. It further is the largest publicly available tree-shaped gas network and, thus, we focus on this network in our computational study. Since the integration of active elements is currently out of scope, 123 Journal of Global Optimization (2022) 82:627–653 647 Table 1 Economic data for exit demands functions Pi,t(qnom i,t)=biqnom i,t+ai,twith ai,t= maxj∈Pu,u∈V+{cvar j}+hi,t, where the integer hi,t(in e/(1000 Nm3/h)) is uniformly sampled in the given intervals and biis given in e/(1000 Nm3/h)2 hi,0hi,1hi,2hi,3bi [5,20][31,50][51,60][31,40]−2 we bypass the single compressor station and single control valve of the GasLib 134 network. Moreover, we slightly adapt the lower pressure bounds of the GasLib 134 network by setting all lower pressure bounds of at least 37.5bar to 32.5bar. This ensures that the intersection of the lower and the upper pressure bound intervals is non-empty, i.e., u∈V+∪V−[p− u,p+ u] =∅. The latter is a necessary condition for the existence of a feasible nomination in a passive network. In total, the network consists of 134 nodes, which contain 3 entries, 45 exits, and 86 inner nodes, and 133 pipes, which contain 47 short pipes2and 86 pipes. Each pipe a∈A is characterized by its length La, diameter Da, and roughness ka.Further,weassumethat all pipes are horizontal. For each pipe a∈A, we compute the pressure loss coefficient a of the considered Weymouth model (1)–(3) according to (2.25) in [10], i.e., a= 4 π!2 λa RsTmLazm,a D5 a . Here, Rsis the specific gas constant, Tma constant mean temperature, λais the friction factor of pipe a∈Acomputed using the formula of Nikarudse, and zm,ais the mean compressibility factor of a pipe a∈Acomputed by the formula of Papay and an a priori estimation of the mean pressure; see Chapters [10,30] for the explicit formulas and additional explanations. We now turn to the modeling of the economic data. The considered time horizon consists of four time periods t∈Tthat model the seasons summer (t=0), autumn (t=1), winter (t=2), and spring (t=3). In line with [2], we assume a single player per node. We model the variable production costs cvar iof the three existing entries as follows. For entry node_80,wesetcvar node_80 =112e/(1000 Nm3/h)and then increase this value by 5% for production costs of the remaining entries. In a simplified way, this roughly represents the current situation regarding production costs in the Greek gas network. For the linear demand functions of the exit nodes, we assume Pi,t(qnom i,t)=biqnom i,t+ai,twith ai,t=max j∈Pu,u∈V+cvar j+hi,t, where the integer hi,tis uniformly sampled in certain intervals; see Table 1. This construction explicitly ensures that Assumption 2is satisfied. We note that ai,tis lowest in the summer (t=0)and highest in the winter (t=2). After fixing the previous values, we consider exogenous network costs C∈{0,5000,10 000,...,30 000}eand the transport costs ctrans t∈{0.1,0.2,...,1.0}e/bar2. Additionally, for the instances with C=15,000e, we vary the intercepts ai,tby adding a “shift” in {−10,−5,0,5,10}e/(1000 Nm3)/h. In total, we obtain 110 instances. We note that all these values have to be seen w.r.t. the considered time horizon of 1h per time period. Moreover, extrapolating the results for the time horizon of a whole year shows 2Although the presented theory is stated for the case of pipes with positive pressure loss coefficient a>0, it is no harm to consider short pipes with a=0 since gas pressure levels are not influenced by including short pipes. 123 648 Journal of Global Optimization (2022) 82:627–653 that the total gas consumption of the base case, i.e., C=15 000eand cvar =0.5e/bar2 deviates by less than 1.4% from the total gas consumption of approximately 5.1 billion m3 in Greece for 2019; see [4]. Additionally, the investment costs and variable costs are chosen such that the sum of the latter corresponds to 6.5% of the market volume. 6.2 Computational setup All optimization problems have been implemented in Python 3usingPyomo 5.6.8, see [18], and have been solved with Gurobi 9.0.1, see [16]. In doing so, we used Gurobi with standard settings except for the following adaptions. We set the parameter NumericFocus to3and the parameter NonConvex to 2. Thus, Gurobi tackles the nonlinear bilinear terms of Constraint (4c) by spatial branching. For the computations, we used the Kaby Lake nodes with Xeon E3-1240 v6 CPUs and 32GB RAM of the computer cluster [27] and set a time limit of 24h. The necessary big-Ms are computed as presented in Sects. 3.1 and 4. Additionally, we used the upper flow bounds of the GasLib 134 network to tighten these big-Ms. We now briefly discuss some statistics of the considered model. Our single-level model consists of 3599 variables, which contain 698 binary variables, and of 22 085 constraints, which contain 267 quadratic constraints. The presolve of Gurobi roughly halves the number of constraints but hardly influences the other statistics including the number of quadratic constraints. We note that before presolve we have 266 combinatorial constraints (27). In the next section, we discuss the numerical results in detail and explicitly analyze the computational speed up of the combinatorial constraints. 6.3 Discussion of numerical results The scope of this section is twofold: We first discuss the numerical results w.r.t. running times. Here, we focus on the computational benefit of the combinatorial constraints (27)of Sect. 5. Afterward, we exemplarily show the effects of modifying the economic data on the output of the four-level gas market model for the Greek gas network to shed some light on the sensitivity of the model and the solution approach. For our discussion of the computational results, we consider 110 instances as described in Sect. 6.1. The running times are summarized in Table 2. Overall, we can solve 107 out of 110 instances to global optimality for the considered four-level gas market model within the time limit. More specifically, we solve 90 of the 110 instances within 1h. One of the key components to achieve this performance is our modeling of the adjustable robust constraints (4d)and theadditional combinatorial constraints (27). Therunning times significantly increase ifthese combinatorial constraints are excluded; see Table 2. This leads to the results that 23 instances could not be solved in the time limit of 24h if the additional combinatorial constraints are neglected. The significant computational speed up of these constraints is underlined by the fact that the minimum running times without them is larger than the median, receptively nearly equal to the third quartile, of the running times including these constraints. Moreover, only 4 of the 110 instances can be solved in 1h if the additional constraints are excluded. We further analyze the computational benefit of the combinatorial constraints with the help of log-scaled performance profiles as proposed in [6]. Figure 1shows the log-scaled performance profiles w.r.t. running times (left) and w.r.t. nodes explored in the branch-and- bound algorithm of Gurobi (right) for all 110 instances. To do so, we separately solved the considered model with the combinatorial constraints (27) and without them. In line with Table 2, the left profile shows that including the combinatorial constraints clearly dominates 123 Journal of Global Optimization (2022) 82:627–653 649 Table 2 Number of solved instances (out of 110 instances) and statistics for the running times (always taken only for all instances solved to optimality) No. of solved Comb-cons 107 w/o comb-cons 87 Time (s) Time (s) Minimum 251.65 2069.42 1st Quartile 670.65 9790.43 Median 1070.32 17685.29 Mean 2868.59 26193.49 3rd Quartile 2127.64 41813.73 Maximum 32833.46 83639.78 Fig. 1 Log-scaled performance profiles of running times (left) and of nodes explored in the branch and bound algorithm (right) for all 110 instances w.r.t. running times. This is mainly explained by the right performance profile in Fig. 1, which compares the number of nodes that are explored during the branch-and-bound solution process. Including the combinatorial constraints significantly reduces the number of explored nodes, which leads to the observed speed up of the solution process. Finally, we now turn to the analysis of the sensitivity of the approach w.r.t. changes in the economic input data. To this end, we consider a base instance with fixed exogenous investment costs C=15 000eand variable transport costs cvar =0.5e/bar2. Then, we adjust the intercepts of the demand functions ai,tfor all i∈Pu,u∈V,t∈T, by adding a constant, which we call “shift”. Table 3shows that increasing, respectively decreasing, the demand mainly affects the nominated amount of gas in the summer period (t=0).The remaining time periods are only slightly affected by demand changes. Moreover, a decrease of the demand affects the nominations more than an increase of the demand. On the one hand, this indicates that for time periods t∈{1,2,3}the network already operates near to its maximal capacity since an increased demand only slightly leads to higher nominations. On the other hand, the demand in time periods t∈{1,2,3}, especially the winter period t=2, is nearly inelastic since an decrease of the demand only leads to a small decrease of the nominated amount of gas. Moreover, the sum of all booked capacities is nearly the same. This can be explained by the almost inelastic demand of the winter period since, usually, the booking is determined by the period with highest demand, i.e., it is determined in winter. Although the total booked capacity is almost not affected by the change of the demand, the 123 650 Journal of Global Optimization (2022) 82:627–653 Table 3 For all i∈Pu,u,t∈T, the intercepts ai,tvary by adding “shift” in e/(1000 Nm3/h).The remaining values denote the corresponding relative changes of the bookings qbook, and nominations qnom w.r.t. the base case marked in bold shift qbook1 qbook base 1 qbook v qbook base,v in ... qnom 01 qnom base,01 qnom 11 qnom base,11 qnom 21 qnom base,21 qnom 31 qnom base,31 −10 0.99 [0.88, 1.20] 0.42 0.90 1.00 0.86 −5 1.00 [0.93, 1.12] 0.71 0.97 1.00 0.96 0 1.00 [1.00, 1.00] 1.00 1.00 1.00 1.00 5 1.01 [0.97, 1.08] 1.18 1.01 1.01 1.02 10 1.01 [0.95, 1.13] 1.24 1.02 1.01 1.02 booked capacity at the single nodes clearly differs; see third column of Table 3. Thus, the overall solution of the four-level optimization problem is clearly affected by demand changes; see Table 3. We illustrate these changes w.r.t. the bookings in Fig. 2. The figure shows that uniformly increasing the demand of all exits decreases the booked capacities in the south and leads to larger booked capacities in the middle, respectively north, of the network. This is possibly based on a combination of the larger willingness to pay of the exits and the transport capacity of the network. There are more exits in the south than in the north and, thus, the network probably already operates at its maximum especially in the south. Consequently, an increased willingness to pay at the demand nodes makes it more attractive for the TSO to reduce the technical capacities in the south and increase them in the north. This results in larger bookings in the north and smaller bookings in the south. 7 Conclusion This paper provides optimization techniques that enable us to solve a multilevel model of the European entry-exit gas market system, see [14], with a nonlinear flow model for real-world sized and tree-shaped networks. In line with the literature [2,14], this multilevel model can be equivalently reformulated to a bilevel problem and, on top of that, to a nonconvex and nonsmooth mixed-integer nonlinear single-level problem. This reformulation is independent of the considered flow model. The core difficulty of this single-level reformulation are the nonlinear adjustable robust constraints, by which the TSO computes the technical capacities of the network. These constraints alone make the considered problem computationally intractable in general. However, under the assumption of passive networks, i.e., no active elements such as compressor stations are considered, we derived a finite-dimensional reformulation of these nonlinear adjustable robust constraints for the case of tree-shaped networks. Moreover, we strengthened this reformulation by additional combinatorial constraints. The latter significantly increase the performance of our model as demonstrated by the numerical results. Further, the presented reformulation can also be generalized to other potential-based flow models under very mild assumptions. The reformulation has some nice properties such thatit only uses convex constraints including newly introduced integervariables.This enables us to solve the multilevel model of the European entry-exit gas market system with a nonlinear flow model for a real-world sized network, namely the Greek gas network without active elements, to global optimality. This is the first time that this multilevel model can be solved for a real-world sized network since even for simplified linear flow models the 123