umontreal.iro.lecuyer.stochprocess
Class InverseGaussianProcessBridge
- java.lang.Object
-
- umontreal.iro.lecuyer.stochprocess.StochasticProcess
-
- umontreal.iro.lecuyer.stochprocess.InverseGaussianProcess
-
- umontreal.iro.lecuyer.stochprocess.InverseGaussianProcessMSH
-
- umontreal.iro.lecuyer.stochprocess.InverseGaussianProcessBridge
-
public class InverseGaussianProcessBridge extends InverseGaussianProcessMSH
Samples the path by bridge sampling: first finding the process value at the final time and then the middle time, etc. The method nextObservation() returns the path value in that non-sequential order. This class uses twoRandomStream's to generate a path.
-
-
Constructor Summary
Constructors Constructor and Description InverseGaussianProcessBridge(double s0, double delta, double gamma, RandomStream stream, RandomStream otherStream)Constructs a new InverseGaussianProcessBridge.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description double[]generatePath()Generates the path.double[]generatePath(double[] unifNorm, double[] unifOther)Instead of using the internal streams to generate the path, it uses two arrays of uniforms U[0, 1).RandomStreamgetStream()Only returns a stream if both inner streams are the same.doublenextObservation()Returns the next observation in the bridge order, not the sequential order.voidresetStartProcess()Resets the observation counter to its initial value j = 0, so that the current observation X(tj) becomes X(t0).voidsetStream(RandomStream stream)Sets both inner streams to the same stream.voidsetStream(RandomStream stream, RandomStream otherStream)Sets the streams.-
Methods inherited from class umontreal.iro.lecuyer.stochprocess.InverseGaussianProcessMSH
generatePath, getNormalGen, getOtherStream, setNormalGen, setOtherStream
-
Methods inherited from class umontreal.iro.lecuyer.stochprocess.InverseGaussianProcess
getAnalyticAverage, getAnalyticVariance, getDelta, getGamma, getNumberOfRandomStreams, setParams
-
Methods inherited from class umontreal.iro.lecuyer.stochprocess.StochasticProcess
generatePath, getArrayMappingCounterToIndex, getCurrentObservation, getCurrentObservationIndex, getNbObservationTimes, getObservation, getObservationTimes, getPath, getSubpath, getX0, hasNextObservation, setObservationTimes, setObservationTimes, setX0
-
-
-
-
Constructor Detail
-
InverseGaussianProcessBridge
public InverseGaussianProcessBridge(double s0, double delta, double gamma, RandomStream stream, RandomStream otherStream)Constructs a new InverseGaussianProcessBridge. The initial value s0 will be overridden by t[0] when the observation times are set.
-
-
Method Detail
-
generatePath
public double[] generatePath()
Generates the path. The two innerRandomStream's are sampled alternatively.- Overrides:
generatePathin classInverseGaussianProcessMSH
-
generatePath
public double[] generatePath(double[] unifNorm, double[] unifOther)Instead of using the internal streams to generate the path, it uses two arrays of uniforms U[0, 1). The length of the arrays unifNorm and unifOther should be equal to the number of time steps, excluding t0.- Overrides:
generatePathin classInverseGaussianProcessMSH
-
nextObservation
public double nextObservation()
Returns the next observation in the bridge order, not the sequential order.- Overrides:
nextObservationin classInverseGaussianProcessMSH
-
resetStartProcess
public void resetStartProcess()
Description copied from class:StochasticProcessResets the observation counter to its initial value j = 0, so that the current observation X(tj) becomes X(t0). This method should be invoked before generating observations sequentially one by one vianextObservation, for a new sample path.- Overrides:
resetStartProcessin classStochasticProcess
-
getStream
public RandomStream getStream()
Only returns a stream if both inner streams are the same.- Overrides:
getStreamin classInverseGaussianProcessMSH
-
setStream
public void setStream(RandomStream stream, RandomStream otherStream)
Sets the streams.- Overrides:
setStreamin classInverseGaussianProcessMSH
-
setStream
public void setStream(RandomStream stream)
Sets both inner streams to the same stream.- Overrides:
setStreamin classInverseGaussianProcessMSH
-
-
DMelt 3.0 © DataMelt by jWork.ORG