public interface ProcessModel
getInitialState(net.finmath.montecarlo.process.MonteCarloProcess)
.
getDrift(net.finmath.montecarlo.process.MonteCarloProcess, int, net.finmath.stochastic.RandomVariable[], net.finmath.stochastic.RandomVariable[])
.
getFactorLoading(net.finmath.montecarlo.process.MonteCarloProcess, int, int, net.finmath.stochastic.RandomVariable[])
.
applyStateSpaceTransform(net.finmath.montecarlo.process.MonteCarloProcess, int, int, net.finmath.stochastic.RandomVariable)
.
Modifier and Type | Method and Description |
---|---|
RandomVariable |
applyStateSpaceTransform(int componentIndex,
RandomVariable randomVariable)
Deprecated.
Will be removed. Please use applyStateSpaceTransform(int, RandomVariable).
|
default RandomVariable |
applyStateSpaceTransform(MonteCarloProcess process,
int timeIndex,
int componentIndex,
RandomVariable randomVariable)
Applies the state space transform fi to the given state random variable
such that Yi → fi(Yi) =: Xi.
|
default RandomVariable |
applyStateSpaceTransformInverse(int componentIndex,
RandomVariable randomVariable)
Deprecated.
|
default RandomVariable |
applyStateSpaceTransformInverse(MonteCarloProcess process,
int timeIndex,
int componentIndex,
RandomVariable randomVariable)
Applies the inverse state space transform f-1i to the given random variable
such that Xi → f-1i(Xi) =: Yi.
|
ProcessModel |
getCloneWithModifiedData(Map<String,Object> dataModified)
Returns a clone of this model where the specified properties have been modified.
|
default RandomVariable[] |
getDrift(int timeIndex,
RandomVariable[] realizationAtTimeIndex,
RandomVariable[] realizationPredictor)
Deprecated.
Will be removed. Please use getDrift(process, ...).
|
default RandomVariable[] |
getDrift(MonteCarloProcess process,
int timeIndex,
RandomVariable[] realizationAtTimeIndex,
RandomVariable[] realizationPredictor)
This method has to be implemented to return the drift, i.e.
|
default RandomVariable[] |
getFactorLoading(int timeIndex,
int componentIndex,
RandomVariable[] realizationAtTimeIndex)
Deprecated.
Will be removed. Please use getFactorLoading(process, ...).
|
default RandomVariable[] |
getFactorLoading(MonteCarloProcess process,
int timeIndex,
int componentIndex,
RandomVariable[] realizationAtTimeIndex)
This method has to be implemented to return the factor loadings, i.e.
|
RandomVariable[] |
getInitialState()
Deprecated.
|
default RandomVariable[] |
getInitialState(MonteCarloProcess process)
Returns the initial value of the state variable of the process Y, not to be
confused with the initial value of the model X (which is the state space transform
applied to this state value.
|
int |
getNumberOfComponents()
Returns the number of components
|
int |
getNumberOfFactors()
Returns the number of factors m, i.e., the number of independent Brownian drivers.
|
default RandomVariable |
getNumeraire(double time)
Deprecated.
Will be removed. Please use getNumeraire(process).get(time).
|
default RandomVariable |
getNumeraire(MonteCarloProcess process,
double time)
Return the numeraire at a given time index.
|
MonteCarloProcess |
getProcess()
Deprecated.
Models will no longer hold references to processes.
|
default RandomVariable |
getRandomVariableForConstant(double value)
Return a random variable initialized with a constant using the models random variable factory.
|
LocalDateTime |
getReferenceDate()
Returns the model's date corresponding to the time discretization's \( t = 0 \).
|
TimeDiscretization |
getTimeDiscretization()
Returns the time discretization of the model parameters.
|
void |
setProcess(MonteCarloProcess process)
Deprecated.
Models will no longer hold references to processes.
|
LocalDateTime getReferenceDate()
TimeDiscretization getTimeDiscretization()
int getNumberOfComponents()
default RandomVariable applyStateSpaceTransform(MonteCarloProcess process, int timeIndex, int componentIndex, RandomVariable randomVariable)
process
- The discretization process generating this model. The process provides call backs for TimeDiscretization and allows calls to getProcessValue for timeIndices less or equal the given one.timeIndex
- The time index (related to the model times discretization).componentIndex
- The component index i.randomVariable
- The state random variable Yi.@Deprecated RandomVariable applyStateSpaceTransform(int componentIndex, RandomVariable randomVariable)
componentIndex
- The component index i.randomVariable
- The state random variable Yi.default RandomVariable applyStateSpaceTransformInverse(MonteCarloProcess process, int timeIndex, int componentIndex, RandomVariable randomVariable)
process
- The discretization process generating this model. The process provides call backs for TimeDiscretization and allows calls to getProcessValue for timeIndices less or equal the given one.timeIndex
- The time index (related to the model times discretization).componentIndex
- The component index i.randomVariable
- The state random variable Xi.@Deprecated default RandomVariable applyStateSpaceTransformInverse(int componentIndex, RandomVariable randomVariable)
default RandomVariable[] getInitialState(MonteCarloProcess process)
process
- The discretization process generating this model. The process provides call backs for TimeDiscretization and allows calls to getProcessValue for timeIndices less or equal the given one.@Deprecated RandomVariable[] getInitialState()
default RandomVariable getNumeraire(MonteCarloProcess process, double time) throws CalculationException
process
- The discretization process generating this model. The process provides call backs for TimeDiscretization and allows calls to getProcessValue for timeIndices less or equal the given one.time
- The time t for which the numeraire N(t) should be returned.RandomVariable
CalculationException
- Thrown if the valuation fails, specific cause may be available via the cause()
method.@Deprecated default RandomVariable getNumeraire(double time) throws CalculationException
time
- The time t for which the numeraire N(t) should be returned.RandomVariableFromDoubleArray
CalculationException
- Thrown if the valuation fails, specific cause may be available via the cause()
method.default RandomVariable[] getDrift(MonteCarloProcess process, int timeIndex, RandomVariable[] realizationAtTimeIndex, RandomVariable[] realizationPredictor)
process
- The discretization process generating this model. The process provides call backs for TimeDiscretization and allows calls to getProcessValue for timeIndices less or equal the given one.timeIndex
- The time index (related to the model times discretization).realizationAtTimeIndex
- The given realization at timeIndexrealizationPredictor
- The given realization at timeIndex+1
or null if no predictor is available.@Deprecated default RandomVariable[] getDrift(int timeIndex, RandomVariable[] realizationAtTimeIndex, RandomVariable[] realizationPredictor)
timeIndex
- The time index (related to the model times discretization).realizationAtTimeIndex
- The given realization at timeIndexrealizationPredictor
- The given realization at timeIndex+1
or null if no predictor is available.int getNumberOfFactors()
default RandomVariable[] getFactorLoading(MonteCarloProcess process, int timeIndex, int componentIndex, RandomVariable[] realizationAtTimeIndex)
process
- The discretization process generating this model. The process provides call backs for TimeDiscretization and allows calls to getProcessValue for timeIndices less or equal the given one.timeIndex
- The time index (related to the model times discretization).componentIndex
- The index j of the driven component.realizationAtTimeIndex
- The realization of X at the time corresponding to timeIndex (in order to implement local and stochastic volatlity models).@Deprecated default RandomVariable[] getFactorLoading(int timeIndex, int componentIndex, RandomVariable[] realizationAtTimeIndex)
timeIndex
- The time index (related to the model times discretization).componentIndex
- The index j of the driven component.realizationAtTimeIndex
- The realization of X at the time corresponding to timeIndex (in order to implement local and stochastic volatlity models).default RandomVariable getRandomVariableForConstant(double value)
value
- The constant value.@Deprecated void setProcess(MonteCarloProcess process)
process
- The process.@Deprecated MonteCarloProcess getProcess()
ProcessModel getCloneWithModifiedData(Map<String,Object> dataModified) throws CalculationException
dataModified
. If data is provided which is ignored by the model
no exception may be thrown.dataModified
- Key-value-map of parameters to modify.CalculationException
- Thrown when the model could not be created.Copyright © 2020 finmath.net. All rights reserved.