Content uploaded by Germán Morales-España

Author content

All content in this area was uploaded by Germán Morales-España on Jul 06, 2022

Content may be subject to copyright.

1

LP Formulation for Optimal Investment and

Operation of Storage Including Reserves

Germán Morales-España, Ricardo Hernandez-Serna, Niina Helistö, and Juha Kiviluoma

Abstract—Energy storage models require binary variables to

correctly model reserves and to ensure that the storage cannot

charge and discharge simultaneously. This paper proposes a tight

linear program (LP), i.e., convex hull, for the storage, which

guarantees that there is no better LP approximation to its mixed-

integer program (MIP) counterpart. Although the resulting LP

formulation cannot guarantee that charge and discharge are

mutually exclusive at all times, it does not affect the feasibility of

providing reserves. By embedding the proposed LP formulation

into large optimization problems, it helps to provide solutions

equal to or very near to the exact integer feasible behaviour of

the storage; and when used in its integer form, it speeds up MIP

problems. Furthermore, the tight LP formulation is extended to

include storage investment decisions, thus providing a very strong

LP relaxation, opposite to the LP relaxation resulting from the

big-M constraints commonly used in storage investment models.

Index Terms—Linear programming, mixed-integer program-

ming, optimal planning, storage, reserves.

I. INTRODUCTION

ENERGY storage systems have become a promising option

to increase power system ﬂexibility and harness larger

shares of variable renewable energy. To get a full picture of

their potential operation and beneﬁts, a realistic representation

of their characteristics is essential in power system models.

Existing storage models require binary variables to correctly

model reserves and to ensure that the storage cannot charge

and discharge simultaneously [1], [2], as further discussed

in Section II-A. Furthermore, to avoid this simultaneous

charge/discharge, investment models use big-M constraints [2]

which greatly damage the strength of the mixed-integer pro-

gram (MIP), thus signiﬁcantly increasing their computational

complexity [3]. Since solving MIP problems are computa-

tionally demanding and can pose a signiﬁcant impediment

in large-scale models, a common practice is to formulate

them as linear programs (LP), where the storage is allowed

to charge and discharge simultaneously, hoping that the the

optimal solution avoids this option since it increases losses

and potentially costs. An attempt to diminish simultaneous

charging and discharging was presented in [4], albeit without

reserves or investment decisions, where the authors argue that

fast storage units can actually charge and discharge within a

period, by charging one part of the period and discharging

the remaining part. Energy models can then greatly beneﬁt

from a tight MIP representation of energy storage because

1) it accelerates solving times of MIP models, and 2) in its

relaxed LP form, the solution will be very near to the optimal

exact MIP solution. This LP formulation can then be used

as a good proxy of the original MIP model in large-scale

optimization models. Furthermore, an LP model allows to

directly apply decomposition algorithms that require convexity

of the operations (second-stage) problem [2].

The main contributions of this letter are threefold: 1) we

propose an LP formulation of storage that correctly models

reserves and better exploits the ﬂexibility of fast storage

units; 2) the proposed LP formulation is the tightest possible,

i.e., convex hull, and consequently it naturally minimizes the

possibility of simultaneous charging and discharging, thus

providing the best linear approximation when used in LP

models, and speeding up solving times when used in MIP

models; and ﬁnally, 3) the tight LP formulation is extended

to include storage investment decisions, thus providing a

very good approximation (strong LP relaxation) to its MIP

counterpart, opposite to the LP relaxation resulting from the

big-M constraints commonly used in investment models.

II. MATHEMATICAL FORMULATION

A. Why an MIP for correct modelling of storage + reserves?

Generic storage models are used to represent many devices

capable of storing energy, such as pump hydro, electric ve-

hicles, thermal storage, and some forms of demand response.

Furthermore, the model of storage output is similar to that of

transmission lines with losses and reserves [5]. A typical MIP

model of storage [6] including reserves is

et=et−1+ctηC∆t−dt

ηD∆t∀t(1)

E≤et≤E∀t(2)

ct+rc−

t≤Cδt∀t(3)

dt+rd+

t≤D(1 −δt)∀t(4)

ct−rc+

t≥0∀t(5)

dt−rd−

t≥0∀t(6)

r+

t=rc+

t+rd+

t∀t(7)

r−

t=rc−

t+rd−

t∀t(8)

rc+

t, rd+

t, rc−

t, rd−

t,ct, dt≥0∀t(9)

δt∈ {0,1}(10)

where the index tstands for time periods and the parameter ∆t

represents the time duration (e.g., ∆t=1h). Parameters C/D

are charge/discharge capacities, ηC/ηDare their corresponding

efﬁciencies, and E/E are the min/max storage capacities.

Variables ct, dt, etare charge, discharge, and state of charge,

respectively. The binary variable δtindicates when the storage

is 1) charging (δt= 1) and it can provide up rc+

tand down

rc−

treserves, or 2) discharging (δt= 0) where it can also

2

Fig. 1. Feasible regions (shadow area) for the maximum up reserves that

storage can provide by using an LP relaxed (left) or an integer (right) model.

provide up rd+

tand down rd−

treserves. The state of charge

of the storage is tracked in (1) and its capacity limits in (2).

The upper bounds for charge and discharge are imposed in

(3) and (4), and their corresponding lower bounds in (5) and

(6). The total up and down reserves r+

t, r−

tare obtained in

(7) and (8). Finally, (9) deﬁnes the continuous variables as

non-negative, and (10) deﬁnes the variable δtas binary.

1) Binary variable to model reserves: The following ex-

ample illustrates why δthas to be integer to correctly model

reserves. Suppose C= 10MW and D= 20MW, if the storage

is charging ct= 8MW, then the maximum up reserves the

model guarantee is rc+

t≤8MW from (5). Also, since the

unit is charging δt= 1 forces rd+

t, xd−

t, dt= 0. On the other

hand, in the LP relaxation, when ct= 8MW, δtcan take

the value of 0.8from (3), then rc+

t≤8MW from (5), and

rd+

t≤4MW from (4), see Fig. 1. The total up reserves are

now r+

t= 12MW from (7), and even though the storage unit

can be fast enough to provide them (see Section II-B), these

reserves are 50% higher than what the MIP model (1)-(10)

intended to be feasible. There are many possible combinations

where the relaxed model can maximize the amount of reserves

outside the feasible region imposed by the integer model.

2) Binary variable to avoid simultaneous charging and

discharging: If there is an incentive to maximize demand, e.g.,

in the event of negative prices, the model in its LP relaxed

form can choose to charge and discharge simultaneously to

virtually increase losses [2], which could be unfeasible in

practice. Therefore, deﬁning δtas integer together with (3) and

(4) imposes that charge and discharge are mutually exclusive.

B. LP (re)formulation

The capacity limits of the storage output (ct−dt)with

reserves could be modelled as

(ct−dt) + r−

t≤C∀t(11)

(ct−dt)−r+

t≥ −D∀t(12)

where the only difference compared with a model of traditional

generating units, which do not need binary variables to include

reserves, is that the storage output (ct−dt)can take either

positive (charge) or negative (discharge) values.

The capacity limits for the storage output are deﬁned as

ct≤C, dt≤D∀t(13)

r+

t≤R+, r−

t≤R−∀t(14)

r+

t, r−

t, ct, dt≥0∀t(15)

Although the resulting LP formulation from (11)-(15) does

not guarantee that variables ctand dtare mutually exclusive,

it does not affect the feasibility of providing reserves, unlike

traditional storage formulations (Section II-A1). Therefore, the

LP formulation (11)-(15) together with (1) and (2) is sufﬁcient

to model lossless (ηC=ηD= 1) storage providing reserves.

This formulation better exploits the ﬂexibility of storage

units: notice that the maximum possible reserves r+

t, r−

tare

min (R+

, C +D)and min (R−

, C +D), respectively. That is,

if the storage unit is fast enough, i.e., R+

, R−≥C+D,

then, within a period, the storage can go from fully charging

(discharging) and deploy the maximum up (down) reserves

to go fully discharging (charging), which can be feasible in

practice, e.g., within an hour by using an intra-hour model.

C. Avoiding simultaneous charging and discharging

The set of constraints (16)-(22) is the tightest possible

representation, i.e., convex hull, for the mutually exclusive

constraints for charging and discharging of storage including

reserves, as proven in the Appendix.

ct−dt+r−

t≤C∀t(16)

ct−dt−r+

t≥ −D∀t(17)

ct≤Cδ ∀t(18)

dt≤D(1 −δ)∀t(19)

r+

t≤R+, r−

t≤R−∀t(20)

r+

t, r−

t, ct, dt≥0∀t(21)

0≤δt≤1∀t(22)

This convex hull guarantees that there is no better LP

approximation for this set of constraints; consequently, by

embedding it into larger optimization problems, 1) it helps

to provide solutions equal to or very near to the exact integer

feasible solution of the storage, and 2) in MIP problems, where

δtis deﬁned as binary, it speeds up solving times.

If the model is always used in its LP form, we can reduce its

dimension by eliminating the variable δtthrough the Fourier-

Motzkin elimination procedure, then the constraints (18), (19)

and (22) can be replaced by their exact equivalent:

ct≤C, dt≤D∀t(23)

ct

C+dt

D≤1∀t(24)

where (24) dominates both constraints in (23), then only (24)

is needed and consequently (23) can be removed.

Notice that although (24) cannot fully guarantee that ctand

dtare mutually exclusive, it diminishes its effect: e.g., if ct=

C(or dt=D), then (24) forces dt= 0 (or ct= 0).

D. LP formulation for investment

For investment problems, the capacity parameters

C, D, E , E become investment variables, then (18) and

(19) become bilinear constraints. These bilinear constraints

are commonly reformulated as big-M MIP constraints [2],

which greatly damage the tightness of the formulation, that is,

the LP relaxation provides a very bad (weak) approximation

3

to its MIP counterpart. Here, we then extend the tight

formulation above including investment decisions:

et=et−1+ctηC∆t−dt

ηD∆t∀t(25)

ct−dt+r−

t≤C0+c∀t(26)

ct−dt−r+

t≥ −α(C0+c)∀t(27)

ct+dt

α≤C0+c∀t(28)

r+

t≤β(C0+c)∀t(29)

r−

t≤θ(C0+c)∀t(30)

φE0+e≤et≤E0+e∀t(31)

r+

t, r−

t, ct, dt≥0∀t(32)

e, c ≥0(33)

where parameters C0and E0are the initial capacities for

charging and storage, and variables cand eare their corre-

sponding new investments. Since all storage capacity values

are proportional between one another [2], the investment

decisions for discharge and up/down reserve capacities are

deﬁned as a proportion αand β/θof the charge capacity,

respectively; and the minimum capacity of the storage is

deﬁned as a proportion φof the maximum capacity. Notice

that (28) is the equivalent of (24) for investment, thus limiting

the possibility of simultaneous charging and discharging in an

LP investment model.

III. CONCLUSIONS

This article provides the tightest possible LP formulation

for the storage operation, thus guaranteeing that there is no

better LP approximation to its MIP counterpart. Although

it cannot guarantee that charge and discharge are mutually

exclusive at all times, it does not affect the feasibility of

providing reserves. Finally, this tight formulation is extended

to investment problems. The formulation for the storage output

can also be used for transmission with losses and reserves,

since transmission could be modelled in the same manner. The

proposed tight formulation can beneﬁt large-scale optimization

problems by providing a good approximation of the storage

operation in LP problems and speeding up solving times in

MIP problems.

ACKNOWLEDGEMENT

This work has received funding from the EU Horizon 2020

research and innovation program under project TradeRES

(grant agreement No 864276)

APPENDIX

The disjunctive set of constraints (34) for a storage unit

activates only the left side of the formulation if the unit is

charging, or only the right side if discharging. To simplify the

notation, here we do not report the time index t.

c+r−≤C

c−r+≥ −D

c≤C

d= 0

r+≤R+, r−≤R−

r+, r−, c ≥0

or

−d+r−≤C

−d−r+≥ −D

c= 0

d≤D

r+≤R+, r−≤R−

r+, r−, d ≥0

(34)

The convex hull of disjunctive constraints is given by [7]

and expressed in a higher dimensional polyhedron:

c1+r1−≤Cδ1,−d2+r2−≤Cδ2(35)

c1−r1+ ≥ −Dδ1,−d2−r2+ ≥ −Dδ2(36)

c1≤Cδ1, c2= 0 (37)

d1= 0, d2≤Dδ2(38)

r1+ ≤R+δ1, r2+ ≤R+δ2(39)

r1−≤R−δ1, r2−

t≤R−δ2(40)

r1+, r1−, c1, d1, δ1≥0, r2+ , r2−, c2, d2, δ 2≥0(41)

r+=r1+ +r2+ (42)

r−=r1−+r2−(43)

c=c1+c2(44)

d=d1+d2(45)

δ1+δ2= 1 (46)

and the projection of this convex hull onto variables r+, r−, c

and dalso results in a convex hull [3].

To reduce the dimensionality of (35)-(46), i.e., projecting

it onto variables r+, r−, c and d, we start by eliminating

c1, c2, d1, d2: since c2= 0 (37) and d1= 0 (38) then c1=c

(44) and d2=d(45). Now we rename the variable δ1as

δ=δ1, and obtain δ2= 1 −δ(46). We also replace r2+ , r2−

by r2+ =r+−r1+ (42) and by r2−=r−−r1−(43),

respectively. Then the polyhedron (35)-(46) becomes

c+r1−≤Cδ, −d+r−−r1−≤C(1 −δ)(47)

c−r1+ ≥ −Dδ, −d−r++r1+ ≥ −D(1 −δ)(48)

c≤Cδ, d ≤D(1 −δ)(49)

r1+ ≤R+δ, r+−r1+ ≤R+(1 −δ)(50)

r1−≤R−δ, r−−r1−≤R−(1 −δ)(51)

r1+, r1−, c ≥0, r+, r−, d ≥0(52)

0≤δ≤1(53)

Now we apply the Fourier-Motzkin elimination procedure

to variables r1−and r1+ , and after removing all redundant

constraints, the projection of the convex hull (35)-(46) onto

variables r+, r−, c and dresults in the convex hull (16)-(22).

REFERENCES

[1] B. Xu, J. Zhao, T. Zheng, E. Litvinov, and D. S. Kirschen, “Factoring

the Cycle Aging Cost of Batteries Participating in Electricity Markets,”

IEEE Trans. Power Syst., vol. 33, no. 2, pp. 2248–2259, Mar. 2018.

[2] R. S. Go, F. D. Munoz, and J.-P. Watson, “Assessing the economic value

of co-optimized grid-scale energy storage investments in supporting high

renewable portfolio standards,” Appl. Energy, vol. 183, pp. 902–913, Dec.

2016.

[3] L. Wolsey, Integer Programming. Wiley-Interscience, 1998.

4

[4] Z. Shen, W. Wei, D. Wu, T. Ding, and S. Mei, “Modeling arbitrage of

an energy storage unit without binary variables,” CSEE J. Power Energy

Syst, vol. 7, no. 1, pp. 156–161, Jan. 2021.

[5] N. Helistö, J. Kiviluoma, J. Ikäheimo, T. Rasku, E. Rinne, C. O’Dwyer,

R. Li, and D. Flynn, “Backbone—An Adaptable Energy Systems Mod-

elling Framework,” Energies, vol. 12, no. 17, p. 3388, Jan. 2019.

[6] Y. Liu, L. Wu,Y. Yang, Y. Chen, R. Baldick, and R. Bo, “Secured Reserve

Scheduling of Pumped-Storage Hydropower Plants in ISO Day-Ahead

Market,” IEEE Trans. Power Syst., vol. 36, no. 6, pp. 5722–5733, Nov.

2021.

[7] E. Balas, “Disjunctive Programming and a Hierarchy of Relaxations for

Discrete Optimization Problems,” SIAM. J. on Algebraic and Discrete

Methods, vol. 6, no. 3, pp. 466–486, Jul. 1985.