The basis for the virtual power plant (VPP) pricing algorithm is a joint stochastic process for the power price and the gas price. Instead of defining a stochastic differential equation for the spark spread directly the spark spread is then given by the difference between the power price and the gas price times the VPP heating rate.

The Kluge model will be used to define the power price process [1], an exponential Ornstein-Uhlenbeck will describe the gas price [2]

where is a Poisson process with jump intensity . To match the power forward curve the seasonal function is given by [1]:

To be consistent with the gas forward curve the seasonal function is defined by

The Feynman-Kac theorem can be applied to derive the corresponding three-dimensional partial integro differential equation

In general at least one further dimension is needed to keep track of the state of the virtual power plant. Therefore solving this model using finite difference methods will lead to a four-dimensional PIDE problem.

The following diagram shows an one year example path for the power and the gas price based on the freely available Kyos example forward curves. The sample parameterization is affected by [1] for the power process and [2] for the gas process.

The code is available here. It depends on the latest QuantLib version from the SVN trunk. If you want to generate the plot directly out of the C++ program you also need R, RCPP and RInside.

[1] T. Kluge, Pricing Swing Options and other Electricity Derivatives

[2] G. Fusai, A. Roncoroni, Implementing Models in Quantitative Finance: Models and Cases, Chapter 19, ISBN: 978-3-540-22348-1

### Like this:

Like Loading...

*Related*

[…] HPC-QuantLib HomeAbout ← VPP Pricing I: Stochastic Processes & Partial Integro Differential Equation […]

Hi,

Thank you for all the detailed examples and codes you provide. I’m actually interested in testing the c++ code of this model and I am wondering if it is possible to have the related data (EEX, and TTF). I was not able to get them form the Kyos website.

Usually gas prices are daily (not hourly), right? So how di you manage to populate your ttfShape with hourly data?

Best regards,

Adel

Unfortunately it seems that the example data is no longer available on that website. I’ll send you an example via email.

Sure, you right, gas prices are daily prices. For the sake of simplicity I’ve “converted” the prices to hourly granularity by keeping the price constant over a day (even ignoring that a “gas trading day” starts ar 06:00 in the morning).

Is it possible you can send me the data for the code?

Kyos is still providing example curves on their website.