FeynmanKacStochasticVolatilityOptionPricing - crowlogic/arb4j GitHub Wiki

The Feynman-Kac formula is a mathematical theorem that relates partial differential equations (PDEs) with stochastic differential equations (SDEs). It essentially states that the solution to a certain kind of PDE can be represented as an expectation of a function of a solution to an SDE.

For options pricing, we often use a model with stochastic volatility, where the volatility of the underlying asset is not a constant, but rather a stochastic process itself. A famous model of this kind is the Heston model.

Let's consider an option on a single underlying asset. We'll model the price of this asset as a stochastic process $S_t$, and its volatility as another stochastic process $v_t$. According to the Heston model, these processes are governed by the following SDEs:

$$dS_t = \mu S_t dt + \sqrt{v_t} S_t dW^1_t$$

$$dv_t = \kappa(\theta - v_t)dt + \sigma \sqrt{v_t} dW^2_t$$

Here:

  • $\mu$ is the drift rate of the underlying asset.
  • $\sqrt{v_t}$ is the standard deviation of the returns of the asset.
  • $\kappa$ is the rate at which $v_t$ reverts to $\theta$.
  • $\theta$ is the long-run average price variance.
  • $\sigma$ is the volatility of volatility.
  • $dW^1_t$ and $dW^2_t$ are two Wiener processes, which may be correlated with correlation $\rho$.

The price $P_t$ at time $t$ of a European option with strike price $K$ and maturity $T$ can be written as a risk-neutral expectation:

$$P_t = e^{-r(T-t)} \mathbb{E}^{\mathbb{Q}}[(S_T-K)^+]$$

where $\mathbb{Q}$ is the risk-neutral measure, $(S_T-K)^+$ denotes the payoff of the European call option, and $e^{-r(T-t)}$ is the discount factor.

The Feynman-Kac theorem tells us that this expectation is the solution to the following PDE:

$$\frac{\partial P}{\partial t} + \frac{1}{2} v S^2 \frac{\partial^2 P}{\partial S^2} + \rho \sigma v S \frac{\partial^2 P}{\partial S \partial v} + \frac{1}{2} \sigma^2 v \frac{\partial^2 P}{\partial v^2} + (r - \mu) S \frac{\partial P}{\partial S} - rP = 0$$

subject to the terminal condition:

$$P(S,v,T) = (S-K)^+$$

Solving this PDE with this terminal condition will give us the price of the option. Unfortunately, this PDE doesn't have a simple closed form solution and we typically have to resort to numerical methods like finite difference methods, or Monte Carlo simulations to solve it.

We can use the risk-neutral measure with the volatility risk premium explicitly estimated as a parameter rather than baked into the parameters. This can be done using the Girsanov's theorem, which helps us shift from the physical measure to the risk-neutral measure. In this case, the risk premium would serve as the drift adjustment in the theorem.

Is the inverse feasible?

The derivation of the Heston SDEs from the corresponding PDE is not a straightforward process and usually involves reverse engineering and expert knowledge about the system. The Heston SDEs were constructed to replicate specific features observed in market prices, including stochastic volatility. Given the PDE that corresponds to the Heston model, one would need to reverse the Feynman-Kac theorem in some way to obtain the original SDEs.

Unfortunately, the Feynman-Kac theorem does not provide a direct method for reverse engineering a PDE to obtain the corresponding SDE. Therefore, unless one has the specific form of the SDEs in mind (as Heston did when he developed his model), it would be extremely difficult to obtain the SDEs from the PDE.

However, if you already know that the Heston model is the correct model for your system, you can identify the terms in the PDE that correspond to the terms in the Heston SDEs. For example, in the PDE, the term $v S^2 \frac{\partial^2 P}{\partial S^2}$ corresponds to the diffusion term $\sqrt{v_t} S_t dW^1_t$ in the SDE for the asset price, while the term $v \frac{\partial^2 P}{\partial v^2}$ corresponds to the diffusion term $\sigma \sqrt{v_t} dW^2_t$ in the SDE for the volatility. The drift terms in the SDEs can also be matched to terms in the PDE.

In practice, the development of models in quantitative finance often starts with the construction of SDEs that represent the system (e.g. the Black-Scholes model or the Heston model), rather than the reverse.