This class extends the class ContinuousDistribution for the Weibull distribution [95] (page 628) with shape parameter \(\alpha> 0\), location parameter \(\delta\), and scale parameter \(\lambda> 0\). More...
Public Member Functions | |
| WeibullDist (double alpha) | |
| Constructs a WeibullDist object with parameters \(\alpha\) = alpha, \(\lambda\) = 1, and \(\delta\) = 0. | |
| WeibullDist (double alpha, double lambda, double delta) | |
| Constructs a WeibullDist object with parameters \(\alpha=\) alpha, \(\lambda\) = lambda, and \(\delta\) = delta. | |
| 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 | getAlpha () |
| Returns the parameter \(\alpha\). | |
| double | getLambda () |
| Returns the parameter \(\lambda\). | |
| double | getDelta () |
| Returns the parameter \(\delta\). | |
| void | setParams (double alpha, double lambda, double delta) |
| Sets the parameters \(\alpha\), \(\lambda\) and \(\delta\) for 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 alpha, double lambda, double delta, double x) |
| Computes the density function. | |
| static double | density (double alpha, double x) |
| Same as density (alpha, 1, 0, x). | |
| static double | cdf (double alpha, double lambda, double delta, double x) |
| Computes the distribution function. | |
| static double | cdf (double alpha, double x) |
| Same as cdf (alpha, 1, 0, x). | |
| static double | barF (double alpha, double lambda, double delta, double x) |
| Computes the complementary distribution function. | |
| static double | barF (double alpha, double x) |
| Same as barF (alpha, 1, 0, x). | |
| static double | inverseF (double alpha, double lambda, double delta, double u) |
| Computes the inverse of the distribution function. | |
| static double | inverseF (double alpha, double x) |
| Same as inverseF (alpha, 1, 0, x). | |
| static double[] | getMLE (double[] x, int n) |
| Estimates the parameters \((\alpha, \lambda)\) of the Weibull distribution, assuming that \(\delta= 0\), using the maximum likelihood method, from the \(n\) observations \(x[i]\), \(i = 0, 1, …, n-1\). | |
| static WeibullDist | getInstanceFromMLE (double[] x, int n) |
| Creates a new instance of a Weibull distribution with parameters. | |
| static double | getMean (double alpha, double lambda, double delta) |
| Computes and returns the mean \(E[X] = \delta+ \Gamma(1 +
1/\alpha)/\lambda\) of the Weibull distribution with parameters \(\alpha\),. | |
| static double | getVariance (double alpha, double lambda, double delta) |
| Computes and returns the variance. | |
| static double | getStandardDeviation (double alpha, double lambda, double delta) |
| Computes and returns the standard deviation of the Weibull distribution with parameters \(\alpha\), \(\lambda\) and. | |
This class extends the class ContinuousDistribution for the Weibull distribution [95] (page 628) with shape parameter \(\alpha> 0\), location parameter \(\delta\), and scale parameter \(\lambda> 0\).
The density function is
\[ f(x) = \alpha\lambda^{\alpha}(x-\delta)^{\alpha-1} e^{-(\lambda(x-\delta))^{\alpha}} \qquad\mbox{for }x>\delta, \tag{fweibull} \]
\[ F(x) = 1 - e^{-(\lambda(x - \delta))^{\alpha}} \qquad\mbox{for }x>\delta, \tag{Fweibull} \]
and the inverse distribution function is
\[ F^{-1}(u) = (-\ln(1-u))^{1/\alpha}/\lambda+ \delta\qquad\mbox{for } 0 \le u < 1. \]
Definition at line 49 of file WeibullDist.java.
| umontreal.ssj.probdist.WeibullDist.WeibullDist | ( | double | alpha | ) |
Constructs a WeibullDist object with parameters \(\alpha\) = alpha, \(\lambda\) = 1, and \(\delta\) = 0.
Definition at line 97 of file WeibullDist.java.
| umontreal.ssj.probdist.WeibullDist.WeibullDist | ( | double | alpha, |
| double | lambda, | ||
| double | delta ) |
Constructs a WeibullDist object with parameters \(\alpha=\) alpha, \(\lambda\) = lambda, and \(\delta\) = delta.
Definition at line 105 of file WeibullDist.java.
|
static |
Computes the complementary distribution function.
Definition at line 191 of file WeibullDist.java.
|
static |
Same as barF (alpha, 1, 0, x).
Definition at line 211 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.barF | ( | double | x | ) |
Returns the complementary distribution function.
The default implementation computes \(\bar{F}(x) = 1 - F(x)\).
| x | value at which the complementary distribution function is evaluated |
Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.
Definition at line 117 of file WeibullDist.java.
|
static |
Computes the distribution function.
Definition at line 165 of file WeibullDist.java.
|
static |
Same as cdf (alpha, 1, 0, x).
Definition at line 184 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.cdf | ( | double | x | ) |
Returns the distribution function \(F(x)\).
| x | value at which the distribution function is evaluated |
Implements umontreal.ssj.probdist.Distribution.
Definition at line 113 of file WeibullDist.java.
|
static |
Computes the density function.
Definition at line 140 of file WeibullDist.java.
|
static |
Same as density (alpha, 1, 0, x).
Definition at line 158 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.density | ( | double | x | ) |
Returns \(f(x)\), the density evaluated at \(x\).
| x | value at which the density is evaluated |
Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.
Definition at line 109 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.getAlpha | ( | ) |
Returns the parameter \(\alpha\).
Definition at line 375 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.getDelta | ( | ) |
Returns the parameter \(\delta\).
Definition at line 389 of file WeibullDist.java.
|
static |
Creates a new instance of a Weibull distribution with parameters.
\(\alpha\), \(\lambda\) and \(\delta= 0\) estimated using the maximum likelihood method based on the \(n\) observations \(x[i]\), \(i = 0, 1, …, n-1\).
| x | the list of observations to use to evaluate parameters |
| n | the number of observations to use to evaluate parameters |
Definition at line 316 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.getLambda | ( | ) |
Returns the parameter \(\lambda\).
Definition at line 382 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.getMean | ( | ) |
Returns the mean.
Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.
Definition at line 125 of file WeibullDist.java.
|
static |
Computes and returns the mean \(E[X] = \delta+ \Gamma(1 + 1/\alpha)/\lambda\) of the Weibull distribution with parameters \(\alpha\),.
\(\lambda\) and \(\delta\).
Definition at line 330 of file WeibullDist.java.
|
static |
Estimates the parameters \((\alpha, \lambda)\) of the Weibull distribution, assuming that \(\delta= 0\), using the maximum likelihood method, from the \(n\) observations \(x[i]\), \(i = 0, 1, …, n-1\).
The estimates are returned in a two-element array, in regular order: [ \(\alpha\), \(\lambda\)]. The maximum likelihood estimators are the values \((\hat{\alpha}\), \(\hat{\lambda})\) that satisfy the equations
\begin{align*} \frac{\sum_{i=1}^n x_i^{\hat{\alpha}} \ln(x_i)}{\sum_{i=1}^n x_i^{\hat{\alpha}}} - \frac{1}{\hat{\alpha}} & = \frac{\sum_{i=1}^n \ln(x_i)}{n} \\ \hat{\lambda} & = \left( \frac{n}{\sum_{i=1}^n x_i^{\hat{\alpha}}} \right)^{1/\hat{\alpha}} \end{align*}
See [114] (page 303).
| x | the list of observations to use to evaluate parameters |
| n | the number of observations to use to evaluate parameters |
Definition at line 303 of file WeibullDist.java.
| double[] umontreal.ssj.probdist.WeibullDist.getParams | ( | ) |
Return a table containing the parameters of the current distribution.
This table is put in regular order: [ \(\alpha\), \(\lambda\), \(\delta\)].
Implements umontreal.ssj.probdist.Distribution.
Definition at line 413 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.getStandardDeviation | ( | ) |
Returns the standard deviation.
Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.
Definition at line 133 of file WeibullDist.java.
|
static |
Computes and returns the standard deviation of the Weibull distribution with parameters \(\alpha\), \(\lambda\) and.
\(\delta\).
Definition at line 368 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.getVariance | ( | ) |
Returns the variance.
Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.
Definition at line 129 of file WeibullDist.java.
|
static |
Computes and returns the variance.
\(\mbox{Var}[X] = | \Gamma(2/\alpha+ 1) - \Gamma^2(1/\alpha+ 1) | /\lambda^2\) of the Weibull distribution with parameters \(\alpha\), \(\lambda\) and \(\delta\).
Definition at line 349 of file WeibullDist.java.
|
static |
Computes the inverse of the distribution function.
Definition at line 218 of file WeibullDist.java.
|
static |
Same as inverseF (alpha, 1, 0, x).
Definition at line 242 of file WeibullDist.java.
| double umontreal.ssj.probdist.WeibullDist.inverseF | ( | double | u | ) |
Returns the inverse distribution function \(x = F^{-1}(u)\).
Restrictions: \(u \in[0,1]\).
| u | value at which the inverse distribution function is evaluated |
| IllegalArgumentException | if \(u\) is not in the interval \([0,1]\) |
Reimplemented from umontreal.ssj.probdist.ContinuousDistribution.
Definition at line 121 of file WeibullDist.java.
| void umontreal.ssj.probdist.WeibullDist.setParams | ( | double | alpha, |
| double | lambda, | ||
| double | delta ) |
Sets the parameters \(\alpha\), \(\lambda\) and \(\delta\) for this object.
Definition at line 397 of file WeibullDist.java.
| String umontreal.ssj.probdist.WeibullDist.toString | ( | ) |
Returns a String containing information about the current distribution.
Definition at line 421 of file WeibullDist.java.