Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

StochasticProcess< RangeType, ScalarType > Class Template Reference

#include <StochasticProcess.h>

List of all members.


Detailed Description

template<typename RangeType = Real, typename ScalarType = Real>
class StochasticProcess< RangeType, ScalarType >

Stochastic process with arbitrary values of vector type RangeType with components of type ScalarType (similar to class RandomObject, Dimension 1 with RangeType=ScalarType is allowed and both types could be std::complex for example). The only reference to these types occurs in the method sampledAt which returns a pointer to RandomObject. Unfortunately this method is fundamental in the theory of stochastic processes (see book, 3.3) and so we cannot avoid the template parameters of the class RandomObject.

Path computation: the basic procedure is to continue a path which has already been realized until time t from this time t to the horizon T (branching at time t).

Here we are simulating future scenarios conditional on the state at time t. This is what is needed for the computation of conditional expectations conditioning on all information available at time t. The computation of entire paths is then merely a continuation from time t=0.

Assuming a setup where paths are computed as a sequence of time steps path computation is reduced to the single abstract method timeStep. If this is not the case the method timeStep can be defined to be empty and the path computation methods overridden.

Time is measured in discrete units (the time step dt). Integer time t corresponds to continuous time t*dt. The case dt=1 is the special case of a sequential stochastic process.

Parameters:
RangeType range of process (possibly vectors).
ScalarType type of RangeType vector components.
Author:
Michael J. Meyer

Definition at line 287 of file StochasticProcess.h.

Public Member Functions

int getDimension () const
int getT () const
virtual RangeType & currentPath (int t)=0
 StochasticProcess (int T_oo)
 StochasticProcess (int d, int T_oo)
virtual ~StochasticProcess ()
virtual void timeStep (int t)=0
virtual void timeStep (int t, int s)
virtual void newPathSegment (int t, int s)
virtual int newPathSegment (int t, StoppingTime *tau)
virtual void newPathSegment (int t)
virtual int newPathSegment (StoppingTime *tau)
virtual void newPathBranch (int t)
virtual void newPath ()
RandomObject< RangeType, ScalarType > * operator() (int t, StoppingTime *tau)
RandomObject< RangeType, ScalarType > * operator() (StoppingTime *tau)

Protected Attributes

int dim
int T


Constructor & Destructor Documentation

template<typename RangeType = Real, typename ScalarType = Real>
StochasticProcess< RangeType, ScalarType >::StochasticProcess int    T_oo [inline]
 

Constructor, scalar process, range dimension = 1.

Parameters:
T_oo number of time steps to horizon.

Definition at line 314 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
StochasticProcess< RangeType, ScalarType >::StochasticProcess int    d,
int    T_oo
[inline]
 

Constructor.

Parameters:
d dimension of range.
T_oo number of time steps to horizon.

Definition at line 320 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
virtual StochasticProcess< RangeType, ScalarType >::~StochasticProcess   [inline, virtual]
 

Definition at line 322 of file StochasticProcess.h.


Member Function Documentation

template<typename RangeType = Real, typename ScalarType = Real>
int StochasticProcess< RangeType, ScalarType >::getDimension   const [inline]
 

Dimension of range.

Definition at line 297 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
int StochasticProcess< RangeType, ScalarType >::getT   const [inline]
 

Number of time steps to horizon.

Definition at line 300 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
virtual RangeType& StochasticProcess< RangeType, ScalarType >::currentPath int    t [pure virtual]
 

The current path at time t.

Parameters:
t discrete time.

Implemented in BrownianVectorProcess, and BrownianScalarProcess.

template<typename RangeType = Real, typename ScalarType = Real>
virtual void StochasticProcess< RangeType, ScalarType >::timeStep int    t [pure virtual]
 

Evolves a path from discrete time [0,t] to time t+1, that is, computes from .

Parameters:
t discrete time.

Implemented in ScalarBrownianMotion, VectorBrownianMotion, and GaussianMartingale.

Referenced by StochasticProcess< Real, Real >::newPathSegment(), and StochasticProcess< Real, Real >::timeStep().

template<typename RangeType = Real, typename ScalarType = Real>
virtual void StochasticProcess< RangeType, ScalarType >::timeStep int    t,
int    s
[inline, virtual]
 

Computes from .

Sometimes this can be accomplished in a single step without stepping through intermediate times t+1,...,s-1. In this case path computations can often be sped up by sampling the path only at the times s which are needed.

Default implementation: individual time steps, no efficiency gain. This is meant to be overridden where possible but a default is provided for convenience.

Parameters:
t current time.
s future time.

Definition at line 350 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
virtual void StochasticProcess< RangeType, ScalarType >::newPathSegment int    t,
int    s
[inline, virtual]
 

Computes a new path segment from time t to time s through all intermediate times t+1,...,s-1. It is assumed that a path has been computed up to time t. Default implementation: calls to timeStep.

Parameters:
t current time.
s future time.

Reimplemented in BrownianVectorProcess, and BrownianScalarProcess.

Definition at line 363 of file StochasticProcess.h.

Referenced by StochasticProcess< Real, Real >::newPathBranch(), and StochasticProcess< Real, Real >::newPathSegment().

template<typename RangeType = Real, typename ScalarType = Real>
virtual int StochasticProcess< RangeType, ScalarType >::newPathSegment int    t,
StoppingTime   tau
[inline, virtual]
 

Computes a new path segment from time t to the random time tau&gt=t and returns the value of the time tau >= t when the path is stopped. Default implementation: calls to timeStep.

Parameters:
t current time
tau random future time

Reimplemented in BrownianVectorProcess, and BrownianScalarProcess.

Definition at line 374 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
virtual void StochasticProcess< RangeType, ScalarType >::newPathSegment int    t [inline, virtual]
 

Computes a new path segment from time 0 to time t. Default implementation: calls to timeStep.

Parameters:
t time when path is stopped.

Reimplemented in BrownianVectorProcess.

Definition at line 387 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
virtual int StochasticProcess< RangeType, ScalarType >::newPathSegment StoppingTime   tau [inline, virtual]
 

Computes a new path segment from time t=0 to the random time tau and returns the value of the time tau when the path is stopped. Default implementation: calls to timeStep.

Parameters:
tau random time when path is stopped.

Reimplemented in BrownianVectorProcess.

Definition at line 396 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
virtual void StochasticProcess< RangeType, ScalarType >::newPathBranch int    t [inline, virtual]
 

Continues a path existing on [0,t] from time t to the horizon, that is, computes from (branching a path at time t).

Default implementation: calls to timeStep. This is not the most efficient method, override if fastest path computation is a concern.

Parameters:
t time of branching.

Definition at line 409 of file StochasticProcess.h.

Referenced by StochasticProcess< Real, Real >::newPath().

template<typename RangeType = Real, typename ScalarType = Real>
virtual void StochasticProcess< RangeType, ScalarType >::newPath   [inline, virtual]
 

Computes a new path from time t=0.

Definition at line 414 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
RandomObject<RangeType,ScalarType>* StochasticProcess< RangeType, ScalarType >::operator() int    t,
StoppingTime   tau
[inline]
 

Computes the random object , that is, X=this sampled at the stopping time conditioned on the state of the stochastic process X at time t.

Parameters:
t current discrete time.
tau stopping time (>=t) at which X is sampled.

Definition at line 426 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
RandomObject<RangeType,ScalarType>* StochasticProcess< RangeType, ScalarType >::operator() StoppingTime   tau [inline]
 

Computes the random object , that is, X=this sampled at the stopping time as seen from time t=0 (no conditioning).

Parameters:
tau stopping time at which X is sampled.

Definition at line 436 of file StochasticProcess.h.


Member Data Documentation

template<typename RangeType = Real, typename ScalarType = Real>
int StochasticProcess< RangeType, ScalarType >::dim [protected]
 

Definition at line 291 of file StochasticProcess.h.

template<typename RangeType = Real, typename ScalarType = Real>
int StochasticProcess< RangeType, ScalarType >::T [protected]
 

Definition at line 292 of file StochasticProcess.h.


The documentation for this class was generated from the following file:
Generated on Mon Sep 22 02:16:33 2003 for Libor-Library by doxygen1.3-rc3