← regime-switching survival certificate · convergence orders →

Survival under regime switching

The expansion in $\varepsilon = 1/\lambda$, one term at a time.

The hazard rate mean-reverts at speed $\kappa = 2$ towards a level that switches between $\theta_1 = 0.15$ and $\theta_2 = 0.02$, with variance $\sigma_1^2 = 0.0555$ in the first regime and $\sigma_2^2 = 0.0055$ in the second. Order 0 is Vasicek's bond price with the averaged parameters. Order $n$ adds every term through $\varepsilon^n$: the outer series in $E = 1 - e^{-\kappa t}$ and, from order 4, the contribution of the initial layer.

The upper chart shows the partial sums settling onto the numerical solution. The lower chart shows the absolute error of each partial sum on a log scale; the notches are where an error changes sign. Over the orders the error falls by about a factor of $\lambda$ per term, though not every single term, until it reaches the $10^{-12}$ accuracy of the in-browser ODE solver. The table lists each term at one maturity. The expansion is asymptotic, so at small $\lambda$ the terms stop shrinking and further orders no longer help. A term that failed to shrink as $\lambda$ grows would refute the expansion.

The numerical solution integrates the two-state linear ODE by fourth-order Runge–Kutta in your browser. The partial sums are computed from the recursion in all_orders.py, ported to JavaScript, and agree with the Python to $10^{-16}$.