Gas Storage and Supply Guarantees - Princeton University

22
Submitted to Management Science manuscript (Please, provide the mansucript number!) Gas Storage and Supply Guarantees: An Optimal Switching Approach Ren´ e Carmona Department of Operations Research and Financial Engineering, also with Bendheim Center for Finance, Princeton University, Princeton, NJ 08544 [email protected], Mike Ludkovski Department of Mathematics, University of Michigan, Ann Arbor, MI 48109 [email protected], http://www.umich.edu/ mludkov We consider the valuation of gas storage on finite horizon. Focusing on the timing optionality of storage we construct a stochastic control model that reduces to solving an optimal switching problem with inventory. Extending the methodology from Carmona and Ludkovski (2005), we then construct a robust numerical scheme based on Monte Carlo regressions. The idea is to simultaneously approximate the optimal switching times along all the simulated paths. The main difficulty is dealing with the path-dependent inventory. The scheme is compared to the traditional quasi-variational framework and illustrated with a variety of concrete examples. We also consider related problems of interest, such as supply guarantees and natural resource management. Key words : optimal switching; Monte Carlo simulations; gas storage; power supply guarantees; impulse control Acknowledgments We thank Nizar Touzi for useful discussions. 1. Introduction. As opposed to purely financial obligations like stocks and bonds, commodities require physical storage. This is especially true for energy fuel commodities whose consumption is highly correlated with weather. The principal example is natural gas that is used by many households in North America for heating during the winter. Thus, natural gas demand has a pronounced spike in the cold season. In contrast, natural gas supply, obtained by extracting gas from gas fields and moving it through the pipeline system, is relatively stable. To accommodate the higher winter demand there are storage facilities that allow for gas to be kept in an easily accessible manner. Such facilities include salt domes, depleted gas fields, aquifers and artificial caverns and form an important class of energy assets. As gas markets de-regulate, trading in gas spot and futures is gaining momentum. Given that short term gas prices are highly volatile and unpredictable, storage also provides a tool for financial 1

Transcript of Gas Storage and Supply Guarantees - Princeton University

Submitted to Management Sciencemanuscript (Please, provide the mansucript number!)

Gas Storage and Supply Guarantees: An OptimalSwitching Approach

Rene CarmonaDepartment of Operations Research and Financial Engineering, also with Bendheim Center for Finance, Princeton University,

Princeton, NJ 08544 [email protected],

Mike LudkovskiDepartment of Mathematics, University of Michigan, Ann Arbor, MI 48109 [email protected],

http://www.umich.edu/∼mludkov

We consider the valuation of gas storage on finite horizon. Focusing on the timing optionality of storage we

construct a stochastic control model that reduces to solving an optimal switching problem with inventory.

Extending the methodology from Carmona and Ludkovski (2005), we then construct a robust numerical

scheme based on Monte Carlo regressions. The idea is to simultaneously approximate the optimal switching

times along all the simulated paths. The main difficulty is dealing with the path-dependent inventory. The

scheme is compared to the traditional quasi-variational framework and illustrated with a variety of concrete

examples. We also consider related problems of interest, such as supply guarantees and natural resource

management.

Key words : optimal switching; Monte Carlo simulations; gas storage; power supply guarantees; impulse

control

Acknowledgments

We thank Nizar Touzi for useful discussions.

1. Introduction.

As opposed to purely financial obligations like stocks and bonds, commodities require physical

storage. This is especially true for energy fuel commodities whose consumption is highly correlated

with weather. The principal example is natural gas that is used by many households in North

America for heating during the winter. Thus, natural gas demand has a pronounced spike in the

cold season. In contrast, natural gas supply, obtained by extracting gas from gas fields and moving

it through the pipeline system, is relatively stable. To accommodate the higher winter demand

there are storage facilities that allow for gas to be kept in an easily accessible manner. Such facilities

include salt domes, depleted gas fields, aquifers and artificial caverns and form an important class

of energy assets.

As gas markets de-regulate, trading in gas spot and futures is gaining momentum. Given that

short term gas prices are highly volatile and unpredictable, storage also provides a tool for financial

1

Carmona and Ludkovski: Optimal Switching for Gas Storage2 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

speculation. In particular, salt domes have high deliverability rate of injecting and releasing gas

that allows speculative betting on intertemporal spreads in gas prices. As documented by de Jong

and Walet (2003), “in the liberalisation process, natural gas storage is unbundled, ... offered as a

distinct, separately charged service. ... Buyers and sellers of natural gas have the possibility to use

storage capacity to take advantages of the volatility in prices”. The basic idea is to rent a storage

facility and then to ‘buy low’ and ‘sell high’, such that the realized profit covers the intermediate

storage and rental costs. Such rent contracts are quite common and nowadays large commodity

trading firms even have ‘storage desks’. It is now natural to ask what is their financial value.

Namely, how much should one pay to gain control of a storage facility for a period of T years.

Observe that the time structure and seasonality of prices become crucial. As a stylized example, if

average gas prices are $4 per thousand Btu’s (British thermal units) in July and $8 in January while

monthly storage costs are 50c cents/kBtu, then one can realize a sure profit of $1 by buying gas in

July, forward selling it in January and storing in between. Transactions like this do take place and

are the ‘bread-and-butter’ of storage operators. However, they should be seen as monetizing the

economic rent of the storage facility rather than arbitrage. Indeed, they ignore the time evolution

of gas prices and reflect the static view of the forward curve. The opportunity to turn a profit

exists simply due to the enormous amount of capital and time that had to be invested to build the

facility in the first place.

In contrast, we are more interested in dynamic trading that responds to short-term fluctuations.

For us a gas storage facility is a straddle on gas prices, making the agent long volatility. High

volatility increases expected intertemporal spreads and creates more of the ‘buy low, sell high’

opportunities. Thus, in this paper we focus on the real option component of storing gas. More

precisely, we analyze the optimal behavior of the renter managing a gas storage facility and exposed

to fluctuating fuel prices. The agent derives the maximum value by optimizing the dispatching

policy, i.e. dynamically deciding when gas is injected and withdrawn, as time and market conditions

evolve. Our emphasis will be on constructing a rigorous mathematical framework that is robust

and flexible and allows for efficient numerical implementation.

The organization of this paper is the following. Section 2 describes the stochastic control model

we use and its relation to existing literature. Section 3 summarizes the theoretical solution method

which is then implemented in Section 4. After outlining the numerical scheme, we proceed to illus-

trative examples in Section 5. Then Sections 6 and 7 discuss extensions to power supply guarantees

and natural resource management, respectively. These sections demonstrate that our methodology

is applicable to a wide variety of real options encountered among commodity derivatives. Finally,

Section 8 concludes and outlines future projects.

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 3

2. Stochastic Model.

To construct a tractable mathematical model we first assume that the market is liquid and the

agent is a price taker, so that her actions do not affect prices. We next postulate that the storage

facility is always in one of three possible operating regimes— injecting gas, withdrawing it or just

storing. The gas is transferred in and out by means of a limited capacity pipeline with the transfer

rate fixed by the operational characteristics. For simplicity, assume there is only a single feasible

injection rate ain and a single withdrawal rate aout1. Both of ai are quoted in millions of Btu

(mmBtu) per time unit. Denote by b the monetary cost for storing one mmBtu for one time period.

This might include direct storage and pumping costs, as well as various seepage losses. Finally,

there are standard operating and managing costs that are accumulated at rate Ki depending on

the current regime.

We model the market gas prices by a continuous time, possibly multi-dimensional, stochastic

process Gt. By prices we mainly mean near-month forwards that are by far the most liquid

contract on the market. However, given a variety of quoted gas prices (spot, balance-of-the-month,

futures, etc.), we remain agnostic about the interpretation of the price process. The current inven-

tory in storage at time t is denoted It and should always be positive and less than total capacity

0≤ It ≤ cmax. Summarizing, if we label the regimes as −1,0,1, then the regime payoff rates ψi

and the corresponding changes in inventory are given by Inject: ψ−1(Gt, It) =−Gt · ain− b(t, It)−K−1, dIt = ain dt,Store: ψ0(Gt, It) =−b(t, It)−K0, dIt = 0,Withdraw: ψ1(Gt, It) = +Gt · aout− b(t, It)−K1, dIt =−aout dt.

(1)

In general, ψi can be any continuous Lipschitz function of (t,Gt, It) such that

E[

supt∈[0,T ]

|ψi(t,Gt, It)|2]<∞.

For example, it is often the case that the injection rates are function of the current inventory,

ai = ai(It) . The driving process Gt may also include longer maturity forwards, however forward

selling is problematic since the price is locked-in in advance while the inventory only changes at

delivery time. For simplicity we assume that any purchase or sale are immediately reflected in the

inventory.

Many possibilities exist for the form of Gt and there is much recent debate (Eydeland and

Wolyniec (2003)) about good models for gas prices. We entirely sidestep this issue; our method

1 A realistic facility has many possible operating levels. However, if the reward is linear in the injection/withdrawalrate, then it is optimal to always inject/withdraw at the maximum possible rate. Thus, our assumption holds in suchcases.

Carmona and Ludkovski: Optimal Switching for Gas Storage4 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

is independent from the assumed model for Gt and we suppose that issues such as parameter

estimation have been already dealt with. For us Gt is just a right continuous strong Markov

process in Rd with left hand limits. A standard choice is an Ito diffusion described by a stochastic

differential equation (SDE)

dGt = µ(t,Gt)dt+σ(t,Gt) · dWt, (2)

where Wt is a standard Wiener process on a filtered probability space (Ω,F,F,P), with F its nat-

ural filtration. A canonical example is a one-dimensional exponential Ornstein-Uhlenbeck process,

namely

dGt =Gt

[κ(θ− logGt)dt+σ dWt

], (3)

or d(logGt) = κ(θ− σ2

2κ− logGt

)dt+σ dWt, G0 = g.

This models the mean-reversion in gas prices documented by Eydeland and Wolyniec (2003), and

moreover makes logGt Gaussian, which allows for explicit calculations. Upward jumps in Gt are

also allowed and can be used to take into account price spikes. The jury is still out whether such

jump-diffusion models are appropriate for natural gas.

2.1. Control Problem.

Each change of the facility’s regime incurs switching costs. Namely, moving the facility from regime i

to regime j costs Ci,j =C(i, j; t,Gt, It). This represents both the effort—one must dispatch workers,

coordinate with the outgoing pipeline, stop/start the decompressors, etc.—and the time needed to

change the operating mode. We assume that the switching costs are discrete Ci,j > ε for all i, j and

some ε > 0. Subject to those costs and the operational constraints, the facility operator would then

like to maximize the net expected profit. Given initial conditions at time t: Gt = g, It = c, initial

operating regime i and a chosen dispatching policy u we denote by J(t, g, c, i;u) the expected profit

until final date T , so that

J(t, g, c, i;u) = E[∫ T

t

ψus(s,Gs, Is)ds−∑τk<T

C(uτk−, uτk)∣∣∣Gt = g, It = c,ut = i

]. (4)

The first term above counts the total profit and loss from running the facility up to terminal time

T and the second term counts the incurred switching costs.

It is convenient to write u = (ξ1, ξ2, . . . ; τ1, τ2, . . .) where the quantities ξk denote the sequence

of operating regimes of u, while τk ≤ τk+1 ≤ T denote the switching times. Let F be the filtration

generated by the driving process Gt. Then we require u to lie in the set U(t) of admissible

strategies, which consists of all F-adapted cadlag (right-continuous with left limits) −1,0,1-valued

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 5

processes u of a.s. finite variation on [t, T ]. F-adaptiveness is a standard condition implying that

the agent only has access to the observed price process and cannot use any other information. The

last requirement means that the number of switches must be finite almost surely. Thus, P[τn <

T ∀n> 0] = 0. From an economic perspective, the facility is likely to have very stringent cycling

restrictions (e.g. at most two cycles in a calendar year), so the above assumption is not restrictive.

After these preliminaries, our formal control problem is computing

J(t, g, c, i) M= supu∈U(t)

J(t, g, c, i;u), (5)

where J(t, g, c, i;u) is as in (4). It remains to specify the terminal condition at T . Typical contracts

specify that the facility should be returned with the same inventory I0 as in the beginning. To

enforce this constraint, various buy-back provisions are employed. A common terminal condition is

J(T, g, IT , i; I0) =−C · g|IT − I0|, making the penalty proportional to the absolute difference with

stipulated inventory times the terminal gas price. One will often also require a specific final mode

of the facility, say uT = 0. In practice, other restrictions, such as time-dependent upper and lower

inventory bounds may exist and further constrain admissible strategies. The most basic one would

be finite storage capacity, so that cmin ≤ It ≤ cmax must hold at all times. These issues will be

revisited in Section 7.2.

2.2. Relation to Existing Literature.

Gas storage is an important practical problem but has only recently received attention from aca-

demics. One major deterrent has always been the path-dependent nature of the problem, making

the real options approach hard to implement. Indeed, while most energy assets are closely related

to regular financial options (e.g. of spread, swing, etc. variety) Eydeland and Wolyniec (2003),

Carmona and Durrleman (2003), gas storage is not. Current inventory is inherently a function of

past decisions and in turn determines the feasibility of future policies.

Nevertheless, apart from path-dependency, much of the classical work can be re-used. This

includes economic foundations of investment with fixed costs under uncertainty described in detail

in Dixit and Pindyck (1994) and analysis of real options in natural resource management by Bren-

nan and Schwartz (1985). Also, optimal switching literature, including Brekke and Øksendal (1994),

Hamadene and Jeanblanc (2004), Carmona and Ludkovski (2005), Zervos (2003) is important

for understanding the mathematical framework. From an economic perspective, it is crucial to

realize that stochasticity of the Gt state process together with discrete switching costs cause

decision delay and the associated hysteresis band of Dixit (1989). This means that the owner will

be risk-averse and will forgo small potential gains due to uncertainty about future prices and the

Carmona and Ludkovski: Optimal Switching for Gas Storage6 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

large outlay required to make a switch. On the other hand, the operator has a timing option and

can dynamically change regimes to take maximal advantage of market conditions. This flexibility

increases the value of the asset, countering the effect above.

When it comes to practical implementations, the shortcoming of aforementioned stochastic con-

trol papers is that they concentrate on explicit solutions. Thus attention is restricted to infinite

horizon with typically a geometric Brownian motion for Gt. This permits finding analytical

solutions but makes the models impractical. To redress this issue in the case of standard optimal

switching, our earlier paper Carmona and Ludkovski (2005) proposed a flexible numerical frame-

work based on Monte Carlo simulations. As we will see the methodology can also be applied to

problems of interest here.

On the applications side, the path-dependency of gas storage resulted in two approaches. First,

one can make (often drastic) simplifications to shoehorn the problem into the real options frame-

work, as described in Eydeland and Wolyniec (2003). For instance, gas storage can be reduced to

a collection of standard calendar Call options, paying out the spread between gas prices today and

Tk years from now. Once this is done, the entire machinery of derivative pricing can be brought to

bear. One gains intuition and computational speed but ignores key operational constraints. Fur-

thermore the method is ad hoc requiring heuristic adjustments to correct for model assumptions.

Alternatively, the problem can be viewed in the framework of general continuous-time stochastic

control (see e.g. Thompson et al. (2003), Ahn et al. (2002)) and the classical quasi-variational tools

can be used. This approach is reviewed in Section 3.1. Unfortunately, the path-dependency makes

the resulting numerical solvers not robust and causes them to be too slow for realistic problems.

Thus, our main contribution is a simulation-based numerical scheme that properly addresses the

operational constraints while maintaining robustness and computational efficiency. We hope this

will help bridge the alluded gap between theoretical and practitioner approaches to gas storage.

3. Iterative Optimal Stopping.

To solve the stochastic control problem in (5) we use the methodology described in Carmona and

Ludkovski (2005). The main idea is that we have an optimal switching problem, which means it

can be efficiently re-written as a sequence of optimal stopping problems. Accordingly, let St denote

the set of all F-stopping times between t and T . Then we recursively construct the value functions

Jk(t, g, c, i) where k= 1,2, . . ., 0≤ t≤ T , g ∈Rd, c∈ [cmin, cmax] and i∈ −1,0,1:

J0(t, g, c, i) M= E[∫ T

t

ψi(s,Gs, Is)ds∣∣∣Gt = g, It = c

], (6)

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 7

Jk(t, g, c, i) M= supτ∈St

E[∫ τ

t

ψi(s,Gs, Is)ds+maxj 6=i

−Ci,j +Jk−1(τ,Gτ , Iτ , j)

∣∣∣Gt = g, It = c]. (7)

The results in Carmona and Ludkovski (2005) show that

Proposition 1. i. Jk is equal to the value function for the optimal switching problem with

at most k switches allowed, i.e. when optimizing over Uk(t) M= (ξ,T ) ∈ U(t) : τ` = T for ` > k +

1 in (5). Hence Jk(t, g, c, i) is the maximum expected profit to be had on the time period [t, T ]

conditional on the initial state (g, c, i) and at most k switches remaining.

ii. The optimal strategy u∗ = (ξ∗,T ∗) for Jk exists, is Markovian and is explicitly defined by

τ ∗0 = 0, and for `= 1, . . . , k by the stopping times

τ ∗`M= inf

s≥ τ ∗`−1 : J `(s,Gs, Is, i) =M`,i(s,Gs, Is)

∧T (8)

and corresponding sequence of regimes ξ∗`M= argmaxj M`,i(τ ∗` −,Gτ∗

`−, Iτ∗

`−). Here M`,i(s,Gs, Is)

M=

maxj 6=i

(−Ci,j + J `−1(s,Gs, Is, j)

)is the switch operator, denoting the value derived from making

the best possible switch immediately.

iii. Taking the pointwise limit in the number of switches k→∞ we recover the true value func-

tion, limk→∞ Jk(t, g, c, i) = J(t, g, c, i). In particular, for any ε > 0, there is a K large enough such

that the optimal control of JK generates an ε-optimal strategy for J .

The key insight behind the proposition is the Bellman optimality principle which implies that

solving the problem with at most k+ 1 switches allowed is equivalent to finding the first optimal

switching time τ which maximizes the initial payoff until τ plus the value function at τ correspond-

ing to optimal switching with k switches.

The difficulty with the gas storage problem is that the dynamics of the inventory It are affected

by the control. However, (It) is in fact degenerate in the sense that it can be deterministically

computed from knowledge of initial inventory level I0 and switching policy u. In particular, in

our model if there are no switches on [t, τ), Iτ is a linear function of It and (τ − t). For instance,

supposing the initial regime is ‘inject’ we can re-write equation (6) as

Jk(t, g, c,−1) = supτ∈St

E[−

∫ τ

t

(ain ·Gs +K−1)ds+maxj 6=i

−Ci,j − b ·

∫ (τ−t)

0

(c+ ain · s)ds

+Jk−1 (τ,Gτ , c+ ain(τ − t), j)∣∣∣Gt = g

],

with no mention of It at all. Above the first term is the total cost of buying gas for injecting on

[t, τ ], and c+ ain · s is the amount of gas in storage at time t≤ t+ s≤ τ .

Carmona and Ludkovski: Optimal Switching for Gas Storage8 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

3.1. Quasi-variational formulation.

The gas storage model presented above is a special case of impulse control. Hence one can apply

the quasi-variational method developed by Bensoussan and Lions (1984). The standard verification

theorem presented below states that a smooth function φ which dominates the switch barrier and

solves the Kolmogorov partial differential equation (PDE) in the continuation area is in fact equal

to the value function.

Proposition 2. Let LG denote the infinitesimal generator of the Markov process Gt. Suppose

there exists φ(t, g, c, i) such that for

D=∪i

(t, g, c) : φ(t, g, c, i) = max

j 6=i(−Ci,j +φ(t, g, c, j))

,

φ(t, x, ·) belongs to C1,2(([0, T ]×Rd × [cmin, cmax])\D

)∩ C1,1(D) and satisfies the following quasi-

variational inequality (QVI) for every i∈ −1,0,1:

i. φ(t, g, c, i) > maxj 6=i

(−Ci,j +φ(t, g, c, j)

),

ii. ∂tφ(t, g, c, i)+LGφ(t, g, c, i)− ai ∂cφ(t, g, c, i)+ψi(t, g, c) 6 0, φ(T, g, c, i) = 0,

iii. For any (t, g, c, i) at least one of the two expressions above is an equality.

Then φ is the optimal value function for the storage problem (5).

This approach has been explored by Ahn et al. (2002). The derived parabolic PDE with a free

boundary can now be solved using standard tools, see for example Chapter 7 of Wilmott et al.

(1995). As a simplest choice, consider the basic finite differencing (FD) algorithm in the diffusion

setting of (2). We set up a uniform space-time grid with steps ∆t, ∆g and ∆c in time and space

respectively, and on this grid solveφt(t, g, c, i)+µ(t, g, c)φ′(t, g, c, i)+ σ(t,g,c)2

2φ′′(t, g, c, i)− ai ·φc(t, g, c, i)+ψi(t, g, c) = 0,

φ(t, g, c, i) > maxj 6=i

(−Ci,j +φ(t, g, c, j)

),

φ(T, g, c, i) = 0,(9)

by replacing derivatives with finite differences in the first equation and directly enforcing the

barrier condition at each step. Using standard properties of the infinitesimal generator LG,

φ(0, g, c, i) ∆t→0,∆g→0,∆c→0−−−−−−−−−−−→ J(0, g, c, i). The FD method is easy to implement but will be very slow

since even in the easiest case where Gt is one-dimensional and has smooth dynamics, the PDE is

two-dimensional in space. Furthermore, the degenerate It-dynamics can cause additional numerical

instability. The algorithm is also not robust. For instance, adding jumps is problematic because

it produces a partial integro-differential equation which is non-local and requires special tools,

see Thompson et al. (2003) for details. On the other hand, many improvements to the FD algo-

rithm are possible, e.g. adaptive grids, ADI schemes, etc., so that on small scale problems it can

be quite competitive.

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 9

4. Numerical Method.

The recursive formulation in (6) allows for an efficient and scalable numerical implementation. To

begin, we discretize in time, setting S∆ = m∆t, m= 0,1, . . . ,M ], ∆t= TM] as our discrete time

grid. Switches are now allowed only at grid points, i.e. τk ∈ S∆. This restriction is similar to looking

at Bermudan options as approximation to American exercise rights.

Let t1 =m∆t, t2 = (m+1)∆t be two consecutive time steps. In discrete time, the construction

of Jk(t1, g, c, i) reduces to deciding between immediate switch at t1 to some other regime j versus

no switching and therefore waiting until t2. Thus, (6) becomes

Jk(t1,Gt1 , It1 , i) = max(E

[∫ t2

t1

ψi(s,Gs, Is)ds+Jk(t2,Gt2 , It2 , i)∣∣Ft1

],Mk,i(t1,Gt1 , It1)

)'

(ψi(t1,Gt1 , It1)∆t+ E

[Jk(t2,Gt2 , It2 , i)|Ft1

])∨

(maxj 6=i

−Ci,j +Jk−1(t1,Gt1 , It1 , j)

). (10)

We see that to solve the problem it suffices to have a computationally efficient algorithm for

evaluating the conditional expectations appearing in (10). The idea is to view them as a map

(g, c) 7→ Et1 [Jk(t2, ·, i)](g, c)

M= E[Jk(t2,Gt2 , It2 , i)|Gt1 = g, It1 = c

]and to approximate the latter

with a projection:

Et(g, c)' Et(g, c) =NB∑j=1

αjBj(g, c), (11)

where Bj(g, c) are the NB bases and αj the R-valued coefficients.

We now would like to replace the projection with an empirical regression based on a Monte

Carlo simulation. This would then give us a method for implementing (10). However, as mentioned

before, It depends on the policy choice, so it cannot be directly simulated. Two choices present

themselves— either we discretize in the It-direction, fixing It1 on a grid, or we construct a quasi-

simulation. The two alternatives will be discussed more fully below, in the meantime let us label by

(Xt) the generic state variable so that our goal is computing Jk(m∆t,Xm∆t, i). Following Longstaff

and Schwartz (2001) we focus on the switching times rather than directly on the value functions.

Let τk(m∆t,Xm∆t, i) ·∆t correspond to the smallest optimal switching time for Jk(m∆t,Xm∆t, i).

In other words, the optimal future rewards are given by

Jk(m∆t, x, i) = E[ τk∑

j=m

ψi(j∆t,Xj∆t)∆t+Mk,i(τk∆t,Xτk∆t)∣∣Xm∆t = x

].

Begin by generatingNp sample paths xn of the discretized Xt process with a fixed initial condition

X0 = x= xn0 . We will approximate Jk(0, x, i) by 1

Np

∑n J

k(0, xn0 , i). The pathwise values Jk(t, xn

t , i)

Carmona and Ludkovski: Optimal Switching for Gas Storage10 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

and τk(t, xnt , i) are computed recursively in a backward fashion, starting with Jk(T,xn

T , i) = 0 and

τk(T,xnT , i) =M ]. The analogue of (10) for τk implies that we should update

τk(m∆t, xnm∆t, i) =

τk((m+1)∆t, xn

(m+1)∆t, i), no switch;m, switch.

(12)

The set of paths on which we switch is given by n : n(m∆t; i) 6= i with

n(t1; i) = argmaxj

(−Ci,j +Jk−1(t1, xn

t1, j), ψi(t1, xn

t1)∆t+ Et1

[Jk(t2, ·, i)

](xn

t1)), (13)

which we obtain by regressing the future values Jk(t2, xnt2, i) onto the basis functions B(xn

t1). As

a result of regression we obtain a prediction Em∆t

[Jk(m∆t, ·, i)

](xn

m∆t) for the continuation value

along the n-th path, which is plugged into (13). To summarize, the recursive pathwise construction

for Jk is

Jk(m∆t, xnm∆t, i) =

ψi(m∆t, xn

m∆t)∆t +Jk((m+1)∆t, xn(m+1)∆t, i), no switch;

−Ci,j +Jk−1(m∆t, xnm∆t, j), switch to j.

(14)

The above scheme is called LSM (Least Squares Monte Carlo or Longstaff Schwartz Method).

Observe that in this version the regression is used solely to update the optimal stopping times τk

and the regressed values are never stored directly. This additional layer of random behavior helps to

eliminate potential biases from the regression step. Alternatively, one can directly approximate the

value functions using the so-called TvR algorithm after Tsitsiklis and Van Roy (2001) by plugging

in the predictions Em∆t

[Jk(m∆t, ·, i)

](xn

m∆t) into (10).

The computations are done bottom-up in k, so that Jk−1(m∆t, ·, ·) is known when computing

Jk(m∆t, ·, ·). The efficiency is maintained by using the same set of paths to compute all the

conditional expectations. At a given layer k, the computations of Jk for different regimes i are

independent of each other, and hence the errors only cumulate with respect to number of switches.

Choosing the Basis Functions. The choice of appropriate basis functions (Bj) is user-

defined and usually heuristic. Proposed choices include Laguerre polynomials in the original paper

of Longstaff and Schwartz (2001) and logistic bases in Haugh and Kogan (2004). Empirically, basis

choice greatly affects numerical precision and customization is desirable. In particular, it helps to

use basis functions that resemble the expected shape of the value function. In practice, NB as small

as five or six normally suffices, and having more bases can often lead to worse numerical results

due to overfitting. When Xt is multidimensional, one can use tensor products of one-dimensional

bases∏

kBjk. However, in most practical cases, the rewards depend on special combinations of the

components of Xt. This can be used to reduce the number of basis functions needed to capture

the relationship between Xt and the value function.

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 11

4.1. Backward Recursion For Inventory Level.

The difficulty with solving (5) by the usual backward dynamic programming algorithm is that at

time t we do not know the optimal current inventory I∗t . Indeed, starting with I0, I∗t depends on the

past path of Gt and the optimal strategy u∗ on [0, t]. Both are unknown from the point of view of

the backward recursion. To overcome this problem, the first solution is to simply discretize the I-

dimension and keep Monte Carlo regressions in theG-dimension. In this modified algorithm suppose

that we know Jk(t2, gnt2, c, i) along the paths (gn)Np

n=1 for any inventory level c. Now fix the current

inventory level c0 and regress the continuation values to derive an estimate for Jk(t1, gnt1, c0, i) in

the same way as in Section 4:

Jk(t1, gnt1, c0, i) =

(Et1

[Jk(t2, ·, c0 + ai∆t, i)

](gn

t1)+ψi(t1, gn

t1, c0)∆t

)∨max

j 6=i

(−Ci,j +Jk−1(t1, gn

t1, c0, j)

). (15)

It remains to obtain a full map c 7→ Jk(t1, gnt1, c, i). To do so, vary the inventory c by using a grid

of N c values cj : cj = c0 + j∆c and interpolate. In principle, for a fixed ∆t we can even construct

a full grid in the I-dimension and solve the problem exactly. Indeed, if we are in regime i then in

one time step ∆t, the inventory changes by ai ·∆t and so if we take

∆c∈ x : ∀i there is an ni ∈N such that x ·ni = ai ∆t

then inventory adjustments in all regimes result in an integral number of jumps on the inventory

grid and no interpolation is needed.

The above approach is very time intensive since we now run a separate regression for each

inventory grid point cj, regime i, number of switches k and time step m∆t. Moreover, we are no

longer able to employ the true LSM scheme of approximating the switching times. Instead we have

to use the TvR version approximating the value functions. Because we only have values for Jk

at the grid points (m∆t, gnm∆t, cj), we must store the conditional expectations at every time step.

From simpler problems (American option pricing and vanilla optimal switching) we know that the

TvR scheme is often biased and so the results may be inaccurate. Nevertheless, the algorithm is

quite robust and is the simplest way of dealing with inventory level parameters.

4.2. Quasi-Simulation of Inventory Levels.

To maintain numerical efficiency it is desirable to eliminate the fixed discretization in the I-space

that resembles the slow lattice schemes. Accordingly, we propose the following modification that

instead uses pathwise inventory levels (Inm∆t). This allows us to do a joint (G,I)-regression and

keep the LSM scheme. The idea is to generate for each path and time point (n,m∆t) a random

Carmona and Ludkovski: Optimal Switching for Gas Storage12 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

inventory level Inm∆t, sampled independently and uniformly from [cmin, cmax]. Then the expected

future profit conditional on Inm∆t and gn

m∆t is obtained by a double regression in (15) of future

values J((m+1)∆t, gn(m+1)∆t, I

n(m+1)∆t, i) against the Markovian current state (gn

m∆t, Inm∆t)Np

n=1. The

extra randomization in (It) allows us to reduce computations by leveraging the information from

other paths. From another angle, the grids for current Im∆t are now random and we use a global

regression (rather than local interpolation) to perform the backward recursion. To perform the

2-d regression it is likely that a large number of basis functions is needed (about 10− 15 in our

experience) which in turn means that a large number of simulations is necessary. Nevertheless, the

scheme still handily beats the interpolation method. Furthermore, viewing It as a generic history

variable we suggest that this idea can be applied to carry out the dynamic programming algorithm

for any past-dependent setting.

Below is a summary of this scheme that we christen Pure Least Squares Monte Carlo (PLSM).

i. Select a set of basis functions (Bj) and algorithm parameters ∆t,M ],Np, K. Let Xt = (Gt, It).

ii. Generate Np paths of the driving process: gnm∆t, m = 0,1, . . . ,M ], n = 1,2, . . . ,Np with

fixed initial condition gn0 = g0. Generate a random terminal inventory level In

T for each path.

iii. Initialize the value functions and switching times Jk(T,xnT , i) = 0, τk(T,xn

T , i) =M ], ∀i, k.

iv. Moving backward in time with t=m∆t, m=M ], . . . ,0 repeat the Loop:

• Compute inductively the layers k= 0,1, . . . , K using (6). To evaluate the conditional expecta-

tion E[Jk(m∆t+∆t, ·, i)|Fm∆t

]regress Jk(m∆t+∆t, xn

m∆t+∆t, i) against current set of selected

basis functions Bj(xnm∆t)NB

j=1. Add the reward ψi(m∆t, xnm∆t) ·∆t to the continuation value.

• Update the switching times and value functions using (12), (13) and (14).

• After determining the optimal policy at time m∆t, update the inventories at (m−1)∆t given

Inm∆t and the current optimal decision.

v. end Loop.

vi. Check whether K switches are enough by comparing J K and J K−1 (they should be equal).

Let us also mention that the switching boundary which is needed for implementing the optimal

policy is easily recovered by our algorithm. Recall that for each k and i, the switching boundary

is given by the graph (t, xt) such that the minimal optimal switching time is given by the first

time of hitting this barrier. Since we already keep track of the optimal minimal τ , it suffices to

summarize at the end of the algorithm the graph of τk(0, x0, i) against Xt. Namely, the set

xnm∆t : n is such that τk(0, xn, i) =m

defines the empirical region of switching from regime i at instant m∆t. The complement is the

continuation set and we can determine the regime switched into by keeping track of n from (13).

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 13

Algorithm Complexity. The algorithm requires O(M 2 ·K ·Np ·M ]) operations. The algorithm

complexity is quadratic in the number M of regimes as we must check the possibility of switching

from each mode i into each other mode j. The algorithm is linear in number of paths Np since

during the regression step we only deal with matrices of size Np×NB. Because the other dimension

is fixed, the number of arithmetic operations is linear in the bigger dimension.

The memory requirements are O(Np · (M ] + K ·M)) where the two terms represent storage of

sample paths and value functions respectively. In practice, the first term is the main constraint

because the backward induction requires keeping the entire array of sample paths in memory. Even

for reasonable values such as M ] = 500,Np = 20,000 this is already 40MB of storage.

4.3. Convergence.

The presented algorithm has several layers of approximations. Looking back four types of errors can

be identified: error due to time discretization, error due to restricting switching times, projection

error and Monte Carlo sampling error. Detailed error analysis has been performed in Carmona and

Ludkovski (2005) for the case with no inventory. Viewing It as a ‘dummy’ variable determined by

the dynamics of Gt and policy u the results carry over without change. Thus, we simply summarize

the findings.

The error from discretizing Xt and simultaneously restricting the switching times to occur only

at the discrete time grid points is O(√

∆t). Next, we replaced the conditional expectations with

a projection Pm on a finite dimensional orthonormal family in L2(P). In Carmona and Ludkovski

(2005) it was proven that the resulting error for computing Jk is O(∆t−k ·(mean projection error)),

however empirically the dependence on ∆t is much better. Finally, we further approximated the

projections by an empirical regression using Np realizations of the paths (xnm∆t, n = 1, . . . ,Np).

This error is difficult to analyze due to interactions between the path-by-path maximum taken in

(13) and the across-the-paths regression. Thus, we do not know the precise convergence behavior

but conjecture that the error is O((∆t · Np)−1/2) which is the expected rate for Monte Carlo

methods. Table 1 illustrates this conjecture on Example 2 below. We run the PLSM algorithm using

8000− 40000 Monte Carlo paths and tabulate the resulting standard errors. We indeed observe

something of a O((Np)−1/2) convergence. Note that besides the sampling error, there are also other

errors present related to fixing basis functions, etc.

5. Numerical Results.

Example 1. As a first illustration of our approach, consider a facility with a total capacity of 8

billion cubic feet (Bcf ≡ 106 mmBtu) rented out for one year. The price process is taken from the

data of de Jong and Walet (2003),

Carmona and Ludkovski: Optimal Switching for Gas Storage14 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

Table 1 Convergence of Monte Carlo error for Example 2 under the PLSM scheme. Standard deviations were

obtained by running the algorithm 50 times.

No. Paths Np Mean Std. Dev

8000 14.24 4.8116000 10.03 2.0824000 9.42 1.4832000 8.63 0.94040000 8.51 0.698

Table 2 Comparison of numerical results for Example 1. Values are in millions of dollars. Standard deviations

were obtained by running the Monte Carlo methods 50 times. The initial gas price is G0 = 3, initial

inventory is I0 = 4 Bcf and initial regime is ‘store’. The simulation schemes converged for K = 7.

Method Mean Std. Dev Time (m)Coarse FD 6.90 - 24Fine FD 6.97 - 65MI TvR 7.11 0.021 47PLSM 7.04 0.038 32

d logGt = 17.1 · (log 3− logGt)dt+1.33dWt.

Observe the very fast mean-reversion of the prices, with a half-life of∼ 20 days. The initial inventory

is 4 Bcf and the terminal condition is J(T, g, c, i) = −2 · g ·max(4 − c,0). The other annualized

parameters in (1) areain = 0.06 · 252, b= 0.1,aout = 0.25 · 252, C = 0.25.

We solve this storage problem using three different solvers: an explicit finite-difference PDE solver

discretizing (9), a mixed interpolation-regression scheme based on Tsitsiklis-van Roy algorithm

(MI TvR) and a pure 2-d regression scheme based on Longstaff-Schwartz algorithm (PLSM). The

results are summarized in Table 2. The first PDE solver used a 300× 300 grid and 10000 time

steps. The second used a finer 500×500 grid and 16000 time steps. The interpolation scheme used

400 time steps, 10000 paths with six basis functions and 80 grid points in the I-dimension. The

pure 2-d regression used 400 time steps and 40000 paths with fifteen basis functions.

We do not have an intuition which method is the most accurate, but it is reassuring to see

all three values within 2.5% of each other. Let us also point out the long times required to run

each method indicating the computational challenges involved. In this light, the 45% time savings

obtained by the joint (G,I)-regression scheme become crucial from a practical point of view.

Figure 1 shows the value function J(t, g, c, i) as a function of current price and inventory for an

intermediate time t= 0.5 and mode ‘store’. Not surprisingly, higher inventory increases the value

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 15

Figure 1 Value function surface for Example 1 showing J(0.5, g, c, ‘store‘;T = 1) as a function of current gas price

Gt = g and current inventory It = c.

function since one has the opportunity to simply sell the excess gas on the market. In the Gt-

direction we observe a parabolic shape with a minimum around the long-term mean Gt = 3. This

suggests that deviations of Gt from its mean imply higher future profits, confirming our intuition

about storage acting as a straddle.

Example 2. A second example uses the situation presented in Thompson et al. (2003). It incor-

porates a more realistic model by using a jump-diffusion for the gas price and letting the current

inventory affect the injection and withdrawal rates. The storage costs in this case are zero and the

switching costs are small. Translating the given operational constraints into our notation we have

dGt = 0.25 · (2.5−Gt)dt+0.2Gt dWt +(ξt−Gt)dNt, ξt ∼N (6,4)

where Nt is an independent Poisson process with intensity λ = 2. The operating regimes are

described by inject ψ−1 =−f−1(It)− 1.7 ∗ 365, dIt =(f−1(It)− 1.7 ∗ 365

)dt,

store ψ0 = 0, dIt = 0,withdraw ψ1 = f1(It), dIt =−f1(It)dt,

(16)

with f1(c) = 2040√c and f−1(c) = 730000

√1

c+500− 1

2500. These reward rates are related to ideal gas

law which states that gas transmission rate is proportional to pressure in the reservoir which in

turn is inversely quadratically related to gas volume. The facility capacity is cmax = 2000 mmBtu

and the horizon is T = 1 one year.

Carmona and Ludkovski: Optimal Switching for Gas Storage16 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

Figure 2 Value function J(t, g0, c0, ‘store′) for Example 2 against time to maturity T − t.

The reference paper Thompson et al. (2003) presents results only in graphical format so we can

only verify that our valuations are in the same ballpark. Figure 2 plots J(t, g0, c0, ‘store′) for

(g0, c0) = (6,0) as a function of t. Because of time-homogeneity, this is equal to solving the original

gas storage problem with horizon T − t. Due to the need to build up inventory before selling it we

see that the value function is convex in time to maturity T − t.

6. Hedging Supply Guarantees.

The model developed in the previous section can be used as a foundation for analyzing the problem

of hedging ‘firm supply’ (as opposed to flexible supply) contracts which are common in the power

industry. The basic setup involves an energy merchant with a gas-fired power plant who signs a

fixed price contract guaranteeing delivery of electricity to a utility during a specified period. Thus,

the merchant becomes the Load Serving Entity (LSE). Given the crucial economic role of electricity,

LSE’s are under strict obligation of delivering power under all circumstances. As a result, the agent

is exposed to two simultaneous risks. First, she is exposed to price risk related to purchasing the

gas needed to run the plant. Second, she is exposed to volume risk, because the actual amount Lt

of power demanded at time t is stochastic and will only be determined at t. It depends on a variety

of factors including weather, state of economy, market prices, etc. The volume risk is generally

very tough to hedge and presents a major source of concern because of strong positive correlation

between demand and fuel prices (e.g. on hot summer days when electricity demand peaks, gas

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 17

prices tend to spike as well). For example, a major reason for the bankruptcy of several California

utilities in the summer of 2001 was their failure to obtain cheap gas for running their plants in the

summer.

Given this situation, the only conservative method of hedging volume risk is having direct and

guaranteed access to cheap fuel. The ideal vehicle for this purpose is gas storage that allows the

agent to buy gas early and lock in lower prices during the off-season. Given the uncertainty of the

demand and the flexibility of gas storage, our task is now to build up a gas inventory to match

the total cumulative load at the lowest total cost. For simplicity, we assume that the conversion of

gas to power (the heat rate) is deterministic so that we can restrict our attention to just the gas

market. Mathematically, the agent therefore needs to solve a gas storage problem that now also

involves consumption at a stochastic rate Lt. We assume that if the agent does not have any gas in

the facility, she will have to buy it on the open market at a large premium of e.g. 100%. This reflects

penalties associated with buying real-time gas versus the cheaper week-ahead (or month-ahead)

contracts.

Before we solve the problem we need to specify the joint dynamics of gas prices Gt and demand

load Lt. One reasonable model is to take the demand to be a mean-reverting process with a

time-dependent level. Hence,

dLt = κL(θLt −Lt)dt+σLdW

2t , (17)

where W 2t is a Brownian motion correlated with W 1 that drives Gt. The mean-reverting level θL

t

can be used to model the seasonal power demand with higher consumption in the peak seasons.

We will continue to assume that the gas prices Gt follow an exponential OU process, cf. (3).

Defining the value function as J(t, g, c, l, i), and taking Xt = (Gt, It,Lt) we have a modified gas

storage problem given by

J(t, g, c, l, i) M= supu∈U(t)

E[∫ T

t

ψus(s,Xs)ds−∑τk<T

C(uτk−, uτk)∣∣∣Xt = (g, c, l), ut = i

], (18)

and with the regimes ψi similar to (1) with additional inventory consumption at rate Lt dt.

Example 3. To illustrate the results we re-use the gas storage Example 1 from the previous

section. We assume that

dLt = 2 · (4 · (1+0.1cos(4πt))−Lt)dt+σLdW2t , d〈W 1,W 2〉t = 0.8dt,

so that the total mean expected load over one year is about 4 mmBtu. The positive correlation

between W 1 and W 2 indicates that the gas price increases together with demand, reflecting supply

Carmona and Ludkovski: Optimal Switching for Gas Storage18 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

shortages. The fluctuation in the mean level of Lt models the bi-yearly seasonality of demand.

Since the average gas price is three dollars per kBtu, without the storage facility the agent will

need to pay about $12 million plus hedging costs. The agent receives the facility empty, and the

total capacity is again 8 mmBtu. The switching costs are set to be pretty high at 0.25 million

dollars.

Table 3 summarizes the expected costs as we vary the amount of time available and the volatility

σL of the load. We see that as the amount of time increases, the relative cost declines and in fact

with a horizon of one year the agent has plenty of time to engage in speculative storage trading on

top of hedging the demand. We also see that as expected, more volatile load costs more since the

agent has less information about how much would be needed and hence will try to superhedge to

avoid the penalty of not having enough. Observe that even though the expected demand is quite

flat in time, the expected cost is clearly convex in the length of the contract. Also, even though

demand volatility only has a second-order effect, its impact is still significant compared to the total

savings from storage (e.g. about 0.9 million over 6 months).

Table 3 Price of power supply guarantee in millions of USD for Example 3. We use the PLSM scheme with

32000 paths and ∆t = 1/400.

Maturity Demand Vol. Demand Vol. Demand Vol.in Months σL = 0.2 σL = 0.4 σL = 0.8

3 3.27 3.24 3.266 5.06 5.10 5.129 6.31 6.33 6.3712 6.95 7.02 7.07

7. Further Extensions.

Natural resource management is another real option that fits into our framework. Indeed, problems

such as management of metal mines, forests and hydro-power have a very similar structure. In all

cases, we are faced with fluctuating sale prices, inventory, and a small number of states that can

describe the facility state. Below we elaborate on some of the possibilities.

Mine management was already studied in Ludkovski (2005). The inventory is the total amount

of resource to be extracted, and the management controls the mine operating regimes given current

metal price Gt. In this situation, It is a non-decreasing process (since resource is only extracted,

never to be replenished) and exhaustion means that J(t, g,0, i) = 0. Armed with our methodology

we can redo the copper mine example analyzed in Brennan and Schwartz (1985) and in a much

more efficient manner.

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 19

In hydro-electric applications, the output is electricity that is sold on the power markets, so Gt

is the (spot) power price. On the other hand, the inventory is the current amount of water in the

dammed reservoir. Running the turbine depletes the reservoir so again It is non-decreasing. One

can also model the spring river run-off which is likely to be stochastic as well. A similar model has

recently been considered by McNickle et al. (2004).

Another application area is emissions trading, Insley (2003). A firm running a factory is subject

to emission laws and must account for its pollution by buying emission permits. Those permits

are nowadays publicly traded at price Gt. The non-increasing inventory It in this case corresponds

to the total number of remaining factory orders that must filled in the current period. Hence, the

management must satisfy all the orders while minimizing emission costs. This setup is similar to

supply guarantees, with an additional constraint of It ≤Ot where Ot is a cumulative order summary

supplied by the customers. Violation of this constraint causes a severe penalty as the firm misses

its shipment.

Many other situations can be imagined—forest management, oilfield development, pipeline ship-

ping, etc. From the description it should be evident that our numerical algorithm should carry

over easily to the new settings. Our point is that optimal switching with inventory is in fact a

widespread financial setting with many practical applications.

7.1. Delay and Time Separation.

An important feature of a realistic model is operational delay. Changing the operating regime of a

physical facility is not only costly, but also takes a significant amount of ramping time. To model

this phenomenon we may want to assume that each switch has a delay of δ. This means that if we

decide to switch at time t, the actual regime switch and the corresponding payoff are only realized

at t+ δ. Delay makes the operator more risk-averse because he is now exposed to additional price

risk between t and t+ δ.

Delay introduces memory into our Markov setting and causes technical difficulties, see for exam-

ple work of Bar-Ilan et al. (2002) on real options with installation delay. However, as an approxi-

mation of time delay we can impose time separation i.e. the constraint τk > τk−1 + δ. This models

the situation where the effect of the switch takes place immediately but then the plant is locked-

up for a period of δ2. Clearly, such situation is less risky than true delay because decisions have

instantaneous impact, however it does limit the flexibility of the operator. The advantage is that

separation is very convenient to implement. Instead of evaluating E[Jk(t+∆t,Xt+∆t, i)|Ft] we now

need to compute E[Jk(t+ δ,Xt+δ, i)∣∣Ft] the conditional expectation δ/∆t steps ahead, which is as

easy as the original computation.

2 See also Carmona and Touzi (2005) for a related discussion in the case of power swing options.

Carmona and Ludkovski: Optimal Switching for Gas Storage20 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

7.2. Incorporating Other Features.

We are fully aware that from a practical standpoint the models presented have been gross sim-

plifications. To somewhat ameliorate this fact, let us discuss what additional features one might

want to add for a more realistic implementation. First of all, energy prices are observed to be

spiky and time-dependent. Thus, as already described (and implemented in Example 2) it may be

desirable to incorporate jumps in Gt. Upward jumps can be added straightforwardly; downward

jumps must be used with care because the value function may cease to be smooth, cf. Ludkovski

(2005). In principle, smoothness is not necessary, however the projected conditional expectations

will have difficulty approximating non-smooth functions. Similarly, time-dependent coefficients of

Gt-dynamics, time-dependent switching costs and reward rates or the latter depending on current

Gt are all straightforward to incorporate.

For some facilities, a crucial feature is maintenance. Sometimes a malfunction will occur and the

facility must be shut down for emergency maintenance. This is in contrast to scheduled repairs

which can be accounted as simply additional operational constraints. For simplicity let us assume

that emergency maintenance shutdowns are completely unpredictable and occur independently

with a constant intensity rate λ. Letting Tk represent the random time of the k-th emergency, we

have P[Tk ≥ s+ Tk−1] = e−λs. Since the times between outages have the memoryless exponential

distribution, the recursive construction (5) becomes

Jk(t, x, i) = supτ∈St

E[∫ τ

t

e−λ(s−t)(ψi(s,Xs)+λ(Jk−1(s,Xs,0)−Ci,0)

)ds

+e−λ(τ−t) maxj 6=i

(Jk−1(τ,Xτ , j)−Ci,j

)∣∣∣Xt = x],

where the first term represents the probability of an outage and a forced switch to mode ‘off’ before

τ . The last equation can now be easily discretized in time.

Finally, let us mention some features that are not easily implementable in our framework. First

and foremost these include ‘memory’ properties of storing gas that destroy the Markov property

of Gt. For instance, the leakage rate may be a function of the time the gas has been in the cave,

meaning that ψi(s,Gs, Is) also depends on the time since last switch. Second, the dynamics of Gt

might be affected by the choice of strategy. This will happen for example if the operator has market

power and its policy affects prices. The last case brings out the weak point of our framework.

Our computational scheme is based on the ability of initially simulating Gt by itself, and then

finding the optimal policy along those paths. Hence, we require the driving process dynamics to

be de-coupled from the control which restricts the range of situations under consideration.

Carmona and Ludkovski: Optimal Switching for Gas StorageArticle submitted to Management Science; manuscript no. (Please, provide the mansucript number!) 21

8. Conclusion.

This paper presented a simple model for gas storage that emphasizes the intertemporal optionality

of the asset. Assuming that the gas can be bought and sold on the spot market, we maximize the

expected profit given operational constraints, in particular the costly operating regime switches.

While the model sidesteps the possibilities of forward trades, it properly accounts for the dynamic

nature of the problem, which is a crucial aspect of revenue maximization.

Our approach is scalable and robust and we provide a detailed description of implementation. As

our numerical examples attest, the model is computationally efficient and we believe better than

any other proposed in the literature. We hope it can fill in the gap between current practitioner

needs and academic models. Moreover, our strategy is applicable to many related problems, such

as electricity supply guarantees of Load Serving Entities, hydropower generation assets, emission

trading and natural resource management.

Mention future projects??

ReferencesAhn, H., A. Danilova, G. Swindle. 2002. Storing arb. Wilmott 1.

Bar-Ilan, A., A. Sulem, A. Zanello. 2002. Time-to-build and capacity choice. J. Econom. Dynam. Control

26(1) 69–98.

Bensoussan, A., J-L. Lions. 1984. Impulse Control and Quasi-Variational Inequalities. Gauthier-Villars,

Paris.

Brekke, K.A., B. Øksendal. 1994. Optimal switching in an economic activity under uncertainty. SIAM J.

Control Optim. 32(4) 1021–1036.

Brennan, M., E. Schwartz. 1985. Evaluating natural resource investments. Journal of Business 58 135–157.

Carmona, R., V. Durrleman. 2003. Pricing and hedging spread options. SIAM Rev. 45(4) 627–685.

Carmona, R., M. Ludkovski. 2005. Optimal switching with applications to energy tolling agreements Sub-

mitted.

Carmona, R., N. Touzi. 2005. Optimal multiple stopping and valuation of swing options. Math. Finance (to

appear).

de Jong, C., K. Walet. 2003. To store or not to store. Tech. rep., Lacima Research Forum. Www.eprm.com.

Dixit, A. 1989. Entry and exit decisions under uncertainty. Journal of Political Economy 97(3) 620–638.

Dixit, A., R. S. Pindyck. 1994. Investment Under Uncertainty . Princeton University Press.

Eydeland, A., K. Wolyniec. 2003. Energy and Power Risk Management: New Developments in Modeling,

Pricing and Hedging . John Wiley&Sons, Hoboken, NJ.

Carmona and Ludkovski: Optimal Switching for Gas Storage22 Article submitted to Management Science; manuscript no. (Please, provide the mansucript number!)

Hamadene, S., M. Jeanblanc. 2004. On the starting and stopping problem: application in reversible invest-

ments Preprint.

Haugh, M., L. Kogan. 2004. Pricing American options: A duality approach. Oper. Res. 52(2) 258–270.

Insley, M. 2003. On the option to invest in pollution control under a regime of tradable emissions allowances.

Canadian Journal of Economics 35(4) 860–883.

Longstaff, F.A., E.S. Schwartz. 2001. Valuing American options by simulations: a simple least squares

approach. The Review of Financial Studies 14 113–148.

Ludkovski, M. 2005. Optimal switching with application to energy tolling agreements. Ph.D. thesis, Princeton

University.

McNickle, D., E. Read, J. Tipping. 2004. The incorporation of hydro storage into a spot price model for the

New Zealand electricity market. Sixth European Energy Conference: Modelling in Energy Economics

and Policy . Zurich.

Thompson, M., M. Davison, H. Rasmussen. 2003. Natural gas storage valuation and optimization: A real

options approach Technical Report.

Tsitsiklis, J.N., B. Van Roy. 2001. Regression methods for pricing complex American-style options. IEEE

Transactions on Neural Networks 12(4) 694–703.

Wilmott, P., S. Howison, J. Dewynne. 1995. The mathematics of financial derivatives. Cambridge University

Press, Cambridge. A student introduction.

Zervos, M. 2003. A problem of sequential entry and exit decisions combined with discretionary stopping.

SIAM J. Control Optim. 42(2) 397–421.