statistic.distribution
Class ConstantDistribution
java.lang.Object
|
+--statistic.distribution.GenericDistribution
|
+--statistic.distribution.GenericContinuousDistribution
|
+--statistic.distribution.ConstantDistribution
- All Implemented Interfaces:
- RandomGenerator
- public class ConstantDistribution
- extends GenericContinuousDistribution
- implements RandomGenerator
Method Summary |
double |
cdf(double x)
Returns the value of the cumulative distribution function at x (=Fonction de repartition) |
double |
inverseCdf(double x)
Return the value of Inverse Function at x |
double |
mean()
Returns the mean of the distribution |
double |
pdf(double x)
Returns the value of the probability distribution function at x |
double |
rand()
Return a random value |
double |
var()
Returns the variance of the distribution |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ConstantDistribution
public ConstantDistribution()
ConstantDistribution
public ConstantDistribution(double a)
pdf
public double pdf(double x)
- Returns the value of the probability distribution function at x
- Specified by:
pdf
in class GenericDistribution
cdf
public double cdf(double x)
- Returns the value of the cumulative distribution function at x (=Fonction de repartition)
- Specified by:
cdf
in class GenericDistribution
inverseCdf
public double inverseCdf(double x)
throws java.lang.IllegalArgumentException
- Return the value of Inverse Function at x
- Specified by:
inverseCdf
in class GenericContinuousDistribution
- Parameters:
x
- with x>=0 and x<=1
java.lang.IllegalArgumentException
mean
public double mean()
- Description copied from class:
GenericDistribution
- Returns the mean of the distribution
- Specified by:
mean
in class GenericDistribution
var
public double var()
- Description copied from class:
GenericDistribution
- Returns the variance of the distribution
- Specified by:
var
in class GenericDistribution
rand
public double rand()
- Description copied from class:
GenericDistribution
- Return a random value
- Overrides:
rand
in class GenericDistribution