SSJ API Documentation
Stochastic Simulation in Java
Loading...
Searching...
No Matches
umontreal.ssj.probdist.NakagamiDist Class Reference

Extends the class ContinuousDistribution for the Nakagami distribution with location parameter \(a\), scale parameter \(\lambda> 0\) and shape parameter \(c > 0\). More...

Inheritance diagram for umontreal.ssj.probdist.NakagamiDist:
umontreal.ssj.probdist.ContinuousDistribution umontreal.ssj.probdist.Distribution

Public Member Functions

 NakagamiDist (double a, double lambda, double c)
 Constructs a NakagamiDist object with parameters \(a =\) a,.
double density (double x)
 Returns \(f(x)\), the density evaluated at \(x\).
double cdf (double x)
 Returns the distribution function \(F(x)\).
double barF (double x)
 Returns the complementary distribution function.
double inverseF (double u)
 Returns the inverse distribution function \(x = F^{-1}(u)\).
double getMean ()
 Returns the mean.
double getVariance ()
 Returns the variance.
double getStandardDeviation ()
 Returns the standard deviation.
double getA ()
 Returns the location parameter \(a\) of this object.
double getLambda ()
 Returns the scale parameter \(\lambda\) of this object.
double getC ()
 Returns the shape parameter \(c\) of this object.
void setParams (double a, double lambda, double c)
 Sets the parameters \(a\), \(\lambda\) and \(c\) of this object.
double[] getParams ()
 Return a table containing the parameters of the current distribution.
String toString ()
 Returns a String containing information about the current distribution.
Public Member Functions inherited from umontreal.ssj.probdist.ContinuousDistribution
double inverseBrent (double a, double b, double u, double tol)
 Computes the inverse distribution function \(x = F^{-1}(u)\), using the Brent-Dekker method.
double inverseBisection (double u)
 Computes and returns the inverse distribution function \(x = F^{-1}(u)\), using bisection.
double getXinf ()
 Returns \(x_a\) such that the probability density is 0 everywhere outside the interval \([x_a, x_b]\).
double getXsup ()
 Returns \(x_b\) such that the probability density is 0 everywhere outside the interval \([x_a, x_b]\).
void setXinf (double xa)
 Sets the value \(x_a=\) xa, such that the probability density is 0 everywhere outside the interval \([x_a, x_b]\).
void setXsup (double xb)
 Sets the value \(x_b=\) xb, such that the probability density is 0 everywhere outside the interval \([x_a, x_b]\).

Static Public Member Functions

static double density (double a, double lambda, double c, double x)
 Computes the density function of the Nakagami distribution.
static double cdf (double a, double lambda, double c, double x)
 Computes the distribution function.
static double barF (double a, double lambda, double c, double x)
 Computes the complementary distribution function.
static double inverseF (double a, double lambda, double c, double u)
 Computes the inverse of the distribution function.
static double getMean (double a, double lambda, double c)
 Computes and returns the mean.
static double getVariance (double a, double lambda, double c)
 Computes and returns the variance.
static double getStandardDeviation (double a, double lambda, double c)
 Computes the standard deviation of the Nakagami distribution with parameters \(a\), \(\lambda\) and \(c\).

Detailed Description

Extends the class ContinuousDistribution for the Nakagami distribution with location parameter \(a\), scale parameter \(\lambda> 0\) and shape parameter \(c > 0\).

The density is

\[ f(x) = \frac{2\lambda^c}{\Gamma(c)} (x-a)^{2c-1} e^{-{\lambda}(x-a)^2} \qquad\mbox{for } x > a,\tag{fnakagami} \]

\[ f(x) = 0 \qquad\mbox{ for } x \le a, \]

where \(\Gamma\) is the gamma function.

Definition at line 44 of file NakagamiDist.java.

Constructor & Destructor Documentation

◆ NakagamiDist()

umontreal.ssj.probdist.NakagamiDist.NakagamiDist ( double a,
double lambda,
double c )

Constructs a NakagamiDist object with parameters \(a =\) a,.

\(\lambda=\) lambda and \(c =\) c.

Definition at line 56 of file NakagamiDist.java.

Member Function Documentation

◆ barF() [1/2]

double umontreal.ssj.probdist.NakagamiDist.barF ( double a,
double lambda,
double c,
double x )
static

Computes the complementary distribution function.

Parameters
athe location parameter
lambdathe scale parameter
cthe shape parameter
xthe value at which the complementary distribution is evaluated
Returns
returns the complementary distribution function

Definition at line 140 of file NakagamiDist.java.

◆ barF() [2/2]

double umontreal.ssj.probdist.NakagamiDist.barF ( double x)

Returns the complementary distribution function.

The default implementation computes \(\bar{F}(x) = 1 - F(x)\).

Parameters
xvalue at which the complementary distribution function is evaluated
Returns
complementary distribution function evaluated at x

Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.

Definition at line 70 of file NakagamiDist.java.

◆ cdf() [1/2]

double umontreal.ssj.probdist.NakagamiDist.cdf ( double a,
double lambda,
double c,
double x )
static

Computes the distribution function.

Parameters
athe location parameter
lambdathe scale parameter
cthe shape parameter
xthe value at which the distribution is evaluated
Returns
returns the cdf function

Definition at line 120 of file NakagamiDist.java.

◆ cdf() [2/2]

double umontreal.ssj.probdist.NakagamiDist.cdf ( double x)

Returns the distribution function \(F(x)\).

Parameters
xvalue at which the distribution function is evaluated
Returns
distribution function evaluated at x

Implements umontreal.ssj.probdist.Distribution.

Definition at line 66 of file NakagamiDist.java.

◆ density() [1/2]

double umontreal.ssj.probdist.NakagamiDist.density ( double a,
double lambda,
double c,
double x )
static

Computes the density function of the Nakagami distribution.

Parameters
athe location parameter
lambdathe scale parameter
cthe shape parameter
xthe value at which the density is evaluated
Returns
returns the density function

Definition at line 99 of file NakagamiDist.java.

◆ density() [2/2]

double umontreal.ssj.probdist.NakagamiDist.density ( double x)

Returns \(f(x)\), the density evaluated at \(x\).

Parameters
xvalue at which the density is evaluated
Returns
density function evaluated at x

Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.

Definition at line 60 of file NakagamiDist.java.

◆ getA()

double umontreal.ssj.probdist.NakagamiDist.getA ( )

Returns the location parameter \(a\) of this object.

Returns
returns the location parameter

Definition at line 227 of file NakagamiDist.java.

◆ getC()

double umontreal.ssj.probdist.NakagamiDist.getC ( )

Returns the shape parameter \(c\) of this object.

Returns
returns the shape parameter

Definition at line 245 of file NakagamiDist.java.

◆ getLambda()

double umontreal.ssj.probdist.NakagamiDist.getLambda ( )

Returns the scale parameter \(\lambda\) of this object.

Returns
returns the scale parameter

Definition at line 236 of file NakagamiDist.java.

◆ getMean() [1/2]

double umontreal.ssj.probdist.NakagamiDist.getMean ( )

Returns the mean.

Returns
the mean

Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.

Definition at line 78 of file NakagamiDist.java.

◆ getMean() [2/2]

double umontreal.ssj.probdist.NakagamiDist.getMean ( double a,
double lambda,
double c )
static

Computes and returns the mean.

\[ E[X] = a + \frac{1}{\sqrt{\lambda}}\; \frac{\Gamma(c+1/2)}{\Gamma(c)}. \]

Parameters
athe location parameter
lambdathe scale parameter
cthe shape parameter
Returns
returns the mean

Definition at line 183 of file NakagamiDist.java.

◆ getParams()

double[] umontreal.ssj.probdist.NakagamiDist.getParams ( )

Return a table containing the parameters of the current distribution.

This table is put in regular order: [ \(a\), \(\lambda\), \(c\)].

Returns
returns the parameters [ \(a\), \(\lambda\), \(c\)]

Implements umontreal.ssj.probdist.Distribution.

Definition at line 274 of file NakagamiDist.java.

◆ getStandardDeviation() [1/2]

double umontreal.ssj.probdist.NakagamiDist.getStandardDeviation ( )

Returns the standard deviation.

Returns
the standard deviation

Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.

Definition at line 86 of file NakagamiDist.java.

◆ getStandardDeviation() [2/2]

double umontreal.ssj.probdist.NakagamiDist.getStandardDeviation ( double a,
double lambda,
double c )
static

Computes the standard deviation of the Nakagami distribution with parameters \(a\), \(\lambda\) and \(c\).

Parameters
athe location parameter
lambdathe scale parameter
cthe shape parameter
Returns
returns the standard deviation

Definition at line 218 of file NakagamiDist.java.

◆ getVariance() [1/2]

double umontreal.ssj.probdist.NakagamiDist.getVariance ( )

Returns the variance.

Returns
the variance

Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.

Definition at line 82 of file NakagamiDist.java.

◆ getVariance() [2/2]

double umontreal.ssj.probdist.NakagamiDist.getVariance ( double a,
double lambda,
double c )
static

Computes and returns the variance.

\[ \mbox{Var}[X] = \frac{1}{\lambda} \left[c - \left(\frac{\Gamma(c+1/2)}{\Gamma(c)}\right)^2\right]. \]

Parameters
athe location parameter
lambdathe scale parameter
cthe shape parameter
Returns
returns the variance

Definition at line 200 of file NakagamiDist.java.

◆ inverseF() [1/2]

double umontreal.ssj.probdist.NakagamiDist.inverseF ( double a,
double lambda,
double c,
double u )
static

Computes the inverse of the distribution function.

Parameters
athe location parameter
lambdathe scale parameter
cthe shape parameter
uthe value at which the inverse distribution is evaluated
Returns
returns the inverse distribution function

Definition at line 159 of file NakagamiDist.java.

◆ inverseF() [2/2]

double umontreal.ssj.probdist.NakagamiDist.inverseF ( double u)

Returns the inverse distribution function \(x = F^{-1}(u)\).

Restrictions: \(u \in[0,1]\).

Parameters
uvalue at which the inverse distribution function is evaluated
Returns
the inverse distribution function evaluated at u
Exceptions
IllegalArgumentExceptionif \(u\) is not in the interval \([0,1]\)

Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.

Definition at line 74 of file NakagamiDist.java.

◆ setParams()

void umontreal.ssj.probdist.NakagamiDist.setParams ( double a,
double lambda,
double c )

Sets the parameters \(a\), \(\lambda\) and \(c\) of this object.

Parameters
athe location parameter
lambdathe scale parameter
cthe shape parameter

Definition at line 256 of file NakagamiDist.java.

◆ toString()

String umontreal.ssj.probdist.NakagamiDist.toString ( )

Returns a String containing information about the current distribution.

Returns
returns a String containing information about the current distribution.

Definition at line 285 of file NakagamiDist.java.


The documentation for this class was generated from the following file: