Stochastic Process

Overview

Stochastic process uses the Random Number Generator(RNG). It uses a given point (t,x) and a time step Δt to calculate the expectation and variance. The class StochasticProcess1D is 1-dimensional stochastic process, and it cooperates with Cox-Ingersoll-Ross and Extended Cox-Ingersoll-Ross Models. The stochastic process can be described as

dxt=μ(t,xt)dt+σ(t,xt)dWt

Implementation

The implementation of StochasticProcess1D is comprised by a few methods. The implementation is introduced as follows:

  1. init: Initialization function used to set up the arguments as below:

    a)speed, the spreads on interest rates;

    b)vola, the overall level of volatility;

    c)x0, the initial value of level;

    d)level, the width of fluctuation on interest rates.

  2. expectation: The expectation method returns the expectation of the process at time E(xt0+Δt|xt0=x0).

  3. variance: The variance method returns the variance V(xt0+Δt|xt0=x0) of the process during a time interval Δt according to the given volatility.