Heston model (source code)

= Heston model
{c}
{title2=$(S_t,v_t)$}
{wiki}

The <Heston model> couples a positive stock price to a square-root <variance> process. Under a chosen <risk-neutral measure>, a standard specification with continuous dividend yield $\delta$ is
$$
\frac{dS_t}{S_t}=(r-\delta)dt+\sqrt{v_t}\,dW_t^S,\qquad dv_t=\kappa(\theta-v_t)dt+\eta\sqrt{v_t}\,dW_t^v,
$$
with $d[W^S,W^v]_t=\rho\,dt$, $\kappa,\theta,\eta>0$ and $|\rho|\le1$. Here $\theta$ is long-run <variance>, $\kappa$ the mean-reversion speed, and $\eta$ the scale of variance shocks. The parameters under the pricing measure need not equal those under the physical measure.

The variance is a <CIR model>. It remains nonnegative; for $v_0>0$, $2\kappa\theta\ge\eta^2$ makes zero inaccessible. Correlation $\rho$ couples price changes to subsequent uncertainty, a mechanism absent from constant-volatility <Black-Scholes model>.

The joint process is affine: its conditional log-price <characteristic function> has the form $\exp(iu\log S_t+C(\tau,u)+D(\tau,u)v_t)$, with coefficients solving <Riccati equations>. <Fourier inversion> then prices <European options>. The familiar closed-form description includes a one-dimensional numerical integral, rather than a purely elementary call-price expression.<A Closed-Form Solution for Options with Stochastic Volatility with Applications to Bond and Currency Options by Steven L. Heston>[Model specification and characteristic-function option valuation]{ref}