Anubhav Ratha

Pierre Pinson
email: p.pinson@imperial.ac.uk

Hélène Le Cadre
email: helene.le-cadre@inria.fr

Ana Virag
email: ana.virag@vito.be

Jalal Kazempour

Moving from Linear to Conic Markets for Electricity

Keywords: OR in energy, spatial equilibrium, mechanism design, electricity markets, conic economics

à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d'enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.

Introduction

The spatial price equilibrium problem, as first analyzed by [START_REF] Enke | Equilibrium among spatially separated markets: Solution by electric analogue[END_REF] and [START_REF] Samuelson | Spatial price equilibrium and linear programming[END_REF], computes commodity prices and trade flows that satisfy partial equilibrium conditions over a network. In a two-sided auction framework, this problem involves price-quantity supply offers and demand bids matched by an auctioneer to maximize the social welfare, contingent on the spatial constraints. Historically, spatial price equilibrium problems rely on linear programming (LP) theory [START_REF] Kantorovich | Mathematical methods of organizing and planning production[END_REF] to derive the market equilibrium prices from marginal equalities. Despite the success of LP in achieving optimal market-clearing outcomes and efficient prices with satisfactory computational effort, it is potentially limiting in physical systems as it may fail to accurately represent the nonlinear operational characteristics of assets and the network. Examples of such physical systems include electricity [START_REF] Bohn | Optimal pricing in electrical networks over space and time[END_REF], natural gas [START_REF] De Wolf | The gas transmission problem solved by an extension of the simplex algorithm[END_REF], water [START_REF] Cai | Solving large nonconvex water resources management models using generalized benders decomposition[END_REF], heat [START_REF] Mitridati | Heat and electricity market coordination: A scalable complementarity approach[END_REF], telecommunication networks [START_REF] Courcoubetis | Pricing Communication Networks[END_REF] and supply chains [START_REF] Snyder | Planning for Disruptions in Supply Chain Networks[END_REF]. Even in non-physical systems facing uncertainty, the use of LP compels a linear modeling of uncertainty and potential risk preferences, which is limiting at times.

A natural question then arises, why should the market-clearing problem be confined to the LP framework? This question is pertinent since LP is the simplest mathematical framework in the convex optimization theory, while more general convex frameworks such as conic programming are available. If such frameworks enable a more accurate representation of physical assets and networks as well as uncertainty, while retaining the advantages of LP in terms of optimality, pricing, and computational ease, it is then, indeed, appealing to adopt them. Leveraging the recent mathematical and computational advances in conic programming [START_REF] Alizadeh | Second-order cone programming[END_REF][START_REF] Aps | MOSEK Modeling Cookbook 3.2.3[END_REF], in this work, we introduce and analyze spatial price equilibrium in a marketclearing context based on the second-order cone programming (SOCP) framework, and demonstrate how it outperforms the LP-based markets. Although our theoretical results are generalizable to any market-clearing context, we choose the domain of electricity markets for exposition as it is rich in examples that worsen the adverse impacts of the limitations imposed by LP-based markets.

Limitations of LP-based Electricity Markets

In electricity markets, the nonlinearities arise from the costs (utilities) and constraints of producers (consumers) and the physics of power flow in the network. Currently, real-world electricity markets follow the original proposal by [START_REF] Bohn | Optimal pricing in electrical networks over space and time[END_REF] to solve the spatial price equilibrium problem as an LP to obtain optimal production and consumption quantities and the spatiallydifferentiated nodal electricity prices, commonly referred to as locational marginal prices (LMPs) in the industry [START_REF] Kirschen | Fundamentals of Power System Economics[END_REF]. To reach climate change mitigation goals, electricity systems are transitioning towards a more sustainable future [START_REF] Chu | Opportunities and challenges for a sustainable energy future[END_REF], by integrating larger shares of weather-dependent renewable energy sources such as wind and solar. This trend challenges LP-based markets on three accounts.

First, with large shares of variable and unpredictable renewable energy, electricity markets are exposed to significant uncertainty, which needs to be accounted for. Classical methods within the LP framework, such as scenario-based stochastic programs [START_REF] Pritchard | A single-settlement, energy-only electric power market for unpredictable and intermittent participants[END_REF][START_REF] Zavala | A stochastic electricity market clearing formulation with consistent pricing properties[END_REF] and robust optimization techniques [START_REF] Bertsimas | Adaptive robust optimization for the security constrained unit commitment problem[END_REF] are unsuitable in practical settings as they suffer from computational intractability and solution conservativism, respectively. Going beyond LP-based markets is beneficial from an uncertainty modeling perspective. For instance, chance-constrained programming [START_REF] Kuang | Pricing chance constraints in electricity markets[END_REF], which admits nonlinear yet convex, computationally tractable and analytically expressable uncertainty models, paves the way for uncertainty-aware electricity markets in practice.

Second, accommodating the uncertainty requires resources that provide flexibility services by adapting their operational status. Such flexible resources include, among others, energy storage [START_REF] Kim | Optimal energy commitments with storage and intermittent supply[END_REF], flexible consumers [START_REF] Anjos | Operations Research Approaches for Building Demand Response in a Smart Grid[END_REF], upcoming power-to-x units [START_REF] Varela | Modeling alkaline water electrolysis for power-to-x applications: A scheduling approach[END_REF] as well as the coordination with natural gas [START_REF] Thompson | Optimal economic dispatch and risk management of thermal power plants in deregulated markets[END_REF] and district heating [START_REF] Mitridati | Heat and electricity market coordination: A scalable complementarity approach[END_REF] sectors. Operational characteristics of such flexible resources are typically nonlinear, i.e, they incur quadratic costs and admit nonlinear feasibility sets. LP-based markets require linear or piecewise-linear approximation of such cost functions, which fail to accurately characterize the costs and deter flexible resources from offering flexibility. Cost functions aside, adopting the inner (outer) polyhedral approximation required by LP-based markets leads to the undermining (overestimation) of the amount of flexibility available. At times, ignoring the characteristics induces operational and reliability risks for the flexibility provider and the electricity system, as witnessed during the 2014 polar vortex event in Northeastern United States (PJM Interconnection, 2014) and more recently, during the cold weather event in Texas [START_REF] Bushnell | To fix the power market, first fix the natural gas market[END_REF]. The need for an asset-aware electricity market remains unfulfilled within the LP framework. Apart from nonlinearities, the feasibility sets of various assets may entail non-convexity arising from integrality constraints, e.g., the commitment status of power producers [START_REF] Hobbs | Why this book? New capabilities and new needs for unit commitment modeling[END_REF]. This non-convexity is resolved in practice by solving a unit-commitment problem as a mixed-integer linear programming (MILP) problem before the actual market clearing from which optimal prices and quantities are derived [START_REF] O'neill | Efficient market-clearing prices in markets with nonconvexities[END_REF]. While considering non-convexities is beyond the scope of this work, Remark 1 further discusses them in the context of the market design proposed.

Third, accurate operational modeling of flexible resources is valuable only if the network constraints are represented in sufficient detail, which is crucial as flexible resources are dispersed across the electricity network. Conventionally, a linear approximation of electricity network constraints is adopted to retain an LP-based market-clearing problem. With this approximation, the marketclearing problem typically results in physical flows that are infeasible in reality [START_REF] Baker | Solutions of DC OPF are never AC feasible[END_REF]. Consequently, flexibility services are procured in a way that the network constraints may not allow the flexibility to be delivered when needed. This is critical in the case of electricity markets as the loss of real-time balance between the production and consumption of electricity in the system may lead to minor, localized supply disruptions at best and a large-scale cascading blackout at worst [START_REF] Daqing | Spatial correlation analysis of cascading failures: Congestions and blackouts[END_REF]. A network-aware procurement of flexibility services is vital for maintaining the real-time balance.

On the above three accounts, the LP framework falls short in meeting the challenges of electricity markets of the future, necessitating a more advanced yet practical alternative.

Towards Conic Economics

Augmenting the LP-based market-clearing problem with conic constraints alleviates these limitations to a great extent. A market-clearing problem that involves conic constraints leads to the emergence of conic economics. Coined by [START_REF] Raissi | Conic Economics[END_REF], conic economics was introduced in the context of general equilibrium theory, focusing on the mitigation of financial risk. In contrast, we argue that the inclusion of second-order cone (SOC) constraints based on the Lorentz cones into the spatial price equilibrium problem leads to a convexity-preserving modeling of nonlinearities within the market framework. The resulting SOCP-based market-clearing problems are efficiently solved in polynomial time using interior-point methods [START_REF] Alizadeh | Second-order cone programming[END_REF] by several off-the-shelf commercial solvers such as MOSEK, Gurobi, and CPLEX.

In the context of electricity markets, SOC constraints have recently gained interest in market proposals based on chance-constrained programming [START_REF] Dvorkin | A chance-constrained stochastic electricity market[END_REF]Mieth et al., 2020). The single-period stochastic market clearing proposed in [START_REF] Dvorkin | A chance-constrained stochastic electricity market[END_REF] discusses the internalization of uncertainty in the price formation process, highlighting the advantages of chance-constrained electricity markets over scenario-based stochastic markets in terms of potential acceptability in a real-world implementation. The work in Mieth et al. (2020) showed that SOC reformulations of chance constraints also enable an analytical characterization of the risk faced by electricity markets in mitigating the uncertainty from renewable energy sources, leading to risk-and variance-aware electricity prices. In regards to asset-awareness, [START_REF] Kuang | Pricing in non-convex markets with quadratic deliverability costs[END_REF] study quadratic costs of deliverability in unit commitment problems, essential to modeling ramping costs while providing flexibility. Finally, towards improving network-awareness, considering the SOC relaxation of power flows in distribution systems, pricing schemes based on conic duality were proposed in a deterministic setting in [START_REF] Papavasiliou | Analysis of distribution locational marginal prices[END_REF], and extended in Mieth and Dvorkin (2020) to include uncertainty modeled via chance constraints.

Previous works have primarily focused on only one of the three aspects, i.e., uncertainty-, asset-, or network-awareness of the markets, whereas integration of large shares of renewable energy in electricity markets requires a combined approach. Our work generalizes the prior works, such that heterogeneous market participants with nonlinear (and potentially inter-temporal constraints) and quadratic costs could participate in multiple commodity trades in an electricity market aimed at harnessing flexibility in a network-aware, cost-efficient manner. Consequently, flexibility providers take a central role in the proposed market design, transforming electricity markets from energycentric to flexibility-centric.

Remark 1 (Addressing non-convexities in electricity markets). Non-convexity of market participants' strategy sets implies that the optimal quantity allocations and prices do not necessarily support social welfare-maximizing equilibrium, e.g., producers may not recover their costs [START_REF] Liberopoulos | Critical review of pricing schemes in markets with non-convex costs[END_REF]. This is resolved in practice by out-of-market payments, called uplift payments, which are in turn minimized by adopting a convex hull pricing scheme, see [START_REF] Gribik | Market-clearing electricity prices and energy uplift[END_REF]; [START_REF] Wang | Commitment cost allocation of fast-start units for approximate extended locational marginal prices[END_REF] for details. Neglecting cost recovery of participants, similar to the two-step unit commitment approach using MILP [START_REF] O'neill | Efficient market-clearing prices in markets with nonconvexities[END_REF], these non-convexities can be potentially incorporated as an extension to our proposed conic market framework, rendering the problem as a mixed-integer second-order cone program (MISOCP). Commercial nonlinear programming solvers can already solve MISOCP problems, adopting a variety of algorithms [START_REF] Benson | Mixed-integer second-order cone programming: A survey[END_REF]. However, further computational advances and analysis of prices are needed prior to adoption in real-world electricity markets.

Contributions

As a broad contribution, our work generalizes the prevalent LP-based market-clearing problem to the SOCP framework and applies conic duality to analyze the market equilibrium prices and the economic properties of the underlying market-clearing problem1 . In the following, we discuss the specific contributions of this work from three perspectives, i.e., from a market design perspective, theoretical perspective, and finally from a practitioner's perspective.

From a market design perspective, our primary contribution is an original proposal for a general conic electricity market. By general, we imply a market framework that improves uncertainty-, asset-and network-awareness of electricity markets beyond the prevalent LP-based markets within the convex optimization realm. Our proposed market framework is uncertainty-aware by design, as it admits a chance-constrained market-clearing formulation. Towards an asset-aware electricity market, we enable heterogeneous market participants to accurately express SOC-representable nonlinearities in their cost (or utility) functions and constraints. Nonlinear network flow models underlying the physical delivery associated with the trades are also included in our proposal, leading to network-aware electricity markets.

From a theoretical perspective, we first formulate the market-clearing problem as a centrallysolved optimization problem and address the challenge of robust solvability of SOCP problems. Theorem 1 provides the necessary and sufficient conditions for optimality and robustness of the market-clearing outcomes, while Theorem 2 gives an analytical expression for conic spatial prices of the traded commodities. Connecting the centrally-solved optimization problem to a spatial equilibrium problem involving rational and self-interested actors, Theorem 3 leverages conic duality to prove the equivalence of the optimization to a competitive equilibrium. Under common assumptions, Theorem 4 proves the satisfaction of economic properties, namely efficiency, cost recovery and revenue adequacy [START_REF] Schweppe | Spot Pricing of Electricity[END_REF], in the proposed market-clearing. This analytically supports that the move towards conic markets does not incur the loss of any economic properties compared to the prevalent LP-based markets.

From a practitioner's perspective, we illustrate the generality of our proposed market-clearing framework by defining a bid format for conic markets, enabling heterogeneous market participants to express their preferences. Our numerical studies highlight how the conic market encompasses an uncertainty-aware electricity market that efficiently remunerates the mitigation of uncertainty by the market participants, such that the real-time balance in the electricity system is ensured. A new class of flexibility products, called adjustment policies, based on linear decision rules [START_REF] Holt | A linear decision rule for production and employment scheduling[END_REF] enable this. These policies are rules, agreed at the day-ahead market stage, that govern how flexibility providers respond to forecast error realizations during or close to the real-time operation. We compare the proposed SOCP-based market-clearing proposal with two LP-based uncertaintyaware benchmarks, highlighting the advantages of moving towards a conic market framework.

Paper organization: In §2 we introduce the market setting, illustrate the relevance of SOC constraints via examples, introduce the bidding format, and present the general conic market-clearing as an optimization problem. In §3, we analyze the spatial equilibrium underlying the optimization problem and discuss the economic properties constituting the market equilibrium. Next, §4 presents numerical results on one of the market-clearing use cases by comparing an uncertaintyaware conic market with the available alternatives within the LP domain. Finally, §5 concludes by highlighting the key findings of this work and discusses future perspectives. Appendix A provides a concise background on SOCP duality, while we prove our theoretical results in Appendix B. We provide modeling examples and present the market-clearing problems employed in numerical studies in the Supplementary Material which serves as an electronic companion to the paper.

Notation:

The set of natural and real numbers is denoted by N and R, respectively, whereas R + and R -, respectively, denote the sets of non-negative and non-positive real numbers. Upper case alphabets with a script typeface, such as A, represent sets, while vectors are denoted by lower case boldface and matrices by upper case boldface alphabets. For a vector x, the operator x denotes its transpose, x represents its Euclidean norm and diag(x) returns a diagonal matrix with vector x as the leading diagonal. We retrieve the k-th element of the vector x as the scalar x k and use the operator [•] k to retrieve the k-th element of a general vector expression. 0 and 1 are vectors of zeros and ones; arithmetic operators ≤, =, and ≥ on vectors are understood element-wise. For a matrix M ∈ R p×q , [M] (:,k) ∈ R p retrieves its k-th column while [M] (k,:) ∈ R 1×q retrieves its k-th row. The operator tr(M) returns the trace of the matrix M, while the expression M 0 indicates its positive-semidefiniteness. Lastly, the operator ⊗ denotes the Kronecker product.

A General Conic Market for Electricity

We discuss the setting of our conic market-clearing problem in §2.1, followed by introducing SOC constraints in a market-clearing context in §2.2. In §2.3, we discuss the equality constraints and present the conic market bids in §2.4. Lastly, we formulate the general market-clearing problem in §2.5 as an SOCP problem.

Market Setting

We consider a forward electricity market involving multiple discrete clearing periods within the finite time horizon of a single day. We focus on hourly electricity markets prevalent across the world and collect the hours of the day in a set T = {1, 2, . . . , T }, where T = 24.

Commodities: Without loss of generality, we assume that participants in the forward market compete at the day-ahead stage. The hourly clearing periods at the day-ahead stage, therefore, correspond to the hours of the next day, which we collectively refer to as the real-time operation. The two types of commodities to be traded are (i) energy and (ii) flexibility services. Both types of commodities are traded hourly in the day-ahead market, which is a purely financial market in the sense that the physical delivery of these commodities occurs during the real-time operation. The former commodity, i.e., energy, represents the quantity in MWh to be exchanged among the market participants during the real-time operation. The latter, i.e., flexibility services, refers to the exchanges that contribute to the supply-demand balance during the real-time operation. For instance, these exchanges could be a result of the activation of adjustment policies allocated to flexible market participants in response to an operational need that may arise during the real-time operation. A potential occurrence of an imbalance between the total production and consumption of energy in the system during the real-time operation is such an operational need. As another example, flexibility services could also be traded for mitigation of a foreseeable congestion in parts of the electricity network. We define a set P = {1, 2, . . . , P } to denote the P commodities traded in the market.

Market participants: Our market framework admits heterogeneous competing participants buying or selling one or more commodities in the market. We introduce the notation and discuss properties applicable to all participants here, while delegating the elaboration on various kinds of participants to §2.2. Let the set I = {1, 2, . . . , I} collect I participants, such that I ≥ 2. For each participant i ∈ I, let q it ∈ R K i denote the K i ≥ P number of decision variables at hour t. We retrieve the k-th element of the decision variable at hour t as q itk ∈ R, ∀k ∈ {1, 2, . . . , K i }. To facilitate a multi-period market-clearing, we stack q it for the T = 24 hours, extending each participant's decision vector to q i ∈ R K i T . The first P elements of the vector q it represent contribution towards the P commodities in hour t. For notational compactness, we introduce q ip ∈ R T , ∀p ∈ P as a subvector of q i extracting the hourly contributions by participant i towards the trades of the p-th commodity over the T hours. Apart from the contributions towards the commodity trades, each participant may have K i -P state variables at each hour t, which are involved in the participant's operational constraints. Let c it (q it ) : R K i → R denote the participant's cost function, such that each c it (q it ) is increasing, convex and twice-differentiable in q it and satisfies c it (0) = 0. We adopt a sign convention that c it (q it ) > 0 applies for injection into the network and c it (q it ) < 0 for withdrawal, thereby representing the convex cost of injection and concave benefit of withdrawal. The temporally-separable structure of the cost function ensures its convexity while accommodating participants such as firms owning energy storage units, who toggle between being producers (discharging) and consumers (charging).

Electricity network:

We represent the electricity network as a directed graph (N , L) formed by a set of nodes N = {1, 2, . . . , N }, each potentially hosting multiple market participants, and a set of lines L comprised of pairs of nodes (n, n ) that are connected. We define I n ⊆ I, ∀n ∈ N as the set of market participants connected to node n. The quantity of power flowing over each line and the direction of the flow is governed by nonlinear and non-convex power flow equations during the real-time operation. Moreover, the flow across the network is limited by a maximum flow quantity in each line, known as the thermal limit or rated capacity of a power line.

System operator: A system operator ensures that (i) optimal market-clearing outcomes and efficient prices are achieved, and (ii) a continuous balance between consumption and generation is maintained during the real-time operation, while satisfying the transport limits of the underlying electricity network. Evidently, these roles correspond to the tasks of operating the market and operating the network, respectively. In this paper, we assume that the system operator is responsible for both the day-ahead market-clearing and the real-time operation, which is consistent with the prevalent organization in the United States.

Competition and timeline: For the simplicity of exposition, this work assumes that no market participant acts strategically to exercise market power. Moreover, we overcome the non-convexity arising from integrality constraints by accepting offers (bids) from participants already committed to producing (consuming). In our market setting, the committed market participants submit their day-ahead supply offers and demand bids to the central system operator, before a predefined gate closure time, without any knowledge of the bids and offers from other participants. Thereafter, the market is cleared by the system operator matching the offers with the bids, while ensuring the feasibility of network constraints. Finally, cleared prices and quantities for all the commodities are publicly disclosed.

Payment mechanism: As in majority of electricity markets worldwide, we adopt a uniform pricing scheme for pricing of energy, implying that all accepted supply offers and demand bids are cleared with a common price at a given location and time. Alternative payment mechanisms, e.g., payas-bid and Vickrey-Clarke-Groves pricing in a single commodity setting [START_REF] Vickrey | Counterspeculation, auctions, and competitive sealed tenders[END_REF] are other possibilities and our market-clearing problem is generalizable to admit them.

SOC Constraints in a Market-Clearing Problem

Our general market framework admits heterogeneous market participants of four kinds. First, we consider conventional power producers such as firms that own coal-fired, gas-fired, nuclear, and hydro power plants. These producers are dispatchable at the day-ahead stage, i.e., they are able to plan their production during real-time operation with a high degree of certainty. Some are flexible, e.g., gas-fired and hydro, meaning that their planned production quantities can be modified during the real-time operation, if needed. On the contrary, some producers are relatively less flexible, e.g., coal-fired and nuclear power producers. Second, we consider firms owning weather-dependent renewable power production sources such as wind and solar power plants. These producers are nondispatchable and inflexible. Third, we consider energy consumers such as small-scale end-consumers or large industries. Some of these consumers may be flexible and can be counted as flexible resources. Last, we consider additional types of flexibility providers, which may not necessarily be conventional power producers or flexible consumers, for instance, firms owning energy storage units.

SOC constraints applicable to these market participants are derived from a second-order cone, which is a convex set and is alternatively referred to as Lorentz cone or ice-cream cone. For the variable q i of participant i, ∀i ∈ I, an SOC constraint in its general form is given by

A i q i + b i ≤ d i q i + e i ⇔ A i d i q i + b i e i ∈ C i ⊆ R m i +1 , (1)
where C i is a second-order cone of dimension m i + 1, where m i ∈ N. The dimensions m i + 1 of the cone reflect the relationship within the decision variables. Considering the heterogeneous mix of market participants involved, the dimensions of the cone in the SOC constraints are not necessarily identical among the various participants or even among the constraints of each participant. Pa-

rameters A i ∈ R m i ×K i T , b i ∈ R m i , d i ∈ R K i
T and e i ∈ R embody the structural and geometrical information for each constraint. We use the two equivalent forms in (1) interchangeably, preferring the form with Euclidean norm while discussing the modeling of participant constraints and the conic form in the analytical proofs.

Linear constraints: Any single-period or multi-period linear constraint arising from the operation of physical assets owned by a participant i is represented by (1) with appropriate choice of parameters. Linear constraints are represented by the SOC constraint (1), provided that A i is a null matrix or the cone is dimensioned such that m i = 0. In the former case, (1) reduces to the linear constraint 0 ≤ d i q i + e i , which denotes a halfspace. Whereas in the latter case, (1) reformulates into a linear constraint 0 ≤ d i q i + e i , where e i = e ib i . For power producers, such constraints are, e.g., minimum or maximum production limits and ramping rate constraints that limit production change over subsequent hours.

Quadratic constraints: While linear constraints are admissible in LP-based electricity markets, convex quadratic constraints are not. However, any convex quadratic operational constraint related to the assets of participant i can be represented by (1) if d i = 0 and e i ≥ 0. Example EC.1 in the Supplementary Material illustrates the conic reformulation of such a quadratic constraint.

Other nonlinear constraints: In a more general sense, beyond linear and convex quadratic constraints, (1) captures the relationship among the K i T number of decision variables for each market participant, contributing towards asset-awareness of the market-clearing problem. For instance, such nonlinear constraints arise in the coordination between the electricity system and natural gas system, wherein the operational constraints of the natural gas system become relevant to the day-ahead electricity market-clearing problem, as discussed in the following.

Example 1 (Electricity and gas system coordination). The interdependence between electricity and natural gas systems primarily arises due to the significant role played by gas-fired power plants in providing flexibility to the electricity system facing uncertainty. Congestion in the gas network during the real-time operation of the electricity system jeopardizes the availability of fuel for gas-fired power plants and therefore, adversely impacts the flexibility provision [START_REF] Byeon | Unit commitment with gas network awareness[END_REF]. One of the crucial operational constraints of the gas system is the relation between gas flows and nodal pressures in the network. The steady-state flow of gas in the pipelines is represented by a non-convex quadratic equality constraint that relates the squared flow magnitude with the difference in squared pressures at the terminal nodes. A convex relaxation of this non-convex equality takes the form of SOC constraints, as illustrated in the following. Let ϕ ∈ R + denote the flow of gas along a gas pipeline connecting two terminal nodes, a sending node s and a receiving node r with nodal pressures denoted by π s ∈ R + and π r ∈ R + , respectively. Proposed by [START_REF] Borraz-Sánchez | Convex relaxations for gas expansion planning[END_REF], the convex relaxation for the non-convex equality between the flow along a pipeline and the pressures at the terminal nodes is expressed as

ϕ 2 ≤ β 2 (π 2 s -π 2 r ), (2)
where β ∈ R + is a constant encoding the friction coefficient and geometry of pipelines. Ignoring all other pipelines and considering the gas network operator as an electricity market participant, we can denote its decision vector as q GN = ϕ π r π s and can represent the constraint (2) as an SOC constraint of the form (1) with parameters

A = 1 β 0 0 0 1 0 , b = 0 2 , d = 0 0 1 and e = 0,
which is a three-dimensional SOC constraint, i.e., m i = 2. Similar SOC constraints are included for other pipelines in the gas network and over various hours, therefore enabling the consideration of gas network operational constraints within the conic electricity market-clearing problem.

Coordination aside, the increased coupling leads to uncertainty propagation from the electricity system to the gas side. This implies that operational constraints involving state variables in the gas system are challenged by uncertain gas withdrawals from gas-fired power plants responding to uncertainty in the electricity system. Accurately modeling and controlling the variance of state variables entails the use of SOC constraints, as studied in [START_REF] Dvorkin | Stochastic control and pricing for natural gas networks[END_REF].

Lastly, beyond asset-awareness, SOC constraints in their general form enable an uncertaintyaware market-clearing problem. Specifically, chance constraints enable endogenous modeling of uncertainty and risk faced by market participants and are analytically reformulated as SOC constraints under some mild conditions [START_REF] Nemirovski | Convex approximations of chance constrained programs[END_REF], see Example 2 below.

Example 2 (Chance Constraints). Consider a market-clearing problem wherein, in addition to the nominal production quantities, a flexibility service is contracted from the flexibility providers in the market. A traded flexibility service is organized as an adjustment policy. As mentioned in §2.1, these adjustment policies allow mitigation of the uncertainty realized during the realtime operation, while look-ahead decisions are made by the system operator at the day-ahead market-clearing stage. Such uncertainty could, for example, arise from imperfect forecasts for the production from weather-dependent renewable energy sources or from imperfect load forecasts for consumers. Assuming a single-period market-clearing problem for notational simplicity, let the set W = {1, 2, . . . , W } collect the W independent sources of uncertainty in the electricity system and vector ξ ∈ R W denote the random forecast errors representing this uncertainty. Assume that ξ follows a probability distribution P ξ , parameterized by the moments, mean µ ∈ R W and covariance Σ ∈ R W ×W , which are estimated by the system operator with access to a finite number of historical measurements. Under the chance-constrained optimization framework, the system operator allocates adjustment policies to flexible producers while allowing them to violate their operational constraints with a small probability ε ∈ [0, 1]. Assume again that participant i has K i = 2 decision variables such that q i1 = qi1 α i1 ∈ R2 , where qi1 and α i1 are, respectively, the nominal production quantity and the adjustment policy. A chance constraint limiting the total production, i.e., the sum of nominal and adjustment, of the participant to its upper limit Q i is written as

P ξ 1 1 ξ qi1 α i1 ≤ Q i ≥ (1 -ε), (3a)
where the uncertainty is characterized by the total forecast error 1 ξ ∈ R. This probabilistic constraint reformulates to its analytic equivalent, based on [START_REF] Nemirovski | Convex approximations of chance constrained programs[END_REF], as

r ε X1 α i1 ≤ Q i -qi1 -1 µ α i1 , (3b)
where all vectors of ones are 1 ∈ R W , and X ∈ R W ×W denotes a factorization of the covariance matrix such that Σ = XX . For instance, since Σ 0 from the definition of covariance matrices, such a factorization can be obtained in a computationally efficient manner using Cholesky decomposition, resulting in X having a lower-triangular structure. This decomposition is uniquely determined for covariance matrices that are full rank, i.e., all uncertainty sources are linearly independent, as assumed. The parameter r ε ∈ R + is a safety parameter chosen by the system operator relying on the knowledge of the distribution P ξ , such that r ε increases as ε reduces 2 . Constraint (3b) is represented by the general SOC constraint (1) with parameters

A = 0 X1 , b = 0 , d = -1/r ε 1 1 µ and e = Q i /r ε ,
thereby resulting in an SOC constraint of dimension W +1. Further modeling details showcasing the analytical reformulation of more complicated constraints, such as inter-temporal chance constraints of market participants, are covered in the Supplementary Material.

Finally, accounting for the potentially multiple SOC constraints faced by participant i, we introduce a set J i = {1, 2, . . . , J i } collecting the J i constraints that extend (1) as

A ij q i + b ij ≤ d ij q i + e ij , ∀j ∈ J i , (4)
where each constraint with parameters

A ij ∈ R m ij ×K i T , b ij ∈ R m ij , d ij ∈ R K i T and e ij ∈ R corresponds to a second-order cone C ⊆ R m ij +1
. The feasibility region for (4) is formed by the Cartesian product of J i second-order cones

C i = j∈J i C ij = C i1 × • • • × C iJ i , which is convex.

Equality Constraints

Each participant may be involved in trades corresponding to the P commodities, subject to equality constraints that arise while considering temporal and spatial dynamics underlying their asset models. We model the equality constraints on the decision variable q i of participant i as

F i q i = h i , where F i ∈ R R i ×K i T and h i ∈ R R i
are parameters encoding the R i equality constraints on q i , such that R i ≤ K i T and F i has full row rank.

The market-clearing conditions are also modeled as marginal equalities coupling the decisions of the participants such that supply-demand balance is ensured for each of the P commodities traded in the market. Modeling these conditions, given the heterogeneous mix of market participants in our framework, requires the following definition.

Definition 1 (Physical Fulfillment of Commodity Trades). For participant i ∈ I, the hourly injection or withdrawal towards commodity p is given by G ip q ip ∈ R T , where G ip ∈ R T ×T is a coupling matrix formed by elements encoding the injection or withdrawal coefficients.

We now elaborate on this definition. The contribution by a dispatchable producer (either flexible or inflexible) towards the commodity representing energy is q ip ∈ R T + , whereas for inflexible consumers, the contribution is q ip ∈ R T -. For both kinds of market participants, the coupling matrices G ip are identity matrices, i.e., G ip = diag(1). Meanwhile, the contribution from energy storage units q ip to the commodity corresponding to energy adopts different signs in the various hours depending on whether the storage unit is discharging (injection) or charging (withdrawal). Information on the conversion factors for participants from other sectors such as natural gas or district heating is also encoded within the entries of the matrix G ip . Finally, in addition to those traded system-wide, the market-clearing problem may entail commodities traded among a subset of all participants and thereby, reflect the agreements among that subset. G ip may thus be null matrices for some commodities and for some participants.

Bid Format in the Conic Electricity Market

For the sake of generality, we adopt a common bid format for the supply offers and demand bids, referring to them as supply and demand bids, respectively and define them in the following.

Definition 2 (Conic Market Bids). Let B i denote a bid submitted by the market participant i to the system operator. The bid B i is a tuple defined as

B i := n i , {A ij , b ij , d ij , e ij } j∈J i , F i , h i , {G ip } p∈P , {c Q it , c L it } t∈T ,
where n i ∈ N is the electricity network node at which the participant i is located. Parameters A ij , b ij , d ij , e ij , ∀j ∈ J i are linked to the J i SOC constraints; G ip , ∀p ∈ P correspond to the coupling matrices for the P commodities; F i and h i correspond to the R i equality constraints; and lastly, c Q it , c L it , ∀t ∈ T denote the temporally-separated quadratic and linear bid prices.

Remark 2 (Conic Market Bids vs. Price-Quantity Bids). The bids B i are a generalization of the classical price-quantity bids that form the backbone of various orders placed in currentlyoperational LP-based electricity markets, see Nord [START_REF] Pool | Nord Pool Day-ahead Trading[END_REF] for example. As the name indicates, in addition to the participant's locational information, a price-quantity bid comprises a bid price representing the bidder's willingness-to-pay or willingness-to-receive for the associated quantity.

In the proposed conic market bids, the quantities are formed by the parameters of the j-th SOC constraint {A ij , b ij , d ij , e ij } admitting the simple linear characterization of quantities q i when A ij is a null matrix or when m ij = 0, while more intricate representations of the operational constraints are covered by a suitable choice of the SOC constraint parameters, as discussed in §2.2.

In contrast to price-quantity bids, the SOC constraint parameters enable market participants to explicitly reflect the SOC-representable nonlinearities in their costs and operational constraints. Furthermore, market participation in terms of supply (or demand) quantity q ip towards a specific commodity p ∈ P is decoupled from the potential costs and constraints with associated with the state variables of the participants comprising q i . However, the proposed bid format requires a more complex exchange of information between the market participants and the market operator.

In practice, a simple bid transformation software layer could convert the standard price-quantity bids by participants into the conic bid format, before the market is cleared.

Market-Clearing as an SOCP Problem

Network constraints: An accurate modeling of the physics of power flows in the electricity network introduces nonlinearities and non-convexities. Convexification of these power flow equations have utilized SOCP [START_REF] Kocuk | Strong SOCP relaxations for the optimal power flow problem[END_REF] and SDP [START_REF] Lavaei | Zero duality gap in optimal power flow problem[END_REF] relaxations to ensure optimality while solving electricity system-related optimization problems. However, electricity market-clearing problems across the world adopt a linearized approximation of the power flow equations, relying on a number of assumptions [START_REF] Cain | History of Optimal Power Flows and Formulations[END_REF]. Consistent with current practice and for simplicity of exposition, our formulation adopts a variation of linearized power flow equations that leverages the so-called Power Transfer Distribution Factor (PTDF) matrix. Example EC.2 in Supplementary Material illustrates an extension to the market-clearing problem formulated in this work to include SOC-based convex relaxation of the non-convex AC power flow equations.

Definition 3 (Power flows using PTDF). With the set I n ⊆ I collecting market participants located at node n, the power flow s a along a line = (n, n ) at hour t is given by

s a = n∈N [Ψ] ( ,n)   i∈In p∈P [G ip q ip ] t   ,
where Ψ ∈ R L×N denotes the PTDF matrix of the electricity network. Derived from the physical parameters of power lines comprising the network, entries of the PTDF matrix are the sensitivity of changes in the flow in any line to a unit injection at a given node. The expression i∈In p∈P [G ip q ip ] t ∈ R computes the algebraic sum of injections or withdrawals of all participants located at node n towards the P commodities at hour t.

Remark 3. All P commodities share the common physical network for fulfillment of the trades, as reflected by the summation in the expression for power flows in Definition 3. Alternative formulations can be envisioned such that not all commodity trades rely on the physical network for fulfillment. For instance, flexibility services may include purely financial instruments to hedge risk in electricity markets [START_REF] Philpott | Equilibrium, uncertainty and risk in hydro-thermal electricity systems[END_REF][START_REF] Mieth | Risk trading in a chance-constrained stochastic electricity market[END_REF].

Conic market-clearing problem, M c : Without loss of generality, we assume that the participants have quadratic cost functions which satisfy the conditions in §2.1. In the interest of computational and analytical simplicity, we reformulate the quadratic costs as SOC constraints following the approach in Example EC.1. Auxiliary decision variables z i ∈ R T , ∀i are introduced, representing the participants' hourly quadratic cost components. The market-clearing problem, hereafter referred to as M c , is formulated as

min q i ,z i i∈I t∈T z it + c L it q it (5a) s.t. C Q it q it 2 ≤ z it , ∀t, ∀i :(µ Q it , κ Q it , ν Q it ) (5b) A ij q i + b ij ≤ d ij q i + e ij , ∀j ∈ J i , ∀i : (µ ij , ν ij ) ( 5c
)
F i q i = h i , ∀i : (γ i ) (5d) i∈I G ip q ip = 0 T , ∀p, : (λ p ) (5e) n∈N [Ψ] (:,n)   i∈In p∈P [G ip q ip ] t   ≤ s, ∀t, : ( t , t ) (5f)
where the objective (5a) minimizes social disutility (or maximizes social welfare) of the marketclearing problem over the time horizon, t ∈ T . Recall that q it ∈ R K i and q ip ∈ R T are subsets of the i-th participant's decision vector q i ∈ R K i T . The Lagrange multipliers associated with the constraints are shown in parentheses next to them. The constraint parameters, in their order of appearance, are

A ij ∈ R m ij ×K i T , b ij ∈ R m ij , d ij ∈ R K i T , e ij ∈ R, F i ∈ R R i ×K i T , h i ∈ R R i , G ip ∈ R T ×T , [Ψ] (:,n) ∈ R L and s ∈ R L .
The index j ∈ J i refers to the J i SOC constraints of participant i as discussed in §2.2, while the index p ∈ P refers to the P commodities traded among the participants. Constraints (5b)-(5d) are participant-specific, while (5e)-(5f) are related to the commodities exchanged in the market.

The temporally-separable quadratic and linear bid prices of participant i are given by c

Q it , c L it ∈ R K i and C Q it ∈ R K i ×K i is a factorization of the quadratic cost matrix such that diag(c Q it ) = C Q it C Q it . Lagrange multipliers µ Q it ∈ R K i , κ Q it ∈ R + and ν Q it ∈ R + , ∀t, ∀i
, are participant-specific dual variables associated with the rotated SOC constraints (5b) which are satisfied with equality at the optimal solution to problem M c . Constraints (5c) model the SOC constraints applicable to the market participants that enable asset-and uncertainty-awareness of the market-clearing problem. The tuple of dual variables associated with the SOC constraints (5c) are (µ ij , ν ij ), where µ ij ∈ R m ij and ν ij ∈ R + . Unlike linear scalar inequalities which admit a single non-negative dual variable, SOC constraints (5b)-(5c) admit tuples of dual variables, as shown while obtaining dual formulations for the SOC constraints in Appendix A.1. Lastly, the dual variable γ i ∈ R R i associates with the R i equality constraints for the participant i, see §2.3.

Constraints (5e) are the system-wide balance constraints that couple the decisions of the market participants for each of the P commodities traded in the market, such that the Lagrange multipliers associated with these constraints λ p ∈ R T are interpretable as commodity prices. For instance, the Lagrange multiplier associated with the balance between electricity production and consumption is the nodal price of electricity. Lastly, constraints (5f) limit the magnitude of power flow in the lines to their rated capacity, s, as given by Definition 3. Given the element-wise absolute value operator in this constraint, we associate a pair of non-negative dual variables t , t ∈ R L + with it. Naturally, constraints (5f) can be altered to include asymmetric limits, i.e., the limits which depend on the direction of flow in the power lines, without significant change to the analytical results that follow. Further, note that instead of the chosen PTDF-based formulation, implementing an SOCP relaxation for the formulation of power flow equations affects the constraint (5f). However, the overall market-clearing problem M c remains within the SOCP framework. Finally, adopting the SOC relaxation for the non-convex AC power flow equations (Example EC.2 in Supplementary Material), constraints (5f) are replaced by SOC constraints while additional state variables are introduced to model the electricity network parameters. In that case, while (5) remains an SOCP problem, the pricing of commodities under such conic network constraints (presented in §3) merits further investigation.

Remark 4 (Strict Convexity). Observe that the optimization problem M c has a strictly convex objective function (5a) provided every market participant incurs a non-zero quadratic cost at all hours for each of its K i variables. To see that, we recall that every positive semidefinite matrix is the Gram matrix for some set of vectors. For the quadratic cost matrix diag(c Q it ) 0,

q it diag(c Q it )q it = q it C Q it C Q it q it = C Q it q it 2 , ∀t, ∀i,
such that strict convexity is guaranteed only if the quadratic cost matrix is positive definite, i.e., diag(c Q it ) 0, which requires c Q itk = 0, ∀k = 1, 2, . . . , K i , ∀t, ∀i.

Economic Interpretation and Equilibrium Analysis

We discuss the price formation process for the P commodities traded in the market in §3.1, followed by the theoretical results that characterize the spatial price equilibrium underlying the centrally-solved market-clearing problem M c in §3.2.

Conic Spatial Prices for Commodities

Deriving optimal market-clearing prices for the problem M c is not straightforward, since strong duality is not trivial to establish for an SOCP problem [START_REF] Ben-Tal | Lectures on Modern Convex Optimization[END_REF]. Unlike their LP counterparts where strong duality is guaranteed merely by the feasibility of the primal and dual problems as formulated in Farkas' lemma, strong duality in SOCP problems derives from the existence of strictly feasible solutions to both the primal and dual problems (Alizadeh and Goldfarb, 2003, Theorem 13). Conventionally, ensuring the strict feasibility or even merely the feasibility of market-clearing problem is considered at a market design stage and is not of high relevance for the market operator. However, in the interest of generality and wider acceptance of a conic market-clearing framework, we address this crucial issue in our analytical results. Following Slater's constraint qualification for convex optimization problems, strict feasibility refers to the existence of points within the feasibility set of the primal problem where all inequalities -SOC and linear -are strictly satisfied. Additionally, a refinement to Slater's constraint qualification yields the so-called essentially strict feasibility of an SOCP problem.

Definition 4 (Essentially Strict Feasibility). The market-clearing problem M c is essentially strictly feasible, if there exists a feasible solution tuple denoted by (q i , z i ), ∀i such that

C Q it q it 2 < z it , ∀t, ∀i, A ij q i + b ij < d ij q i + e ij , ∀j ∈ J i , ∀i.
Observe that essentially strict feasibility is a weaker requirement as compared to strict feasibility. However, it is necessary and sufficient for strong duality to hold for M c since other inequalities (5f) are linear in decision variables (Boyd and Vandenberghe, 2004, §5.2.3). We now provide the analytical results crucial to deriving optimal prices from the market-clearing problem M c .

Theorem 1 (Strong Duality). Let D c denote the dual problem to the market-clearing problem M c . If the set of feasible solutions to the primal problem M c is non-empty, then both the primal problem M c and dual problem D c are essentially strictly feasible, and consequently, strong duality holds for the primal-dual pair of problems M c and D c .

Conditioned on feasibility of the primal market-clearing problem M c , Theorem 1 enables economic interpretations of the market-clearing outcomes. Relying on classical Lagrangian duality theory, we provide an analytical expression for the optimal, spatially-differentiated nodal prices of the P commodities in the following theorem.

Theorem 2 (Conic Spatial Prices). The solution to the conic market-clearing problem M c results in optimal contributions q ip , ∀i ∈ I for the p ∈ P commodities and the market clears with optimal prices Π p ∈ R N ×T for the p-th commodity given by

Π p = Λ p -Ψ (ρ -ρ ), ∀p ∈ P, (6)
where ρ , ρ ∈ R L×T and Λ p ∈ R N ×T are variables with stacked columns of optimal dual variables t , t , ∀t and λ p , ∀n, respectively, over the T market-clearing hours, i.e.,

ρ = [ 1 • • • T ], ρ = [ 1 • • • T ], and
Λ p := 1 N ⊗ λ p .
The commodity prices given by Theorem 2 are analogous in structure to the LMPs resulting from the prevalent LP-based electricity market-clearing frameworks. Specifically, the optimal prices Π p comprise of a nodal price component for each commodity Λ p and a network price component which is non-zero only if congestion arises in the network as a consequence of the power flows along the lines to fulfill the trades.

M c as a Spatial Equilibrium Problem

First, we show the equivalence of the optimization problem M c to a spatial equilibrium problem. Referring to the two roles played by the system operator discussed in §1, consider a virtual separation of the system operator into a market operator and a network operator. First, the market operator, acting as a price setter, collects the conic market bids from market participants and is responsible for clearing the day-ahead market and for the real-time operation of the system. Second, the network operator, responsible for the physical fulfillment of the commodities, acts as a spatial arbitrager to collect a non-zero revenue, congestion rent, whenever the trades lead to congestion in the network.

Consider an equilibrium problem E c comprised of a set of individual optimization problems of the i ∈ I market participants, the network operator and the market-clearing conditions. For market participant i located at node n i ∈ N , let W ip ∈ R N ×T denote the quantities of the commodity p ∈ P transacted (bought or sold) over the N nodes at the T hours. Under the perfect competition assumption, the commodity prices Π p , ∀p are exogenous to the participants' optimization problem. Therefore, participant i maximizes her profit by deciding the optimal contributions q ip , ∀p ∈ P commodities traded in the market, subject to her operational constraints, by solving the problem max

q i , z i ,W ip p∈P tr(Π p W ip ) - t∈T z it + c L it q it - t∈T ω t p∈P [W ip ] (:,t) -I n i [G ip q ip ] t (7a) s.t. C Q it q it 2 ≤ z it , ∀t :(µ Q it , κ Q it , ν Q it ) (7b) A ij q i + b ij ≤ d ij q i + e ij , ∀j ∈ J i :(µ ij , ν ij ) (7c) F i q i = h i :(γ i ) (7d) W ip 1 = G ip q ip , ∀p ∈ P, :( λ ip ) (7e)
where the three terms comprising the objective function (7a) are the revenues generated by the transactions, the cost (utility) of production (consumption) and the third term is the transport cost for the physical fulfillment of the transactions at the nodes where they are delivered. Here, the indicator vector I n i ∈ R N contains the element corresponding to the location of participant i as 1, while all other elements are 0. Constraints (7e) ensure a balance of the commodity transactions with the contributions towards the trades as given by Definition 1. Variables λ ip ∈ R T are the Lagrange multipliers associated with these constraints. Note that the nodal commodity prices Π p and the price of transmitting power ω t ∈ R N , ∀t are set by the market operator and, as such, are considered as fixed by the participant.

Next, the network operator maximizes congestion rent, while fulfilling the trades of all the commodities in the market. Let y t ∈ R N , ∀t denote the net power injection comprising of all commodities and all market participants at the N nodes at each hour. The network operator solves the following maximization problem subject to the network limits max yt t∈T

ω t y t s.t. -s ≤ Ψy t ≤ s, : ( t , t ), (8)
where ω t are variables exogenous to the network operator and the constraints limit the power flows along the lines to their rated capacity in both directions. Lastly, the market operator clears the market based on the following equalities

p∈P [Q inj p ] (:,t) = y t , ∀t :(ω t ) (9a) i∈I G ip q ip = 0, ∀p ∈ P, :(λ p ) (9b)
where the auxiliary variable Q inj p ∈ R N ×T denotes the commodity-specific net nodal injections

Q inj p := i∈I 1 (G ip q ip ) i∈I 2 (G ip q ip ) • • • i∈I N (G ip q ip ) . ( 10
)
The market-clearing equalities (9a) ensure the net injection at each of the nodes of the network is balanced by the transport service provided by the network operator. The shadow price of this constraint, ω t , appears as a parameter in the network operator's maximization (8) and is interpreted as the price of transmitting power from an arbitrary hub to the each of the nodes. As discussed previously, (9b) ensure the system-wide balance of traded commodities.

Theorem 3 (Competitive Spatial Equilibrium). The convex market-clearing problem M c solved centrally by the system operator is equivalent to a competitive spatial equilibrium E c comprised of market participants, i ∈ I each solving the profit maximization (7), the network operator solving the congestion rent maximization (8) and the market operator clearing the market by enforcing the equalities (9).

The proof for Theorem 3 relies on the equivalence of the Karush-Kuhn-Tucker (KKT) optimality conditions of the two problems.

Corollary 1 (Existence and Uniqueness). The solution to the competitive spatial price equilibrium problem E c exists and is unique in allocations q i , provided all market participants bid with non-zero quadratic price components, i.e., c Q itk = 0, ∀k = 1, 2, . . . , K i , ∀t, ∀i ∈ I. While Corollary 1 yields uniqueness of allocations q i , conditioned on the strict convexity of the objective function (5a), no such guarantees on the uniqueness of the prices Π p can be given since the dual problem to (5) (formulated in Appendix A.2) does not admit a strictly convex objective function. The conditions on the uniqueness of the allocations at equilibrium closely correspond to those in prevalent LP-based markets3 . Next, we analyze the desired economic properties underlying the equilibrium E c .

Theorem 4 (Economic Properties). The market-clearing problem M c and its equivalent competitive spatial equilibrium E c result in optimal allocations q i , ∀i ∈ I and spatial commodity prices Π p , ∀p ∈ P such that the following economic properties are attained at optimality: (i) Market efficiency: Under the perfect competition assumption, social welfare is maximized, such that no participant desires to unilaterally deviate from the market-clearing outcomes.

(ii) Cost recovery: Let the market bids B i for each market participant i ∈ I be such that e ij ≥ b ij , ∀j ∈ J i and h i = 0. Then, the optimal allocations q i , ∀i ∈ I and optimal spatial commodity prices Π p , ∀p ∈ P ensure cost recovery for the market participants.

(iii) Revenue adequacy: The market operator does not incur financial deficit at the end of the market-clearing horizon, i.e.,

p∈P i∈I tr(Π p W ip ) - t∈T ω t y t ≥ 0.
Theorem 4 characterizes the economic properties underlying the market-clearing outcomes from the conic market-clearing M c . While market efficiency is guaranteed under the perfect competition assumption, cost recovery is ensured for all participants under two conditions, which we elaborate in the following. First, as shown in the modeling examples in the Supplementary Material, the condition e ij ≥ b ij holds true for all participants in most practical settings, with the notable exception of market participants having a non-zero lower bound on their decision variables. The practical issue of non-guarantee of cost recovery for such market participants also prevails in currentlyoperational LP-based electricity markets. The second condition relates to the homogeneity of the linear equality constraints (5d), i.e., q i = 0, ∀i is a feasible solution to the market-clearing problem. Observe that, the feasibility of a zero-allocation solution, i.e., q i = 0, ∀i also satisfies the first condition, thereby indicating that these two conditions are equivalent. Lastly, the condition for revenue adequacy for the market operator requires that the net payments received from the market participants i ∈ I less the payments made by the market operator to the network operator towards transmission service is non-negative.

Remark 5 (Incentive Compatibility). The incentive for actors to deviate from price-taking, perfectly-competitive behavior decreases to zero as the number of actors goes to infinity [START_REF] Roberts | The incentives for price-taking behavior in large exchange economies[END_REF]. Thus, assuming a very large number of market participants, the conic market-clearing proposal tends towards incentive compatibility, i.e., at the limit participants bid according to their true preferences. The conditions under which incentive compatiobility is satisfied by M c is akin to the prevalent LP-based electricity markets, thereby preserving this desired economic property in the move towards an SOCP-based market-clearing framework.

Beyond the desired economic properties discussed so-far, we analyze the robustness of the market-clearing outcomes resulting from M c against small changes in parameters. Strong duality aside, in the context of a market-clearing problem, this property is crucial to be studied for SOCP problems. Robust solvability refers to the property of an SOCP problem such that it remains solvable and obtains the optimal solution even when the problem parameters are changed by arbitrary small perturbations. Proposition 1.4.6 in Ben-Tal and [START_REF] Ben-Tal | Lectures on Modern Convex Optimization[END_REF] establishes that robust solvability is guaranteed by the strict feasibility of both primal and dual problems. The following corollary to Theorem 1 formalizes robust solvability of the conic market-clearing problem.

Corollary 2 (Robust Solvability of M c ). The market-clearing problem M c is robust solvable, i.e., for the p ∈ P commodities traded in the market, both the optimal contributions q ip , ∀i and the optimal prices Π p obtained, are robust against small perturbations in the parameters comprising the bids B i , ∀i ∈ I.

The proof to Corollary 2 is a direct consequence of Theorem 1. This result ensures robust outcomes from a large-scale market-clearing problem admitting hundreds (possibly thousands) of market participants and their SOC constraints. Robust solvability status of the market-clearing problem implies that numerical pathologies arising from approximations, e.g., rounding-off errors, estimation of uncertain parameters, etc. do not cause solvability-related issues.

Numerical Studies

We perform numerical experiments on a 24-node electricity system wherein the various market participants, comprising of 6 wind power producers, 9 flexible and 3 inflexible power producers (PPs), 3 identical energy storage units (ESUs) owners, and 17 inflexible consumers, are connected at the nodes as shown in Figure 2(a). The system data is adapted from [START_REF] Conejo | Decision making under uncertainty in electricity markets[END_REF] to include the wind farms and ESUs. We study the market-clearing outcomes under various renewable energy share (RES) paradigms4 , ranging from 10% to 60% of the total energy demand from consumers met by the wind power producers. The wind power producers bid at zero prices to ensure acceptance of bids, and ESU owners bid at prices lower than the cheapest flexible PP. We assume that the inflexible loads exhibit perfect inelasticity of demand, rendering the social welfare maximization problem equivalent to finding cost-minimal dispatch, in expectation, for PPs and ESUs to provide energy and flexibility services needed to meet the net demand. Here, net demand refers to the energy demand from inelastic loads reduced by the production from wind farms during the real-time operation. There is no uncertainty in the inelastic demand. The expected net demand based on the day-ahead wind power production forecasts for the 50% RES paradigm is shown in Figure 2 demand due to the high share of weather-dependent renewable energy. To highlight the impact of network congestion on spatial prices and quantities, we consider two network configurations: (i) without any network bottlenecks and (ii) with network bottlenecks induced by reducing capacities of three transmission lines of the network, shown in blue in Figure 2(a). Based on this setup, §4.1 demonstrates the uncertainty-awareness of our market-clearing proposal, followed by an analysis of the market-clearing outcomes and conic spatial equilibrium prices. In §4.2, we compare the proposed SOCP market-clearing problem with two uncertainty-aware alternatives within the LP domain. While we discuss our numerical results solely in the context of an uncertainty-aware market framework in this section, the examples provided in the Supplementary Material can be used to extend the market-clearing problem to include asset-and/or network-awareness.

SOCP-based Uncertainty-aware Energy and Flexibility Market

Recalling Example 2, we consider a chance-constrained electricity market-clearing problem wherein two commodities, energy and adjustment policies, are cleared by the system operator. Figure 1 illustrates such a two-commodity market, highlighting the day-ahead clearing and the activities during the real-time operation. The commodities are traded such that an uncertaintyaware spatial price equilibrium is achieved.

Adjustment policies as a flexibility service: Optimal adjustment policies allocated to flexibility providers enable the mitigation of uncertainty realized during the real-time operation, while lookahead decisions are made by the system operator at the day-ahead market-clearing stage. Activated during the real-time operation, these policies are in per unit and imply the contribution of each flexibility provider towards mitigating the potential real-time imbalance in the system. For example, a flexibility provider may, in the day-ahead market, be allocated a policy corresponding to 10% adjustment, implying that it contributes to mitigating 10% of any type of imbalance (either overor under-supply) during the real-time operation. Contrary to the prevalent capacity-based reserves [START_REF] González | Joint energy and reserve markets: Current implementations and modeling trends[END_REF], further discussed in §4.2, such adjustment policies when considered in a two-commodity market clearing setup, tightly couple the flexibility provider's actual operational constraints with the delivery of the flexibility service. Consequently, the flexibility procured is dimensioned optimally and can be priced dynamically, consistent with the actual flexibility needs in the electricity system [START_REF] Ratha | Exploring market properties of policy-based reserve procurement for power systems[END_REF]. First proposed by [START_REF] Warrington | Policy-based reserves for power systems[END_REF] within a robust optimization framework, such policies are preferable over capacity-based reserves since they are temporally coupled and therefore, potentially exploit the spatio-temporal correlation of forecast errors. This is highly relevant in a multi-period market setting with flexibility providers facing temporally-coupled constraints. Finally, from a practical standpoint, adopting these policies implies that in addition to payments for energy, flexibility providers are paid for their flexibility service upfront, i.e., at the day-ahead stage.

Optimal policies in a chance-constrained market: Employing chance-constrained stochastic programs to optimize the adjustment policies in contrast to scenario-based or robust stochastic programs is beneficial from an economic interpretation point of view. First, chance-constrained stochastic programs can be safely approximated by deterministic programs under mild conditions, e.g., the feasibility region formed by the inequalities is polyhedral and the adjustment policies are affine in random variables [START_REF] Nemirovski | On safe tractable approximations of chance constraints[END_REF]. Computational tractability aside, such a problem reformulation is particularly suitable for market settings since the clearing outcomes (commodity quantities and prices) are deterministic, analytically expressable, and therefore, more acceptable to market participants. Furthermore, the convex approximations become exact when the uncertainty follows a Gaussian distribution. Second, the economic properties of the market equilibrium, discussed in §3, hold not only for the expected allocations obtained but also for every realization drawn from the probability distribution underlying the system operator's uncertainty model. Referring to Example 2, this implies that, for a given choice of r ε, Theorem 4 holds for the expected value and every realization ξ drawn from the distribution P ξ characterized by mean µ and Σ [START_REF] Dvorkin | A chance-constrained stochastic electricity market[END_REF]. These advantages make chance-constrained optimization a suitable framework to incorporate uncertainty in electricity markets5 . Considering the novelty of admitting adjustment policies as opposed to the conventional flexible capacity to meet the uncertain net demand, we provide insights into the endogenous consideration of uncertainty and quantify the flexibility payments in the following. The modeling of market participants, chance-constrained market-clearing problem and its SOCP reformulation (which we refer to hereafter as M cc ) is provided in the Supplementary Material.

Impact of congestion and uncertainty on prices: The density plot in Figure 2(a) visualizes the impact of network bottlenecks on the day-ahead energy prices for hour 23 under the 50% renewable energy share paradigm. Figures 2(c) and 2(d) show the commodity prices for the network configuration without bottlenecks for the various RES paradigms. Observe that with higher shares of renewable energy, the payment made by the market operator towards flexibility increases, complementary to the gradual reduction in the energy price due to wind farms bidding with zero prices. Overall, increasing uncertainty faced at the day-ahead market-clearing stage leads to lower energy prices while the payments towards flexibility services increase, thereby resulting in the right market signals for investments in flexibility over the long run. Note that, since the adjustment polices are quantified in per unit, the hourly flexibility payments shown in Figure 2(d) correspond to total payments made by the market operator towards flexibility, adopting an allocation determined by the adjustment policies of individual flexibility providers and as such, following a differentiated pricing scheme. We now discuss the allocation of adjustment policies and provide further insights into the pricing of flexibility.

Flexibility allocation and payments: For the 50% RES paradigm, Figures 3(a)-3(f) show the optimal allocation of dispatch and adjustment policies to the PPs (f 1, f 2, . . . , f 12) and to the ESUs (s1, s2, s3) for selected hours of the day for both network configurations. First, observe that non-zero adjustment policies are only allocated to flexibility providers that are also dispatched for the commodity energy, which is consistent with the requirement that both over-and under-supply imbalances during the real-time operation are mitigated by the flexibility delivered. Second, the network configuration with bottlenecks mandates the allocation of adjustment policies to more number of flexible power producers, as network congestion is expected to impact the flexibility that the adjustment policies may take negative values, implying that the action (increasing/decreasing) production by power producers may be in opposition to the system requirement (under-/over-supply), provided it leads to cost-optimal flexibility provision under congested network conditions. Figures 3(g)-3(h) show the flexibility payments made to flexibility providers under the two network configurations. Flexibility payments are, in general, higher for the case with network bottlenecks as compared to the case without any bottlenecks. Moreover, as previously-discussed in reference to Figure 2(d), flexibility payments are higher for hours with high production from wind farms. In the short run, this incentivizes market participants to bid their flexibility in these hours.

To further analyze how flexibility is valued and paid for by the market operator, we introduce an ex-post parameter called flexibility payment rate (FPR). Defined for each flexibility provider i, FPR is the rate in $/MWh at which it is paid for the flexibility service: where [Π p ] (n i ,t) retrieves the price of the commodity flexibility service at the node n i where the participant i is located, q it and α it denote the nominal dispatch and adjustment policy allocated to the participant i, respectively. The quantity q it is the dispatch under the perfect forecast case, i.e., when the day-ahead market-clearing is deterministic. We obtain q it by solving the market-clearing problem M cc assuming day-ahead forecasts are realized perfectly during the real-time operation, such that all adjustment policies are set to zero, i.e., α it = 0, ∀t, ∀i ∈ I. Figures 3(i) -3(j) show the FPRs for the various participants for the two network configurations. Observe that, equal segments within each bar indicate equal FPRs for all flexibility providers for a given hour. First, we note that, in general, more flexibility providers being allocated non-zero adjustment policies in the network configuration with bottlenecks leads to lower FPRs for the flexibility providers contrary to the one without bottlenecks. A notable exception is hour 7 in the case without bottlenecks, wherein ESUs are paid for the flexibility at very high rate. This is a consequence of two contributing factors: (i) ESUs are dispatched with small nominal quantities in the hours 7 and 8 (see Figure 3(e)) which implies that their ability to provide both charging and discharging flexibility is valued highly, and (ii) the net demand follows a steep rise in the hours 6-8 (see Figure 2(b)) and as a result the market-clearing problem faces a scarcity of not only flexible capacity, but also the ramping ability needed to meet this change in uncertainty. In contrast, in hour 8, while the ESUs are still nominally dispatched close to zero, the flexibility is no longer scarce in the system as the net demand rises sufficiently enough to lead to the nominal dispatch of power producer f 1, thereby homogenizing the FPRs again. Overall, the FPR for a flexibility provider depends on a number of factors, including the level of uncertainty perceived by the system (quantified by the forecast error covariance matrix as well as the day-ahead forecasts), the location of the flexibility provider, congestion in the network and whether other flexibility providers are available.

FPR it = [Π p ] (n i ,t) × α it |q it -q it | , (11)
f 1 f 2 f 3 f 4 f 5 f 6 f 7 f 8 f 9 f 10 f 11 f 12 s1 s2 s3 (a) (b) (c) (d) (e) (f) (g) (h) (i) (j)

Comparison with LP-based Uncertainty-aware Benchmarks

Next, using numerical simulations corresponding to realizations of the uncertain wind power production, we compare the market-clearing outcomes and performance of the proposed SOCPbased uncertainty-aware market-clearing problem M cc to alternatives within the LP-domain.

We consider two LP-based market-clearing problems as benchmarks: R1 and R2. While it is most closely related to the currently-operational electricity markets, the deterministic marketclearing problem R1 considers uncertainty during the day-ahead clearing stage by commissioning flexibility in the form of reserve capacity. The procured capacity is subsequently activated in realtime electricity markets, cleared closer to physical delivery. To ensure a cost-optimal allocation of the reserve capacity, the market operator enforces a exogenously-determined minimum reserve requirement to procure flexible capacity from flexibility providers. Market-clearing problem R2 considers uncertainty based on day-ahead scenarios for realizations of uncertain renewable energy production. The market operator seeks to maximize the expected social welfare under uncertainty, resulting in a day-ahead schedule which is then adjusted during real-time operation for each of the foreseen scenarios. Similarly to M cc , this approach considers uncertainty endogenously as parameterized by the scenarios considered while solving the market-clearing problem. However, leaving aside the fundamental question of trusting the scenario-generating agent, this approach mandates a large number of scenarios to appropriately represent the uncertainty, thereby, limiting its practical adoption from a computational perspective. Figure 4 illustrates the market-clearing activities, starting with pre-market processing of forecast error samples to generate statistical moments (mean and covariance), to dimension the reserve requirement and to generate scenarios, for M cc , R1 and R2, respectively. In our numerical studies, we impose a minimum reserve requirement such that the probability of demand curtailment, due to unavailability of flexible capacity to be dispatched during the real-time operation, is less than 5% for the forecast error samples considered. Moreover, observe that the real-time operation in M cc does not involve pricing and can be done without re-optimization provided uncertainty bounds defined by statistical moments are reliable, whereas both R1 and R2 involve real-time markets, whose outcomes are used to price flexibility services. As with M cc , the market-clearing formulations and further details on the two reference problems R1 and R2 are provided in the Supplementary Material.

In-sample market-clearing results: First, we study the in-sample performance of the market-clearing problems. In-sample refers to the forecast samples used in the pre-market stage to obtain the parameters and scenarios for the market-clearing problems M cc and the benchmarks R1 and R2, see Figure 4. For the 6 wind farms in the network, we consider 100 forecast error samples drawn from a multivariate Gaussian distribution having zero mean and a standard deviation of 10% of the nominal day-ahead forecast values. Consequently, the safety parameter r ε is the inverse cumulative distribution function of the standard Gaussian distribution evaluated at (1ε)-quantile. For M cc , we fix the system operator's constraint violation probability at ε = 0.05. Figure 5 shows a comparison of the expected day-ahead market-clearing cost for the three market-clearing problems under the two network configurations in the various RES paradigms. Observe that, with increasing share of renewable energy, due to its exogenous consideration of uncertainty, market-clearing problem R1 performs increasingly worse compared to the other problems for both the network configurations, leading to infeasibility of market-clearing problem at 60% renewable energy share for the case with network bottlenecks. Furthermore, market-clearing problems M cc and R2 result in comparable in-sample expected cost. However, it is worth noting that, contrary to M cc , R2 does not provide any guarantees on the feasibility of market-clearing problem when faced with scenarios beyond those considered as in-sample6 . We discuss the out-of-sample performance further in the following. The first two rows in Table 1 provide a comparison for the cost and computation times of the various market-clearing problems in the 50% RES paradigm.

Out-of-sample performance:

To examine the out-of-sample performance, we perform a deterministic real-time market clearing such that the day-ahead decisions made for each of the market-clearing problems are fixed while adjustments are made in real-time to meet the uncertainty realization.

For the market-clearing problem M cc , this implies that the flexible market participants adjust their production in real-time strictly in accordance to the adjustment policies assigned at the day-ahead market-clearing stage. On the other hand, for the LP-based reference market-clearing problems R1 and R2, the adjustments in real-time are allowed up to the flexible capacity limits obtained at the day-ahead stage. Consistent with the prevalent practice on handling real-time adjustments in electricity markets, we introduce a 10% premium over the bid prices in the day-ahead market-clearing stage to incentivize the market participants to adjust their schedule during real-time operation.

Since some wind forecast scenarios may lead to infeasibility of the market-clearing problem due to unavailability of flexibility during the real-time operation, we introduce contingency actions in the market-clearing that correspond to load shedding and wind curtailment respectively. Variables corresponding to these contingency actions are penalized in the market-clearing objective such that they are the last resort in ensuring supply-demand balance. We prepare a test dataset comprised of 500 wind forecast scenarios, distinct from those used for in-sample simulations, drawn from the same multivariate Gaussian distribution. The box and whiskers plots in Figure 6 show the distribution of the resulting out-of-sample cost for the marketclearing problems under the 50% RES paradigm. For each box, the central line indicates the median, whereas the ends denote the 25th and 75th percentiles. The whiskers extend upto 1.5 times the inter-quartile range, while remaining values are shown as outliers in the form of rings. The second part of Table 1 provides the results from the out-of-sample simulations. First, referring to Figure 6, observe that the ordering in terms of expected cost is preserved from the in-sample simulations, i.e., R1 leads to higher costs. We note that market-clearing problem R2 results in highly variable out-of-sample costs compared to the SOCP market-clearing problem M cc . Second, the out-of-sample expected cost for M cc is close to the in-sample case, mentioned in Table 1. On the other hand, market-clearing problem R1 exhibits an increase in cost of 0.75% and 5.34% over their in-sample values for the network configurations with and without bottlenecks, respectively. Similarly, problem R2 results in out-of-sample expected cost which exceeds that in-sample expected cost by 3.54% and 4.1%, respectively for the network configurations with and without bottlenecks. Finally, both the LP-based market-clearing problems endure load shedding or wind curtailment when faced with unknown forecast samples. These results highlight how the proposed SOCP-based uncertainty-aware market-clearing problem outperforms the prevalent LP-based alternatives. Next, we provide comparative insights on the day-ahead market-clearing outcomes for the three problems.

Day ahead-market-clearing outcomes: For the 50% RES paradigm, Figure 7 compares the dayahead market-clearing outcomes among the three problems for the network configuration without any bottlenecks. Observe that, as expected, the energy price in Figure 7(a) closely follows the swings in net demand, shown in Figure 2(b). Figure 7(b) compares the flexibility payment at the day-ahead market-clearing stage for the problems M cc and R1. In contrast to M cc wherein flexibility payments are a result of the dual solution to the market-clearing problem, flexibility payments in R1 correspond to the primal solution, i.e., the payments made towards the reserve capacity to meet the minimum reserve requirement. The difference in hourly flexibility payments illustrate the challenge in dimensioning the capacity-based reserves properly. Note that, in absence of any specific capacity reservation or a meaningful flexibility balance at the day-ahead clearing stage, R2 mandates the real-time markets for pricing of flexibility services and is therefore omitted from the comparison7 . Figures 7(c) and 7(d) show the scheduled dispatch of PPs and ESUs, respectively, for a selection of hours of the day. On account of the minimum reserve requirement associated with market-clearing problem R1, in contrast with the other two problems which consider uncertainty endogenously, the dispatch involves higher generation in hours 7 through 12. The excess generation, which partly explains the higher market-clearing cost associated with R1, is used to charge the ESUs in the network such that sufficient flexible capacity is available to meet the minimum reserve requirement. This effect further underscores the importance of endogenous consideration of uncertainty within the market-clearing framework.

Concluding Remarks

We proposed and analyzed a new conic formulation for forward markets, which we applied to the specific case of electricity markets. Our contribution is threefold. From a market design perspective, we revisited the spatial price equilibrium problem beyond the LP framework by formulating the market-clearing problem within an SOCP framework. From a theoretical perspective, we relied on Lagrangian duality theory for SOCP problems to characterize the solution to the spatial price equilibrium problem involving rational and self-interested market participants in terms of optimality and robustness to parameter perturbation. We derived analytical expressions for conic spatial prices of the traded commodities and provided analytical proofs to demonstrate that moving towards conic markets for electricity does not incur the loss of any desired economic properties, i.e., the proposed conic market retains market efficiency, cost recovery and revenue adequacy, under common assumptions also applicable to LP-based markets. Finally, from a practitioner's perspective, we illustrated the generality of our proposed market-clearing framework by defining a bid format for conic markets.

Our conic market proposal admits SOC-representable nonlinearities underlying the costs and constraints of market participants and the system operator to enable an uncertainty-, asset-and network-aware market-clearing problem. This step in the evolution of electricity markets is crucial for the successful transition of electricity systems worldwide from dispatchable, fossil fuel-based system towards a weather-dependent, renewable energy-based system, supported by a heterogeneous mix of energy and flexibility providers. Our numerical studies leverage in-sample and out-of-sample simulations to showcase the benefits of the proposed SOCP-based market-clearing problem over the LP-based benchmarks in terms of social welfare and its invariability, endogenous representation of uncertainty, appropriate dimensioning of flexibility need, and guarantees on the feasibility of the market-clearing problem. We provide insights into payments associated with the flexibility procurement based on adjustment policies, which are central to our uncertainty-aware SOCP-based market-clearing proposal.

This paper opens up a variety of important directions for future work. First, considering the generality of the proposal, it is potentially interesting to model market-clearing use cases that involve one or more of the attributes related to uncertainty-, asset-and network-awareness. For instance, the modeling examples and the theoretical results developed in this work can be used to study the coordination between the transmission and distribution system operators in an uncertainty-and network-aware setting. This enables the flexibility available at the distribution level to be appropriately harnessed and priced within the market framework while considering a physically-accurate network constraint representation. Along similar lines is the use case studying the market-based coupling of the electricity and natural gas sectors. Here, the focus of the analysis potentially broadens from merely an optimal network-and asset-aware flexibility procurement to one that designs well-aligned incentives and risk measures to ensure a reliable and resilient system operation in both the interdependent sectors. Second, the conic market bids introduced in §2.4 merit further evaluation in terms of acceptance by market participants, alignment with market regulatory agencies as well as adaptations needed in the prevalent market-clearing algorithms to adopt them. Intended to accelerate their practical adoption, such evaluations could take shape as market simulations and participant-specific sensitivity studies to systematically quantify the costs and benefits of moving towards conic electricity markets. Third, the theoretical results discussed in the paper can be extended to include market participants that act strategically. One can then leverage conic complementarity programs to investigate how exercising market power influences the market-clearing outcomes, specifically in the context of the flexibility payments involved in uncertainty-aware use case analyzed in §4, and more generally regarding the satisfaction of desired economic properties. Further, beyond the operational economic properties analyzed in this work, it is of interest to evaluate the satisfaction of long-run equilibrium properties, such as long-run cost recovery of participants. Another important direction to pursue is the extension of the analytical results we derived on the Lorentz cone to the cone of semidefinite matrices, which results in an SDP-based market-clearing framework. Further generalization over the LP framework aside, such an extension could potentially give rise to markets that consider uncertainty under the paradigm of distributionally-robust chance-constrained optimization and that admit an SDP-based convexification approach for non-convex power flows in the electricity network. Finally, beyond the electricity system, the theoretical results in this work are of potential interest in competitive settings involving physical or non-physical systems wherein cost-and constraintbased nonlinearities currently mandate the use of approximation techniques via linearization.

Appendix A. Lagrangian Duality for SOCP Problems

In Appendix A.1, we provide a concise theoretical background of SOCP duality, while directing interested readers to Lobo et al. (1998), Ben-Tal and[START_REF] Ben-Tal | Lectures on Modern Convex Optimization[END_REF] and [START_REF] Alizadeh | Second-order cone programming[END_REF] for details. The dual problem to market-clearing problem M c is provided in Appendix A.2.

Appendix A.1. Preliminaries

Consider an arbitrary SOCP problem in variable x ∈ R N of the form

min x c x s.t. A j x + b j ≤ d j x + e j , ∀j = 1, 2, . . . , J, (A.1) with parameters c ∈ R N , A j ∈ R k j ×N , b j ∈ R k j , d j ∈ R N and e j ∈ R.
Based on (1), the SOC constraint in problem (A.1) may be expressed as

A j d j x + b j e j ∈ C j ⇔ - A j x + b j d j x + e j C j 0,
where C j ⊆ R k j +1 is the standard second-order cone and generalized inequality C j denotes a partial ordering over the cone C j . The Lagrangian function for (A.1) writes as

Θ(x, λ 1 , . . . , λ J ) = c x - J j=1 λ j A j d j x + b j e j ,
where λ j ∈ R k j +1 for j = 1, 2, . . . , J are Lagrange multipliers. The dual function is given by

g(λ 1 , . . . , λ J ) =        -J j=1 λ j b j e j , c = J j=1 A j d j λ j , -∞, otherwise.
Lastly, the dual problem to (A.1) after substituting λ j = µ j ν j , such that µ j ∈ R k j and ν j ∈ R + are auxiliary dual variables, can be written as max

µ j ,ν j - J j=1 (b j µ j + e j ν j ) (A.2a) s.t. J j=1 (A j µ j + d j ν j ) = c (A.2b) µ j ≤ ν j , ∀j = 1, 2, . . . , J. (A.2c)
Similarly, we write an arbitrary SOCP problem with rotated SOC constraints as

min x c x s.t. A j x + b j 2 ≤ d j x + e j , ∀j = 1, 2, . . . , J. (A.3)
From the definition of a rotated second-order cone (Mosek ApS, 2021), we have the equivalence

A j x + b j 2 ≤ d j x + e j ⇔ -   A j x + b j d j x + e j 1 2   C R j 0,
where C R j ⊆ R k j +2 denotes the rotated second-order cone. As before, defining Lagrange multipliers λ j = [µ j ν j κ j ] ∈ R k j +2 for j = 1, 2, . . . , J, such that µ j ∈ R k j , ν j ∈ R + and κ j ∈ R + , the Lagrangian function for the problem (A.3) can be written as

Θ(x, µ 1 , . . . , µ J , ν 1 , . . . , ν j , κ 1 , . . . , κ J ) = c x - J j=1 (µ j A j x + µ j b j + 1 2 κ j + ν j d j x + ν j e j ),
from which the dual problem is derived as max

µ j ,ν j ,κ j - J j=1 (b j µ j + e j ν j + 1 2 κ j ) (A.4a) s.t. J j=1 (A j µ j + d j ν j ) = c (A.4b) µ j 2 ≤ κ j ν j , ∀j = 1, 2, . . . , J. (A.4c) Appendix A.2. Dual Problem to Problem M c
Let D c denote the dual problem to the market-clearing problem M c . We now derive D c relying on the dualization approach in Appendix A.1. Let Θ(q i , z

i , µ Q it , κ Q it , ν Q it , µ ij , ν ij , γ i , λ p , t , t ) denote the Lagrangian function of M c given by Θ = i∈I t∈T z it + c L it q it - i∈I t∈T µ Q it C Q it q it + 1 2 κ Q it + ν Q it z it - i∈I j∈J i µ ij (A ij q i + b ij ) + ν ij (d ij q i + e ij ) + γ (F i q i -h i ) - p∈P λ p i∈I G ip q ip + t∈T   t   n∈N [Ψ] (:,n)   i∈In p∈P [G ip q ip ] t   -s   -t   n∈N [Ψ] (:,n)   i∈In p∈P [G ip q ip ] t   + s     .
For notational convenience, let cost vectors for various hours be stacked to obtain

c L i ∈ R K i T and a block diagonal matrix C Q i = C Q i1 ⊕ • • • ⊕ C Q iT ∈ R K i T ×K i T . Let µ Q i ∈ R K i T and ν Q i ∈ R T denote the stacked dual variables µ Q it and ν Q it , respectively. Let λ i ∈ R K i T
denote the stacked version of an auxiliary dual variable λ it ∈ R K i for each market participant i with its k-th element given by

λ itk = [G ip λ p ] t , if k = p, 0, otherwise. (A.5)
This auxiliary dual variable represents the contribution of each market participant towards the trades of the P commodities in the market. Finally, we define an auxiliary variable representing the i-th participant's contribution towards network congestion, denoted as it ∈ R K i , given by

itk = 1 [G ip ] (:,t) I n i Ψ ( t -t ), if k = p, 0, otherwise, (A.6)
where 1 ∈ R T and I n i ∈ R N is an indicator vector having the element corresponding to the node n i ∈ N where participant i is located as 1, while all other elements are zero. The variables it are then stacked to obtain i ∈ R K i T . With these substitutions, we write the dual problem D c as max

Ξ - i∈I j∈J i (b ij µ ij + e ij ν ij ) - i∈I t∈T 1 2 κ Q it - t∈T s ( t + t ) (A.7a) s.t. 1 -ν Q i = 0, ∀i (A.7b) c L i -C Q i µ Q i - j∈J i (A ij µ ij + d ij ν ij ) + F i γ i -λ i + i = 0, ∀i (A.7c) µ Q it 2 ≤ κ Q it ν Q it , ∀t, ∀i (A.7d) µ ij ≤ ν ij , ∀j ∈ J i , ∀i. (A.7e) (A.5) -(A.6), ∀k = 1, 2, . . . , K i , ∀t, ∀i, (A.7f) which is an SOCP problem in variables Ξ = {µ Q i , κ Q it , ν Q i , µ ij , ν ij , γ i , λ p , λ i , t , t , i }.

Appendix B. Proofs

Proof of Theorem 1

First, we prove the existence of essentially strictly feasible solutions to the market-clearing problem M c and its dual D c , inspired by the theory in [START_REF] Lobo | Applications of second-order cone programming[END_REF]. From Definition 4, finding strictly feasible solutions to the primal market-clearing problem M c reduces to finding tuples (q i , z i ), ∀i, which strictly satisfy the SOC constraints (5b)-(5c). Likewise, proving strict dual feasibility reduces to finding tuples (µ

Q it , κ Q it , ν Q it )
, ∀t, ∀i and (µ ij , ν ij ), ∀j ∈ J i , ∀i that strictly satisfy the SOC constraints (A.7d)-(A.7e), respectively. Relying on a variant of the big-M method widely applied to LP problems [START_REF] Fortuny-Amat | A representation and economic interpretation of a two-level programming problem[END_REF], we require the following auxiliary result to find strictly feasible solutions to D c . Lemma 1. Given the feasibility of the market-clearing problem M c , for each market participant i ∈ I, there exists a large enough finite scalar bound D Q i ∈ R on the Euclidean norm of q i given by q i ≤ D Q i , such that the optimal solution to M c , denoted by (q i , z i ), is unchanged with addition of the norm bounds. Proof. For each participant i ∈ I, the K i number of decision variables at each hour t constituting q it are either the commodity contributions [q ip ] t for the p ∈ P physical commodities discussed in §2.1 or any physical state variables pertaining to the participants. Hence, q it , ∀t are finite and both bounded above and below. Observe that, a bounded q it results in a bounded z it due to (5b).

Given feasible points q i , ∀i, one could arbitrarily choose scalars

D Q i such that D Q i ≥ q i ,
∀i and iteratively solve M c for values of D Q i large enough such that the optimal solution (q i , z i ), ∀i no longer changes over the subsequent iterations. Such an iterative scheme would result in the norm bounds D Q i , ∀i, thereby completing the proof.

Due to Definition 4 and Lemma 1, we write a reduced form of market-clearing problem M c while retaining only the SOC constraints with additional norm bound constraints min q i ,z i i∈I t∈T

(z it + c L it q it ) (B.1a) s.t. C Q it q it 2 ≤ z it , ∀t, ∀i :(µ Q it , κ Q it , ν Q it ) (B.1b) A ij q i + b ij ≤ d ij q i + e ij , ∀j ∈ J i , ∀i : (µ ij , ν ij ) (B.1c) q i ≤ D Q i , ∀i, : (µ i , ν i ) (B.1d)
where Lagrangian multipliers µ i ∈ R K i T and ν i ∈ R + are associated with the norm bound constraints. Following the approach in Appendix A.1, the dual problem to (B.1) in variables

Ξ R = {µ Q i , κ Q it , ν Q i , µ ij , ν ij , µ i , ν i } writes as max Ξ R - i∈I j∈J i (b ij µ ij + e ij ν ij ) - i∈I t∈T 1 2 κ Q it - i∈I D Q i ν i (B.2a) s.t. 1 -ν Q i = 0, ∀i (B.2b) c L i -C Q i µ Q i - J i j=1 (A ij µ ij + d ij ν ij ) + µ i = 0, ∀i (B.2c) µ Q it 2 ≤ κ Q it ν Q it , ∀t, ∀i (B.2d) µ ij ≤ ν ij , ∀j ∈ J i , ∀i (B.2e) µ i ≤ ν i , ∀i. (B.2f)
Proving the existence of strictly feasible points for (B.2) is straightforward. Choosing any arbitrary vectors µ ij , ∀j ∈ J i , ∀i and µ Q it , ∀t, ∀i, we can compute the values of

ν ij > µ ij and κ Q it > µ Q it , while ν Q it = 1 from (B.2b
). Now, the variable µ i follows from the equality (B.2c) and consequently, ν i can be any number larger than µ i . Hence, we have found at least one strictly feasible solution to (B.2), which proves essentially strict feasibility of the dual problem D c , given that Lemma 1 holds.

Next, we prove essentially strict feasibility of the primal market-clearing problem M c employing the so-called Phase-I method, discussed in Boyd and Vandenberghe (2004, §11.4). Consider an SOCP problem in variables (q i , z i , x i , x Q i ) where x i ∈ R and x Q i ∈ R are arbitrary slack variables min

q i ,z i ,x i ,x Q i i∈I t∈T (z it + c L it q it ) + i∈I (x i + x Q i ) (B.3a) s.t. C Q it q it 2 ≤ z it + x Q i , ∀t, ∀i (B.3b) A ij q i + b ij ≤ d ij q i + e ij + x i , ∀j ∈ J i , ∀i. (B.3c)
Observe that, obtaining strictly solutions to the primal problem (B.3) and its dual problem is straightforward. For instance, choosing

q i = 0, x i > max j∈J i b ij -e ij , ∀i, (B.4a) any z i ∈ R T + and x Q i > max t∈T -z it , ∀i, (B.4b)
gives a strictly feasible primal solution to (B.3). Likewise, a strictly feasible solution for the dual problem to (B.3) can be found by an approach (omitted from presentation, for the sake of brevity) discussed above, i.e., by adding non-binding upper bound constraints on the primal variables (x i , x Q i ), ∀i. Consequently, Alizadeh and Goldfarb (2003, Theorem 13) establishes strong duality for (B.3) due to strict primal and dual feasibility. We now provide an auxiliary result relating the augmented problem (B.3) to the primal market-clearing problem M c . Lemma 2. For the tuple (q i , z i , x i , x Q i ), ∀i denoting the optimal solution to problem (B.3), only one of the following conditions holds: (i) if x i < 0, ∀i and x Q i < 0, ∀i, then (q i , z i ), ∀i is strictly feasible for the problem M c , or (ii) if for any participant i, x i = 0 or x Q i = 0, then for that participant (q i , z i ) is strictly feasible for problem M c , provided e ij > b ij , ∀j ∈ J i and the quadratic cost components c Q it = 0, ∀t.

Proof. First, observe that if the tuple of optimal solution solution (q i , z

i , x i , x Q i ), ∀i to problem (B.
3) is such that for any i, x i > 0 or x Q i > 0, then it implies that problem M c is infeasible, which contradicts our assumption in Theorem 1. Hence, for feasibility of the problem (B.3), we have x i ≤ 0, ∀i and x Q i ≤ 0, ∀i. Now, from (B.3b) and (B.3c), it is clear that if both x i < 0, ∀i and x Q i < 0, ∀i hold, we have found (q i , z i ), ∀i which strictly satisfy the SOC inequalities in M c , i.e., (5b) and (5c). Conversely, if the optimal solution is obtained such that for any i, x i = 0 or x Q i = 0, then (q i , z i ) strictly satisfies the SOC inequalities corresponding to the i-th participant in M c under some mild conditions derived from (B.4). Note that

x Q i = 0 > max t -z it holds
true only if z it > 0, ∀t. This is ensured by non-zero quadratic cost components of the market participant i at all hours, i.e., c Q it = 0, ∀t. Moreover if any c Q it = 0, then the constraint (5b) corresponding to that hour is trivially satisfied and therefore, can be possibly eliminated. Lastly, from x i = 0 > max j∈J i b ije ij , we obtain b ije ij < 0, ∀j ∈ J i , which is then a requirement for q i = 0 from (B.4a) to be strictly feasible for (5c). This completes the proof.

From Lemma 2, solving problem (B.3) leads to (q i , z i ), ∀i that are essentially strictly feasible for M c under some mild conditions. Evident from the Examples and formulations in the Supplementary Material, these conditions are met in the practical implementations of M c . We have now proved that an essentially strictly feasible solution to primal problem M c exists.

Essentially strict feasibility of the primal and dual problems is necessary and sufficient for strong duality to hold for the primal-dual pair of problems M c and D c (Ben-Tal and Nemirovski, 2001, Theorem 1.4.4), thereby completing the proof.

Proof of Theorem 2

The proof follows from the partial Lagrangian function of M c , obtained by keeping the constraints (5b)-(5d) and relaxing the others, which we write as

Θ = - p∈P λ p i∈I G ip q ip + t∈T t   n∈N [Ψ] (:,n)   i∈In p∈P [G ip q ip ] t   -s   - t∈T t   n∈N [Ψ] (:,n)   i∈In p∈P [G ip q ip ] t   + s   .
With the substitution of the auxiliary variable Q inj p , ∀p ∈ P defined in (10) followed by a rearrangement of terms, the partial Lagrangian equivalently writes as follows

Θ = - p∈P λ p Q inj p 1 System-wide balance + t∈T t   p∈P Ψ [Q inj p ] (:,t)   - t∈T t s - t∈T t   p∈P Ψ [Q inj p ] (:,t)   - t∈T t s
Line flow limits , (B.5)

where the vector of ones 1 ∈ R N . Here, the partial Lagrangian comprises of terms corresponding to the system-wide balance equalities and the line flow limit inequalities, as indicated. In the sense of [START_REF] Bohn | Optimal pricing in electrical networks over space and time[END_REF], the spot price of electricity for consumers at a given hour is analytically expressed as the sum of shadow price of the system balance constraint and the sensitivity of changes in the demand to the flow in the capacity-constrained transmission lines. We denote these optimal prices Π p ∈ R N ×T for the p-th commodity and provide an analytical expression in the following.

We derive an expression for the spot price of commodities as the negative sensitivity of the partial Lagrangian (B.5) to the nodal injections as

∂ Θ ∂[Q inj p ] (:,t) = --1[λ p ] t + Ψ ( t -t ) , ∀p, ∀t, (B.6)
where the negative sign originates from the sign convention adopted in this work, such that the consumption (withdrawals) are given by q ip ∈ R T -. For compactness of expression, we extend (B.6) to all hours by defining auxiliary variables ρ, ρ ∈ R L×T and

Λ p ∈ R N ×T , such that ρ = [ 1 • • • T ], ρ = [ 1 • • • T ] and Λ p = 1 ⊗ λ p .
Lastly, we express the spatial prices as

Π p = Λ p -Ψ (ρ -ρ), ∀p, (B.7)
which are analogous in structure to conventional LMPs prevalent in LP-based market-clearing problems. Theorem 1 proves strong duality for the market-clearing problem M c , thereby ensuring the optimality of the spatial prices when the dual variables in (B.7) are replaced by their values at the optimal solution.

Proof of Theorem 3.

To prove the equivalence of the optimization problem M c with the equilibrium E c , we show that the KKT conditions of the equilibrium problem are identical to those of the optimization. First, for the network operator's congestion rent maximization problem (8), let Θ NO denote the Lagrangian function of the problem (8). We write the KKT conditions defining the optimal solution as • Stationarity condition:

∂Θ NO ∂y t = ω t + Ψ ( t -t ) = 0, ∀t (B.8a)
• Primal feasibility, dual feasibility and complementarity conditions:

-Ψy t ≤ s; t ≥ 0; t (Ψy t + s) = 0 (B.8b) Ψy t ≤ s; t ≥ 0; t (Ψy t -s) = 0, (B.8c)
where denotes the Hadamard (element-wise) product operator.

For each participant i ∈ I,

let Θ i (q i , z i , µ Q it , κ Q it , ν Q it , µ ij , ν ij , γ i , λ ip ) denote the Lagrangian function for problem (7) given by Θ i = p∈P tr(Π p W ip ) - t∈T z it + c L it q it - t∈T ω t p∈P [W ip ] (:,t) + t∈T ω t p∈P I n i [G ip q ip ] t + t∈T µ Q it C Q it q it + 1 2 κ Q it + ν Q it z it + j∈J i µ ij A ij q i + b ij + ν ij (d ij q i + e ij -γ i (F i q i -h i ) + λ ip G ip q ip -W ip 1 (B.9)
Using the auxiliary dual variables µ Q i , ν i and parameters c L i , C Q i defined previously in Appendix A.2, we write the KKT optimality conditions for a participant i ∈ I as • Stationarity conditions:

∂Θ i ∂q i = -c L i + C Q i µ Q i + j∈J i A ij µ ij + d ij ν ij -F i γ i + ∂ ∂q i λ ip G ip q ip + ∂ ∂q i t∈T ω t I n i p∈P [G ip q ip ] t = 0 (B.10a) ∂Θ i ∂W ip = Π p -λ ip 1 -Ω = 0, ∀p ∈ P, (B.10b) ∂Θ i ∂z i = 1 -ν i = 0 (B.10c)
where

Ω ∈ R N ×T := ω 1 ω 2 • • • ω T , such that the term t∈T ω t p∈P [W ip ] (:,t)
in the Lagrangian (B.9) reduces to tr(Ω W ip ). Furthermore, from (B.8a), we have ω t = -Ψ ( tt ) at the optimal solution. With this and from the definitions of λ i and i in (A.5) and (A.6), respectively, (B.10a) reduces to

∂Θ i ∂q i = -c L i + C Q i µ Q i + j∈J i A ij µ ij + d ij -F i γ i + λ i -i = 0 (B.10d)
Similarly, the stationarity condition (B.10b) reduces to

∂Θ i ∂W ip = Π p -λ ip 1 + Ψ (ρ -ρ) = 0, ∀p ∈ P, (B.10e)
following the definitions of auxiliary dual variables ρ and ρ in Theorem 2.

• Primal feasibility, dual feasibility and complementarity conditions:

C Q it q it 2 ≤ z it ; µ Q it 2 ≤ κ Q it ν Q it , κ Q it ≥ 0, ν Q it ≥ 0 ; µ Q it ν Q it κ Q it   C Q it q it z it 1 2   = 0, ∀t (B.10f) A ij q i + b ij ≤ d ij q i + e ij ; µ ij ≤ ν ij , ν ij ≥ 0 ; µ ij ν ij A ij d ij q i + b ij e ij = 0, ∀j ∈ J i (B.10g) F i q i = h i ; γ i free (B.10h) (A.5) -(A.6), ∀k = 1, 2, . . . , K i , ∀t, ∀i. (B.10i)
Equations (B.8), (B.10c)-(B.10i), ∀i ∈ I and (9) form the KKT optimality conditions for the equilibrium problem E c . Observe that, in addition to the primal and dual feasibility involving SOC constraints, (B.10f)-(B.10g) ensure the conic complementarity condition is met at the optimal solution (Alizadeh and Goldfarb, 2003, Theorem 16).

To see that the KKT optimality conditions for the optimization problem M c are identical to those of the equilibrium, observe that at the optimal solution: (i) λ ip , ∀i ∈ I appearing in (B.10e) are attained such that λ ip = λ p , ∀p ∈ P, ∀i ∈ I, where λ p , ∀p ∈ P corresponds to the system-wide price of the commodities. Therefore, (B.10e) provides the analytical expression for conic spatial prices as formulated in Theorem 2, and

(ii) y t , ∀t appearing in (B.8b)-(B.8c) are obtained such that y t = p∈P [Q inj p ] (:,t) , ∀t. This follows from the market-clearing condition (9a). Note that the auxiliary variable Q inj p appears in the partial Lagrangian of problem M c , as shown (B.5).

This establishes the equivalence of the KKT optimality conditions for the centrally-solved optimization problem M c and the equilibrium problem E c , thereby completing the proof.

Proof of Corollary 1

To prove existence of solutions to the competitive spatial price equilibrium problem E c , we recall Rosen (1965, Theorem 1) which provides an existence result for solutions to equilibrium problems conditioned on the convexity and compactness of each participant's strategy sets and the continuity of their payoff functions. For the market participants i ∈ I, while convexity and closure of the strategy sets are given by the feasibility region defined by equalities and non-strict inequalities (7b)-(7e), Lemma 1 proves that (q i , z i ), ∀i are bounded. Note that the quantities bought or sold by the i-th participant W ip , ∀p are bounded, conditioned on the boundedness of q i due to (7e). Consequently, the strategy sets of the participants are convex as well as closed and bounded, thereby satisfying the convexity and compactness conditions. Further, each participant's cost function (7a) is continuous in the decision variables. For the network operator, convexity and compactness of the strategy set is given due to the network limits and continuity of the payoff function is satisfied by the linear objective function in (8). Therefore, from Rosen (1965, Theorem 1), this proves that at least one solution exists for the spatial price equilibrium problem E c . To derive conditions under which at most one solution exists to problem E c , we refer to the equivalence of equilibrium problem E c to the convex market-clearing optimization problem M c established by Theorem 3. From this equivalence, the uniqueness of allocations q i , ∀i at the equilibrium relies on the strict convexity of the problem M c , which we characterize in Remark 4. However, observe that, the uniqueness of solutions to the dual market-clearing problem D c is not given due to lack of the strict convexity property of the dual objective (A.7a). Therefore, uniqueness of spatiallydifferentiated conic prices Π p , ∀p given by ( 6) is not guaranteed. This completes the proof.

Proof of Theorem 4

(i) Market efficiency: An efficient market maximizes social welfare, such that no participant unilaterally deviates from the market-clearing outcomes since each participant maximizes her profit at the optimal allocations q i and prices Π p , ∀p. Under the assumption of perfectly competitive market participants, this is given if the KKT optimality conditions of the centrally-solved optimization problem M c and equilibrium problem E c involving rational and self-interested actors are identical, which we have established in Proof of Theorem 3.

(ii) Cost recovery: Mathematically, the non-negativity of payoff for the market participants holds true, if at the optimal solution

p∈P tr(Π p W ip ) - t∈T z it + c L it q it - t∈T ω t p∈P [W ip ] (:,t) -I n i [G ip q ip ] t ≥ 0, ∀i ∈ I. (B.11)
To prove that (B.11) holds, we derive dual problems to each participant's profit maximization problem (7). The dual problem in variables

Ξ i = {µ Q i , κ Q it , ν Q i , µ ij , ν ij , γ i } writes as ∀i ∈ I                    min Ξ i j∈J i (b ij µ ij + e ij ν ij ) + t∈T 1 2 κ Q it + γ i h i s.t. (B.10c) -(B.10e) µ Q it 2 ≤ κ Q it ν Q it , ∀t µ ij ≤ ν ij , ∀j ∈ J i κ Q it ≥ 0, ν Q it ≥ 0, (B.12)
Using Lemmas 1 and 2 provided in the Proof of Theorem 1, existence of strictly feasible primal-dual solutions to the participant's profit maximization problem (7) and its dual (B.12) is established (omitted from presentation, for the sake of brevity). Consequently, from Theorem 1, strong duality holds for this primal-dual pair, thereby enforcing the primal problem (7) and its dual (B.12) to attain identical objective function values at the optimal solution. Condition (B.11) is equivalent to the non-negativity of the dual objective in (B.12) at the optimal solution, which we now analyze in the following.

Observe that, the second term of the objective function of the dual problem (B.12) is nonnegative from the primal feasibility condition κ it ≥ 0, ∀i. The first term, enclosed in parenthesis, is non-negative if e ij ≥ b ij , ∀j ∈ J i . This stems from the Cauchy-Schwarz Inequality, i.e., we have

|b ij µ ij | ≤ b ij µ ij ≤ b ij ν ij , ∀j ∈ J i ,
where the last inequality is due to the primal feasibility condition

µ ij ≤ ν ij , ∀j ∈ J i . With the condition e ij ≥ b ij , ∀j ∈ J i , we have |b ij µ ij | ≤ e ij ν ij , ∀j ∈ J i .
Under the condition e ij ≥ b ij , e ij ν ij ≥ 0 ∀j ∈ J i ; therefore, the first term in the objective is bounded below by 0. The variable γ i is free, therefore the third term in the objective is guaranteed to be non-negative if h i = 0. This completes the proof of cost recovery for the market participants i ∈ I under the conditions: (i) e ij ≥ b ij , ∀j ∈ J i , ∀i and (ii) h i = 0, ∀i.

(iii) Revenue adequacy: Mathematically, the market operator is revenue adequate if

p∈P i∈I tr(Π p W ip ) Term A - t∈T ω t y t Term B ≥ 0, (B.13)
where Term A refers to the net payments received from the i ∈ I market participants for the p ∈ P commodities and Term B refers to the payments made to the network operator towards transmission service. To reduce notational complexity, we drop the superscript denoting optimal values in the proof that follows, yet they are always implied. Using (B.6), we expand Term A and rearrange the summation operators to reflect the dependence of variables

p∈P i∈I tr(Π p W ip ) = p∈P i∈I t∈T 1[λ p ] t -Ψ ( t -t ) [W ip ] (:,t) = p∈P i∈I t∈T [λ p ] t 1 [W ip ] (:,t) - t∈T Ψ ( t -t ) p∈P i∈I [W ip ] (:,t) .
(B.14)

Gathering the equalities (7e) representing the transaction quantities with the injections (or withdrawals) for the I participants, we have W ip 1 = G ip q ip , ∀i. Since this equality holds individually for each participant, we can add them for all participants to get i∈I 1

W ip = i∈I (G ip q ip ) , such that i∈I 1 [W ip ] (:,t) = i∈I [G ip q ip ] t = 0, ∀t, (B.15)
where the second equality results from the market-clearing condition (9b) that holds at optimality. Hence, the first term in (B.14) vanishes. The second term in (B.14) is non-zero only if there is a congestion in the grid, i.e., any t = 0 or t = 0. Next, we expand Term B in (B.13), using the stationarity condition (B.8a) and the market-clearing condition (9a), as

- t∈T ω t y t = t∈T Ψ ( t -t ) p∈P [Q inj p ] (:,t) (B.16)
which is non-zero only if there is congestion in the network, i.e., the network operator earns congestion rent. We remove the summation over the hours by using the expression for the conic spatial prices given by Theorem 2 and the auxiliary variables defined therein, to rewrite Term B of (B.13) as

- t∈T ω t y t = t∈T Ψ ( t -t ) p∈P [Q inj p ] (:,t) = p∈P tr (Ψ (ρ -ρ)) Q inj p = p∈P tr (Λ p -Π p ) Q inj p .
(B.17)

Similarly, using (B.15), we rewrite Term A of (B.13) after rearrangement as

p∈P i∈I tr(Π p W ip ) = - t∈T Ψ ( t -t ) p∈P i∈I [W ip ] (:,t) = - p∈P tr (Λ p -Π p ) ( i∈I W ip ) . (B.18)
Observe that i∈I W ip sums the transaction quantities over the nodes and periods for all participants for a given commodity p, which is indeed equal to the commodity-specific net nodal injections given by (10), i.e., Q inj p = i∈I W ip , ∀p. Therefore, the terms in (B.17) and (B.18) cancel each other out, thereby satisfying the revenue adequacy condition for the market operator at the optimal solution. As a result, we have shown that there exists a budget balance for the market operator under the proposed conic market framework, i.e., the market-operator does not accrue any surplus revenue.

Moving from Linear to Conic Markets for Electricity Anubhav Ratha, Pierre Pinson, Hélène Le Cadre, Ana Virag, Jalal Kazempour This document serves as an electronic companion (EC) for the paper "Moving from Linear to Conic Markets for Electricity". In §EC.1, we provide modeling examples that illustrate how second order cone (SOC) constraints enable future electricity markets to be uncertainty-, asset-and network-aware. In §EC.2, we present the market-clearing problems of the proposed SOCP-based uncertainty-aware electricity market as well as the linear programming (LP) based market-clearing benchmarks. Numbered sections and equations throughout the electronic companion correspond to those in the paper, while a prefix 'EC.' denotes these elements within this document. Example EC.1 (Quadratic cost). Consider participant i having a quadratic cost (utility) of production (consumption), such that the cost function at each hour t is given by c it (q it ) =

EC.1. Modeling Examples

q it diag(c Q it )q it + c L it q it , where c Q it ∈ R K i and c L it ∈ R K i denote the quadratic and linear cost coeffi- cients, respectively. Let C Q it ∈ R K i ×K i be defined as a factorization of the quadratic cost matrix such that diag(c Q it ) = C Q it C Q it .
The existence of such a factorization is given since diag(c Q it ) 0, ∀t, ∀i ∈ I. The quadratic objective function of the participant i is equivalently written as min q it ,z it t∈T

z it + c L it q it (EC.1a) s.t. C Q it q it 2 ≤ z it , ∀t, (EC.1b)
where z it ∈ R + is an auxiliary variable, resulting in the linear objective function (EC.1a). The rotated SOC constraint (EC.1b) is a special form of the general SOC constraint (??), see ?.

We illustrate this for single-period market-clearing, i.e., T = 1, assuming that participant i has K i = 2 decisions variables, such that q i1 ∈ R 2 . Extending the decision vector of participant i to ec1 arXiv:2103.12122v2 [econ.TH] 4 Oct 2022 The SOC relaxation for the power flow equations ∀ = (n, n ) ∈ L is

q i = q i1 z i1 ∈ R 3 , we have the parameters A i = C Q it 0 2 , d i =
s a 2 + s r 2 ≤ θ v n (EC.2a) s a 2 + s r 2 ≤ s 2 , (EC.2b)
where s ∈ R + is a parameter denoting the rated power transfer capacity of line . Constraints (EC.2) can be reformulated as SOC constraints admitting the variables s a s r θ v n . For instance, (EC.2a) is equivalent to an SOC constraint of the general form (??) with the parameters

A =   2 0 0 0 0 2 0 0 0 0 1 -1   , b = 0 3 , d = 0 0 1 1 and e = 0,
which is a four-dimensional SOC constraint. Similarly, (EC.2b) is a three-dimensional SOC constraint with a structure similar that in Example ??.

EC.2. Market-clearing Problems

For the uncertainty-aware conic market framework proposed in the paper, we first outline the participant models in §EC.2.1, followed by the chance-constrained market-clearing problem and its reformulation as the SOCP problem M cc in §EC.2.2. In §EC.2.3 we provide formulations for the two LP-based uncertainty-aware benchmark market-clearing problems, R1 and R2. Finally, §EC.2.4 formulates the real-time market-clearing problem entailed in the out-of-sample simulation studies discussed in ??.

EC.2.1. Modeling of Market Participants

To enhance the clarity of exposition, we define subsets of market participants I comprised of flexible power producers F ⊆ I, energy storage owners S ⊆ I and inflexible consumers D ⊆ I. Let the uncertainty faced by the market-clearing problem arise from a set of weather-dependent renewable power producers W ⊆ I, such that F ∪ S ∪ D ∪ W = I and F ∩ S ∩ D ∩ W = ∅. We consider consumers to be inflexible. However, the methodology adopted in this paper is extendable to include demand-side flexibility providers.

Weather-dependent power producers: At the day-ahead stage, the stochastic power production qit ∈ R from weather-dependent power producers i ∈ W = {1, 2, . . . , W } are modeled as qit (ξ t ) = qit -ξ it , ∀i ∈ W, ∀t,

(EC.3)
where qit ∈ R is the nominal production, usually in the form of the best-available day-ahead forecast, while the random variable ξ it ∈ R is the forecast error encountered by producer i at hour t. The stochastic power production qit has an upper bound given by the rated power production capacity Q i , while being bounded below by Q i = 0. The vector ξ = ξ 11 ξ 21 . . . ξ W t . . . ξ W T ∈ R W T denotes the overall uncertainty faced by the market-clearing problem, formed by extending ξ t ∈ R W , as defined in Example ??, to a multi-period setting. We assume that ξ follows an unknown multivariate probability distribution P ξ , characterized by mean µ ∈ R W T and covariance Σ ∈ R W T ×W T , which are estimated by the system operator having an access to a finite number of historical measurement samples. Without much loss of generality, we assume the distribution P ξ to have a mean µ = 0, as any non-zero elements of the sample mean are used to update the forecast qit in (EC.3).

The structure of Σ is such that its diagonal blocks, comprised of sub-matrices, Σ t ∈ R W ×W , ∀t, capture the spatial correlation among the forecast errors at hour t, while the off-diagonal blocks contain information about spatio-temporal correlation of uncertainty 1 . The net deviation from the day-ahead forecasts realized during real-time operation at hour t is thus given by 1 ξ t ∈ R. As a sign convention, 1 ξ t > 0 implies a deficit of production from renewable energy sources during real-time operation stage as compared to the day-ahead forecast. Weather-dependent power producers are associated with a decision vector q it = qit ξ it , ∀t, ∀i ∈ W such that participation in the two commodities traded in the market is determined as follows. For the commodity energy, i.e., p = 1, the contribution is given by

q ip = qi1 qi2 . . . qi(T-1) qiT , G ip = diag(1), ∀i ∈ W,
1 Under probability distribution other than multivariate Gaussian distribution, considered in ??, the analytical approximation of chance-constrained program as a deterministic SOCP problem relies on independence of the random variables (?), i.e., the covariance matrix Σ must be modeled as a diagonal matrix, neglecting any spatio-temporal correlation.

where 1 ∈ R T . For p = 2, i.e., flexibility, the weather-dependent power producers are modeled as the uncertainty sources

q ip = 1, G ip = -    1 ξ 1 • • • 0 . . . . . . . . . 0 • • • 1 ξ T    , ∀i ∈ W,
where 1 ∈ R T and the negative sign arises from the convention adopted in (EC.3).

Flexible power producers: For each flexible power producer i ∈ F, we model the stochastic power production during real-time operation at hour t as qit (ξ t ) = qit + h it (ξ t ) , ∀i ∈ F, ∀t, (EC.4)

where qit denotes the nominal production and the function h it (ξ t ) : R W → R is the adjustment policy allocated to the market participant i, encoding its share in the recourse actions needed to mitigate the net deviation in the electricity system arising from forecast errors realized at hour t.

Typically, these adjustment policies h it (ξ t ) represent convex decision rules, which may be linear [START_REF] Georghiou | The decision rule approach to optimization under uncertainty: methodology and applications[END_REF] or generalized [START_REF] Georghiou | Generalized decision rule approximations for stochastic programming via liftings[END_REF]. In this work, we adopt adjustment policies affinely dependent on the total uncertainty faced by the system operator, such that

h it (ξ t ) = 1 ξ t α it , ∀i ∈ F, ∀t,
where α it is the adjustment policy allocated to participant i at hour t. The nominal production quantity qit and the policy α it are optimally decided by the day-ahead market-clearing program.

Recalling Example ??, we write chance constraints limiting the production from participants to their uppers limit Q i as

P ξ qit + 1 ξ t α it ≤ Q i ≥ (1 -ε), ∀t, ∀i ∈ F, (EC.5a) which is reformulated as a W + 1-dimensional SOC constraint r ε X t 1α it ≤ Q i -qit , ∀t, ∀i ∈ F, (EC.5b)
where X t ∈ R W ×W is obtained by Cholesky decomposition of the submatrix Σ t of the covariance matrix Σ such that Σ t = X t X t . Recall that the parameter r ε is a safety parameter, related to constraint violations, chosen by the system operator based on the knowledge of distribution P ξ , such that r ε increases as ε decreases. Similar reformulation is obtained for the lower bounds on the production, Q i . Apart from the production bounds, a flexible power producer may have capacity bounds on the flexibility provision, denoted by Q R i , Q R i , which are reformulated in a similar manner. Lastly, inter-temporal constraints such as the limits on the downward and upward ramping rates ∆ i , ∆ i ∈ R are modeled as

P ξ (q it + 1 ξ t α it ) -(q i(t-1) + 1 ξ t-1 α i(t-1) ) ≥ -∆ i ≥ (1 -ε), ∀t > 2, ∀i ∈ F (EC.6a) P ξ (q it + 1 ξ t α it ) -(q i(t-1) + 1 ξ t-1 α i(t-1) ) ≤ ∆ i ≥ (1 -ε), ∀t > 2, ∀i ∈ F (EC.6b)
and reformulated as 2W + 1-dimensional SOC constraints of the form

r ε X t-1:t 1 α i(t-1) -1 α it ≤ ∆ i -(q it-1 -qit ), ∀t > 2, ∀i ∈ F (EC.6c) r ε X t-1:t -1 α i(t-1) 1 α it ≤ ∆ i + (q it-1 -qit ), ∀t > 2, ∀i ∈ F, (EC.6d)
where X t-1:t ∈ R 2W ×2W denotes the factorization of the blocks of covariance matrix Σ corresponding to the spatio-temporal covariance of forecast errors in two consecutive hours. Flexible power producers participate in the conic market with decision vectors q it = qit α it , ∀t, ∀i ∈ F.

Towards the commodity energy, i.e., p = 1, flexible generators contribute as

q ip = qi1 qi2 . . . qi(T-1) qiT , G ip = diag(1), ∀i ∈ F, with 1 ∈ R T .
For the commodity flexibility (p = 2), the contribution is given by

q ip = α i1 α i2 . . . α i(T -1) α iT , G ip =    1 ξ 1 • • • 0 . . . . . . . . . 0 • • • 1 ξ T    , ∀i ∈ F.
Energy storage operators: For each energy storage unit s ∈ S, the power produced or consumed during real-time operation at hour t is given by qit (ξ t ) = qit + 1 ξ t γ it , ∀i ∈ S, ∀t, (EC.7)

where qit is the nominal production/consumption and γ it is the affine adjustment policy allocated.

We adopt the sign convention qit (ξ t ) > 0 for hours when the storage is discharging (production), while qit (ξ t ) < 0 indicates charging (consumption). In practice, energy storage units are limited by their charging and discharging capacities which are modeled using chance constraints as

P ξ qit + 1 ξ t γ it ≤ η D i Q D i ≥ (1 -ε), ∀t, ∀i ∈ S (EC.8a) P ξ qit + 1 ξ t γ it ≥ - 1 η C i Q C i ≥ (1 -ε), ∀t, ∀i ∈ S (EC.8b)
and are reformulated as W + 1-dimensional SOC constraints as

r ε X t 1γ it ≤ η D i Q D i -qit , ∀t, ∀i ∈ S (EC.8c) r ε X t 1γ it ≤ 1 η C i Q C i + qit , ∀t, ∀i ∈ S, (EC.8d)
where η D i , η C i ∈ [0, 1] are energy conversion factors representing discharging and charging efficiencies, while

Q D i , Q C i ∈ R are,
respectively, the maximum discharging and charging capacities of the energy storage unit i ∈ S. Inter-temporal constraints are critical for energy storage units to ensure that (i) the storage operation trajectory remains within the limits of state of charge, and (ii) the storage unit is neither depleted nor over-charged at the end of market-clearing horizon. While the former ensures safe operation of the storage unit within its operational limits, the latter is relevant in a market-clearing setup where the storage unit is expected to provide flexibility to the grid on an ongoing basis. Figure EC.1 shows the trajectory (in red) of energy content of a storage unit. At each hour, the changes to energy content due to production (discharging) or consumption (charging) by the storage unit is given by qit (ξ t ), with the rate of change being limited by the charging and discharging power limits in (EC.8). The energy content of a storage unit evolves as

P ξ E 0 i - t t =1 (q it + 1 ξ t γ it ) ≤ E i ≥ (1 -ε), ∀t, ∀i ∈ S (EC.9a) P ξ E 0 i - t t =1 (q it + 1 ξ t γ it ) ≥ E i ≥ (1 -ε), ∀t, ∀i ∈ S, (EC.9b)
which are reformulated as W × t + 1, ∀t-dimensional SOC constraints, expressed as

r ε X 1:t 1 γ i1 1 γ i2 • • • 1 γ it ≤ E i -E 0 i + t t =1 qit , ∀t, ∀i ∈ S (EC.9c) r ε X 1:t 1 γ i1 1 γ i2 • • • 1 γ it ≤ E 0 i -E i - t t =1
qit , ∀t, ∀i ∈ S, (EC.9d)

where E 0 i ∈ R is the energy content at t = 0 and E i , E i ∈ R are the minimum and maximum energy storage capacity of the storage unit, respectively, such that

E 0 i ∈ [E i , E i ]. Furthermore, to
ensure the ongoing market-participation of the storage unit, we utilize the concept of end-of-horizon energy neutrality. We define lower and upper bounds, B i , B i ∈ R respectively, around the initial energy stored E 0 i to reflect the preference of the energy storage owner on the energy content at the end of market-clearing horizon, see Figure EC.1. This ensures the end-of-horizon energy content to be within [E 0 i -B i , E 0 i + B i ]. These preferences are captured through chance constraints

P ξ E 0 i - T t =1 (q it + 1 ξ t γ it ) ≤ E 0 i + B i ≥ (1 -ε), ∀i ∈ S (EC.10a) P ξ E 0 i - T t =1 (q it + 1 ξ t γ it ) ≥ E 0 i -B i ≥ (1 -ε), ∀i ∈ S (EC.10b)
which are reformulated as W × T + 1-dimensional SOC constraints, expressed as

r ε X 1:T 1 γ i1 1 γ i2 • • • 1 γ iT ≤ B i + T t =1 qit , ∀i ∈ S (EC.10c) r ε X 1:T 1 γ i1 1 γ i2 • • • 1 γ iT ≤ B i - T t =1
qit , ∀i ∈ S.

(EC.10d)

Each energy storage operators participates in the conic market with a decision vector q it = qit γ it , ∀t, ∀i ∈ S. Likewise, towards the commodity energy, i.e., p = 1, we have

q ip = qi1 qi2 . . . qi(T-1) qiT , G ip = diag(1), ∀i ∈ S,
with 1 ∈ R T . For the commodity flexibility (p = 2), the storage unit contributes to the trades as

q ip = γ i1 γ i2 . . . γ i(T -1) γ iT , G ip =    1 ξ 1 • • • 0 . . . . . . . . . 0 • • • 1 ξ T    , ∀i ∈ S.
Inflexible consumers: For each inflexible consumer d ∈ D, the power consumed during realtime operation at hour t is given by qit (ξ t ) = qit , ∀i ∈ D, ∀t, where qit ∈ R -is the power demand by consumer d ∈ D. The above modeling can be extended to include flexible consumers that may respond to the uncertainty by reducing/increasing their consumption based on an affine adjustment policy, similar to flexible generators and energy storage units. However, for clarity of exposition, this paper is restricted to modeling inflexible and perfectly inelastic demand. Each consumer contributes towards the trades of commodity energy, i.e., for p = 1, as

q ip = qi1 qi2 . . . qi(T-1) qiT , G ip = diag(1), ∀i ∈ D,
where 1 ∈ R T . Lastly, for p = 2, considering inflexible consumers, we have q ip = 0, G ip = 0, ∀i ∈ D.

EC.2.2. Chance-constrained Market Clearing

In the following, we formulate the chance-constrained market-clearing problem in stochastic optimization variables qit (ξ t ), ∀i ∈ I which are functions of the random variable ξ t . We drop this dependency for notational convenience, yet it is always implied.

min

qit E P ξ i∈I\D t∈T c Q it q2 it + c L it qit (EC.11a) s.t. P ξ i∈I G ip qip = 0 T , ∀p ∈ P, a.s.
= 1, (EC.11b)

P ξ                           Q i ≤ qit ≤ Q i , ∀t, ∀i ∈ F ∪ W -Q R i ≤ h it (ξ t ) ≤ Q R i , ∀i ∈ F -∆ i ≤ qit -qi(t-1) ≤ ∆ i , ∀t > 2, ∀i ∈ F - 1 η C i Q C i ≤ qit ≤ η D i Q D i , ∀t, ∀i ∈ S E i ≤ E 0 i - t t =1 qit ≤ E i , ∀t, ∀i ∈ S E 0 i -B i ≤ E 0 i - T t =1 qit ≤ E 0 i + B i , ∀i ∈ S -s ≤ n∈N [Ψ] ( ,n) i∈In p∈P [G ip qip ] t ≤ s , ∀t, ∀ ∈ L                           ≥ 1 -ε, (EC.11c)
where the objective function (EC.11a) minimizes the expected cost, which is equivalent to minimizing negative social welfare when facing an inflexible and perfectly inelastic demand. The almost sure (a. s.) constraint (EC.11b) ensures the satisfaction of the supply-demand balance constraint for both commodities with a probability of 1, whereas the chance constraint (EC.11c) ensures the inequalities are jointly met with a probability of (1ε). The prescribed constraint violation probability ε ∈ (0, 1) reflects risk tolerance of the system operator towards the violation of technical limits of the system and in our numerical studies discussed in ??, we set ε = 0.05. The chance-constrained market-clearing problem (EC.11) is computationally intractable since it involves infinitely many constraints arising from the uncertain production from weather-dependent power producers. We gain tractability by expressing the stochastic variables qit , ∀i, ∀t as affine, finite-dimensional functions of the random variable ξ as discussed in the previous section, resulting in an approximate solution to the infinite-dimensional problem. In the following, we discuss the reformulations to reach the final tractable SOCP-based chance-constrained market-clearing problem.

Reformulation of joint chance constraint: Observe that (EC.11c) models a joint violation of the constraints, in contrast to the individual chance constraints discussed so far. In this paper, following the Bonferroni approximation of joint chance constraints (Xie et al. 2019), we adopt a consideration of individual chance constraints with the analytical parameterization of risk. Let N ineq denote the number of individual inequalities forming the joint chance constraint (EC.11c), such that ε ∈ R N ineq + collects all the individual violation probabilities for the inequality constraints.

The Bonferroni reformulation of joint chance constraint mandates that the individual constraint violation probabilities be chosen such that 1 ε ≤ ε. Furthermore, this approach provides a joint constraint feasibility guarantee even if the choice of individual probabilities is done trivially, e.g., ε

is chosen such that εk = ε N ineq , ∀k = 1, 2, . . . , N ineq . We compute the individual constraint violation probabilities in this manner and adopt the SOC reformulation techniques for individual chance constraints discussed so far.

Reformulation of almost sure constraint:

The almost sure constraint (EC.11b) must be held at the optimal solution to (EC.11) with a probability of 1. Considering the affine dependency of the stochastic decision variables qit , ∀i, ∀t with respect to the random variables ξ t , this amounts to a separation of (EC.11b) into nominal and recourse equalities. Corresponding to the two commodities energy and flexibility, these equalities are given by i∈I

G ip q ip = 0, p = 1 (EC.12a) i∈I\(W∪D) diag(1)q ip = 1, p = 2. (EC.12b)
Power flow limits: Apart from the participant-specific chance constraints discussed so far, the constraints limiting the power flows in the network are

P ξ n∈N [Ψ] ( ,n) i∈In p∈P [G ip qip ] t ≤ s ≥ 1 -ε, ∀t, ∀ ∈ L (EC.13a) P ξ n∈N [Ψ] ( ,n) i∈In p∈P [G ip qip ] t ≥ -s ≥ 1 -ε, ∀t, ∀ ∈ L, (EC.13b)
which require tractable reformulations. In the following, we illustrate the reformulation of (EC.13a) as an SOC constraint and adopt a similar approach for the other flow direction. First, we rewrite (EC.13a) such that nominal and uncertainty-dependent terms are separable. To that end, we define auxiliary network matrices Ψ F ∈ R N ×|F | , Ψ S ∈ R N ×|S| , Ψ W ∈ R N ×W and Ψ D ∈ R N ×|D| which map the flexible power producers, energy storage units, weather-dependent power producers and consumers, respectively, to the electricity network nodes. We collect all commodity contributions by participant groups at a given hour by defining auxiliary variables qF t , qF t , α t ∈ R |F | to denote the stochastic production, nominal production and the adjustment policies for the flexible power producers, qS t , qS t , γ t ∈ R |S| to denote stochastic production, nominal production and adjustment policies for the storage units, qW t ∈ R W for the forecasted production from weather-dependent Objective function reformulation: We decompose the objective (EC.11a) among the various participants and expand the stochastic term to its nominal and recourse values to obtain

E P ξ i∈F t∈T c Q it (q it + 1 ξ t α it ) 2 + c L it (q it + 1 ξ t α it ) Term A + i∈S t∈T c Q it (q it + 1 ξ t γ it ) 2 + c L it (q it + 1 ξ t γ it ) Term B + i∈W t∈T c Q it (q it -ξ it ) 2 + c L it (q it -ξ it ) Term C
.

Linearity of the expectation operator allows us to separate the cost terms and we rewrite the cost of flexible generators, i.e., Term A as

i∈F t∈T c Q it q2 it + c Q it E P ξ [(1 ξ t ) 2 ]α 2 it + 2q it c Q it E P ξ [1 ξ t ]α it + c L it qit + c L it E P ξ [1 ξ t ]α it .
The zero-mean assumption made on ξ t factors out the terms last two terms under the expectation operator. As discussed in [START_REF] Bienstock | Chance-constrained optimal power flow: Risk-aware network control under uncertainty[END_REF], the first term under expectation operator can be reformulated as the variance of ξ t , i.e., E P ξ [(1 ξ t ) 2 ] = var(1 ξ t ) = 1 Σ t 1, where Σ t is the covariance matrix as previously discussed. Therefore, the Term A reduces to

i∈F t∈T c Q it q2 it + c Q it 1 Σ t 1α 2 it + c L it qit .
Lastly, following Example EC.1, we reformulate the quadratic cost terms as a rotated SOC constraint in the interest of analytical and computational appeal. Introducing variables z q it ∈ R and z α it ∈ R, for any fixed values of qit and α it , Term A of the objective function retrieves the expected cost by solving the following SOCP problem min z q it ,z α it i∈F t∈T z q it + z α it + c L it qit (EC.16a)

s.t. (c Q it )
1 2 qit 2 ≤ z q it , ∀t, ∀i ∈ F (EC.16b)

X t 1(c Q it ) 1 2 α it 2 ≤ z α it , ∀t, ∀i ∈ F. (EC.16c)
Term B of the objective function characterizing the cost of operation of energy storage units follows a similar reformulation. For the set of wind power producers, i.e., the cost in Term C, we use the following equivalence to eliminate the expectation operator

i∈W t∈T c Q it q2 it + c Q it E P ξ [ξ 2 it ] + c L it qit ⇔ i∈W t∈T c Q it q2 it + c Q it tr[Σ t ] + c L it qit .
The quadratic term in the expression is then reformulated as a rotated SOC constraint as before.

The term c Q it tr[Σ t ] is a cost term that is constant, depending on the historical forecast error samples. Adopting the reformulations of the objective function and the chance constraints, we obtain the final tractable chance-constrained market-clearing problem M cc . Solved centrally by the system operator, the problem M cc is an SOCP problem that results in optimal market-clearing quantities and prices for both the commodities traded in the market, i.e., energy and flexibility. min ≤ z q it , ∀t, ∀i ∈ I \ D (EC.17b)

V
X t 1(c Q it ) 1 2 α it 2 ≤ z α it , ∀t, ∀i ∈ F (EC.17c) X t 1(c Q it ) 1 2 γ it 2 ≤ z γ it , ∀t, ∀i ∈ S (EC.17d) r ε X t 1α it ≤ Q i -qit , ∀t, ∀i ∈ F (EC.17e) r ε X t 1α it ≤ qit -Q i , ∀t, ∀i ∈ F (EC.17f) r ε X t 1α it ≤ Q R i , ∀t, ∀i ∈ F (EC.17g) r ε X t 1α it ≤ Q R i , ∀t, ∀i ∈ F (EC.17h)
r ε X t-1:t -1 α i(t-1) l 1 α it ≤ ∆ i + (q it-1qit ), ∀t > 2, ∀i ∈ F (EC.17i) r ε X t-1:t 1 α i(t-1) -1 α it ≤ ∆ i -(q it-1qit ), ∀t > 2, ∀i ∈ F (EC.17j)

r ε X t 1γ it ≤ η D i Q D i -qit , ∀t, ∀i ∈ S (EC.17k) r ε X t 1γ it ≤ 1 η C i Q C i + qit , ∀t, ∀i ∈ S (EC.17l) r ε X 1:t 1 γ i1 1 γ i2 • • • 1 γ it ≤ E i -E 0 i + t t =1
qit , ∀t, ∀i ∈ S (EC.17m)

r ε X 1:t 1 γ i1 1 γ i2 • • • 1 γ it ≤ E 0 i -E i - t t =1
qit , ∀t, ∀i ∈ S (EC.17n)

r ε X 1:T 1 γ i1 1 γ i2 • • • 1 γ iT ≤ B i + T t =1
qit , ∀i ∈ S (EC.17o)

r ε X 1:T 1 γ i1 1 γ i2 • • • 1 γ iT ≤ B i - T t =1
qit , ∀i ∈ S (EC.17p) i∈I G ip q ip = 0, p = 1 (EC.17q) i∈I\(W∪D)

diag(1)q ip = 1, p = 2 (EC.17r) Day-ahead market-clearing problem R1 a :

r ε X t [Ψ(Ψ F α t 1 + Ψ S γ t 1 -Ψ W )]
min q DA ity ,q R it i∈I\D t∈T y∈Y c Y ity q DA ity + i∈F ∪S t∈T c R it q R it (EC.18a) s.t. 0 ≤ q DA ity ≤ 1 Y (Q i -Q i )
, ∀y, ∀t, ∀i ∈ I \ D (EC.18b)

Q i ≤ y∈Y q DA ity ≤ Q i , ∀t, ∀i ∈ F ∪ W (EC.18c) Q i ≤ y∈Y q DA ity + q R it ≤ Q i , ∀t, ∀i ∈ F (EC.18d)
-∆ i ≤ y∈Y (q DA ityq DA i(t-1)y ) ≤ ∆ i , ∀t > 2, ∀i ∈ F (EC.18e) ( y∈Y q DA it y + q R it ) ≤ E i , ∀t, ∀i ∈ S (EC.18h)

- 1 η C i Q C i ≤ y∈Y q DA ity ≤ η D i Q D i , ∀t, ∀i ∈ S (EC.18f) - 1 η C i Q C i ≤ y∈Y q DA ity + q R it ≤ η D i Q D i ,
E 0 i -B i ≤ E 0 i - t t =1
( y∈Y q DA it y + q R it ) ≤ E 0 i + B i , ∀i ∈ S (EC.18i)

0 ≤ q R it ≤ Q R i , ∀t, ∀i ∈ F ∪ S (EC.18j) i∈I y∈Y
q DA ity = 0, ∀t (EC.18k)

i∈F ∪S q R it ≥ M R , ∀t (EC.18l) -s ≤ n∈N [Ψ] ( ,n) i∈In y∈Y
q DA ity ≤ s , ∀t, ∀ ∈ L, (EC.18m)

where the parameter M R is the exogenously-determined minimum reserve requirement set by the system operator. Next, closer to real-time the following flexibility activation problem is solved for each uncertainty realization, denoted by ξ.

Real-time flexibility activation problem, R1 b , ∀ ξ:

min q RT ity i∈I\D t∈T y∈Y c Y ity q RT ity + i∈W c spill q RT it - i∈D c shed q RT it (EC.19a) s.t. - q R it Y ≤ q RT ity ≤ q R it Y
, ∀y, ∀t, ∀i ∈ F ∪ S (EC.19b) where (q DA ity , q R it ) = argmin R1 a are day-ahead dispatch and reserve capacity, respectively.

-q R it ≤ y∈Y q RT ity ≤ q R it ,
Scenario-based market framework: The scenario-based stochastic market-clearing problem R2 is a two-stage problem. The first stage involves the day-ahead schedules as a result of the socalled here-and-now decisions, whereas the second stage adjusts the day-ahead schedules with realtime adjustments to mitigate the uncertainty from weather-dependent power producers (wait-andsee). The adjustment decisions for real-time stage are already included in the day-ahead marketclearing problem by considering a finite number of uncertainty realization scenarios, anticipating that the actual power production is captured in the scenarios considered. Like with R1, we adopt a linear approximation of the quadratic costs to remain within the LP framework. In the following, we provide a concise formulation for this benchmark.

Q i ≤ y∈Y q DA ity ≤ Q i , ∀t, ∀i ∈ F ∪ W (EC.20c) -∆ i ≤ y∈Y (q DA ity -q DA i(t-1)y ) ≤ ∆ i , ∀t > 2, ∀i ∈ F (EC.20d) - 1 η C i Q C i ≤ y∈Y q DA ity ≤ η D i Q D i , ∀t, ∀i ∈ S (EC.20e) E i ≤ E 0 i - t t =1 y∈Y
q DA it y ≤ E i , ∀t, ∀i ∈ S (EC.20f)

E 0 i -B i ≤ E 0 i - T t =1 y∈Y q DA it y ≤ E 0 i + B i ,
- Q R i Y ≤ p RT itky ≤ Q R i
Y ∀y, ∀k, ∀t, ∀i ∈ F ∪ S (EC.20j)

-Q R i ≤ y∈Y p RT itky ≤ Q R i , ∀k, ∀t, ∀i ∈ F ∪ S (EC.20k) -Q i ≤ y∈Y (p DA ity + p RT itky ) ≤ Q i , ∀k, ∀t, ∀i ∈ F ∪ W (EC.20l) - 1 η C i Q C i ≤ y∈Y (q DA ity + q RT itky ) ≤ η D i Q D i
, ∀k, ∀t, ∀i ∈ S (EC.20m)

E i ≤ E 0 i -( t t =1 y∈Y
(q DA it y + q RT it ky )) ≤ E i , ∀t, ∀i ∈ S (EC.20n)

E 0 i -B i ≤ E 0 i -( t t =1 y∈Y
(q DA it y + q RT it ky )) ≤ E 0 i + B i , ∀k, ∀i ∈ S (EC.20o) i∈I y∈Y

q RT itky = 0, ∀k, ∀t (EC.20p)

-s ≤ n∈N [Ψ] ( ,n)
i∈In y∈Y (q DA ity + q RT itky ) ≤ s , ∀k, ∀t, ∀ ∈ L (EC.20q)

EC.2.4. Out-of-sample simulations

Out-of-sample simulations are performed to evaluate the quality of the day-ahead market-clearing outcomes by fixing the decisions obtained at the day-ahead stage to their optimal values and solving a real-time flexibility activation problem. For the proposed conic market framework, the out-ofsample problem (EC.21) formulated in the following admits fixed day-ahead decisions (q it , α it , γ it ) obtained from the solution to M cc . For the LP-based benchmark problems, we use q it = y∈Y q DA ity from the solution to R1 a for the deterministic benchmark problem and q it = y∈Y q DA ity from the solution to R2 for the scenario-based stochastic benchmark problem. We have, ∀ ξ :

min q RT it i∈I\(D∪W) t∈T c Q it (q it + q RT it ) 2 + c L it (q it + q RT it ) + i∈W c spill q RT it + i∈D c shed q RT it (EC.21a) s.t. Q i ≤ q it + q RT it ≤ Q i , ∀t, ∀i ∈ F (EC.21b) -∆ i ≤ q it + q RT it ≤ ∆ i , ∀t > 1, ∀i ∈ F (EC.21c) - 1 η C Q C i ≤ q it + q RT it ≤ η D Q D i , ∀t, ∀i ∈ S (EC.21d) E i ≤ E 0 i -( t t =1
q it + q RT it ) ≤ E i , ∀t, ∀i ∈ S (EC.21e)

E 0 i -B i ≤ E 0 i -( t t =1
q it + q RT it ) ≤ E 0 i + B i , ∀i ∈ S (EC.21f) 0 ≤ q RT it ≤ qit -ξ it , ∀t, ∀i ∈ W (EC.21g)

-qit ≤ q RT it ≤ 0, ∀t, ∀i ∈ D (EC.21h)

-Q R i ≤ q RT it ≤ Q R i , ∀t, ∀i ∈ F ∪ S (EC.21i) i∈I\W q RT it = 1 ξ t + i∈W q RT it , ∀t (EC.21j) -s ≤ n∈N [Ψ] ( ,n) i∈In q it + q RT it ≤ s , ∀t, ∀ ∈ L (EC.21k)
For M cc , these additional constraints restrict the real-time adjustments:

q RT it = 1 ξ t α it , ∀t, ∀i ∈ F ; q RT it = 1 ξ t γ it , ∀t, ∀i ∈ S.

(EC.21l)

Figure 1 :

 1 Figure 1: Illustration of commodities traded in an uncertainty-aware electricity market

Figure 2 :

 2 Figure 2: (a) 24-node electricity network showing a visualization of spatial prices of energy for the network configuration with bottlenecks, (b) expected net demand for the 50% RES paradigm, (c) system-wide prices for energy and (d) the total hourly flexibility payments for various RES paradigmsdelivery during real-time operation. However, note that ESUs are not allocated adjustment policies in this configuration. This is explained by (i) the availability of flexible PPs in favorable locations of the network with respect to congested power lines, and (ii) the inter-temporal constraints and end-of-day energy balance requirement for ESUs (see Supplementary Material). Indeed, for the paradigm with 60% RES (not shown in the Figure), ESUs in the case with network bottlenecks are allocated non-zero adjustment policies to contribute towards flexibility provision, with the marketclearing problem choosing a more expensive flexibility allocation, offset by the reduced cost of energy provision. Finally, observe in Figure3(b) that the adjustment policies may take negative values, implying that the action (increasing/decreasing) production by power producers may be in opposition to the system requirement (under-/over-supply), provided it leads to cost-optimal flexibility provision under congested network conditions.Figures3(g)-3(h) show the flexibility payments made to flexibility providers under the two network configurations. Flexibility payments are, in general, higher for the case with network bottlenecks as compared to the case without any bottlenecks. Moreover, as previously-discussed in reference to Figure2(d), flexibility payments are higher for hours with high production from wind farms. In the short run, this incentivizes market participants to bid their flexibility in these hours.To further analyze how flexibility is valued and paid for by the market operator, we introduce an ex-post parameter called flexibility payment rate (FPR). Defined for each flexibility provider i, FPR is the rate in $/MWh at which it is paid for the flexibility service:

Figure 3 :Figure 4 :

 34 Figure 3: Market-clearing outcomes in hours 4-12: (a)-(b) show the adjustment policies, (c)-(f) show the nominal dispatch of power producers (PPs) and energy storage units (ESUs) for both the network configurations, and (g)-(h) show the flexibility payments and (i)-(j) show the flexibility payment rates (FPRs)

Figure 5 :

 5 Figure 5: In-sample market-clearing cost in the various RES paradigms considered

Figure 7 :

 7 Figure 7: Day-ahead market-clearing outcome for various problems: (a) hourly system-level energy price, (b) hourly flexibility payment, (c) dispatch of power producers (PPs) and (d) dispatch of energy storage units (ESUs)

  In addition to the examples discussed in the paper, this section demonstrates the versatility of SOC constraints in modeling the various asset-and network-related nonlinearities faced by electricity markets. While Example EC.1 covers the general case of including participants with quadratic costs in electricity markets, Example EC.2 demonstrates the network-awareness of the market framework proposed in the paper by showing how it can be extended to include the SOCP relaxation of nonlinear and non-convex power flow equations.

  0 0 1 , while b i = 0 2 and e i = 0, resulting in a three-dimensional rotated SOC constraint, i.e., m i = 2.Example EC.2 (Electricity network). Known as the branch flow model[START_REF] Farivar | Branch flow model: Relaxations and convexification-Part I[END_REF], the SOCP relaxation of power flow equations is exact for the distribution networks that exhibit a radial graph structure under mild conditions. The power flow equations model the nonlinear relation of active and reactive power transported along a line with the current and terminal node voltages. While active power is the actual quantity in MWh of power produced or consumed, reactive power is a necessary component oscillating within the network and regulates voltage across the nodes. Consider a power line = (n, n ) ∈ L connecting adjacent nodes n, n ∈ N . Let s a ∈ R and s r ∈ R denote the active power and reactive power; θ ∈ R + and v n ∈ R + denote the squared magnitude of current flow in the line and the squared voltage magnitude at the node n, respectively.

  e-companion toRatha et al.: Moving from Linear to Conic Markets for Electricity ec3

  EC.2.3. LP-based market-clearing benchmarksIn the following, we concisely formulate the two reference uncertainty-aware benchmarks within the LP framework. To account for the quadratic costs of market participants in an LP problem, we perform a piecewise linear approximation of the cost by discretizing the production quantities into a set of bins given by Y = {1, 2, . . . , Y }.Deterministic two-stage market framework: In the deterministic market-clearing problem R1, the system operator procures energy and flexibility (in the form of reserve capacity) in the day-ahead market. Thereafter, during real-time operation stage, via another market-clearing mechanism, the reserves are activated based on the allocation capacity bounds cleared during the day-ahead market. This two-stage deterministic market-clearing problem is a natural uncertaintyaware extension of currently-operational electricity markets.

  -Q i ), ∀y, ∀t, ∀i ∈ I \ D (EC.20b)

Table 1 :

 1 In-sample and out-of-sample performance of market-clearing problems for the 50% RES paradigm

	Parameter In-sample expected cost		No network bottlenecks M cc R1 R2 $1000 221.85 257.85 216.49 256.62 377.56 With network bottlenecks Unit M cc R1 R2 235.16
	Market-clearing computation time	s	2.08	0.22	178.23	2.38	0.27	215.5
	Out-of-sample expected cost	$1000 221.76 259.57 224.29 256.51 396.86	244.28
	Out-of-sample infeasibility	%	0.2	3.2	0	0.2	0.6	8.8
	Load shedding probability	%	0	0	0	0	1.0	0.4
	Wind curtailment probability	%	0	0	46.0	0	0	50.8
	Out-of-sample cost (k$)	250 300 350 400					M cc R1 R2
		200
		No bottlenecks		With bottlenecks
			Network configuration
	Figure 6: Out-of-sample market-clearing cost comparison in the 50% RES paradigm

  -companion to Ratha et al.: Moving from Linear to Conic Markets for Electricity

				ec5
				E i
			E it
		i E 0	qit	B i
				B i
				E i
		1 2	t	T
	Figure EC.1	Illustration of the operation of an energy storage unit for flexibility provision.

e

  power producers and lastly, qD t ∈ R |D| for the inflexible demand from consumers. With that, we rewrite (EC.13a) asP ξ [Ψ(Ψ F qF t + Ψ S qS t + Ψ W (q W tξ t ) + Ψ D qD t )] ≤ s ≥ 1ε, ∀t, ∀ ∈ L, (EC.14)which we then reformulate as an SOC constraint after separating the nominal and uncertaintydependent terms. The final SOC reformulation for (EC.13a) results in ∀t, ∀ ∈ L,r ε X t [Ψ(Ψ F α t 1 + Ψ S γ t 1 -Ψ W )] ( ,:) ≤ s -[Ψ(Ψ F qF t + Ψ S qS t + Ψ W qW t + Ψ D qD t )] .(EC.15)

  opt ,V aux i∈I\D t∈T

				z qit it + c L it qit +	z α it +	z γ it +	c Q it tr[Σ t ]	(EC.17a)
				i∈F t∈T	i∈S t∈T	i∈W t∈T
	s.t.	(c Q it )	2 qit 1	2

  ( ,:) ≤ s -[Ψ(Ψ F qF t + Ψ S qS t + Ψ W qW t + Ψ D qD t )] , ∀t, ∀ ∈ L (EC.17s) r ε X t [Ψ(Ψ F α t 1 + Ψ S γ t 1 -Ψ W )] ( ,:) ≤ s + [Ψ(Ψ F qF t + Ψ S qS t + Ψ W qW t + Ψ D qD t )] , ∀t, ∀ ∈ L, (EC.17t)where the set of optimization variables isV opt = {q it , z qit it , α it , z αit it , γ it , z γit it }and the set of auxiliary variables is V aux = {q ip , qF t , α t , qS t , γ t , qW t , qD t }, formed as previously discussed.

  ∀t, ∀i ∈ S (EC.18g) e-companion to Ratha et al.: Moving from Linear to Conic Markets for Electricity

		ec13
		t
	E i ≤ E 0 i -	t =1

Beyond the SOCP framework, semidefinite programming (SDP) which operates on the cone of semi-definite matrices instead of the Lorentz cone, allows for further broadening of the scope of the market-clearing, albeit at the cost of a higher computational burden. Our theoretical results and their proofs build on Lagrangian duality involving generalized inequalities, which lay the foundation for an SDP-based market framework in future.

When the random forecast errors ξ are assumed to be normally distributed, the safety parameter r ε is given by the inverse cumulative distribution function of the standard Gaussian distribution evaluated at (1ε)-quantile[START_REF] Nemirovski | Convex approximations of chance constrained programs[END_REF]. Dropping the assumption of normality, a more conservative choice of r ε is obtained based on the so-called moment-based distributionally-robust chance constraints[START_REF] Wagner | Stochastic 0-1 linear programming under limited distributional information[END_REF], which considers the distribution Pξ to lie inside an ambiguity set of all probability distributions characterized by the empirically-estimated moments µ and Σ. In that case, the safety parameter r ε = 1-ε ε . A further generalization that considers even the moments of distribution P ξ to lie in well-defined uncertainty sets such as ellipsoids[START_REF] Delage | Distributionally robust optimization under moment uncertainty with application to datadriven problems[END_REF], lead to a semidefinite constraint instead of the SOC constraint in (3b), leading to a SDP-based market-clearing problem.

Recently,[START_REF] Krebs | Uniqueness and multiplicity of market equilibria on DC power flow networks[END_REF] provided conditions on network connectivity, PTDF matrix parameters, and the specific structure of participants' cost functions under which unique allocations are obtained at market equilibrium with linear constraints. Further research in similar directions is needed to study such conditions for the proposed SOCP-based market.

These paradigms are derived by suitably varying the installed capacity of the wind farms while dimensioning the ESUs such that the total available charging/discharging capacity remains fixed at 12.5% of the total wind farm installed capacity. Such dynamic dimensioning of storage-related flexibility is crucial to ensure market-clearing feasibility for the high RES paradigms.

In addition to the assumption that distributional knowledge is available to the system operator (or can be estimated from historical data), the modeling of chance constraints adopted in this paper is agnostic to the degree of constraint violations. Future modeling extensions can be made to provide bounds on the cost of expected constraint violations, e.g., adopting the approach by[START_REF] Chen | From cvar to uncertainty set: Implications in joint chance-constrained optimization[END_REF] which remains within the SOCP framework. Finally, beyond the fully stochastic optimization frameworks, quasi-stochastic market-clearing approaches such as[START_REF] Mays | Quasi-stochastic electricity markets[END_REF], have recently been proposed to alleviate the adverse impacts of decisions made under uncertainty in dayahead electricity markets. Although formulated as LP (or MILP) problems, such approaches attempt to approximate the fully stochastic market equilibrium relying on parameters exogenous to the market, e.g., administrative choices made by system operators, outcomes from stochastic reliability problems solved ahead of the day-ahead market, etc.

Depending on the constraint violation probability ε and the number of decision variables,(Alamo et al., 2015, Theorem 4) provides an analytical expression for the number of scenarios that must be considered while solving R2 to obtain the same probabilistic feasibility guarantee as M cc . For the network considered in this numerical study, this evaluates to > 80, 000 scenarios, thereby rendering problem R2 unable to provide such a guarantee while being cleared within the desired day-ahead market-clearing solve times (typically, about 1-2 hours).

A real-time balance is indeed enforced in R2, such that real-time adjustments in each scenario is aligned with the supply-demand balance. However, the price convergence between day-ahead energy prices and real-time prices is a desired property to maximize welfare, as discussed in[START_REF] Zavala | A stochastic electricity market clearing formulation with consistent pricing properties[END_REF]. This price convergence is in fact a characteristic of our implementation R2, but it limits the ability to explicitly extract values corresponding to flexibility payment either from the primal or dual solutions to the market-clearing problem.