Documentation / Manuel développeur
Modules disponibles
Calibration,  DataServer,  Launcher,  MetaModelOptim,  Modeler,  Optimizer,  ReLauncher,  Reliability,  ReOptimizer,  Sampler,  Sensitivity,  UncertModeler,  XmlProblem,  ![]()  | 
  
    Uranie / DataServer
    v4.10.0
    
   | 
 
Description of the class TGammaDistribution. More...
#include <TGammaDistribution.h>


Public Member Functions | |
Constructor and Destructor  | |
| TGammaDistribution () | |
| Default constructor.  More... | |
| TGammaDistribution (TString name) | |
| Constructor setting the name.  More... | |
| TGammaDistribution (TString name, Double_t alpha, Double_t scale=1.0, Double_t location=0.0) | |
| Constructor setting name, scale and location.  More... | |
| TGammaDistribution (URANIE::DataServer::TAttribute *att, Double_t alpha, Double_t scale=1.0, Double_t location=0.0) | |
| Construction of a TGammaDistribution from an existing TAttribute object.  More... | |
| virtual | ~TGammaDistribution () | 
| Default destructor.  More... | |
Getters and Setters parameters  | |
The gamma distribution has three parameters: the shape \( \alpha \), a scale parameter (default equal to 1) and a location parameter (default equal to 0).  | |
| Double_t | getParameterAlpha () | 
| Return the shape parameter.  More... | |
| Double_t | getParameterScale () | 
| Return the scale parameter.  More... | |
| Double_t | getParameterLocation () | 
| Return the location parameter.  More... | |
| virtual void | setParameters (Double_t alpha, Double_t scale=1.0, Double_t location=0, Bool_t recompute=kTRUE) | 
| Set all the parameters.  More... | |
| void | setParameterAlpha (Double_t alpha, Bool_t recompute=kTRUE) | 
| Set alpha value.  More... | |
| void | setParameterScale (Double_t scale, Bool_t recompute=kTRUE) | 
| Set scale value.  More... | |
| void | setParameterLocation (Double_t location, Bool_t recompute=kTRUE) | 
| Set location value.  More... | |
Distribution specific methods  | |
PDF, CDF, etc.  | |
| virtual void | computeTheoreticalInformation () | 
| Computes the theoretical values of various statistical measures.  More... | |
| virtual Double_t | getPDF (Double_t x) | 
| Returns the probability density for the value x.  More... | |
| virtual Double_t | getCDF (Double_t x) | 
| Returns the cumulative distribution for the value x.  More... | |
| virtual Double_t | getInvCDF (Double_t p) | 
| Returns the value corresponding to the cumulative density p.  More... | |
Printing Log  | |
| virtual void | printLog (Option_t *option="") | 
  Public Member Functions inherited from URANIE::DataServer::TInfiniteDistribution | |
| TInfiniteDistribution () | |
| Default Constructor.  More... | |
| TInfiniteDistribution (TString str) | |
| Constructor setting the name.  More... | |
| TInfiniteDistribution (TString str, ELawType value) | |
| Constructor setting the name and the law type.  More... | |
| TInfiniteDistribution (TAttribute *object, ELawType value) | |
| Construction of a TInfiniteDistribution from an existing TAttribute object.  More... | |
| virtual | ~TInfiniteDistribution () | 
| Default Destructor.  More... | |
| virtual void | printLog () | 
| Display information specific to this class.  More... | |
| virtual void | setLowerBound (Double_t val) | 
| Sets the lower bound of the attribute.  More... | |
| virtual void | setUpperBound (Double_t val) | 
| Sets the upper bound of the attribute.  More... | |
| virtual void | setBounds (Double_t lower, Double_t upper) | 
| Sets the lower and upper bounds of the attribute.  More... | |
  Public Member Functions inherited from URANIE::DataServer::TStochasticAttribute | |
| TStochasticAttribute () | |
| Default Constructor.  More... | |
| TStochasticAttribute (TString str) | |
| Constructor setting the name.  More... | |
| TStochasticAttribute (TString str, ELawType value) | |
| Constructor setting the name and the law type.  More... | |
| TStochasticAttribute (TString str, ELawType value, Double_t min, Double_t max) | |
| Constructor setting the name, the law type, and the range (lower and upper bounds)  More... | |
| TStochasticAttribute (TAttribute *object, ELawType value) | |
| Construction of a TStochasticAttribute from an existing TAttribute object.  More... | |
| virtual | ~TStochasticAttribute () | 
| Default Destructor.  More... | |
| double | getPDFforTF1 (double *x) | 
| double | getCDFforTF1 (double *x) | 
| double | getInvCDFforTF1 (double *x) | 
| virtual Double_t | getTheoreticalMean () | 
| Returns the theoretical value of the mean.  More... | |
| virtual Double_t | getTheoreticalStdDev () | 
| Returns the theoretical value of the standard deviation.  More... | |
| virtual Double_t | getTheoreticalMode () | 
| Returns the theoretical value of the mode.  More... | |
| void | setLawType (ELawType value) | 
| Sets the law type from an integer value.  More... | |
| void | setLawType (TString name) | 
| Sets the law type from a law name.  More... | |
| int | getLawType () | 
| Returns the law type as an integer.  More... | |
| void | setStochasticBasis (EStochasticBasis n) | 
| Defines an orthogonal polynomial family to represent the stochastic attribute.  More... | |
| void | setDefaultStochasticBasis () | 
| Sets the default orthogonal polynomial family representing the stochastic attribute.  More... | |
| EStochasticBasis | getStochasticBasis () const | 
| Returns the orthogonal polynomial which is used to represent the attribute.  More... | |
| virtual Double_t | getPMin () | 
| Returns the minimum value of the cumulative distribution function.  More... | |
| virtual Double_t | getPMax () | 
| Returns the maximum value of the cumulative distribution function.  More... | |
  Public Member Functions inherited from URANIE::DataServer::TAttribute | |
| TAttribute () | |
| Default constructor.  More... | |
| TAttribute (const char *name, const char *title) | |
| TAttribute (TString name) | |
| Constructor by name only.  More... | |
| TAttribute (TString name, EType type) | |
| Constructor by name and type only.  More... | |
| TAttribute (TString name, TString value, EType type) | |
| Constructor by name and range.  More... | |
| TAttribute (TString name, Double_t lower, Double_t upper) | |
| Constructor by name and range.  More... | |
| TAttribute (const TAttribute &attr) | |
| Copy constructor.  More... | |
| TAttribute * | Clone (const char *newname) const | 
| Clone an attribute with a new name.  More... | |
| virtual | ~TAttribute () | 
| Default destructor.  More... | |
| void | checkSizeBeforePush (const char *type, int iel, Double_t val) | 
| Internal method used to check the validity of all setters when dealing with vectors.  More... | |
| Double_t | checkSizeBeforeGet (const char *type, int iel=0) | 
| Internal method used to check the validity of all getters when dealing with vectors and return the request.  More... | |
| void | setQuantile (double prob, double quantile, int iel=0) | 
| Set the quantile value.  More... | |
| void | getQuantilesSize (int &nb, int iel=0) | 
| Returns the number of quantile computed and stored for element iel.  More... | |
| void | getQuantiles (double *prob, double *quantile, int iel=0) | 
| Returns all the probabilities and corresponding quantiles computed for element iel.  More... | |
| void | getQuantile (double &prob, double &quantile, int iel=0) | 
| Returns the value of the quantile for element iel, given the probability.  More... | |
| void | getQuantileVector (double &prob, vector< double > &quantile) | 
| Returns the vector of quantile given the probability.  More... | |
| Double_t | getMinimum (int iel=0) | 
| Double_t | getMinimumSize () | 
| Returns the size of the vector of minimum.  More... | |
| Bool_t | hasDefault () | 
| Details whether this attribute has a default value.  More... | |
| void | setMinimum (Double_t val, int iel=0) | 
| Set the minimum value oef element iel.  More... | |
| Double_t | getMaximum (int iel=0) | 
| Double_t | getMaximumSize () | 
| Returns the size of the vector of maximum.  More... | |
| void | setMaximum (Double_t val, int iel=0) | 
| Set the maximum value oef element iel.  More... | |
| void | getStatisticalVector (const char *type, vector< double > &vec) | 
| Returns the vector of considered statistical value.  More... | |
| Double_t | getMean (int iel=0) | 
| Double_t | getMeanSize () | 
| Returns the size of the vector of mean.  More... | |
| void | setMean (Double_t val, int iel=0) | 
| Set the mean value oef element iel.  More... | |
| Double_t | getStd (int iel=0) | 
| Double_t | getStdSize () | 
| Returns the size of the vector of std.  More... | |
| void | setStd (Double_t val, int iel=0) | 
| Set the std value oef element iel.  More... | |
| void | setSlurmOption (TString value) | 
| EType | getDataType () const | 
| Returns the datatype of the considered attribute.  More... | |
| TString | getDataTypeStr () | 
| Returns the datatype as TString.  More... | |
| void | setTitle (const char *title) | 
| Defines the title of the attribute.  More... | |
| void | setTitle (TString str) | 
| TString | getTitle () | 
| void | setDataType (EType thetype) | 
| Change the type of data.  More... | |
| void | setDataType (TString name) | 
| Change the type of data.  More... | |
| TString | getLegend () | 
| Returns the legend of the attribut.  More... | |
| TString | getUnit () | 
| void | setUnit (TString str) | 
| TString | getUnity () | 
| void | setUnity (TString str) | 
| TString | getNote () | 
| void | setNote (TString str) | 
| Bool_t | setDefault (TString value) | 
| TString | getDefault (TString format="%e") | 
| Bool_t | setDefaultValue (Double_t val) | 
| Bool_t | getDefaultValue (Double_t &val) | 
| Bool_t | hasDefaultValue () | 
| Bool_t | setDefaultVector (vector< double > &vec) | 
| Bool_t | getDefaultVector (vector< double > *val) | 
| Bool_t | hasDefaultVector () | 
| Bool_t | setDefaultString (TString str) | 
| Bool_t | getDefaultString (string &str) | 
| Bool_t | hasDefaultString () | 
| void | setStepValue (Double_t val) | 
| Bool_t | getStepValue (Double_t &val) | 
| TString | getSlurmOption () | 
| EOrigin | getOrigin () | 
| void | setOrigin (EOrigin ind) | 
| Int_t | getShare () | 
| void | setOutput () | 
| Sets the attribute as an output attribute.  More... | |
| void | setInput () | 
| Sets the attribute as Input.  More... | |
| EAttribute | getInputOutput () | 
| Returns the input/Output information of the attribute.  More... | |
| void | setFileNameOfKey (TString str) | 
| Sets the file name for a key.  More... | |
| list< URANIE::DataServer::TAttributeFileKey * > | getKeyList () | 
| Gets KeyList for the attribute.  More... | |
| void | setFieldOfKey (Int_t ind) | 
| Sets index ind in the unique field related to a unique key.  More... | |
| void | setFieldOfKey (Int_t sIndex, Int_t ind) | 
| void | setFileKey (TString sfile, TString skey="", TString sformatToSubstitute="%e", TAttributeFileKey::EFileType FileType=TAttributeFileKey::kKey) | 
| Defines the input files and eventually others informations like key, format to substitute.  More... | |
| void | setFileFlag (TString sfile, TString skey="", TString sformatToSubstitute="%e") | 
| Defines the input files as in the "flag" format and eventually others informations like key, format to substitute.  More... | |
| void | setFileXMLAttribute (TString sfile, TString sXPathAttribute, TString sformatToSubstitute="%e") | 
| Defines the input files as an "XML" input file with XPath attribute format and eventually the format to substitute.  More... | |
| void | setFileXMLField (TString sfile, TString sXPathField, TString sformatToSubstitute="%e") | 
| Defines the input files as an "XML" input file with XPath field and eventually the format to substitute.  More... | |
| void | setFileFMU (TString sfile, TString sXPathField, TString sformatToSubstitute="%e") | 
| const char * | getFormatToSubstitute () | 
| Returns the format of substitution.  More... | |
| void | setFormatToSubstitute (TString str) | 
| Sets the format of substitution.  More... | |
| Bool_t | isInput () | 
| Tests if the attribute is an input attribute.  More... | |
| Bool_t | isOutput () | 
| Tests if the attribute is an output attribute.  More... | |
| void | addShare () | 
| void | delShare () | 
| void | initShare () | 
| void | clearVectors () | 
| virtual void | setLowerBound (Double_t val, bool internalcall=false) | 
| Sets the lower bound value of the attribute.  More... | |
| Double_t | getLowerBound () | 
| Gets the lower bound value of the attribute.  More... | |
| Bool_t | isLowerBounded () | 
| Returns a boolean if the attribute have a lower bound.  More... | |
| virtual void | setUpperBound (Double_t val, bool internalcall=false) | 
| Sets the upper bound value of the attribute.  More... | |
| Double_t | getUpperBound () | 
| Gets the upper bound value of the attribute.  More... | |
| Bool_t | isUpperBounded () | 
| Returns a boolean if the attribute have an upper bound.  More... | |
| Bool_t | isBounded () | 
| Returns a boolean if the attribute have a lower AND an upper bounds.  More... | |
| void | setLog () | 
| void | unsetLog () | 
| void | changeLog () | 
| Bool_t | getLog () | 
| TAttribute * | getSonAttribute () | 
| void | setSonAttribute (TAttribute *tatt) | 
| void | removeSonAttribute () | 
| Int_t | getLevel () | 
| void | setLevel (Int_t nlevel) | 
| Bool_t | haveSon () | 
Private Attributes | |
| Double_t | _dparameterAlpha | 
| the shape parameter  More... | |
| Double_t | _dparameterScale | 
| the scale parameter  More... | |
| Double_t | _dparameterLocation | 
| the location parameter  More... | |
Additional Inherited Members | |
  Public Types inherited from URANIE::DataServer::TStochasticAttribute | |
| enum | ELawType {  kUniform, kLogUniform, kNormal, kStudent, kLogNormal, kTrapezium, kTriangular, kLogTriangular, kExponential, kBeta, kGamma, kInvGamma, kCauchy, kUniformByParts, kWeibull, kGumbel, kMultinomial, kGenPareto, kGeneralizedNormal, kGeneralizedNormalV2, kCompose, kUnknown }  | 
| The list of laws that a TStochasticAttribute can follow.  More... | |
| enum | EStochasticBasis {  kUnknownBasis, kHermite, kLegendre, kLaguerre, kJacobi }  | 
| The list of orthogonal polynomial families that can represent a given TStochasticAttribute.  More... | |
  Public Types inherited from URANIE::DataServer::TAttribute | |
| enum | EOrigin {  kInternal, kIterator, kConstant, kAttribute, kDeleted }  | 
| enum | EAttribute { kInput, kOutput } | 
| enum | EType {  kDefault, kReal, kVector, kString, kCategory, kInconnu }  | 
  Protected Attributes inherited from URANIE::DataServer::TStochasticAttribute | |
| ELawType | _lawType | 
| The law type ELawType.  More... | |
| Double_t | _dtheoreticalMean | 
| The theoretical mean.  More... | |
| Double_t | _dtheoreticalStdDev | 
| The theoretical standard deviation.  More... | |
| Double_t | _dtheoreticalMode | 
| The theoretical mode.  More... | |
| Double_t | _pmin | 
| The min value of cumulative density function.  More... | |
| Double_t | _pmax | 
| The max value of cumulative density function.  More... | |
| EStochasticBasis | _nStochasticBasis | 
| The stochastic representation of an orthogonal basis.  More... | |
  Protected Attributes inherited from URANIE::DataServer::TAttribute | |
| EOrigin | _norigin | 
| The origin of the attribute (Internal of uranie, attribute or Input, Output...)  More... | |
| EAttribute | _nAttribute | 
| The nature of attributes : kInput (default) or kOutput.  More... | |
| EType | _nType | 
| The type of attribute: real (double), vector (of double), string...  More... | |
| TString | _sunity | 
| Unity.  More... | |
| TString | _snote | 
| Note.  More... | |
| Bool_t | _blog | 
| Log printing.  More... | |
| Int_t | _nshare | 
| The number of time this attribute is shared in TDataServer.  More... | |
| TAttribute * | _attSon | 
| Son attribute.  More... | |
| Int_t | _nlevel | 
| level to its "father"  More... | |
| Bool_t | _haveSon | 
| true if the attribute have a son  More... | |
| TString | _sFormatSubstitute | 
| Format to substitute the value.  More... | |
| list< TEventList * > | _nfields | 
| List of all TEventLists created for the attribute.  More... | |
| list< TAttributeFileKey * > | _KeyList | 
| List of Keys Attributes structures.  More... | |
| Double_t | upperBound | 
| Upper bound.  More... | |
| Bool_t | _bHaveUpperBound | 
| If have an upper bound.  More... | |
| Double_t | lowerBound | 
| Lower bound.  More... | |
| Bool_t | _bHaveLowerBound | 
| If have a lower bound.  More... | |
| Double_t | _defaultValue | 
| Default value.  More... | |
| Bool_t | _bHaveDefaultValue | 
| If have a default value.  More... | |
| vector< double > | _defaultVector | 
| Default value for vector.  More... | |
| Bool_t | _bHaveDefaultVector | 
| If have a default value for vector.  More... | |
| string | _defaultString | 
| Default value for string.  More... | |
| Bool_t | _bHaveDefaultString | 
| If have a default value for string.  More... | |
| Double_t | _stepValue | 
| Step value when using in Optimization.  More... | |
| Bool_t | _bHaveStepValue | 
| If have a step value.  More... | |
| vector< Double_t > | _vminimum | 
| All minimun calculated.  More... | |
| vector< Double_t > | _vmaximum | 
| All maximun calculated.  More... | |
| vector< Double_t > | _vmean | 
| All mean calculated.  More... | |
| vector< Double_t > | _vstd | 
| All std calculated.  More... | |
| vector< Double_t > * | _vbuffer | 
| vector< map< double, double > *> | _vquantile | 
More...  | |
| TString | _slurmValue | 
Detailed Description
Description of the class TGammaDistribution.
This class defines a stochastic attribute following a Gamma distribution.
The distribution is defined over the interval \( ]0,+\infty [ \). It only depends on a shape parameter \( \alpha>0 \) in the standardized form. To scale and/or shift the distribution, one can use the scale parameter and the location parameter respectively.
- Probability Density Function (PDF):
 
- \( f(x) = x^{\alpha - 1} / \Gamma(\alpha) \times exp{(-x)} \) is the standardized form. To shift and/or scale the distribution use the \( loc \) and \( scale \) parameters. The density becomes \( \frac{f(y)}{scale} \) where \( y=(x-loc)/scale \) .
 
- Cumulative Distribution Function (CDF):
 
- \( F(x) = \frac{\gamma(\alpha,(x-loc)/scale)}{\Gamma(\alpha)}\) where the numerator is the lower incomplete gamma function.
 
- Inverse CDF:
 - There is no analytical representation of the Inverse CDF of the Gamma distribution. The value \( F^{-1}(p) \) is estimated by dichotomy from the CDF.
 
Constructor & Destructor Documentation
◆ TGammaDistribution() [1/4]
| URANIE::DataServer::TGammaDistribution::TGammaDistribution | ( | ) | 
Default constructor.
Default shape is 1.0, default scale and location are 1.0 and 0.0 respectively.
Referenced by ClassImp().
◆ TGammaDistribution() [2/4]
| URANIE::DataServer::TGammaDistribution::TGammaDistribution | ( | TString | name | ) | 
Constructor setting the name.
Default shape is 1.0, default scale and location are 1.0 and 0.0 respectively.
- Parameters
 - 
  
name (TString) Name of the attribute  
◆ TGammaDistribution() [3/4]
| URANIE::DataServer::TGammaDistribution::TGammaDistribution | ( | TString | name, | 
| Double_t | alpha, | ||
| Double_t | scale = 1.0,  | 
        ||
| Double_t | location = 0.0  | 
        ||
| ) | 
Constructor setting name, scale and location.
- Parameters
 - 
  
name (TString) Name of the attribute alpha (Double_t) the shape parameter \( \alpha \) scale (Double_t) the scale parameter (Default = 0.0) location (Double_t) the location parameter (Default = 0.0)  
◆ TGammaDistribution() [4/4]
| URANIE::DataServer::TGammaDistribution::TGammaDistribution | ( | URANIE::DataServer::TAttribute * | att, | 
| Double_t | alpha, | ||
| Double_t | scale = 1.0,  | 
        ||
| Double_t | location = 0.0  | 
        ||
| ) | 
Construction of a TGammaDistribution from an existing TAttribute object.
- Warning
 - this copy constructor is incomplete. Please do not use. (Nicolas Gilardi, 2010.06.11)
 
- Parameters
 - 
  
att (TAttribute *) Pointer to an existing TAttribute object alpha (Double_t) the shape parameter \( \alpha \) scale (Double_t) the scale parameter (Default = 0.0) location (Double_t) the location parameter (Default = 0.0)  
◆ ~TGammaDistribution()
      
  | 
  virtual | 
Default destructor.
Referenced by ClassImp().
Member Function Documentation
◆ computeTheoreticalInformation()
      
  | 
  virtual | 
Computes the theoretical values of various statistical measures.
Implements URANIE::DataServer::TStochasticAttribute.
Referenced by ClassImp().
◆ getCDF()
      
  | 
  virtual | 
Returns the cumulative distribution for the value x.
- Parameters
 - 
  
x (Double_t) An acceptable value for the attribute  
Implements URANIE::DataServer::TStochasticAttribute.
Referenced by ClassImp().
◆ getInvCDF()
      
  | 
  virtual | 
Returns the value corresponding to the cumulative density p.
- Parameters
 - 
  
p (Double_t) A valid probability  
- Exceptions
 - 
  
UErrorExceptions if p is outside of the interval [0,1]  
Implements URANIE::DataServer::TStochasticAttribute.
Referenced by ClassImp().
◆ getParameterAlpha()
      
  | 
  inline | 
Return the shape parameter.
◆ getParameterLocation()
      
  | 
  inline | 
Return the location parameter.
References _dparameterLocation.
◆ getParameterScale()
      
  | 
  inline | 
Return the scale parameter.
References _dparameterScale.
◆ getPDF()
      
  | 
  virtual | 
Returns the probability density for the value x.
- Parameters
 - 
  
x (Double_t) An acceptable value for the attribute  
Implements URANIE::DataServer::TStochasticAttribute.
Referenced by ClassImp().
◆ printLog()
      
  | 
  virtual | 
◆ setParameterAlpha()
| void URANIE::DataServer::TGammaDistribution::setParameterAlpha | ( | Double_t | alpha, | 
| Bool_t | recompute = kTRUE  | 
        ||
| ) | 
Set alpha value.
- Parameters
 - 
  
alpha (double) : value of alpha to be used recompute (bool, default=true) : recompute the theoretical properties  
Referenced by ClassImp().
◆ setParameterLocation()
| void URANIE::DataServer::TGammaDistribution::setParameterLocation | ( | Double_t | location, | 
| Bool_t | recompute = kTRUE  | 
        ||
| ) | 
Set location value.
Change the minimum used (default being 0)
- Parameters
 - 
  
location (double) : value of location to be used recompute (bool, default=true) : recompute the theoretical properties  
Referenced by ClassImp().
◆ setParameters()
      
  | 
  virtual | 
Set all the parameters.
- Parameters
 - 
  
lambda (Double_t) the rate parameter \( \lambda \) mode (Double_t) the mode parameter \( x_{min} \) (Default = 0.0) 
recompute (Bool_t) should we recompute the theoretical information ? (Default = kTRUE)  
Referenced by ClassImp().
◆ setParameterScale()
| void URANIE::DataServer::TGammaDistribution::setParameterScale | ( | Double_t | scale, | 
| Bool_t | recompute = kTRUE  | 
        ||
| ) | 
Set scale value.
- Parameters
 - 
  
scale (double) : value of scale to be used recompute (bool, default=true) : recompute the theoretical properties  
Referenced by ClassImp().
Member Data Documentation
◆ _dparameterAlpha
      
  | 
  private | 
the shape parameter
Referenced by ClassImp().
◆ _dparameterLocation
      
  | 
  private | 
the location parameter
Referenced by ClassImp(), and getParameterLocation().
◆ _dparameterScale
      
  | 
  private | 
the scale parameter
Referenced by ClassImp(), and getParameterScale().
            
            
 Public Member Functions inherited from