umontreal.iro.lecuyer.probdist
Class NakagamiDist
- java.lang.Object
-
- umontreal.iro.lecuyer.probdist.ContinuousDistribution
-
- umontreal.iro.lecuyer.probdist.NakagamiDist
-
- All Implemented Interfaces:
- Distribution
public class NakagamiDist extends ContinuousDistribution
Extends the classContinuousDistributionfor the Nakagami distribution with location parameter a, scale parameter λ > 0 and shape parameter c > 0. The density isf (x) = 2λc/Γ(c) (x - a)2c-1 e-λ(x-a)2 for x > a,f (x) = 0 for x <= a,where Γ is the gamma function.
-
-
Field Summary
-
Fields inherited from class umontreal.iro.lecuyer.probdist.ContinuousDistribution
decPrec
-
-
Constructor Summary
Constructors Constructor and Description NakagamiDist(double a, double lambda, double c)Constructs a NakagamiDist object with parameters a = a, λ = lambda and c = c.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description doublebarF(double x)Returns the complementary distribution function.static doublebarF(double a, double lambda, double c, double x)Computes the complementary distribution function.doublecdf(double x)Returns the distribution function F(x).static doublecdf(double a, double lambda, double c, double x)Computes the distribution function.doubledensity(double x)Returns f (x), the density evaluated at x.static doubledensity(double a, double lambda, double c, double x)Computes the density function of the Nakagami distribution.doublegetA()Returns the location parameter a of this object.doublegetC()Returns the shape parameter c of this object.doublegetLambda()Returns the scale parameter λ of this object.doublegetMean()Returns the mean.static doublegetMean(double a, double lambda, double c).double[]getParams()Return a table containing the parameters of the current distribution.doublegetStandardDeviation()Returns the standard deviation.static doublegetStandardDeviation(double a, double lambda, double c)Computes the standard deviation of the Nakagami distribution with parameters a, λ and c.doublegetVariance()Returns the variance.static doublegetVariance(double a, double lambda, double c).doubleinverseF(double u)Returns the inverse distribution function x = F-1(u).static doubleinverseF(double a, double lambda, double c, double u)Computes the inverse of the distribution function.voidsetParams(double a, double lambda, double c)Sets the parameters a, λ and c of this object.java.lang.StringtoString()Returns a String containing information about the current distribution.-
Methods inherited from class umontreal.iro.lecuyer.probdist.ContinuousDistribution
getXinf, getXsup, inverseBisection, inverseBrent, setXinf, setXsup
-
-
-
-
Constructor Detail
-
NakagamiDist
public NakagamiDist(double a, double lambda, double c)Constructs a NakagamiDist object with parameters a = a, λ = lambda and c = c.
-
-
Method Detail
-
density
public double density(double x)
Description copied from class:ContinuousDistributionReturns f (x), the density evaluated at x.- Specified by:
densityin classContinuousDistribution- Parameters:
x- value at which the density is evaluated- Returns:
- density function evaluated at x
-
cdf
public double cdf(double x)
Description copied from interface:DistributionReturns the distribution function F(x).- Parameters:
x- value at which the distribution function is evaluated- Returns:
- distribution function evaluated at x
-
barF
public double barF(double x)
Description copied from class:ContinuousDistributionReturns the complementary distribution function. The default implementation computes bar(F)(x) = 1 - F(x).- Specified by:
barFin interfaceDistribution- Overrides:
barFin classContinuousDistribution- Parameters:
x- value at which the complementary distribution function is evaluated- Returns:
- complementary distribution function evaluated at x
-
inverseF
public double inverseF(double u)
Description copied from class:ContinuousDistributionReturns the inverse distribution function x = F-1(u). Restrictions: u∈[0, 1].- Specified by:
inverseFin interfaceDistribution- Overrides:
inverseFin classContinuousDistribution- Parameters:
u- value at which the inverse distribution function is evaluated- Returns:
- the inverse distribution function evaluated at u
-
getMean
public double getMean()
Description copied from class:ContinuousDistributionReturns the mean.- Specified by:
getMeanin interfaceDistribution- Overrides:
getMeanin classContinuousDistribution- Returns:
- the mean
-
getVariance
public double getVariance()
Description copied from class:ContinuousDistributionReturns the variance.- Specified by:
getVariancein interfaceDistribution- Overrides:
getVariancein classContinuousDistribution- Returns:
- the variance
-
getStandardDeviation
public double getStandardDeviation()
Description copied from class:ContinuousDistributionReturns the standard deviation.- Specified by:
getStandardDeviationin interfaceDistribution- Overrides:
getStandardDeviationin classContinuousDistribution- Returns:
- the standard deviation
-
density
public static double density(double a, double lambda, double c, double x)Computes the density function of the Nakagami distribution.- Parameters:
a- the location parameterlambda- the scale parameterc- the shape parameterx- the value at which the density is evaluated- Returns:
- returns the density function
-
cdf
public static double cdf(double a, double lambda, double c, double x)Computes the distribution function.- Parameters:
a- the location parameterlambda- the scale parameterc- the shape parameterx- the value at which the distribution is evaluated- Returns:
- returns the cdf function
-
barF
public static double barF(double a, double lambda, double c, double x)Computes the complementary distribution function.- Parameters:
a- the location parameterlambda- the scale parameterc- the shape parameterx- the value at which the complementary distribution is evaluated- Returns:
- returns the complementary distribution function
-
inverseF
public static double inverseF(double a, double lambda, double c, double u)Computes the inverse of the distribution function.- Parameters:
a- the location parameterlambda- the scale parameterc- the shape parameteru- the value at which the inverse distribution is evaluated- Returns:
- returns the inverse distribution function
-
getMean
public static double getMean(double a, double lambda, double c). Computes and returns the meanE[X] = a +
.
- Parameters:
a- the location parameterlambda- the scale parameterc- the shape parameter- Returns:
- returns the mean
-
getVariance
public static double getVariance(double a, double lambda, double c). Computes and returns the varianceVar[X] =
[c - ([tex2html_wrap_indisplay261])2].
- Parameters:
a- the location parameterlambda- the scale parameterc- the shape parameter- Returns:
- returns the variance
-
getStandardDeviation
public static double getStandardDeviation(double a, double lambda, double c)Computes the standard deviation of the Nakagami distribution with parameters a, λ and c.- Parameters:
a- the location parameterlambda- the scale parameterc- the shape parameter- Returns:
- returns the standard deviation
-
getA
public double getA()
Returns the location parameter a of this object.- Returns:
- returns the location parameter
-
getLambda
public double getLambda()
Returns the scale parameter λ of this object.- Returns:
- returns the scale parameter
-
getC
public double getC()
Returns the shape parameter c of this object.- Returns:
- returns the shape parameter
-
setParams
public void setParams(double a, double lambda, double c)Sets the parameters a, λ and c of this object.- Parameters:
a- the location parameterlambda- the scale parameterc- the shape parameter
-
getParams
public double[] getParams()
Return a table containing the parameters of the current distribution. This table is put in regular order: [a, λ, c].- Returns:
- returns the parameters [a, λ, c]
-
toString
public java.lang.String toString()
Returns a String containing information about the current distribution.- Overrides:
toStringin classjava.lang.Object- Returns:
- returns a String containing information about the current distribution.
-
-
DMelt 3.0 © DataMelt by jWork.ORG