BM {sde}R Documentation

Brownian motion, Brownian Bridge and Geometric Brownian motion simulators

Description

Brownian motion, Brownian Bridge and Geometric Brownian motion simulators

Usage

BBridge(x=0, y=0, t0=0, T=1, N=100)
BM(x=0, t0=0, T=1, N=100)
GBM(x=1, r=0, sigma=1, T=1, N=100)

Arguments

x intial value of the process at time t0
y terminal value of the process at time T
t0 initial time.
r the interest rate of the GBM.
sigma the volatility of the GBM.
T final time.
N number of intervals in which to split [t0,T].

Details

These functions return an invisible ts object containing a trajectory of the process calculated on grid of N+1 equidistant points between t0 and T, i.e. t[i] = t0 + (T-t0)*i/N, i in 0:N. t0=0 for the Geometric Brownian Motion.

The function BBridge returns a trajectory of the Brownian Bridge starting in x at time t0 and ending at y at time T, i.e. (B(t), t0 <= t <= T | B(t_0)=x, B(T)=y)

The function BM returns a trajectory of the translated Brownian Motion (B(t), t>= t0 | B(t0)=x), i.e. x+B(t-t0), for t >= t0. The standard Brownian motion is obtained choosing x=0 and t0=0 (the default values).

The function GBM returns a trajectory of the Geometric Brownian Motion starting at x at time t0=0, i.e. the process S(t) = x * exp((r-sigma^2/2)*t + sigma*B(t)).

Value

X an invisible ts object

Note

This package is a companion to the book Simulation and Inference for Stochastic Differential Equation, Springer, NY.

Author(s)

Stefano Maria Iacus

Examples

plot(BM())
plot(BBridge())
plot(GBM())

[Package sde version 1.9.14 Index]