jphase.fit
Class MomentsECPositiveFit
java.lang.Object
jphase.fit.ContPhaseFitter
jphase.fit.MomentsContPhaseFitter
jphase.fit.MomentsECPositiveFit
- All Implemented Interfaces:
- PhaseFitter
public class MomentsECPositiveFit
- extends MomentsContPhaseFitter
This class implements the Matching Moments method
proposed by Osogami and Harchol in "Closed form
solutions for mapping general distributions to
quasi-minimal PH distributions", 2005. The method
match the first three moments of any distribution
to a subclass of Phase-Type distributions known as
Erlang-Coxian distributions. This class implements
the Positive solution.
- Author:
- Juan Fernando Perez
Method Summary |
ContPhaseVar |
fit()
Fit a Phase Type distribution with no mass at zero
from a set of moments with the
Positive method described by Osogami et al. |
double[] |
getParam()
Solve the equation system to get the parameters of the distribution,
if the moments are feasible |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MomentsECPositiveFit
public MomentsECPositiveFit(double[] data)
- Parameters:
data
-
MomentsECPositiveFit
public MomentsECPositiveFit(double m1,
double m2,
double m3)
- Parameters:
m1
- m2
- m3
-
fit
public ContPhaseVar fit()
- Fit a Phase Type distribution with no mass at zero
from a set of moments with the
Positive method described by Osogami et al.
- Specified by:
fit
in interface PhaseFitter
- Specified by:
fit
in class ContPhaseFitter
- Returns:
- Phase variable found
- See Also:
PhaseFitter.fit()
getParam
public double[] getParam()
throws java.lang.IllegalArgumentException
- Solve the equation system to get the parameters of the distribution,
if the moments are feasible
- Returns:
- Parameters of the Acyclic Continuous Phase Distribution
of order n. param[0]=n, param[1]=p, param[2]=lambdaY,
param[3]=lambdaX1, param[4]=lambdaX2, param[5]=pX. If it is
necessary, a new exponential phase with parameter lambda
will be aggregated through convolution: param[6]=lambda.
If it is necessary, a new exponential phase with parameter lambda
will be mixed up with probability 1-pMix: param[6]=lambda,
param[7] = pMix.
- Throws:
java.lang.IllegalArgumentException