public class RandomWalk extends Brownian implements Construction
For constant μ and σ, this method is exact in the sense that the joint distribution of the simulated values coincides with the joint distribution of the corresponding Brownian motion a the time grid points. Please note that this says nothing about what happens between two successive grid points.
For time-dependent μ and σ, this method in general introduce discretization error even at the time grid points, because the increments will no longer have exactly the correct mean and variance.
| Constructor and Description |
|---|
RandomWalk(int T)
Construct a univariate Brownian motion at even time points, [0, 1, ......, T].
|
RandomWalk(TimeGrid timePoints)
Construct a univariate Brownian motion at time points specified.
|
| Modifier and Type | Method and Description |
|---|---|
RandomWalk.Realization |
nextRealization(double x0)
Construct a realization of the stochastic process.
|
void |
seed(long seed)
Seed the construction process so that we may generate the same realizations.
|
public RandomWalk(TimeGrid timePoints)
timePoints - specifying the time points in a gridpublic RandomWalk(int T)
T - the length of the gridpublic RandomWalk.Realization nextRealization(double x0)
ConstructionnextRealization in interface Constructionx0 - the starting point of the trajectorypublic void seed(long seed)
Constructionseed in interface Constructionseed - seeding the same seed gives arise to the same realization