Class Batch
java.lang.Object
random.AbstractDistribution
random.Batch
- All Implemented Interfaces:
Distribution, StorableDistribution
This is the Batched distribution.
Copyright (c) 2003
Politecnico di Milano - dipartimento di Elettronica e Informazione
Copyright (c) 2003
Politecnico di Milano - dipartimento di Elettronica e Informazione
- Author:
- Jerry Zhu
-
Field Summary
Fields inherited from class AbstractDistribution
engine -
Constructor Summary
ConstructorsConstructorDescriptionBatch(DistributionContainer base, Integer fixedBatchSize, Boolean IsFixedBatchSize) Batch(DistributionContainer base, DistributionContainer batchSize, Integer fixedBatchSize, Boolean isFixedBatchSize) This is the constructor. -
Method Summary
Modifier and TypeMethodDescriptiondoubleThis method is used to obtain from the distribution its cumulative distribution function evaluated where required by the user.doubleThis method is used to obtain from the distribution the next number distributed according to the distribution parameter.doubleThis method is used to obtain from the distribution its probability distribution function evaluated where required by the user.doubleThis method is used to obtain from the distribution the value of its own theoretic mean.doubleThis method is used to obtain from the distribution the value of its own theoretic variance.Methods inherited from class AbstractDistribution
setRandomEngineMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Distribution
setRandomEngine
-
Constructor Details
-
Batch
public Batch(DistributionContainer base, DistributionContainer batchSize, Integer fixedBatchSize, Boolean isFixedBatchSize) This is the constructor. It creates a new Batched distribution -
Batch
-
-
Method Details
-
cdf
Description copied from interface:DistributionThis method is used to obtain from the distribution its cumulative distribution function evaluated where required by the user.- Specified by:
cdfin interfaceDistribution- Parameters:
x- the x valuep- the p value- Returns:
- always 0 because in this type of distribution it has no sense to request the cdf of the distribution.
- Throws:
IncorrectDistributionParameterException- if the operation cannot be completed
-
pdf
Description copied from interface:DistributionThis method is used to obtain from the distribution its probability distribution function evaluated where required by the user.- Specified by:
pdfin interfaceDistribution- Parameters:
x- the x valuep- the p value- Returns:
- always 0 because in this type of distribution it has no sense to request the pdf of the distribution.
- Throws:
IncorrectDistributionParameterException- if the operation cannot be completed
-
theorMean
This method is used to obtain from the distribution the value of its own theoretic mean.- Specified by:
theorMeanin interfaceDistribution- Parameters:
p- parameter of the constant distribution.- Returns:
- double with the theoretic mean of the distribution.
- Throws:
IncorrectDistributionParameterException
-
theorVariance
Description copied from interface:DistributionThis method is used to obtain from the distribution the value of its own theoretic variance.- Specified by:
theorVariancein interfaceDistribution- Parameters:
p- the p value- Returns:
- always 0 because in this type of distribution it has no sense to request the variance of the distribution.
- Throws:
IncorrectDistributionParameterException- if the operation cannot be completed
-
nextRand
This method is used to obtain from the distribution the next number distributed according to the distribution parameter.- Specified by:
nextRandin interfaceDistribution- Parameters:
p- parameter of the exponential distribution.- Returns:
- double with the next random number of this distribution.
- Throws:
IncorrectDistributionParameterException
-