DEJDCharacteristicFunction
- class quantmetrics.price_calculators.dejd_pricing.dejd_characteristic_function.DEJDCharacteristicFunction(model: LevyModel, option: Option)[source]
Bases:
object
Implements the characteristic function for a lognormal jump-diffusion (LJD) model.
Parameters
- modelLevyModel
A LevyModel object specifying the underlying asset’s model and its parameters.
- optionOption
An Option object specifying the option parameters: interest rate, strike price, time to maturity, dividend yield and the equivalent martingale measure.
- calculate(u: ndarray) ndarray [source]
Calculate the characteristic function for the DEJD model.
Parameters
- unp.ndarray
Input array for the characteristic function.
Returns
- np.ndarray
The characteristic function values.
Notes
The characteristic function of the DEJD under the risk-neutral measure is defined as follows:
If
emm = "mean-correcting"
:
\[\Phi^{\mathbb{Q}}(u) = \exp\left\{T \left[i u b^\mathbb{Q} -\frac{u^2}{2}c + \lambda \left( \frac{p\eta_1}{\eta_1 - iu} + \frac{q \eta_2}{\eta_2 + iu} - 1 \right) \right]\right\},\]where
\[b^\mathbb{Q}= r - \frac{\sigma^2}{2} -\lambda \kappa \quad c = \sigma^2\]\[\kappa = \frac{p\eta_1}{\eta_1 -1} + \frac{q\eta_2}{\eta_2+1} - 1, \quad q = 1-p\]If
emm = "Esscher"
andpsi = 0
:
\[\Phi^{\mathbb{Q}}(u) = \exp\left\{T \left[i u b^\mathbb{Q} -\frac{u^2}{2}c + \lambda^\mathbb{Q} \left( \frac{\frac{p\eta_1}{\eta_1 - (\theta +iu)} + \frac{q\eta_2}{\eta_2 + (\theta + iu)}}{\frac{p\eta_1}{\eta_1 - \theta} + \frac{q\eta_2}{\eta_2 + \theta}} - 1 \right) \right]\right\},\]where
\[b^\mathbb{Q}= r - \frac{\sigma^2}{2} -\lambda \kappa + \theta \sigma^2 \quad c = \sigma^2\]\[\lambda^\mathbb{Q} = \lambda \left( \frac{p\eta_1}{\eta_1 - \theta} + \frac{q\eta_2}{\eta_2 + \theta} \right)\]If
emm = "Esscher"
andpsi != 0
:
\[\Phi^{\mathbb{Q}}(u) = \exp\left\{T \left[i u b^\mathbb{Q} -\frac{u^2}{2}c + \lambda^\mathbb{Q} \left(\frac{p\eta_1 I(\theta+iu, \eta_1, \psi) + q\eta_2 I(\theta +iu, -\eta_2, \psi)}{p\eta_1 I(\theta, \eta_1, \psi) + q\eta_2 I(\theta, -\eta_2, \psi)} - 1 \right)\right] \right\},\]where
\[b^\mathbb{Q}= r - \frac{\sigma^2}{2} -\lambda \kappa + \theta(\psi) \sigma^2 \quad c = \sigma^2\]\[\lambda^\mathbb{Q} = \lambda \frac{1}{2}\sqrt{\frac{\pi}{|\psi|}} \left[p\eta_1 I(\theta, \eta_1, \psi) + q\eta_2 I(\theta, -\eta_2, \psi) \right],\]\[I(a,b,\psi):= \exp \left[-\psi \left(\frac{a-b}{2\psi} \right)^2 \right] \left\{1 - erf\left[\sqrt{|\psi|} \left(\frac{a-b}{2\psi} \right) \right] \right\}\]with
\[\psi < 0.\]The first-order Esscher parameter \(\theta\) is the risk premium (market price of risk) and which is the unique solution to the martingale equation for each \(\psi\) which is the second-order Esscher parameter. See the documentation of the
RiskPremium
class for the martingale equation and refer to [1] for more details.\(\mathbb{Q}\) is the risk-neutral measure.
\(T\) is the time to maturity.
\(i\) is the imaginary unit.
\(u\) is the input variable.
\(r\) is the risk-free interest rate.
\(\sigma\) is the volatility of the underlying asset.
\(p,q\geq 0, p+q =1\) are the probabilities of upward and downward jumps.
The upward jump sizes are exponentially distributed with mean \(1/\eta_1\) with \(\eta_1>1\).
The downward jump sizes are exponentially distributed with mean \(1/\eta_2\) with \(\eta_2 >0\).
\(\lambda\) is the jump intensity rate.
References