Simulate approximate solution of diagonal-drift
[Paths, Times, Z] = simBySolution(MDL, NPERIODS)
[Paths, Times, Z] = simBySolution(MDL, NPERIODS, 'Name1',
Value1,'Name2', Value2, ...)
simBySolution method simulates
NVARS correlated state variables, driven
NBROWNS Brownian motion sources of risk over
observation periods, approximating continuous-time Hull-White/Vasicek
HWV), and geometric Brownian motion (
short-rate models by an approximation of the closed-form solution.
Consider a separable, vector-valued
of the form:
X is an NVARS-by-1 state vector of process variables.
S is an NVARS-by-NVARS matrix of mean reversion speeds (the rate of mean reversion).
L is an NVARS-by-1 vector of mean reversion levels (long-run mean or level).
V is an NVARS-by-NBROWNS instantaneous volatility rate matrix.
W is an NBROWNS-by-1 Brownian motion vector.
or a separable, vector-valued
GBM model of
Xt is an
state vector of process variables.
μ is an
generalized expected instantaneous rate of return matrix.
V is an
volatility rate matrix.
dWt is an
Brownian motion vector.
simBySolution method simulates
the state vector Xt using
an approximation of the closed-form solution of diagonal-drift models.
When evaluating the expressions,
that all model parameters are piecewise-constant over each simulation
In general, this is not the exact solution to the models, because the probability distributions of the simulated and true state vectors are identical only for piecewise-constant parameters.
When parameters are piecewise-constant over each observation period, the simulated process is exact for the observation times at which Xt is sampled.
|Positive scalar integer number of simulation periods. The value of this argument determines the number of rows of the simulated output series.|
Specify optional input arguments as variable-length lists of
matching parameter name/value pairs:
... and so on. The following rules apply when specifying parameter-name
Specify the parameter name as a character string, followed by its corresponding parameter value.
You can specify parameter name/value pairs in any order.
Parameter names are case insensitive.
You can specify unambiguous partial string matches.
Valid parameter names are:
|Positive scalar integer number of simulated trials (sample
paths) of |
|Scalar or |
|Positive scalar integer number of intermediate time steps within
each time increment dt (specified as |
|Scalar logical flag that indicates whether antithetic sampling
is used to generate the Gaussian random variates that drive the Brownian
motion vector (Wiener processes). When |
|Direct specification of the dependent random noise process
used to generate the Brownian motion vector (Wiener process) that
drives the simulation. Specify this argument as a function, or as
|Scalar logical flag that indicates how |
|Function or cell array of functions that indicates a sequence
of end-of-period processes or state vector adjustments of the form |
you specify more than one processing function,
you do not specify a processing function,
The input argument
Z allows you
to directly specify the noise generation process. This process takes
precedence over the
Correlation parameter of the
and the value of the
Antithetic input flag. If
you do not specify a value for
correlated Gaussian variates, with or without antithetic sampling
Gaussian diffusion models, such as
allow negative states. By default,
nothing to prevent negative states, nor does it guarantee that the
model be strictly mean-reverting. Thus, the model may exhibit erratic
or explosive growth.
allows you to terminate a given trial early. At the end of each time
simBySolution tests the state vector Xt for
NaN condition. Thus, to signal an early
termination of a given trial, all elements of the state vector Xt must
NaN. This test enables a user-defined
to signal early termination of a trial, and offers significant performance
benefits in some situations (for example, pricing down-and-out barrier
Ait-Sahalia, Y., "Testing Continuous-Time Models of the Spot Interest Rate," The Review of Financial Studies, Spring 1996, Vol. 9, No. 2, pp. 385–426.
Ait-Sahalia, Y., "Transition Densities for Interest Rate and Other Nonlinear Diffusions," The Journal of Finance, Vol. 54, No. 4, August 1999.
Glasserman, P., Monte Carlo Methods in Financial Engineering, New York: Springer-Verlag, 2004.
Hull, J. C., Options, Futures, and Other Derivatives, 5th ed. Englewood Cliffs, NJ: Prentice Hall, 2002.
Johnson, N. L., S. Kotz, and N. Balakrishnan, Continuous Univariate Distributions, Vol. 2, 2nd ed. New York: John Wiley & Sons, 1995.
Shreve, S. E., Stochastic Calculus for Finance II: Continuous-Time Models, New York: Springer-Verlag, 2004.