Class DMAP
-
- All Implemented Interfaces:
-
java.io.Serializable,jline.lang.Copyable
public class DMAP extends MarkovModulated implements Serializable
A Discrete Markovian Arrival Process (DMAP). Unlike MAP (continuous-time), D0+D1 is a stochastic matrix (row sums = 1).
-
-
Method Summary
Modifier and Type Method Description static DMAPrand()static DMAPrand(int order)MatrixD(int i)Gets the i-th matrix of the Markovian arrival process representation. doublegetMean()Mean inter-arrival time: pi * (I - D0)^{-1} * e doublegetVar()Variance: 2*pi*(I-D0)^{-2}*e - mean - mean^2 doublegetSCV()Gets the squared coefficient of variation (SCV) of this distribution. MatrixgetMu()Row sums of (I - D0). Array<double>sample(int n, Random random)Generates random samples from this distribution using the specified random generator. Array<double>sample(int n)Generates random samples from this distribution using default random generator. doublegetRate()Gets the rate of this distribution (inverse of mean). doubleevalCDF(double t)CDF(t) = 1 - pi * D0^floor(t) * e MatrixgetTransitionMatrix()Embedded chain P = (I - D0)^{-1} * D1. longgetNumberOfPhases()Gets the number of phases in this Markovian distribution. voidnormalize()MatrixCellgetProcess()Gets the matrix representation of this Markovian process. StringtoString()booleanequals(Object obj)inthashCode()-
Methods inherited from class jline.lang.processes.MarkovModulated
evalACFT, getACFDecay -
Methods inherited from class jline.lang.processes.Markovian
acf, embedded, embeddedProb, evalCDF, evalLST, evalMeanT, evalVarT, getACF, getEmbedded, getEmbeddedProb, getIDC, getIDI, getInitProb, getMoments, getPhi, getSkewness, getSubgenerator, getVariance, idc, idi, initProb, mean, moments, mu, numPhases, numberOfPhases, phi, process, rate, scv, setMean, setProcess, setRate, skewness, subgenerator, var, variance -
Methods inherited from class jline.lang.processes.Distribution
evalProbInterval, getName, getNumParams, getParam, getSupport, isContinuous, isDisabled, isDiscrete, isImmediate, isMarkovian, name, numParams, param, setNumParams, setParam, support -
Methods inherited from class jline.lang.Copyable
copy -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
DMAP
DMAP(MatrixCell map)
-
DMAP
DMAP()
-
-
Method Detail
-
D
Matrix D(int i)
Gets the i-th matrix of the Markovian arrival process representation.
- Parameters:
i- the matrix index (0 for D0, 1 for D1, etc.- Returns:
the matrix at index i
-
getMean
double getMean()
Mean inter-arrival time: pi * (I - D0)^{-1} * e
-
getVar
double getVar()
Variance: 2*pi*(I-D0)^{-2}*e - mean - mean^2
-
getSCV
double getSCV()
Gets the squared coefficient of variation (SCV) of this distribution. SCV = Var(X) / E[X]^2.
- Returns:
the squared coefficient of variation
-
sample
Array<double> sample(int n, Random random)
Generates random samples from this distribution using the specified random generator.
- Parameters:
n- the number of samples to generaterandom- the random number generator to use- Returns:
array of random samples
-
sample
Array<double> sample(int n)
Generates random samples from this distribution using default random generator.
- Parameters:
n- the number of samples to generate- Returns:
array of random samples
-
getRate
double getRate()
Gets the rate of this distribution (inverse of mean).
- Returns:
the rate value (1/mean)
-
evalCDF
double evalCDF(double t)
CDF(t) = 1 - pi * D0^floor(t) * e
-
getTransitionMatrix
Matrix getTransitionMatrix()
Embedded chain P = (I - D0)^{-1} * D1.
-
getNumberOfPhases
long getNumberOfPhases()
Gets the number of phases in this Markovian distribution.
- Returns:
the number of phases
-
normalize
void normalize()
-
getProcess
MatrixCell getProcess()
Gets the matrix representation of this Markovian process.
- Returns:
MatrixCell containing D0, D1, ... matrices
-
hashCode
int hashCode()
-
-
-
-