ae function

Asymptotic Expansion

Asymptotic Expansion

Asymptotic expansion of uni-dimensional and multi-dimensional diffusion processes.

ae( model, xinit, order = 1L, true.parameter = list(), sampling = NULL, eps.var = "eps", solver = "rk4", verbose = FALSE )

Arguments

  • model: an object of yuima-class or yuima.model-class.
  • xinit: initial value vector of state variables.
  • order: integer. The asymptotic expansion order. Higher orders lead to better approximations but longer computational times.
  • true.parameter: named list of parameters.
  • sampling: a yuima.sampling-class object.
  • eps.var: character. The perturbation variable.
  • solver: the solver for ordinary differential equations. One of "rk4" (more accurate) or "euler" (faster).
  • verbose: logical. Print on progress? Default FALSE.

Returns

An object of yuima.ae-class

Details

If sampling is not provided, then model must be an object of yuima-class with non-empty sampling.

if eps.var does not appear in the model specification, then it is internally added in front of the diffusion matrix to apply the asymptotic expansion scheme.

Examples

## Not run: # model gbm <- setModel(drift = 'mu*x', diffusion = 'sigma*x', solve.variable = 'x') # settings xinit <- 100 par <- list(mu = 0.01, sigma = 0.2) sampling <- setSampling(Initial = 0, Terminal = 1, n = 1000) # asymptotic expansion approx <- ae(model = gbm, sampling = sampling, order = 4, true.parameter = par, xinit = xinit) # exact density x <- seq(50, 200, by = 0.1) exact <- dlnorm(x = x, meanlog = log(xinit)+(par$mu-0.5*par$sigma^2)*1, sdlog = par$sigma*sqrt(1)) # compare plot(x, exact, type = 'l', ylab = "Density") lines(x, aeDensity(x = x, ae = approx, order = 1), col = 2) lines(x, aeDensity(x = x, ae = approx, order = 2), col = 3) lines(x, aeDensity(x = x, ae = approx, order = 3), col = 4) lines(x, aeDensity(x = x, ae = approx, order = 4), col = 5) ## End(Not run)

Author(s)

Emanuele Guidotti emanuele.guidotti@unine.ch

  • Maintainer: Stefano M. Iacus
  • License: GPL-2
  • Last published: 2024-02-29