 Finance - Maple Programming Help

Home : Support : Online Help : Mathematics : Finance : Short Rate Models : Finance/HullWhiteModel

Finance

 HullWhiteModel
 create Hull-White interest rate model

 Calling Sequence HullWhiteModel(theta, alpha, sigma)

Parameters

 theta - observed term structure of interest rates alpha - speed of mean reversion sigma - volatility

Description

 • The HullWhiteModel command creates a Hull-White model with the specified parameters. Under this model the short rate process $r\left(t\right)$ has the following dynamics with respect to the risk-neutral measure

$\mathrm{dr}\left(t\right)=\left(\mathrm{\theta }\left(t\right)-\mathrm{\alpha }r\left(t\right)\right)\mathrm{dt}+\mathrm{\sigma }\mathrm{dW}\left(t\right)$

where $\mathrm{\alpha }$ and $\mathrm{\sigma }$ are non-negative constants and W(t) is a Wiener process modeling the random market risk factor.

Examples

 > $\mathrm{with}\left(\mathrm{Finance}\right):$
 > $\mathrm{times}≔\left[0.08,0.24,0.48,1.0,2.0,5.0,10.0,30.0\right]$
 ${\mathrm{times}}{≔}\left[{0.08}{,}{0.24}{,}{0.48}{,}{1.0}{,}{2.0}{,}{5.0}{,}{10.0}{,}{30.0}\right]$ (1)
 > $\mathrm{rates}≔\left[0.03,0.032,0.035,0.04,0.045,0.05,0.053,0.055\right]$
 ${\mathrm{rates}}{≔}\left[{0.03}{,}{0.032}{,}{0.035}{,}{0.04}{,}{0.045}{,}{0.05}{,}{0.053}{,}{0.055}\right]$ (2)
 > $R≔\mathrm{ZeroCurve}\left(\mathrm{times},\mathrm{rates}\right)$
 ${R}{≔}{\mathbf{module}}\left({}\right)\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{\mathbf{end module}}$ (3)
 > $\mathrm{plot}\left(R,0..30,\mathrm{axes}=\mathrm{BOXED},\mathrm{thickness}=2,\mathrm{gridlines}=\mathrm{true}\right)$ > $M≔\mathrm{HullWhiteModel}\left(R,1.0,0.02\right)$
 ${M}{:=}{\mathbf{module}}\left({}\right)\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{\mathbf{end module}}$ (4)
 > $X≔\mathrm{ShortRateProcess}\left(M\right)$
 ${X}{≔}{\mathrm{_R}}$ (5)
 > $\mathrm{PathPlot}\left(X\left(t\right),t=0..1,\mathrm{timesteps}=50,\mathrm{replications}=20,\mathrm{axes}=\mathrm{BOXED},\mathrm{thickness}=2,\mathrm{color}=\mathrm{red}..\mathrm{blue},\mathrm{gridlines}=\mathrm{true}\right)$ Here is the corresponding short-rate tree.

 > $T≔\mathrm{ShortRateTree}\left(M,20,20\right)$
 ${T}{:=}{\mathbf{module}}\left({}\right)\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{\mathbf{end module}}$ (6)
 > $\mathrm{TreePlot}\left(T,\mathrm{axes}=\mathrm{BOXED},\mathrm{thickness}=2,\mathrm{gridlines}=\mathrm{true}\right)$ References

 Brigo, D., Mercurio, F., Interest Rate Models: Theory and Practice, New York: Springer-Verlag, 2001.
 Glasserman, P., Monte Carlo Methods in Financial Engineering, New York: Springer-Verlag, 2004.
 Hull, J., Options, Futures, and Other Derivatives, 5th. edition, Upper Saddle River, New Jersey: Prentice Hall, 2003.
 Vasicek, O.A., An Equilibrium Characterization of the Term Structure, Journal of Financial Economics, 5 (1977), pp 177-188.

Compatibility

 • The Finance[HullWhiteModel] command was introduced in Maple 15.