public class org.apache.commons.math.distribution.GammaDistribution extends org.apache.commons.math.distribution.AbstractRealDistribution
{
public static final double DEFAULT_INVERSE_ABSOLUTE_ACCURACY;
private static final long serialVersionUID;
private final double shape;
private final double scale;
private final double shiftedShape;
private final double densityPrefactor;
private final double densityPrefactor;
private final double minY;
private final double maxLogY;
private final double solverAbsoluteAccuracy;
public void <init>(double, double) throws org.apache.commons.math.exception.NotStrictlyPositiveException
{
org.apache.commons.math.distribution.GammaDistribution v;
double v, v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v := @parameter: double;
v := @parameter: double;
specialinvoke v.<org.apache.commons.math.distribution.GammaDistribution: void <init>(double,double,double)>(v, v, 1.0E-9);
return;
}
public void <init>(double, double, double) throws org.apache.commons.math.exception.NotStrictlyPositiveException
{
org.apache.commons.math.distribution.GammaDistribution v;
org.apache.commons.math.random.Well19937c v;
double v, v, v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v := @parameter: double;
v := @parameter: double;
v := @parameter: double;
v = new org.apache.commons.math.random.Well19937c;
specialinvoke v.<org.apache.commons.math.random.Well19937c: void <init>()>();
specialinvoke v.<org.apache.commons.math.distribution.GammaDistribution: void <init>(org.apache.commons.math.random.RandomGenerator,double,double,double)>(v, v, v, v);
return;
}
public void <init>(org.apache.commons.math.random.RandomGenerator, double, double, double) throws org.apache.commons.math.exception.NotStrictlyPositiveException
{
org.apache.commons.math.distribution.GammaDistribution v;
byte v, v;
org.apache.commons.math.exception.NotStrictlyPositiveException v, v;
java.lang.Double v, v;
double v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v;
org.apache.commons.math.exception.util.LocalizedFormats v, v;
org.apache.commons.math.random.RandomGenerator v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v := @parameter: org.apache.commons.math.random.RandomGenerator;
v := @parameter: double;
v := @parameter: double;
v := @parameter: double;
specialinvoke v.<org.apache.commons.math.distribution.AbstractRealDistribution: void <init>(org.apache.commons.math.random.RandomGenerator)>(v);
v = v cmpg 0.0;
if v > 0 goto label;
v = new org.apache.commons.math.exception.NotStrictlyPositiveException;
v = <org.apache.commons.math.exception.util.LocalizedFormats: org.apache.commons.math.exception.util.LocalizedFormats SHAPE>;
v = staticinvoke <java.lang.Double: java.lang.Double valueOf(double)>(v);
specialinvoke v.<org.apache.commons.math.exception.NotStrictlyPositiveException: void <init>(org.apache.commons.math.exception.util.Localizable,java.lang.Number)>(v, v);
throw v;
label:
v = v cmpg 0.0;
if v > 0 goto label;
v = new org.apache.commons.math.exception.NotStrictlyPositiveException;
v = <org.apache.commons.math.exception.util.LocalizedFormats: org.apache.commons.math.exception.util.LocalizedFormats SCALE>;
v = staticinvoke <java.lang.Double: java.lang.Double valueOf(double)>(v);
specialinvoke v.<org.apache.commons.math.exception.NotStrictlyPositiveException: void <init>(org.apache.commons.math.exception.util.Localizable,java.lang.Number)>(v, v);
throw v;
label:
v.<org.apache.commons.math.distribution.GammaDistribution: double shape> = v;
v.<org.apache.commons.math.distribution.GammaDistribution: double scale> = v;
v.<org.apache.commons.math.distribution.GammaDistribution: double solverAbsoluteAccuracy> = v;
v = v + 4.7421875;
v = v + 0.5;
v.<org.apache.commons.math.distribution.GammaDistribution: double shiftedShape> = v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shiftedShape>;
v = 6.283185307179586 * v;
v = 2.718281828459045 / v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double sqrt(double)>(v);
v = v * v;
v = staticinvoke <org.apache.commons.math.special.Gamma: double lanczos(double)>(v);
v = v / v;
v.<org.apache.commons.math.distribution.GammaDistribution: double densityPrefactor2> = v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double densityPrefactor2>;
v = v / v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shiftedShape>;
v = neg v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double pow(double,double)>(v, v);
v = v * v;
v = v + 4.7421875;
v = staticinvoke <org.apache.commons.math.util.FastMath: double exp(double)>(v);
v = v * v;
v.<org.apache.commons.math.distribution.GammaDistribution: double densityPrefactor1> = v;
v = v + 4.7421875;
v = staticinvoke <org.apache.commons.math.util.FastMath: double log(double)>(1.7976931348623157E308);
v = v - v;
v.<org.apache.commons.math.distribution.GammaDistribution: double minY> = v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double log(double)>(1.7976931348623157E308);
v = v - 1.0;
v = v / v;
v.<org.apache.commons.math.distribution.GammaDistribution: double maxLogY> = v;
return;
}
public double getAlpha()
{
org.apache.commons.math.distribution.GammaDistribution v;
double v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
return v;
}
public double getShape()
{
org.apache.commons.math.distribution.GammaDistribution v;
double v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
return v;
}
public double getBeta()
{
org.apache.commons.math.distribution.GammaDistribution v;
double v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
return v;
}
public double getScale()
{
org.apache.commons.math.distribution.GammaDistribution v;
double v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
return v;
}
public double density(double)
{
org.apache.commons.math.distribution.GammaDistribution v;
byte v, v, v;
double v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v := @parameter: double;
v = v cmpg 0.0;
if v >= 0 goto label;
return 0.0;
label:
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v / v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double minY>;
v = v cmpg v;
if v <= 0 goto label;
v = staticinvoke <org.apache.commons.math.util.FastMath: double log(double)>(v);
v = v.<org.apache.commons.math.distribution.GammaDistribution: double maxLogY>;
v = v cmpl v;
if v < 0 goto label;
label:
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shiftedShape>;
v = v - v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shiftedShape>;
v = v / v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = staticinvoke <org.apache.commons.math.util.FastMath: double log1p(double)>(v);
v = v - v;
v = v * v;
v = neg v;
v = v * 5.2421875;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shiftedShape>;
v = v / v;
v = v + 4.7421875;
v = v + v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double densityPrefactor2>;
v = v / v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double exp(double)>(v);
v = v * v;
return v;
label:
v = v.<org.apache.commons.math.distribution.GammaDistribution: double densityPrefactor1>;
v = neg v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double exp(double)>(v);
v = v * v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v - 1.0;
v = staticinvoke <org.apache.commons.math.util.FastMath: double pow(double,double)>(v, v);
v = v * v;
return v;
}
public double cumulativeProbability(double)
{
org.apache.commons.math.distribution.GammaDistribution v;
byte v;
double v, v, v, v, v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v := @parameter: double;
v = v cmpg 0.0;
if v > 0 goto label;
v = 0.0;
goto label;
label:
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v / v;
v = staticinvoke <org.apache.commons.math.special.Gamma: double regularizedGammaP(double,double)>(v, v);
label:
return v;
}
protected double getSolverAbsoluteAccuracy()
{
org.apache.commons.math.distribution.GammaDistribution v;
double v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double solverAbsoluteAccuracy>;
return v;
}
public double getNumericalMean()
{
org.apache.commons.math.distribution.GammaDistribution v;
double v, v, v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v * v;
return v;
}
public double getNumericalVariance()
{
org.apache.commons.math.distribution.GammaDistribution v;
double v, v, v, v, v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v * v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v * v;
return v;
}
public double getSupportLowerBound()
{
org.apache.commons.math.distribution.GammaDistribution v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
return 0.0;
}
public double getSupportUpperBound()
{
org.apache.commons.math.distribution.GammaDistribution v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
return #Infinity;
}
public boolean isSupportLowerBoundInclusive()
{
org.apache.commons.math.distribution.GammaDistribution v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
return 1;
}
public boolean isSupportUpperBoundInclusive()
{
org.apache.commons.math.distribution.GammaDistribution v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
return 0;
}
public boolean isSupportConnected()
{
org.apache.commons.math.distribution.GammaDistribution v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
return 1;
}
public double sample()
{
org.apache.commons.math.distribution.GammaDistribution v;
byte v, v, v, v, v, v, v;
double v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v, v;
org.apache.commons.math.random.RandomGenerator v, v, v, v, v;
v := @this: org.apache.commons.math.distribution.GammaDistribution;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v cmpg 1.0;
if v >= 0 goto label;
label:
v = v.<org.apache.commons.math.distribution.GammaDistribution: org.apache.commons.math.random.RandomGenerator random>;
v = interfaceinvoke v.<org.apache.commons.math.random.RandomGenerator: double nextDouble()>();
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v / 2.718281828459045;
v = 1.0 + v;
v = v * v;
v = v cmpg 1.0;
if v > 0 goto label;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = 1.0 / v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double pow(double,double)>(v, v);
v = v.<org.apache.commons.math.distribution.GammaDistribution: org.apache.commons.math.random.RandomGenerator random>;
v = interfaceinvoke v.<org.apache.commons.math.random.RandomGenerator: double nextDouble()>();
v = neg v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double exp(double)>(v);
v = v cmpl v;
if v > 0 goto label;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v * v;
return v;
label:
v = v - v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v / v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double log(double)>(v);
v = -1.0 * v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: org.apache.commons.math.random.RandomGenerator random>;
v = interfaceinvoke v.<org.apache.commons.math.random.RandomGenerator: double nextDouble()>();
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v - 1.0;
v = staticinvoke <org.apache.commons.math.util.FastMath: double pow(double,double)>(v, v);
v = v cmpl v;
if v > 0 goto label;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v * v;
return v;
label:
v = v.<org.apache.commons.math.distribution.GammaDistribution: double shape>;
v = v - 0.3333333333333333;
v = staticinvoke <org.apache.commons.math.util.FastMath: double sqrt(double)>(v);
v = 3.0 * v;
v = 1.0 / v;
label:
v = v.<org.apache.commons.math.distribution.GammaDistribution: org.apache.commons.math.random.RandomGenerator random>;
v = interfaceinvoke v.<org.apache.commons.math.random.RandomGenerator: double nextGaussian()>();
v = v * v;
v = 1.0 + v;
v = v * v;
v = 1.0 + v;
v = v * v;
v = v * v;
v = 1.0 + v;
v = v * v;
v = v cmpg 0.0;
if v <= 0 goto label;
v = v * v;
v = v.<org.apache.commons.math.distribution.GammaDistribution: org.apache.commons.math.random.RandomGenerator random>;
v = interfaceinvoke v.<org.apache.commons.math.random.RandomGenerator: double nextDouble()>();
v = 0.0331 * v;
v = v * v;
v = 1.0 - v;
v = v cmpg v;
if v >= 0 goto label;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v * v;
v = v * v;
return v;
label:
v = staticinvoke <org.apache.commons.math.util.FastMath: double log(double)>(v);
v = 0.5 * v;
v = 1.0 - v;
v = staticinvoke <org.apache.commons.math.util.FastMath: double log(double)>(v);
v = v + v;
v = v * v;
v = v + v;
v = v cmpg v;
if v >= 0 goto label;
v = v.<org.apache.commons.math.distribution.GammaDistribution: double scale>;
v = v * v;
v = v * v;
return v;
}
}