ajdmom.ito_cond2_mom

Itô process conditional moments under Square-Root Jump Diffusion (SRJD), with condition on the initial state and the realized jumps over the interval.

Note that:

Highlights

This module

  • offers supports for deriving conditional moments for models including jumps in the variance ( SRJD, SVVJ, SVIJ and SVCJ), by

  • assuming that the initial state of the SRJD, and the realized jump times and jump sizes in the SRJD over the concerned interval are given beforehand.

Square-Root Jump Diffusion

The Square-Root Jump Diffusion (SRJD) is described by the following SDE,

\[dv(t) = k(\theta - v(t))dt + \sigma_v\sqrt{v(t)}dw^v(t) + dz(t),\]

which adds a jump component \(z(t)\) (a CPP) into the CIR diffusion. We introduce the following notations for simplification,

\[\begin{split}\begin{align*} I\!Z_t &\triangleq \int_0^tdz(s) ~~\left(\equiv \sum_{i=1}^{N(t)} J_i\right),\\ I\!E\!Z_t &\triangleq \int_0^te^{ks}dz(s) ~~\left(\equiv \sum_{i=1}^{N(t)} e^{ks_i}J_i\right). \end{align*}\end{split}\]

The solution to the SDE can then be expressed as

\[e^{kt}v(t) = (v_0-\theta) + e^{kt}\theta + \sigma_v I\!E_t + I\!E\!Z_t,\]

noting that \(v_0 \equiv v(0)\) and \(I\!E_t \equiv \int_0^t e^{ks}\sqrt{v(s)} dw^v(s)\). Further,

\[e^{kt}(v(t) - \theta) - (v_0-\theta) = \sigma_v I\!E_t + I\!E\!Z_t.\]

In order to derive conditional moment formulae for models including jumps in the variance, SVVJ, SVIJ and SVCJ, we first compute the conditional moments

\[\mathbb{E}[I\!E_t^{n_1} I_t^{n_2} (I_t^{*})^{n_3}|v_0, z(s), 0\le s\le t],\]

noting that \(I_t \equiv \int_0^t \sqrt{v(s)} dw^v(s)\), \(I_t^{*} \equiv \int_0^t \sqrt{v(s)} dw(s)\) and the Brownian motion in the price process is decomposed as \(w^s(t) = \rho w^v(t) + \sqrt{1-\rho^2}w(t)\), refer to the Theory page for the definitions of these quantities.

Recursive Equations

Itô process moment

(1)\[\begin{split}\begin{align*} &\mathbb{E}[ I\!E_t^{n_1} I_t^{n_2} (I_t^{*})^{n_3}|v_0, z(s), 0\le s\le t ] \\ &= \frac{1}{2} n_1(n_1-1)(v_0-\theta)\times&\int_0^t e^{ks} \mathbb{E}[ I\!E_s^{n_1-2}I_s^{n_2}(I_s^{*})^{n_3}]ds\\ &\quad + \frac{1}{2} n_1(n_1-1)\theta \times&\int_0^t e^{2ks} \mathbb{E}[ I\!E_s^{n_1-2}I_s^{n_2}(I_s^{*})^{n_3}]ds\\ &\quad + \frac{1}{2} n_1(n_1-1)\sigma_v \times&\int_0^t e^{ks} \mathbb{E}[ I\!E_s^{n_1-1}I_s^{n_2}(I_s^{*})^{n_3}]ds\\ &\quad + \frac{1}{2} n_1(n_1-1) \times&\int_0^t e^{ks}I\!E\!Z_s \mathbb{E}[ I\!E_s^{n_1-2}I_s^{n_2}(I_s^{*})^{n_3}]ds\\ &\color{blue}\quad + \frac{1}{2} n_2(n_2-1)(v_0-\theta) \times&\color{blue}\int_0^t e^{-ks} \mathbb{E}[ I\!E_s^{n_1}I_s^{n_2-2}(I_s^{*})^{n_3}]ds\\ &\color{blue}\quad + \frac{1}{2} n_2(n_2-1)\theta \times&\color{blue}\int_0^t \mathbb{E}[ I\!E_s^{n_1}I_s^{n_2-2}(I_s^{*})^{n_3}]ds\\ &\color{blue}\quad + \frac{1}{2} n_2(n_2-1)\sigma_v \times&\color{blue}\int_0^t e^{-ks} \mathbb{E}[ I\!E_s^{n_1+1}I_s^{n_2-2}(I_s^{*})^{n_3}]ds\\ &\color{blue}\quad + \frac{1}{2} n_2(n_2-1) \times&\color{blue}\int_0^t e^{-ks}I\!E\!Z_s \mathbb{E}[ I\!E_s^{n_1}I_s^{n_2-2}(I_s^{*})^{n_3}]ds\\ &\quad + n_1n_2(v_0-\theta) \times&\int_0^t \mathbb{E}[ I\!E_s^{n_1-1}I_s^{n_2-1}(I_s^{*})^{n_3}]ds\\ &\quad + n_1n_2\theta \times&\int_0^t e^{ks} \mathbb{E}[ I\!E_s^{n_1-1}I_s^{n_2-1}(I_s^{*})^{n_3}]ds\\ &\quad + n_1n_2\sigma_v \times&\int_0^t \mathbb{E}[ I\!E_s^{n_1}I_s^{n_2-1}(I_s^{*})^{n_3}]ds\\ &\quad + n_1n_2 \times&\int_0^t I\!E\!Z_s \mathbb{E}[ I\!E_s^{n_1-1}I_s^{n_2-1}(I_s^{*})^{n_3}]ds\\ &\color{blue}\quad + \frac{1}{2}n_3(n_3-1)(v_0-\theta) \times&\color{blue} \int_0^t e^{-ks} \mathbb{E}[ I\!E_s^{n_1} I_s^{n_2} (I_s^{*})^{n_3-2}]ds\\ &\color{blue}\quad + \frac{1}{2}n_3(n_3-1)\theta \times&\color{blue} \int_0^t \mathbb{E}[ I\!E_s^{n_1} I_s^{n_2} (I_s^{*})^{n_3-2}]ds\\ &\color{blue}\quad + \frac{1}{2}n_3(n_3-1)\sigma_v \times&\color{blue} \int_0^t e^{-ks} \mathbb{E}[ I\!E_s^{n_1+1} I_s^{n_2} (I_s^{*})^{n_3-2}]ds\\ &\color{blue}\quad + \frac{1}{2}n_3(n_3-1) \times&\color{blue} \int_0^t e^{-ks} I\!E\!Z_s \mathbb{E}[ I\!E_s^{n_1} I_s^{n_2} (I_s^{*})^{n_3-2}]ds, \end{align*}\end{split}\]

in which, for notation simplification, the condition notation \(|v_0, z(s), 0\le s\le t\) is also removed from all conditional expectations on the right-hand side of above equation.

We decode \(\mathbb{E}[I\!E_t^{n_1} I_t^{n_2} (I_t^{*})^{n_3}|v_0, z(s), 0\le s\le t]\) as the following Poly,

\[\mathbb{E}[I\!E_t^{n_1}I_t^{n_2}I_t^{*n_3}|v_0, z(s), 0\le s \le t] = \sum_{\boldsymbol{j}, \boldsymbol{l}, \boldsymbol{o} } c_{\boldsymbol{j}\boldsymbol{l}\boldsymbol{o}} e^{j_1kt} t^{j_2} k^{-j_3} (v_0-\theta)^{j_4} \theta^{j_5} \sigma_v^{j_6} f_{Z_t}(\boldsymbol{l}, \boldsymbol{o}),\]

where \(c_{\boldsymbol{j}\boldsymbol{l}\boldsymbol{o}}\) denotes the corresponding coefficient, vector \(\boldsymbol{j} \equiv (j_1,\dots,j_6)\),

\[\begin{split}\boldsymbol{l} \equiv \begin{cases} (l_1,\dots,l_n) & \text{if } n \ge 1,\\ & \text{otherwise}, \end{cases} \quad \boldsymbol{o} \equiv \begin{cases} (o_1,\dots,o_n) & \text{if } n \ge 1,\\ & \text{otherwise}, \end{cases}\end{split}\]

\(n\) denotes the number of CPPs being multiplied together, and function \(f_{Z_t}(\boldsymbol{l}, \boldsymbol{o})\) is defined as

(2)\[\begin{split} \begin{align*} &f_{Z_t}(\boldsymbol{l}, \boldsymbol{o})\\ &\equiv \begin{cases} \sum_{i_1=1}^{N(t)} \cdots \sum_{i_n=1}^{N(t)} \left[\prod_{p=1}^n \left[e^{ks_{i_p}} J_{i_p} \cdot e^{l_p k (s_{i_1}\vee \cdots \vee s_{i_p} )}(s_{i_1}\vee \cdots \vee s_{i_p} )^{o_p} \right] \right] & \text{if } n \ge 1,\\ 1 & \text{otherwise}. \end{cases} \end{align*}\end{split}\]

Please note that \(s_{i_1}\vee \cdots \vee s_{i_p} \equiv \max\{s_{i_1},\dots,s_{i_p} \}\).

Formulae for \(n_1+n_2=2\) combinations,

\[\begin{split}\begin{align*} &\mathbb{E}[I\!E_t^2 |v_0, z(s), 0\le s\le t] \\ &= (v_0-\theta)k^{-1}(e^{kt}-1) + \frac{1}{2}\theta k^{-1} (e^{2kt} - 1) + k^{-1}\sum_{i=1}^{N(t)} e^{ks_i}J_i (e^{kt} - e^{ks_i})\\ &=~~ e^{kt}t^0k^{-1} (v_0-\theta)^1 \theta^0 \sigma_v^0 f_{Z_t}((),()),\\ &\quad - e^{0kt} t^0 k^{-1} (v_0-\theta)^1 \theta^0 \sigma_v^0 f_{Z_t}((),()),\\ &\quad + \frac{1}{2} e^{2kt} t^0 k^{-1} (v_0-\theta)^0 \theta^1 \sigma_v^0 f_{Z_t}((),()),\\ &\quad - \frac{1}{2} e^{0kt} t^0 k^{-1} (v_0-\theta)^0 \theta^1 \sigma_v^0 f_{Z_t}((),()),\\ &\quad + e^{kt} t^0 k^{-1} (v_0-\theta)^0 \theta^0 \sigma_v^0 f_{Z_t}((0),(0)),\\ &\quad - e^{0kt} t^0 k^{-1} (v_0-\theta)^0 \theta^0 \sigma_v^0 f_{Z_t}((1),(0)), \end{align*}\end{split}\]
\[\begin{split}\begin{align*} &\mathbb{E}[I\!E_t I_t |v_0, z(s), 0\le s\le t] \\ &= (v_0-\theta) t + \theta k^{-1} (e^{kt} - 1) + \sum_{i=1}^{N(t)} e^{ks_i}J_i (t-s_i)\\ &=~~ e^{0kt} t^1 k^{-0} (v_0-\theta)^1 \theta^0 \sigma_v^0 f_{Z_t}((),()),\\ &\quad + e^{kt} t^0 k^{-1} (v_0-\theta)^0 \theta^1 \sigma_v^0 f_{Z_t}((),()),\\ &\quad - e^{0kt} t^0 k^{-1} (v_0-\theta)^0 \theta^1 \sigma_v^0 f_{Z_t}((),()),\\ &\quad + e^{0kt} t^1 k^{-0} (v_0-\theta)^0 \theta^0 \sigma_v^0 f_{Z_t}((0),(0)),\\ &\quad - e^{0kt} t^0 k^{-0} (v_0-\theta)^0 \theta^0 \sigma_v^0 f_{Z_t}((0),(1)), \end{align*}\end{split}\]
\[\begin{split}\begin{align*} &\mathbb{E}[I_t^2 |v_0, z(s), 0\le s\le t] \\ &= -(v_0-\theta)k^{-1}(e^{-kt} - 1) + \theta t - k^{-1}\sum_{i=1}^{N(t)} e^{ks_i}J_i (e^{-kt} - e^{-ks_i})\\ &= - e^{-kt} t^0 k^{-1} (v_0-\theta)^1 \theta^0 \sigma_v^0 f_{Z_t}((),()),\\ &\quad + e^{0kt} t^0 k^{-1} (v_0-\theta)^1 \theta^0 \sigma_v^0 f_{Z_t}((),()),\\ &\quad + e^{0kt} t^1 k^{-0} (v_0-\theta)^0 \theta^1 \sigma_v^0 f_{Z_t}((),()),\\ &\quad - e^{-kt} t^0 k^{-1} (v_0-\theta)^0 \theta^0 \sigma_v^0 f_{Z_t}((0),(0)),\\ &\quad + e^{0kt} t^0 k^{-1} (v_0-\theta)^0 \theta^0 \sigma_v^0 f_{Z_t}((-1),(0)). \end{align*}\end{split}\]

Integrals

The essential computation now becomes

(3)\[\int_{0}^t e^{iks} s^j f_{Z_s}(\boldsymbol{l}, \boldsymbol{o}) ds.\]

We first present the result and implementation as the following:

\[\int_{0}^t e^{iks} s^j f_{Z_s}(\boldsymbol{l}, \boldsymbol{o}) ds = F_{Z_t}(\boldsymbol{l}, \boldsymbol{o}, i, j),\]

where the function on the right-hand side is defined as

\[\begin{split}\begin{align*} &F_{Z_t}(\boldsymbol{l},\boldsymbol{o}, i, j)\\ &\equiv \sum_{i_1=1}^{N(t)} \cdots \sum_{i_n=1}^{N(t)} \left[\prod_{p=1}^n \left[e^{ks_{i_p}} J_{i_p} \cdot e^{l_p k (s_{i_1}\vee \cdots \vee s_{i_p} )}(s_{i_1}\vee \cdots \vee s_{i_p} )^{o_p} \right] \right] \cdot \int_{s_{i_1}\vee \cdots \vee s_{i_n}}^t e^{iks} s^j ds, \end{align*}\end{split}\]

if \(n \ge 1\), otherwise, \(F_{Z_t}(\boldsymbol{l},\boldsymbol{o}, i, j)\equiv\int_{0}^t e^{iks} s^j ds\).

The integral in (3) is implemented in int_et_fZ() in module ito_cond2_mom. The integral \(\int_{s_{i_1}\vee \cdots \vee s_{i_n}}^t e^{iks} s^j ds\) is calculated as we did for \(\int_0^t e^{iks} s^j ds\) in ajdmom.ito_mom.

Then, we explain the calculations. Let’s take a look at a simple example, \(\int_0^te^{ks}I\!E\!Z_s ds\).

\[\begin{split}e^{ks}I\!E\!Z_s = \begin{cases} 0, &0 ~~~~ \le s<s_1,\\ e^{ks}\sum_{i=1}^1 e^{ks_i}J_i, &s_1~~~ \le s<s_2,\\ & \vdots \\ e^{ks}\sum_{i=1}^{N(t)-1} e^{ks_i}J_i, &s_{N(t)-1} \le s<s_{N(t)},\\ e^{ks}\sum_{i=1}^{N(t)} e^{ks_i}J_i, &s_{N(t)}~~~ \le s< t. \end{cases}\end{split}\]
\[\begin{split}\begin{align*} &\int_0^t e^{ks}I\!E\!Z_s ds\\ &= \int_0^{s_1} e^{ks}I\!E\!Z_s ds + \int_{s_1}^{s_2} e^{ks}I\!E\!Z_s ds + \cdots + \int_{s_n}^{t} e^{ks}I\!E\!Z_s ds\\ &= \frac{1}{k}(e^{ks_2} - e^{ks_1}) \sum_{i=1}^{1}e^{ks_i}J_i + \cdots + \frac{1}{k}(e^{ks_n} - e^{ks_{n-1}})\sum_{i=1}^{N(t)-1}e^{ks_i}J_i\\ & \quad + \frac{1}{k}(e^{kt} - e^{ks_n})\sum_{i=1}^{N(t)}e^{ks_i}J_i\\ &= \sum_{i=1}^{N(t)} e^{ks_i}J_i \frac{1}{k}(e^{kt} - e^{ks_i}). \end{align*}\end{split}\]

In short,

\[\begin{split}\begin{align*} I\!E\!Z_t &= \sum_{i=1}^{N(t)} e^{ks_i}J_i,\\ \int_0^t e^{ks}I\!E\!Z_s ds &= \sum_{i=1}^{N(t)} e^{ks_i}J_i \frac{1}{k} (e^{kt} - e^{ks_i}). \end{align*}\end{split}\]

Another example

\[\int_0^t e^{ks} I\!E\!Z_s I\!E\!Z_s ds = ?\]
\[\int_0^t e^{ks} \sum_{i=1}^{N(s)}\sum_{j=1}^{N(s)} e^{ks_i+ks_j}J_iJ_jds = \sum_{i=1}^{N(t)}\sum_{j=1}^{N(t)}e^{ks_i+ks_j}J_iJ_j \frac{1}{k} (e^{kt} -e^{k(s_i\vee s_j)}).\]

Hopefully, the two examples should have explained the derivation well.

Implementation summary

  1. Define recursive_IEII() to realize the recursive step in equation (1).

  2. Define moment_IEII() to finish the computation of \(\mathbb{E}[I\!E_t^{n_1}I_t^{n_2}(I_t^{*})^{n_3}|v_0, z_s, 0\le s\le t]\).

Functions

int_e_IEZ_poly(coef, m, poly)

integral of \(coef \times \int_0^t e^{mks} I\!E\!Z_s poly ds\)

int_e_poly(coef, tp, m, poly)

integral of \(coef \times tp \times \int_0^t e^{mks} poly ds\)

int_et_fZ(n, m, N_sum)

integral of \(\int_0^t e^{iks} s^j f_{Z_s}(l,o)ds\)

moment_IEII(n1, n2, n3)

\(\mathbb{E}[I\!E_t^{n_1}I_t^{n_2}(I_t^{*})^{n_3} |v_0, z(s), 0\le s\le t]\)

poly2num(poly, par)

Convert a polynomial to numerical value

recursive_IEII(n1, n2, n3, IEII)

Recursive step in equation (1)